original_string: public function search($type, $filename = '', $return = 'relative')
      {
          $matches = array();
          foreach ($this->elements as $location) {
              if (!($location instanceof PathFinder_Location)) {
                  continue;
              }
  
              $path = $location->locate($type, $filename, $return);
  
              if (is_string($path)) {
                  // file found!
                  $matches[] = $path;
              }
          }
  
          return $matches;
      }
code: public function search($type, $filename = '', $return = 'relative')
      {
          $matches = array();
          foreach ($this->elements as $location) {
              if (!($location instanceof PathFinder_Location)) {
                  continue;
              }
  
              $path = $location->locate($type, $filename, $return);
  
              if (is_string($path)) {
                  // file found!
                  $matches[] = $path;
              }
          }
  
          return $matches;
      }
code_tokens: public function search ( $ type , $ filename = '' , $ return = 'relative' ) { $ matches = array ( ) ; foreach ( $ this -> elements as $ location ) { if ( ! ( $ location instanceof PathFinder_Location ) ) { continue ; } $ path = $ location -> locate ( $ type , $ filename , $ return ) ; if ( is_string ( $ path ) ) { // file found! $ matches [ ] = $ path ; } } return $ matches ; }
docstring: Search is similar to locate, but will return array of all matching
  files.
  
  @param string $type     Type of resource to search surch as "php"
  @param string $filename Name of the file to search for
  @param string $return   'relative','url','path' or 'location'
  
  @return string|object as specified by $return
docstring_tokens: Search is similar to locate but will return array of all matching files .