Event
extends AbstractEvent
in package
Generic event class - used by trigger() for any ad-hoc, non-typed event name
Tags
Table of Contents
Properties
- $name : string
- Event name
- $params : array<string|int, mixed>
- Event params
- $propagationStopped : bool
- Propagation stopped flag
Methods
- __construct() : mixed
- Constructor
- get() : mixed
- Get a single param by key
- getName() : string
- Get the event name
- isPropagationStopped() : bool
- Determine if propagation of this event has been stopped
- stopPropagation() : void
- Stop propagation of this event to any remaining listeners
- toParams() : array<string|int, mixed>
- Get the params array
Properties
$name
Event name
protected
string
$name
$params
Event params
protected
array<string|int, mixed>
$params
$propagationStopped
Propagation stopped flag
protected
bool
$propagationStopped
= false
Methods
__construct()
Constructor
public
__construct(string $name[, array<string|int, mixed> $params = [] ]) : mixed
Instantiate the generic event object.
Parameters
- $name : string
- $params : array<string|int, mixed> = []
get()
Get a single param by key
public
get(string $key) : mixed
Parameters
- $key : string
getName()
Get the event name
public
getName() : string
Return values
stringisPropagationStopped()
Determine if propagation of this event has been stopped
public
isPropagationStopped() : bool
Return values
boolstopPropagation()
Stop propagation of this event to any remaining listeners
public
stopPropagation() : void
toParams()
Get the params array
public
toParams() : array<string|int, mixed>