Skip to content

Commit 1c6f730

Browse files
authored
PHPLIB-1192: Remove useCursor option in aggregate (#1130)
* PHPLIB-1192: Remove useCursor option in aggregate * Remove unnecessary property for isExplain
1 parent ffb8946 commit 1c6f730

File tree

2 files changed

+2
-23
lines changed

2 files changed

+2
-23
lines changed

source/includes/apiargs-MongoDBCollection-method-aggregate-option.yaml

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -59,22 +59,6 @@ source:
5959
file: apiargs-MongoDBCollection-common-option.yaml
6060
ref: typeMap
6161
---
62-
arg_name: option
63-
name: useCursor
64-
type: boolean
65-
description: |
66-
Indicates whether the command will request that the server provide results
67-
using a cursor. The default is ``true``.
68-
69-
.. note::
70-
71-
MongoDB 3.6+ no longer supports returning results without a cursor (excluding
72-
when the explain option is used) and specifying false for this option will
73-
result in a server error.
74-
interface: phpmethod
75-
operation: ~
76-
optional: true
77-
---
7862
source:
7963
file: apiargs-MongoDBCollection-common-option.yaml
8064
ref: writeConcern

source/reference/method/MongoDBCollection-aggregate.txt

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,8 @@ Errors/Exceptions
5050
Behavior
5151
--------
5252

53-
:phpmethod:`MongoDB\\Collection::aggregate()`'s return value depends on the
54-
MongoDB server version and whether the ``useCursor`` option is specified. If
55-
``useCursor`` is ``true``, a :php:`MongoDB\\Driver\\Cursor
56-
<class.mongodb-driver-cursor>` object is returned. If ``useCursor`` is
57-
``false``, an :php:`ArrayIterator <arrayiterator>` is returned that wraps the
58-
``result`` array from the command response document. In both cases, the return
59-
value will be :php:`Traversable <traversable>`.
53+
:phpmethod:`MongoDB\\Collection::aggregate()`'s returns a
54+
:php:`MongoDB\\Driver\\Cursor <class.mongodb-driver-cursor>` object.
6055

6156
Examples
6257
--------

0 commit comments

Comments
 (0)