WC_Data_Store::__call()publicWC 3.0.0

Data stores can define additional functions (for example, coupons have some helper methods for increasing or decreasing usage). This passes through to the instance if that function exists.

Метод класса: WC_Data_Store{}

Хуков нет.

Возвращает

Разное.

Использование

$WC_Data_Store = new WC_Data_Store();
$WC_Data_Store->__call( $method, $parameters );
$method(строка) (обязательный)
Method.
$parameters(разное) (обязательный)
Parameters.

Список изменений

С версии 3.0.0 Введена.

Код WC_Data_Store::__call() WC 8.7.0

public function __call( $method, $parameters ) {
	if ( is_callable( array( $this->instance, $method ) ) ) {
		$object     = array_shift( $parameters );
		$parameters = array_merge( array( &$object ), $parameters );
		return $this->instance->$method( ...$parameters );
	}
}