PHP Класс Webiny\Component\EventManager\Event

Each time an event is fired, an instance of Event class is passed to handlers. By extending this class you can implement your own event class and expand it with whatever functionality you might need.
Наследование: implements ArrayAccess, implements IteratorAggregate, use trait Webiny\Component\StdLib\StdLibTrait
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
__construct ( $eventData = null )
__get ( string $name ) : mixed Access internal data as if it was a real object
__isset ( string $name ) : boolean Override __isset
__set ( string $name, mixed $value ) : void Set internal data as if it was a real object
__unset ( string $name ) : void Override __unset
get ( string $name, mixed $default = null ) : mixed Get value or return $default if there is no element set.
getIterator ( ) : Traversable (PHP 5 >= 5.0.0)
Retrieve an external iterator
isPropagationStopped ( ) : boolean Check if propagation for this event is stopped
offsetExists ( mixed $offset ) : boolean (PHP 5 >= 5.0.0)
Whether a offset exists
offsetGet ( mixed $offset ) : mixed (PHP 5 >= 5.0.0)
Offset to retrieve
offsetSet ( mixed $offset, mixed $value ) : void (PHP 5 >= 5.0.0)
Offset to set
offsetUnset ( mixed $offset ) : void (PHP 5 >= 5.0.0)
Offset to unset
stopPropagation ( ) : void Stops the propagation of the event to further event listeners.
toArray ( ) : array Get event data in form of an array

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

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

public __construct ( $eventData = null )

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

Access internal data as if it was a real object
public __get ( string $name ) : mixed
$name string
Результат mixed

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

Override __isset
public __isset ( string $name ) : boolean
$name string
Результат boolean

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

Set internal data as if it was a real object
public __set ( string $name, mixed $value ) : void
$name string
$value mixed
Результат void

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

Override __unset
public __unset ( string $name ) : void
$name string
Результат void

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

Get value or return $default if there is no element set.
public get ( string $name, mixed $default = null ) : mixed
$name string
$default mixed
Результат mixed Config value or default value

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

(PHP 5 >= 5.0.0)
Retrieve an external iterator
public getIterator ( ) : Traversable
Результат Traversable An instance of an object implementing Iterator or Traversable

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

Check if propagation for this event is stopped
public isPropagationStopped ( ) : boolean
Результат boolean

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

(PHP 5 >= 5.0.0)
Whether a offset exists
public offsetExists ( mixed $offset ) : boolean
$offset mixed

An offset to check for.

Результат boolean true on success or false on failure.

The return value will be casted to boolean if non-boolean was returned.

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

(PHP 5 >= 5.0.0)
Offset to retrieve
public offsetGet ( mixed $offset ) : mixed
$offset mixed

The offset to retrieve.

Результат mixed Can return all value types.

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

(PHP 5 >= 5.0.0)
Offset to set
public offsetSet ( mixed $offset, mixed $value ) : void
$offset mixed

The offset to assign the value to.

$value mixed

The value to set.

Результат void

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

(PHP 5 >= 5.0.0)
Offset to unset
public offsetUnset ( mixed $offset ) : void
$offset mixed
Результат void

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

After stopPropagation() is called, no other listeners will be processed.
public stopPropagation ( ) : void
Результат void

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

Get event data in form of an array
public toArray ( ) : array
Результат array Event data array