PHP Class ViMbAdmin_Controller_PluginAction

All application controlers subclass this rather than Zend's version directly.
Inheritance: extends ViMbAdmin_Controller_Action, implements OSS_Plugin_Observable
Afficher le fichier Open project: opensolutions/vimbadmin

Protected Properties

Свойство Type Description
$isEdit boolean Set by the add/edit actions, else null. Can be used by plugins to know if this is an add or edit operation.

Méthodes publiques

Méthode Description
__construct ( Zend_Controller_Request_Abstract $request, Zend_Controller_Response_Abstract $response, array $invokeArgs = null ) Override the Zend_Controller_Action's constructor (which is called at the very beginning of this function anyway).
attach ( OSS_Plugin_Observer $observer ) Attach an instaniated observer
detach ( OSS_Plugin_Observer $observer ) Detach an observer
isEdit ( ) : boolean Getter method for isEdit
notify ( string $controller, string $action, string $hook, OSS_Controller_Action $controllerObject, object $params = null ) Give any observers a chance to execute their plugin code

Méthodes protégées

Méthode Description
loadObservers ( $path ) Loads any found plugin and instaniates it (unless disabled by configuration).
registerObservers ( ) Registers any plugins found in the main plugin directory as well as modules.

Method Details

__construct() public méthode

Override the Zend_Controller_Action's constructor (which is called at the very beginning of this function anyway).
public __construct ( Zend_Controller_Request_Abstract $request, Zend_Controller_Response_Abstract $response, array $invokeArgs = null )
$request Zend_Controller_Request_Abstract See Parent class constructor
$response Zend_Controller_Response_Abstract See Parent class constructor
$invokeArgs array See Parent class constructor

attach() public méthode

Attach an instaniated observer
public attach ( OSS_Plugin_Observer $observer )
$observer OSS_Plugin_Observer

detach() public méthode

Detach an observer
public detach ( OSS_Plugin_Observer $observer )
$observer OSS_Plugin_Observer

isEdit() public méthode

Getter method for isEdit
public isEdit ( ) : boolean
Résultat boolean

loadObservers() protected méthode

Loads any found plugin and instaniates it (unless disabled by configuration).
protected loadObservers ( $path )

notify() public méthode

Give any observers a chance to execute their plugin code
public notify ( string $controller, string $action, string $hook, OSS_Controller_Action $controllerObject, object $params = null )
$controller string The controller name (e.g. 'mailbox', 'alias', etc
$action string The action name (e.g. 'add', 'edit', etc)
$hook string The name of the hook to add (e.g. 'preSave')
$controllerObject OSS_Controller_Action The controller object
$params object An optional anonymous object ( http://www.barryodonovan.com/index.php/2012/07/05/anonymous-objects-in-php )

registerObservers() protected méthode

FIXME This is 'autoload' functionality which can be expensive. Keep found plugin list in memcache? FIXME Ordering - allow option to specify desired plugins in config
protected registerObservers ( )

Property Details

$isEdit protected_oe property

Set by the add/edit actions, else null. Can be used by plugins to know if this is an add or edit operation.
protected bool $isEdit
Résultat boolean