Manager/GenericDocumentManager.php
public function count(array $filters = [], $query = false)
    {
        $qb = $this->dm->createQueryBuilder($this->document);
        $qb = $this->addFilters($qb, $filters);

        if ($query) {
            $query = $this->getDefault('query', $query);
            $qb = $this->addQuery($qb, $this->queryFields, $query);
        }

        $qb->count();
        $query   = $qb->getQuery();
        $results = $query->execute();

        return $results;
    }
public function count(array $filters = [], $query = false)
    {
        $qb = $this->dm->createQueryBuilder($this->document);
        $qb = $this->addFilters($qb, $filters);

        if ($query) {
            $query = $this->getDefault('query', $query);
            $qb = $this->addQuery($qb, $this->queryFields, $query);
        }

        $qb->count();
        $query   = $qb->getQuery();
        $results = $query->execute();

        return $results;
    }
Get a list documents

@param array $filters

List or conditional selectors http://bit.ly/1efirww

@example filters

[
[
'field' => 'id',
'selector' => 'equals',
'value' => 12
],
…
]

@return MongoCursor