Skip to content

Commit 15ee46b

Browse files
committed
Merge pull request #276
2 parents 416c06f + 1a964b4 commit 15ee46b

File tree

175 files changed

+3707
-2461
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

175 files changed

+3707
-2461
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
arg_name: option
2+
name: typeMap
3+
type: array
4+
description: |
5+
Default :php:`type map
6+
<manual/en/mongodb.persistence.deserialization.php#mongodb.persistence.typemaps>`
7+
to apply to cursors, which determines how BSON documents are converted to PHP
8+
values. The |php-library| uses the following type map by default:
9+
10+
.. code-block:: php
11+
12+
[
13+
'array' => 'MongoDB\Model\BSONArray',
14+
'document' => 'MongoDB\Model\BSONDocument',
15+
'root' => 'MongoDB\Model\BSONDocument',
16+
]
17+
interface: phpmethod
18+
operation: ~
19+
optional: true
20+
...

source/includes/apiargs-MongoDBClient-method-construct-param.yaml

Lines changed: 21 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -2,46 +2,41 @@ arg_name: param
22
name: $uri
33
type: string
44
description: |
5-
The URI of the standalone, replica set, or sharded cluster to which to connect. Refer
6-
to the :manual:`MongoDB connection string reference </reference/connection-string>`
7-
for formatting.
8-
9-
Defaults to ``mongodb://localhost:27017`` if unspecified.
5+
The URI of the standalone, replica set, or sharded cluster to which to
6+
connect. Refer to the :manual:`MongoDB connection string reference
7+
</reference/connection-string>` for formatting.
8+
9+
Defaults to ``"mongodb://127.0.0.1:27017"`` if unspecified.
1010
interface: phpmethod
11-
operation: MongoDB\\Client::__construct
11+
operation: ~
1212
optional: true
13-
position: 1
1413
---
1514
arg_name: param
1615
name: $uriOptions
1716
type: array
1817
description: |
19-
Specifies additional URI options, such as authentication credentials
20-
or query string parameters. The options specified in ``$uriOptions``
21-
take precedence over any analogous options present in the
22-
``$uri`` string.
23-
post: |
18+
Specifies additional URI options, such as authentication credentials or query
19+
string parameters. The options specified in ``$uriOptions`` take precedence
20+
over any analogous options present in the ``$uri`` string.
21+
2422
Refer to the :php:`MongoDB\\Driver\\Manager::__construct()
25-
<mongodb-driver-manager.construct>` extension reference and
26-
:manual:`MongoDB connection string </reference/connection-string>`
27-
documentation for valid options.
23+
<mongodb-driver-manager.construct>` extension reference and :manual:`MongoDB
24+
connection string </reference/connection-string>` documentation for accepted
25+
options.
2826
interface: phpmethod
29-
operation: MongoDB\\Client::__construct
27+
operation: ~
3028
optional: true
31-
position: 2
3229
---
3330
arg_name: param
3431
name: $driverOptions
3532
type: array
3633
description: |
37-
Specify driver-specific options. In addition to any
38-
options supported by the :php:`extension <mongodb-driver-manager>`,
39-
the |php-library| allows you to specify a default ``typeMap`` to
40-
apply to the cursors it creates. Refer to the driver's
41-
:php:`Persistence documentation <mongodb-persistence>` for more
42-
about type maps.
34+
Specify driver-specific options, such as SSL options. In addition to any
35+
options supported by the :php:`extension <mongodb-driver-manager>`, the
36+
|php-library| allows you to specify a default :php:`type map
37+
<manual/en/mongodb.persistence.deserialization.php#mongodb.persistence.typemaps>`
38+
to apply to the cursors it creates.
4339
interface: phpmethod
44-
operation: MongoDB\\Client::__construct
40+
operation: ~
4541
optional: true
46-
position: 3
47-
...
42+
...
Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,19 @@
1-
arg_name: option
2-
interface: phpmethod
3-
operation: MongoDB\\Client::dropDatabase
41
source:
52
file: apiargs-common-option.yaml
63
ref: typeMap
7-
position: 1
4+
post: |
5+
This will be used for the returned command result document.
6+
---
7+
arg_name: option
8+
name: writeConcern
9+
type: :php:`MongoDB\\Driver\\WriteConcern <class.mongodb-driver-writeconcern>`
10+
description: |
11+
:manual:`Write concern </reference/write-concern>` to use for the operation.
12+
Defaults to the client's write concern.
13+
14+
This is not supported for server versions prior to 3.4 and will result in an
15+
exception at execution time if used.
16+
interface: phpmethod
17+
operation: ~
18+
optional: true
819
...
Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,10 @@
11
source:
2-
ref: $databaseName
32
file: apiargs-common-param.yaml
4-
arg_name: param
5-
interface: phpmethod
6-
operation: MongoDB\\Client::dropDatabase
3+
ref: $databaseName
4+
replacement:
5+
action: " to drop"
76
---
87
source:
9-
ref: $options
108
file: apiargs-common-param.yaml
11-
arg_name: param
12-
interface: phpmethod
13-
operation: MongoDB\\Client::dropDatabase
14-
position: 2
9+
ref: $options
1510
...
Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
source:
2-
ref: $databaseName
32
file: apiargs-common-param.yaml
4-
arg_name: param
5-
interface: phpmethod
6-
operation: MongoDB\\Client::__get
3+
ref: $databaseName
4+
replacement:
5+
action: " to select"
76
...
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
source:
22
file: apiargs-common-option.yaml
33
ref: maxTimeMS
4-
position: 1
54
...
Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
source:
2-
ref: $options
32
file: apiargs-common-param.yaml
4-
arg_name: param
5-
interface: phpmethod
6-
operation: MongoDB\\Client::listDatabases
7-
position: 1
3+
ref: $options
84
...
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
source:
2+
file: apiargs-common-option.yaml
3+
ref: readConcern
4+
replacement:
5+
resource: "collection"
6+
parent: "client"
7+
---
8+
source:
9+
file: apiargs-common-option.yaml
10+
ref: readPreference
11+
replacement:
12+
resource: "collection"
13+
parent: "client"
14+
---
15+
source:
16+
file: apiargs-common-option.yaml
17+
ref: typeMap
18+
replacement:
19+
parent: "client"
20+
---
21+
source:
22+
file: apiargs-common-option.yaml
23+
ref: writeConcern
24+
replacement:
25+
resource: "collection"
26+
parent: "client"
27+
...
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
source:
2+
file: apiargs-common-param.yaml
3+
ref: $databaseName
4+
replacement:
5+
action: " containing the collection to select"
6+
---
7+
source:
8+
file: apiargs-common-param.yaml
9+
ref: $collectionName
10+
replacement:
11+
action: " to select"
12+
---
13+
source:
14+
file: apiargs-common-param.yaml
15+
ref: $options
16+
...
Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,27 @@
11
source:
2-
ref: readConcern
32
file: apiargs-common-option.yaml
4-
operation: MongoDB\\Client::selectDatabase
3+
ref: readConcern
54
replacement:
65
resource: "database"
6+
parent: "client"
77
---
88
source:
9-
ref: readPreference
109
file: apiargs-common-option.yaml
11-
operation: MongoDB\\Client::selectDatabase
10+
ref: readPreference
1211
replacement:
1312
resource: "database"
13+
parent: "client"
1414
---
1515
source:
16-
ref: typeMap
1716
file: apiargs-common-option.yaml
18-
operation: MongoDB\\Client::selectDatabase
17+
ref: typeMap
18+
replacement:
19+
parent: "client"
1920
---
2021
source:
21-
ref: writeConcern
2222
file: apiargs-common-option.yaml
23-
operation: MongoDB\\Client::selectDatabase
23+
ref: writeConcern
2424
replacement:
2525
resource: "database"
26-
...
26+
parent: "client"
27+
...

0 commit comments

Comments
 (0)