Doctrine\MongoDB\Query\Query::count PHP Method

count() public method

If the query resulted in a Cursor, the $foundOnly parameter will ignore limit/skip values if false (the default). If the Query resulted in an EagerCursor or ArrayIterator, the $foundOnly parameter has no effect.
public count ( boolean $foundOnly = false ) : integer
$foundOnly boolean
return integer
    public function count($foundOnly = false)
    {
        return $this->getIterator()->count($foundOnly);
    }