original_string: public function filter($className, $parameters = array())
      {
          if ($className instanceof \Closure
              || is_array($className)
          ) {
              array_unshift($parameters, $this);
              call_user_func_array($className, $parameters);
              return;
          }
  
          if (in_array($className, $this->disabledFilters)) {
              return;
          }
  
          if (!class_exists($className, true)) {
              $className = 'Piwik\DataTable\Filter\\' . $className;
          }
          $reflectionObj = new ReflectionClass($className);
  
          // the first parameter of a filter is the DataTable
          // we add the current datatable as the parameter
          $parameters = array_merge(array($this), $parameters);
  
          $filter = $reflectionObj->newInstanceArgs($parameters);
  
          $filter->enableRecursive($this->enableRecursiveFilters);
  
          $filter->filter($this);
      }
code: public function filter($className, $parameters = array())
      {
          if ($className instanceof \Closure
              || is_array($className)
          ) {
              array_unshift($parameters, $this);
              call_user_func_array($className, $parameters);
              return;
          }
  
          if (in_array($className, $this->disabledFilters)) {
              return;
          }
  
          if (!class_exists($className, true)) {
              $className = 'Piwik\DataTable\Filter\\' . $className;
          }
          $reflectionObj = new ReflectionClass($className);
  
          // the first parameter of a filter is the DataTable
          // we add the current datatable as the parameter
          $parameters = array_merge(array($this), $parameters);
  
          $filter = $reflectionObj->newInstanceArgs($parameters);
  
          $filter->enableRecursive($this->enableRecursiveFilters);
  
          $filter->filter($this);
      }
code_tokens: public function filter ( $ className , $ parameters = array ( ) ) { if ( $ className instanceof \ Closure || is_array ( $ className ) ) { array_unshift ( $ parameters , $ this ) ; call_user_func_array ( $ className , $ parameters ) ; return ; } if ( in_array ( $ className , $ this -> disabledFilters ) ) { return ; } if ( ! class_exists ( $ className , true ) ) { $ className = 'Piwik\DataTable\Filter\\' . $ className ; } $ reflectionObj = new ReflectionClass ( $ className ) ; // the first parameter of a filter is the DataTable // we add the current datatable as the parameter $ parameters = array_merge ( array ( $ this ) , $ parameters ) ; $ filter = $ reflectionObj -> newInstanceArgs ( $ parameters ) ; $ filter -> enableRecursive ( $ this -> enableRecursiveFilters ) ; $ filter -> filter ( $ this ) ; }
docstring: Applies a filter to this datatable.
  
  If {@link enableRecursiveFilters()} was called, the filter will be applied
  to all subtables as well.
  
  @param string|Closure $className Class name, eg. `"Sort"` or "Piwik\DataTable\Filters\Sort"`. If no
  namespace is supplied, `Piwik\DataTable\BaseFilter` is assumed. This parameter
  can also be a closure that takes a DataTable as its first parameter.
  @param array $parameters Array of extra parameters to pass to the filter.
docstring_tokens: Applies a filter to this datatable .