public function count()
{
return (int) $this->collection->getMongoCollection()->count($this->expression->toArray());
}
public function getTotalRowsCount() { if ($this->totalRowsCount) { return $this->totalRowsCount; } $this->totalRowsCount = $this->cursor->count(); return $this->totalRowsCount; }