getState()
getState() : mixed
State Interface Status Get
Event Interface - Defines basic event functionality
This interface defines the basic functionality and members that all events share. This serves as the universal event type checker. All recognizable event in the event system must implement this interface.
Technically an event is an object 'state', when the state changes in a publisher, it's like 'triggering' an event.
CHANGELOG
1.0 Created Abstract Event - August 16th, 2013 2.0 Integrated into Primus2 - September 12th, 2015 3.0: reformatted for invlusion in phabstractic - July 29th, 2016
setState( $state)
State Interface Status Set
In an 'event' publisher/observer ecosystem, such as asherwunk/phabstractic/-/event:
Replaces the current state object's data. In order for the observer/publisher pattern to work it is recommended that the caller of this function notifies all observers of the host object.
$state |
setStateWithEvent(\Phabstractic\Event\Resource\Phabstractic\Event\Resource\EventInterface $event, boolean $morph = true)
This sets or morphs an event with new information
If morph is set, the event doesn't clear it's information, and instead overwrites whats already there.
\Phabstractic\Event\Resource\Phabstractic\Event\Resource\EventInterface | $event | The state information encapsulated in an object |
boolean | $morph | Whether we should replace or overwrite the object state |
setStateWithArray(array $state, boolean $morph = true)
This sets or morphs an event with new information
If morph is set, the event doesn't clear it's information, and instead overwrites whats already there.
array | $state | |
boolean | $morph | Whether we should replace or overwrite the object state |