/** * @param Query $query * @return Collection */ public function find(Query $query) { $result = new Collection(); foreach ($this->collection as $token) { if ($query->isValid($token)) { $result[] = $token; } } return $result; }