EventManager/FilterChain.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework
LICENSE This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_EventManager  

\Zend_EventManager_FilterChain

Package: Zend_EventManager
FilterChain: intercepting filter manager
Implements
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Properties

>VPropertyprotected\Zend_EventManager_Filter_FilterIterator $filters

All filters

Methods

methodpublic__construct() : void

Constructor

Initializes Zend_EventManager_Filter_FilterIterator in which filters will be aggregated
methodpublicattach(callback $callback, int $priority = 1) : \Zend_Stdlib_CallbackHandler

Connect a filter to the chain

Parameters
NameTypeDescription
$callbackcallback

PHP Callback

$priorityint

Priority in the queue at which to execute; defaults to 1 (higher numbers == higher priority)

Returns
TypeDescription
\Zend_Stdlib_CallbackHandler(to allow later unsubscribe)
methodpublicclearFilters() : void

Clear all filters

methodpublicdetach(\Zend_Stdlib_CallbackHandler $filter) : bool

Detach a filter from the chain

Parameters
NameTypeDescription
$filter\Zend_Stdlib_CallbackHandler
Returns
TypeDescription
boolReturns true if filter found and unsubscribed; returns false otherwise
methodpublicgetFilters() : \Zend_EventManager_Filter_FilterIterator

Retrieve all filters

methodpublicgetResponses() : null | \Zend_EventManager_ResponseCollection

Return current responses

Only available while the chain is still being iterated. Returns the current ResponseCollection.
Returns
TypeDescription
null | \Zend_EventManager_ResponseCollection
methodpublicrun(mixed $context, mixed $argv = array()) : mixed

Apply the filters

Begins iteration of the filters.
Parameters
NameTypeDescription
$contextmixed

Object under observation

$argvmixed

Associative array of arguments

Returns
TypeDescription
mixed
Documentation was generated by phpDocumentor 2.2.0 .