original_string: public function getFilters()
      {
          $filters = [];
  
          $names = explode('_', $this->name);
          $base = '';
          $filters = [];
          while ($name = array_shift($names)) {
              $filter = $this->_searchInControllerDir($base, 'filter.yml');
              if ($filter) $filters[] = $filter;
  
              // when has rest.
              if (count($names) > 0) {
                  $base = $base . DS . ucfirst($name);
  
              // when last.
              } else {
                  $filter = $this->_searchInControllerDir($base, "{$name}.filter.yml");
                  if ($filter) $filters[] = $filter;
              }
          }
  
          return $filters;
      }
code: public function getFilters()
      {
          $filters = [];
  
          $names = explode('_', $this->name);
          $base = '';
          $filters = [];
          while ($name = array_shift($names)) {
              $filter = $this->_searchInControllerDir($base, 'filter.yml');
              if ($filter) $filters[] = $filter;
  
              // when has rest.
              if (count($names) > 0) {
                  $base = $base . DS . ucfirst($name);
  
              // when last.
              } else {
                  $filter = $this->_searchInControllerDir($base, "{$name}.filter.yml");
                  if ($filter) $filters[] = $filter;
              }
          }
  
          return $filters;
      }
code_tokens: public function getFilters ( ) { $ filters = [ ] ; $ names = explode ( '_' , $ this -> name ) ; $ base = '' ; $ filters = [ ] ; while ( $ name = array_shift ( $ names ) ) { $ filter = $ this -> _searchInControllerDir ( $ base , 'filter.yml' ) ; if ( $ filter ) $ filters [ ] = $ filter ; // when has rest. if ( count ( $ names ) > 0 ) { $ base = $ base . DS . ucfirst ( $ name ) ; // when last. } else { $ filter = $ this -> _searchInControllerDir ( $ base , "{$name}.filter.yml" ) ; if ( $ filter ) $ filters [ ] = $ filter ; } } return $ filters ; }
docstring: Get filter paths
  
  1. Controller/filter.yml
  2. Controller/foo.filter.yml
docstring_tokens: Get filter paths