HijackAccountEventSink Class Reference
EventSink to deal with system update. More...
Inheritance diagram for
HijackAccountEventSink:
Public Member Functions |
|
on_event ($event_name, $event_params, &$result) | |
Invoked to handle events. |
Detailed Description
EventSink to deal with system update.
Definition at line 5 of file hijackaccount.eventsink.php.
Member Function Documentation
HijackAccountEventSink::on_event | ( | $ | event_name, | |
$ | event_params, | |||
&$ | result | |||
) |
Invoked to handle events.
Events can be anything, and they are invoked through the router One event is "cron", it has no parameters
- Parameters:
-
string Event name mixed Event parameter(s)
Implements IEventSink.
Definition at line 15 of file hijackaccount.eventsink.php.
00015 { 00016 switch ($event_name) { 00017 case 'get_actions': 00018 $source = $event_params['source']; 00019 $contextes = array('view', 'list'); 00020 if ($source instanceof DAOUsers && in_array($event_params['context'], $contextes)) { 00021 $result['hijack'] = tr('Hijack Account', 'hijackaccount'); 00022 } 00023 break; 00024 case 'notifications_collect_sources': 00025 $result['usermanagement.hijackaccount'] = tr('usermanagement.hijackaccount', 'hijackaccount'); 00026 break; 00027 case 'notifications_translate': 00028 if ($event_params == 'usermanagement.hijackaccount') { 00029 $result = tr('usermanagement.hijackaccount', 'hijackaccount'); 00030 } 00031 break; 00032 } 00033 }
The documentation for this class was generated from the following file:
- contributions/usermanagement.hijackaccount/behaviour/base/hijackaccount.eventsink.php