Skip to content

Commit ba3cfe3

Browse files
committed
NR feedback
1 parent 750dba2 commit ba3cfe3

File tree

6 files changed

+23
-28
lines changed

6 files changed

+23
-28
lines changed

source/crud/read-operations/retrieve.txt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,11 +99,10 @@ Find Example: Full File
9999

100100
.. include:: /includes/crud/example-intro.rst
101101

102-
The following code is a complete, standalone file that performs the following
103-
actions:
102+
This example is a complete, standalone file that performs the following actions:
104103

105-
- Calls the ``find()`` method to retrieve multiple documents that have a ``runtime`` value less than 15, applying a projection and sort to the results
106-
- Calls the ``find()`` and ``first()`` method to retrieve a document that has a ``title`` value of ``"The Room"``, applying a projection and sort before returning the first match
104+
- Calls the ``find()`` method to retrieve multiple documents that have a ``runtime`` value less than ``15``, applying a projection and sort to the results
105+
- Calls the ``find()`` and ``first()`` methods to retrieve a document that has a ``title`` value of ``"The Room"``, applying a projection and sort before returning the first match
107106

108107
.. io-code-block::
109108

@@ -176,7 +175,7 @@ API Documentation
176175
~~~~~~~~~~~~~~~~~
177176

178177
For more information about the methods and classes used to retrieve documents
179-
on this page, see the following API cocumentation:
178+
on this page, see the following API documentation:
180179

181180
- `find() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#find()>`__
182181
- `first() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoIterable.html#first()>`__

source/crud/write-operations/bulk.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ actions:
370370

371371
#. Creates a list of instances of the ``InsertOneModel``, ``UpdateOneModel``,
372372
``DeleteOneModel``, and ``ReplaceOneModel`` classes.
373-
#. Runs an ordered ``bulkWrite()`` operation on the list.
373+
#. Runs an ordered ``bulkWrite()`` operation that performs the writes specified in the model list.
374374

375375
.. io-code-block::
376376

@@ -652,7 +652,7 @@ MongoCollection
652652
- `MongoBulkWriteException <{+api+}/apidocs/mongodb-driver-core/com/mongodb/MongoBulkWriteException.html>`__
653653

654654
MongoClient
655-
````````````
655+
```````````
656656

657657
- `bulkWrite() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCluster.html#bulkWrite(com.mongodb.client.ClientSession,java.util.List)>`__
658658
- `ClientBulkWriteOptions <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/bulk/ClientBulkWriteOptions.html>`__

source/crud/write-operations/delete.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ Delete Example: Full File
154154
.. include:: /includes/crud/example-intro.rst
155155

156156
The following code is a complete, standalone file that performs a delete one
157-
operation and a delete many operation.
157+
operation and a delete many operation:
158158

159159
.. io-code-block::
160160

@@ -166,11 +166,11 @@ operation and a delete many operation.
166166
:language: none
167167
:visible: false
168168

169-
DeleteOne document count: 1
170-
DeleteMany document count: 4
169+
deleteOne() document count: 1
170+
deleteMany() document count: 4
171171

172172

173-
The query in this examples uses the ``eq()`` and ``lt()`` filters to query documents. For more
173+
The queries in these examples use the ``eq()`` and ``lt()`` filters to query documents. For more
174174
information about filters, see the `Filters Class
175175
<{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/Filters.html>`__
176176
API documentation.
@@ -181,7 +181,7 @@ Additional Information
181181
API Documentation
182182
~~~~~~~~~~~~~~~~~
183183

184-
For more information about the methods and classes used to delete documents, see the following API cocumentation:
184+
For more information about the methods and classes used to delete documents, see the following API documentation:
185185

186186
- `deleteOne() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#deleteOne(org.bson.conversions.Bson)>`__
187187
- `deleteMany() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#deleteMany(org.bson.conversions.Bson)>`__

source/crud/write-operations/insert.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ Insert Example: Full File
162162
.. include:: /includes/crud/example-intro.rst
163163

164164
The following code is a complete, standalone file that performs an insert one
165-
operation and an insert many operation.
165+
operation and an insert many operation:
166166

167167
.. io-code-block::
168168

