Ejemplo n.º 1
0
 /**
  * Iterate the next filter in the chain
  *
  * Iterates and calls the next filter in the chain.
  *
  * @param  mixed $context
  * @param  array $params
  * @param  FilterIterator $chain
  * @return mixed
  */
 public function next($context = null, array $params = array(), $chain = null)
 {
     if (empty($context) || $chain->isEmpty()) {
         return;
     }
     $next = $this->extract();
     if (!$next instanceof CallbackHandler) {
         return;
     }
     $return = call_user_func($next->getCallback(), $context, $params, $chain);
     return $return;
 }
 /**
  * Iterate the next filter in the chain
  *
  * Iterates and calls the next filter in the chain.
  *
  * @param  mixed $context
  * @param  array $params
  * @param  FilterIterator $chain
  * @return mixed
  */
 public function next($context = null, array $params = [], $chain = null)
 {
     if (empty($context) || $chain instanceof FilterIterator && $chain->isEmpty()) {
         return;
     }
     //We can't extract from an empty heap
     if ($this->isEmpty()) {
         return;
     }
     $next = $this->extract();
     if (!$next instanceof CallbackHandler) {
         return;
     }
     $return = call_user_func($next->getCallback(), $context, $params, $chain);
     return $return;
 }
Ejemplo n.º 3
0
 /**
  * Iterate the next filter in the chain
  *
  * Iterates and calls the next filter in the chain.
  *
  * @param  mixed $context
  * @param  array $params
  * @param  FilterIterator $chain
  * @return mixed
  */
 public function next($context = null, array $params = [], $chain = null)
 {
     if (empty($context) || $chain instanceof FilterIterator && $chain->isEmpty()) {
         return;
     }
     //We can't extract from an empty heap
     if ($this->isEmpty()) {
         return;
     }
     $next = $this->extract();
     return $next($context, $params, $chain);
 }