| @@ 41-48 (lines=8) @@ | ||
| 38 | /** |
|
| 39 | * {@inheritdoc} |
|
| 40 | */ |
|
| 41 | public function aggregate(array $pipeline, array $options = []) |
|
| 42 | { |
|
| 43 | $query = $this->prepareQuery(__FUNCTION__, null, $pipeline, $options); |
|
| 44 | $result = parent::aggregate($query->getData(), $query->getOptions()); |
|
| 45 | $this->notifyQueryExecution($query); |
|
| 46 | ||
| 47 | return $result; |
|
| 48 | } |
|
| 49 | ||
| 50 | /** |
|
| 51 | * {@inheritdoc} |
|
| @@ 53-60 (lines=8) @@ | ||
| 50 | /** |
|
| 51 | * {@inheritdoc} |
|
| 52 | */ |
|
| 53 | public function count($filter = [], array $options = []) |
|
| 54 | { |
|
| 55 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 56 | $result = parent::count($query->getFilters(), $query->getOptions()); |
|
| 57 | $this->notifyQueryExecution($query); |
|
| 58 | ||
| 59 | return $result; |
|
| 60 | } |
|
| 61 | ||
| 62 | /** |
|
| 63 | * {@inheritdoc} |
|
| @@ 65-72 (lines=8) @@ | ||
| 62 | /** |
|
| 63 | * {@inheritdoc} |
|
| 64 | */ |
|
| 65 | public function find($filter = [], array $options = []) |
|
| 66 | { |
|
| 67 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 68 | $result = parent::find($query->getFilters(), $query->getOptions()); |
|
| 69 | $this->notifyQueryExecution($query); |
|
| 70 | ||
| 71 | return $result; |
|
| 72 | } |
|
| 73 | ||
| 74 | /** |
|
| 75 | * {@inheritdoc} |
|
| @@ 77-84 (lines=8) @@ | ||
| 74 | /** |
|
| 75 | * {@inheritdoc} |
|
| 76 | */ |
|
| 77 | public function findOne($filter = [], array $options = []) |
|
| 78 | { |
|
| 79 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 80 | $result = parent::findOne($query->getFilters(), $query->getOptions()); |
|
| 81 | $this->notifyQueryExecution($query); |
|
| 82 | ||
| 83 | return $result; |
|
| 84 | } |
|
| 85 | ||
| 86 | /** |
|
| 87 | * {@inheritdoc} |
|
| @@ 89-96 (lines=8) @@ | ||
| 86 | /** |
|
| 87 | * {@inheritdoc} |
|
| 88 | */ |
|
| 89 | public function findOneAndUpdate($filter, $update, array $options = []) |
|
| 90 | { |
|
| 91 | $query = $this->prepareQuery(__FUNCTION__, $filter, $update, $options); |
|
| 92 | $result = parent::findOneAndUpdate($query->getFilters(), $query->getData(), $query->getOptions()); |
|
| 93 | $this->notifyQueryExecution($query); |
|
| 94 | ||
| 95 | return $result; |
|
| 96 | } |
|
| 97 | ||
| 98 | /** |
|
| 99 | * {@inheritdoc} |
|
| @@ 101-108 (lines=8) @@ | ||
| 98 | /** |
|
| 99 | * {@inheritdoc} |
|
| 100 | */ |
|
| 101 | public function findOneAndDelete($filter, array $options = []) |
|
| 102 | { |
|
| 103 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 104 | $result = parent::findOneAndDelete($query->getFilters(), $query->getOptions()); |
|
| 105 | $this->notifyQueryExecution($query); |
|
| 106 | ||
| 107 | return $result; |
|
| 108 | } |
|
| 109 | ||
| 110 | /** |
|
| 111 | * {@inheritdoc} |
|
| @@ 113-120 (lines=8) @@ | ||
| 110 | /** |
|
| 111 | * {@inheritdoc} |
|
| 112 | */ |
|
| 113 | public function deleteMany($filter, array $options = []) |
|
| 114 | { |
|
| 115 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 116 | $result = parent::deleteMany($query->getFilters(), $query->getOptions()); |
|
| 117 | $this->notifyQueryExecution($query); |
|
| 118 | ||
| 119 | return $result; |
|
| 120 | } |
|
| 121 | ||
| 122 | /** |
|
| 123 | * {@inheritdoc} |
|
| @@ 125-132 (lines=8) @@ | ||
| 122 | /** |
|
| 123 | * {@inheritdoc} |
|
| 124 | */ |
|
| 125 | public function deleteOne($filter, array $options = []) |
|
| 126 | { |
|
| 127 | $query = $this->prepareQuery(__FUNCTION__, $filter, null, $options); |
|
| 128 | $result = parent::deleteOne($query->getFilters(), $query->getOptions()); |
|
| 129 | $this->notifyQueryExecution($query); |
|
| 130 | ||
| 131 | return $result; |
|
| 132 | } |
|
| 133 | ||
| 134 | /** |
|
| 135 | * {@inheritdoc} |
|
| @@ 137-144 (lines=8) @@ | ||
| 134 | /** |
|
| 135 | * {@inheritdoc} |
|
| 136 | */ |
|
| 137 | public function replaceOne($filter, $replacement, array $options = []) |
|
| 138 | { |
|
| 139 | $query = $this->prepareQuery(__FUNCTION__, $filter, $replacement, $options); |
|
| 140 | $result = parent::replaceOne($query->getFilters(), $query->getData(), $query->getOptions()); |
|
| 141 | $this->notifyQueryExecution($query); |
|
| 142 | ||
| 143 | return $result; |
|
| 144 | } |
|
| 145 | ||
| 146 | /** |
|
| 147 | * {@inheritdoc} |
|
| @@ 149-156 (lines=8) @@ | ||
| 146 | /** |
|
| 147 | * {@inheritdoc} |
|
| 148 | */ |
|
| 149 | public function insertOne($document, array $options = []) |
|
| 150 | { |
|
| 151 | $query = $this->prepareQuery(__FUNCTION__, [], $document, $options); |
|
| 152 | $result = parent::insertOne($query->getData(), $query->getOptions()); |
|
| 153 | $this->notifyQueryExecution($query); |
|
| 154 | ||
| 155 | return $result; |
|
| 156 | } |
|
| 157 | ||
| 158 | /** |
|
| 159 | * {@inheritdoc} |
|
| @@ 161-168 (lines=8) @@ | ||
| 158 | /** |
|
| 159 | * {@inheritdoc} |
|
| 160 | */ |
|
| 161 | public function updateOne($filter, $update, array $options = []) |
|
| 162 | { |
|
| 163 | $query = $this->prepareQuery(__FUNCTION__, $filter, $update, $options); |
|
| 164 | $result = parent::updateOne($query->getFilters(), $query->getData(), $query->getOptions()); |
|
| 165 | $this->notifyQueryExecution($query); |
|
| 166 | ||
| 167 | return $result; |
|
| 168 | } |
|
| 169 | ||
| 170 | /** |
|
| 171 | * {@inheritdoc} |
|
| @@ 173-180 (lines=8) @@ | ||
| 170 | /** |
|
| 171 | * {@inheritdoc} |
|
| 172 | */ |
|
| 173 | public function distinct($fieldName, $filter = [], array $options = []) |
|
| 174 | { |
|
| 175 | $query = $this->prepareQuery(__FUNCTION__, $filter, ['fieldName' => $fieldName], $options); |
|
| 176 | $result = parent::distinct($fieldName, $query->getFilters(), $query->getOptions()); |
|
| 177 | $this->notifyQueryExecution($query); |
|
| 178 | ||
| 179 | return $result; |
|
| 180 | } |
|
| 181 | ||
| 182 | /** |
|
| 183 | * @param string $method |
|