$identityCounter
$identityCounter : mixed
The Global Identity Generator Marker
When the identity is polled, this marker is 'advanced'. It's static to the class, in that way it's unique for each one.
Generic Event Class - Provides a simple implementation of AbstractEvent
This class provides the member methods necessary to instantiate or inherit an AbstractEvent.
It is recommended that all events inherit from the generic event class to be used in the universal event system
CHANGELOG
1.0 Created Generic Event - August 16th, 2013 2.0 Integrated Generic Event into Primus2 - September 13th, 2015 3.0: reformatted for inclusion in phabstractic - July 29th., 2016
__construct(object $target, string $function, string $class, string $namespace, mixed $data = null, array $tags = array(), array $cats = array())
The Generic Event Constructor
This is implements an event, setting all the necessary fields
object | $target | The target of the event |
string | $function | The function/method generating the event |
string | $class | The class name generating the event if applicable |
string | $namespace | The namespace of the generating point |
mixed | $data | Any data associated with the event |
array | $tags | An array of strings associating the event with a set of tags |
array | $cats | An array of strings associating the event with a set of categories |
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 |
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.
$state must include identifier
array | $state | |
boolean | $morph | Whether we should replace or overwrite the object state |
setStateWithEvent(\Phabstractic\Event\Resource\EventInterface $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.
\Phabstractic\Event\Resource\EventInterface | $state | |
boolean | $morph | Whether we should replace or overwrite the object state |