public function applyExtract(IExtractStrategy $extract)
    {
        $found = [];
        foreach($this->tokens as $token) 
        { 
            if($extract->filter($token)) {
                $found[] = $token;
            }
        }
        return $found;
    }
public function applyExtract(IExtractStrategy $extract)
    {
        $found = [];
        foreach($this->tokens as $token) 
        { 
            if($extract->filter($token)) {
                $found[] = $token;
            }
        }
        return $found;
    }
public function applyExtract ( IExtractStrategy $ extract ) { $ found = [ ] ; foreach ( $ this -> tokens as $ token ) { if ( $ extract -> filter ( $ token ) ) { $ found [ ] = $ token ; } } return $ found ; }
Apply an extract filter and return the results after filter
all the documents in the collection
@param IExtractStrategy $extract
@return array
Apply an extract filter and return the results after filter all the documents in the collection