public function remove(Object $object) { foreach ($this as $index => $item) { if ($item === $object) { $this->removeAt($index); } } }