@@ 485-493 (lines=9) @@ | ||
482 | case self::TYPE_REMOVE: |
|
483 | return $this->collection->deleteMany($this->query['query'], $options); |
|
484 | ||
485 | case self::TYPE_DISTINCT: |
|
486 | $collection = $this->collection; |
|
487 | $query = $this->query; |
|
488 | ||
489 | return $collection->distinct( |
|
490 | $query['distinct'], |
|
491 | $query['query'], |
|
492 | array_merge($options, $this->getQueryOptions('readPreference')) |
|
493 | ); |
|
494 | ||
495 | case self::TYPE_COUNT: |
|
496 | $collection = $this->collection; |
|
@@ 495-502 (lines=8) @@ | ||
492 | array_merge($options, $this->getQueryOptions('readPreference')) |
|
493 | ); |
|
494 | ||
495 | case self::TYPE_COUNT: |
|
496 | $collection = $this->collection; |
|
497 | $query = $this->query; |
|
498 | ||
499 | return $collection->count( |
|
500 | $query['query'], |
|
501 | array_merge($options, $this->getQueryOptions('hint', 'limit', 'skip', 'readPreference')) |
|
502 | ); |
|
503 | } |
|
504 | } |
|
505 | } |