@@ -53,7 +53,7 @@ string field called ``name``:
5353
5454.. code-block:: java
5555 :copyable: true
56-
56+
5757 current().getString("name")
5858
5959To specify a value in an operation, pass it to the ``of()`` constructor method to
@@ -62,7 +62,7 @@ value of ``1.0``:
6262
6363.. code-block:: java
6464 :copyable: true
65-
65+
6666 of(1.0)
6767
6868To create an operation, chain a method to your field or value reference.
@@ -73,7 +73,7 @@ Mexico who have visited the doctor’s office at least once. The operation
7373performs the following actions:
7474
7575- Checks if the size of the ``visitDates`` array is greater than ``0``
76- by using the ``gt()`` method
76+ by using the ``gt()`` method
7777- Checks if the ``state`` field value is “New Mexico” by using the
7878 ``eq()`` method
7979
@@ -82,7 +82,7 @@ matches only documents that meet both criteria.
8282
8383.. code-block:: java
8484 :copyable: true
85-
85+
8686 current()
8787 .getArray("visitDates")
8888 .size()
@@ -155,7 +155,7 @@ expressions.
155155
156156 * - `ofEntry() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlValues.html#ofEntry(com.mongodb.client.model.mql.MqlString,T)>`__
157157 - Returns an entry value.
158-
158+
159159 * - `ofMap() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlValues.html#ofMap()>`__
160160 - Returns an empty map value.
161161
@@ -391,7 +391,7 @@ with ``lt()``. The ``project()`` method stores these filtered results as a new
391391 You must specify the type of the array that you retrieve with the
392392 ``getArray()`` method if you need to work with the values of the
393393 array as their specific type.
394-
394+
395395 In this example, we specify that the ``seats`` array contains values
396396 of type ``MqlDocument`` so that we can extract nested fields from
397397 each array entry.
@@ -433,7 +433,7 @@ the Query API:
433433 input: "$showtimes",
434434 as: "showtime",
435435 cond: { $lt: [ "$$showtime.ticketsBought", { $sum: "$$showtime.seats" } ] }
436- } }
436+ } }
437437 } } ]
438438
439439Boolean Operations
@@ -451,7 +451,7 @@ using the methods described in this section.
451451
452452 * - `and() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlBoolean.html#and(com.mongodb.client.model.mql.MqlBoolean)>`__
453453 - :manual:`$and </reference/operator/aggregation/and/>`
454-
454+
455455 * - `not() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlBoolean.html#not()>`__
456456 - :manual:`$not </reference/operator/aggregation/not/>`
457457
@@ -657,7 +657,7 @@ into custom static methods.
657657 - Aggregation Pipeline Operator
658658
659659 * - `passTo() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlValue.html#passTo(java.util.function.Function)>`__
660-
660+
661661 | **Typed Variants**:
662662 | `passArrayTo() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlArray.html#passArrayTo(java.util.function.Function)>`__
663663 | `passBooleanTo() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlBoolean.html#passBooleanTo(java.util.function.Function)>`__
@@ -719,7 +719,7 @@ The following code shows the pipeline for this aggregation:
719719
720720.. code-block:: java
721721 :copyable: true
722-
722+
723723 var students = current().<MqlDocument>getArray("students");
724724
725725 asList(project(fields(
@@ -762,7 +762,7 @@ types using the methods described in this section.
762762
763763 * - `asDocument() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlMap.html#asDocument()>`__
764764 - *No corresponding operator*
765-
765+
766766 * - `asMap() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlDocument.html#asMap()>`__
767767 - *No corresponding operator*
768768
@@ -798,7 +798,7 @@ The following code shows the pipeline for this aggregation:
798798 var graduationYear = current().getString("graduationYear");
799799
800800 asList(addFields(
801- new Field("reunionYear",
801+ new Field("reunionYear",
802802 graduationYear
803803 .parseInteger()
804804 .add(5))
@@ -894,10 +894,10 @@ the Query API:
894894 [ { $match: {
895895 $expr: {
896896 $eq: [ {
897- $dayOfWeek: {
897+ $dayOfWeek: {
898898 date: { $dateFromString: { dateString: "$deliveryDate" } },
899899 timezone: "America/New_York" }},
900- 2
900+ 2
901901 ] }
902902 } } ]
903903
@@ -934,8 +934,8 @@ using the methods described in this section.
934934 * - `setField() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlDocument.html#setField(java.lang.String,com.mongodb.client.model.mql.MqlValue)>`__
935935 - :manual:`$setField </reference/operator/aggregation/setField/>`
936936
937- * - `unsetField() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/>`__
938- - :manual:`$unsetField </reference/operator/aggregation/unsetField/MqlDocument.html#unsetField(java.lang.String) >`
937+ * - `unsetField() <{+api+}/apidocs/mongodb-driver-core/com/mongodb/client/model/mql/MqlDocument.html#unsetField(java.lang.String) >`__
938+ - :manual:`$unsetField </reference/operator/aggregation/unsetField/>`
939939
940940Suppose you have a collection of legacy customer data which includes
941941addresses as child documents under the ``mailing.address`` field. You want
@@ -983,10 +983,10 @@ the Query API:
983983 [
984984 { $match: {
985985 $expr: {
986- $eq: [{
986+ $eq: [{
987987 $getField: {
988- input: { $getField: { input: "$$CURRENT", field: "mailing.address"}},
989- field: "state" }},
988+ input: { $getField: { input: "$$CURRENT", field: "mailing.address"}},
989+ field: "state" }},
990990 "WA" ]
991991 }}}]
992992
@@ -997,7 +997,7 @@ You can perform a map operation on a value of either type ``MqlMap`` or
997997``MqlEntry`` using the methods described in this section.
998998
999999.. tip::
1000-
1000+
10011001 You should represent data as a map if the data maps
10021002 arbitrary keys such as dates or item IDs to values.
10031003
@@ -1146,7 +1146,7 @@ The following code shows the pipeline for this aggregation:
11461146 .append(employeeID)
11471147 .toLower())
11481148 )));
1149-
1149+
11501150The following code provides an equivalent aggregation pipeline in
11511151the Query API:
11521152
0 commit comments