Class Amfphp_Core_FilterManager

Description

This class is a kind of event dispatcher

Filters are provided by Amfphp to allow your contexts to 'filter into' the rest of Amfphp, i.e. to call functions in your context at specific times
This is a singleton, so use getInstance

  • author: Ariel Sommeria-klein

Located in /Amfphp/Core/FilterManager.php (line 19)


	
			
Method Summary
void addFilter (String $filterName, Object $object, String $methodName)
mixed callFilters (String $filterName, parameters 1)
Methods
static method getInstance (line 40)
  • access: public
static Amfphp_Core_FilterManager getInstance ()
addFilter (line 89)

register an object method for the given filter

call this method in your contexts to be notified when the filter occures

void addFilter (String $filterName, Object $object, String $methodName)
  • String $filterName: the name of the filter
  • Object $object: the object on which to call the method
  • String $methodName: the name of the method to call on the object
callFilters (line 56)

call the functions registered for the given filter. There can be as many parameters as necessary, but only the first one can be changed and and returned by the callees.

The other parameters must be considered as context, and should not be modified by the callees, and will not be returned to the caller.

  • return: the first call parameter, as filtered by the callees.
  • access: public
mixed callFilters (String $filterName, parameters 1)
  • String $filterName: the name of the filter which was used in addFilter( a string)
  • parameters 1: for the function call. As many as necessary can be passed, but only the first will be filtered

Documentation generated on Thu, 24 Mar 2011 16:55:40 +0100 by phpDocumentor 1.4.3