symfony entity setmaxresult/limit on array collection
You can use doctrine's Criteria
class to filter/sort/limit your records
public function getShoes() {
$criteria = \Doctrine\Common\Collections\Criteria::create()
->orderBy(array('your_property_to_sort_collection'=> \Doctrine\Common\Collections\Criteria::DESC))
->setMaxResults(5);
return $this->shoes->matching($criteria);
}