| @@ 1156-1158 (lines=3) @@ | ||
| 1153 | */ |
|
| 1154 | public function update($col, $cond, $data, $flags = 0, $cb = null, $params = []) |
|
| 1155 | { |
|
| 1156 | if (mb_orig_strpos($col, '.') === false) { |
|
| 1157 | $col = $this->dbname . '.' . $col; |
|
| 1158 | } |
|
| 1159 | ||
| 1160 | if (is_string($cond)) { |
|
| 1161 | $cond = new \MongoCode($cond); |
|
| @@ 1276-1278 (lines=3) @@ | ||
| 1273 | */ |
|
| 1274 | public function insert($col, $doc = [], $cb = null, $params = []) |
|
| 1275 | { |
|
| 1276 | if (mb_orig_strpos($col, '.') === false) { |
|
| 1277 | $col = $this->dbname . '.' . $col; |
|
| 1278 | } |
|
| 1279 | ||
| 1280 | if (!isset($doc['_id'])) { |
|
| 1281 | $doc['_id'] = new \MongoId; |
|
| @@ 1341-1343 (lines=3) @@ | ||
| 1338 | */ |
|
| 1339 | public function insertMulti($col, $docs = [], $cb = null, $params = []) |
|
| 1340 | { |
|
| 1341 | if (mb_orig_strpos($col, '.') === false) { |
|
| 1342 | $col = $this->dbname . '.' . $col; |
|
| 1343 | } |
|
| 1344 | ||
| 1345 | $ids = []; |
|
| 1346 | $bson = ''; |
|
| @@ 1390-1392 (lines=3) @@ | ||
| 1387 | */ |
|
| 1388 | public function remove($col, $cond = [], $cb = null, $params = []) |
|
| 1389 | { |
|
| 1390 | if (mb_orig_strpos($col, '.') === false) { |
|
| 1391 | $col = $this->dbname . '.' . $col; |
|
| 1392 | } |
|
| 1393 | ||
| 1394 | if (is_string($cond)) { |
|
| 1395 | $cond = new \MongoCode($cond); |
|
| @@ 1435-1437 (lines=3) @@ | ||
| 1432 | */ |
|
| 1433 | public function getMore($col, $id, $number, $conn) |
|
| 1434 | { |
|
| 1435 | if (mb_orig_strpos($col, '.') === false) { |
|
| 1436 | $col = $this->dbname . '.' . $col; |
|
| 1437 | } |
|
| 1438 | ||
| 1439 | $this->request( |
|
| 1440 | self::OP_GETMORE, |
|