class Event
Process queuing/execution class. Allows an unlimited number of callbacks
to be added to 'events'. Events can be run multiple times, and can also
process event-specific data. By default, Kohana has several system events.
$Id: Event.php 4390 2009-06-04 03:05:36Z zombor $ AuthorsVariables
| Name | Visibility | Description |
$data | (static) | |
$events | (static) | |
$has_run | (static) | |
Functions
| Name | Visibility | Description |
| add | public (static) | Add a callback to an event queue. |
| addAfter | public (static) | Add a callback to an event queue, after a given event. |
| addBefore | public (static) | Add a callback to an event queue, before a given event. |
| clear | public (static) | Clear some or all callbacks from an event. |
| get | public (static) | Get all callbacks for an event. |
| hasRun | public (static) | Check if a given event has been run. |
| insertEvent | private (static) | Inserts a new event at a specfic key location. |
| replace | public (static) | Replaces an event with another event. |
| run | public (static) | Execute all of the callbacks attached to an event. |
public addboolean Event::add ( string $name , array $callback );
Add a callback to an event queue. boolean Event::addAfter ( string $name , array $existing , array $callback );
Add a callback to an event queue, after a given event. boolean Event::addBefore ( string $name , array $existing , array $callback );
Add a callback to an event queue, before a given event. void Event::clear ( string $name [, array $callback ] );
Clear some or all callbacks from an event. public getarray Event::get ( string $name );
Get all callbacks for an event. boolean Event::hasRun ( string $name );
Check if a given event has been run. void Event::insertEvent ( string $name , integer $key , array $callback );
Inserts a new event at a specfic key location. boolean Event::replace ( string $name , array $existing , array $callback );
Replaces an event with another event. public runvoid Event::run ( string $name [, array &$data ] );
Execute all of the callbacks attached to an event.
|