@@ -174,16 +174,16 @@ operation and an insert many operation.
174174
:language: none
175175
:visible: false
176176

177-
InsertOne document id: BsonObjectId{value=...}
178-
InsertMany document ids: {0=BsonObjectId{value=...}, 1=BsonObjectId{value=...}}
177+
insertOne() document id: BsonObjectId{value=...}
178+
insertMany() document ids: {0=BsonObjectId{value=...}, 1=BsonObjectId{value=...}}
179179

180180
Additional Information
181181
----------------------
182182

183183
API Documentation
184184
~~~~~~~~~~~~~~~~~
185185

186-
For more information about the methods and classes used to insert documents, see the following API cocumentation:
186+
For more information about the methods and classes used to insert documents, see the following API documentation:
187187

188188
- `insertOne() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#insertOne(TDocument)>`__
189189
- `InsertOneResult <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/result/InsertOneResult.html>`__

source/crud/write-operations/modify.txt

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -166,11 +166,11 @@ documents match.
166166
Update Example: Full File
167167
~~~~~~~~~~~~~~~~~~~~~~~~~
168168

169-
The following code is a complete, standalone file that performs an update one
170-
operation and an update many operation.
171-
172169
.. include:: /includes/crud/example-intro.rst
173170

171+
The following code is a complete, standalone file that performs an update one
172+
operation and an update many operation:
173+
174174
.. io-code-block::
175175

176176
.. input:: /includes/crud/Update.java
@@ -297,29 +297,25 @@ The following code is a complete, standalone file that performs a replace one op
297297
:language: none
298298
:visible: false
299299

300-
UpdateOne modified document count: 1
300+
updateOne() modified document count: 1
301301
Upserted ID: null
302302

303-
UpdateMany modified document count: 242
303+
updateMany() modified document count: 242
304304

305305
Additional Information
306306
----------------------
307307

308308
API Documentation
309309
~~~~~~~~~~~~~~~~~
310310

311-
For more information about the methods and classes used to modify documents, see the following API cocumentation:
311+
For more information about the methods and classes used on this page, see the following API documentation:
312312

313313
- `updateOne() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#updateOne(org.bson.conversions.Bson,java.util.List,com.mongodb.client.model.UpdateOptions)>`__
314314
- `updateMany() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#updateMany(org.bson.conversions.Bson,java.util.List,com.mongodb.client.model.UpdateOptions)>`__
315315
- `UpdateOptions <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/UpdateOptions.html>`__
316316
- `replaceOne() <{+api+}/apidocs/mongodb-driver-sync/com/mongodb/client/MongoCollection.html#replaceOne(org.bson.conversions.Bson,TDocument)>`__
317317
- `ReplaceOptions <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/ReplaceOptions.html?is-external=true>`__
318318
- `UpdateResult <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/result/UpdateResult.html>`__
319-
320-
For more information about the methods used in the examples on this
321-
page, see the following API cocumentation:
322-
323319
- `eq() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/Filters.html#eq(java.lang.String,TItem)>`__
324320
- `combine() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/Updates.html#combine(org.bson.conversions.Bson...)>`__
325321
- `set() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/Updates.html#set(java.lang.String,TItem)>`__

source/includes/crud/Update.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public static void main(String[] args) {
4343
UpdateResult result = collection.updateOne(updateOneQuery, updateOneUpdates, options);
4444

4545
// Prints the number of updated documents and the upserted document ID, if an upsert was performed
46-
System.out.println("UpdateOne modified document count: " + result.getModifiedCount());
46+
System.out.println("updateOne() modified document count: " + result.getModifiedCount());
4747
System.out.println("Upserted ID: " + result.getUpsertedId());
4848

4949
// Prints a message if any exceptions occur during the operation
@@ -63,7 +63,7 @@ public static void main(String[] args) {
6363
UpdateResult result = collection.updateMany(updateManyQuery, updateManyUpdates);
6464

6565
// Prints the number of updated documents
66-
System.out.println("\nUpdateMany modified document count: " + result.getModifiedCount());
66+
System.out.println("\nupdateMany() modified document count: " + result.getModifiedCount());
6767

6868
// Prints a message if any exceptions occur during the operation
6969
} catch (MongoException me) {

0 commit comments

Comments
 (0)