WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru Получай пассивный доход от сайта
функция не описана

Yoast\WP\SEO\Presentations

Abstract_Presentation::of() public Yoast 1.0

Creates a model presentation.

{} Это метод класса: Abstract_Presentation{}

Хуков нет.

Возвращает

static. A model presentation.

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

$Abstract_Presentation = new Abstract_Presentation();
$Abstract_Presentation->of( $data );
$data(массив) (обязательный)
The data that this is a presentation of.

Код Abstract_Presentation::of() Yoast 16.8

<?php
public function of( $data ) {
	if ( ! $this->is_prototype() ) {
		throw new Exception( 'Attempting to create a model presentation from another model presentation. Use the prototype presentation gained from DI instead.' );
	}

	// Clone self to allow stateful services that do benefit from DI.
	$presentation = clone $this;
	foreach ( $data as $key => $value ) {
		$presentation->{$key} = $value;
	}
	$presentation->is_prototype = false;
	return $presentation;
}