PHP Класс Elgg\WidgetDefinition

Helper class for defining a widget
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$context In which contexts is the widget available
$description Description of the widget
$id Identifier of the widget
$multiple Can the widget be added multiple times
$name Readable name of the widget

Открытые методы

Метод Описание
__construct ( string $id ) WidgetDefinition constructor
__get ( string $name ) : mixed Magic getter to return the deprecated attribute 'handler'
factory ( array $options ) : WidgetDefinition Create an WidgetDefinition from an associative array. Required key is id.

Описание методов

__construct() публичный Метод

WidgetDefinition constructor
public __construct ( string $id )
$id string Identifier of the widget

__get() публичный Метод

Magic getter to return the deprecated attribute 'handler'
public __get ( string $name ) : mixed
$name string attribute to get
Результат mixed

factory() публичный статический Метод

Create an WidgetDefinition from an associative array. Required key is id.
public static factory ( array $options ) : WidgetDefinition
$options array Option array of key value pairs id => STR Widget identifier (required) name => STR Name of the widget description => STR Description of the widget context => ARRAY contexts in which the widget is available multiple => BOOL can the widget be added multiple times
Результат WidgetDefinition

Описание свойств

$context публичное свойство

In which contexts is the widget available
public $context

$description публичное свойство

Description of the widget
public $description

$id публичное свойство

Identifier of the widget
public $id

$multiple публичное свойство

Can the widget be added multiple times
public $multiple

$name публичное свойство

Readable name of the widget
public $name