Skip to content

Commit dbfd4e5

Browse files
christophstroblmp911de
authored andcommitted
Polishing.
Reformat code. See #3712 Original pull request: #3740.
1 parent c574e5c commit dbfd4e5

File tree

3 files changed

+14
-12
lines changed

3 files changed

+14
-12
lines changed

spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/aggregation/AccumulatorOperators.java

+8-8
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,8 @@ public StdDevSamp stdDevSamp() {
143143
}
144144

145145
/**
146-
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the value of the given
147-
* field to calculate the population covariance of the two.
146+
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the value of the
147+
* given field to calculate the population covariance of the two.
148148
*
149149
* @param fieldReference must not be {@literal null}.
150150
* @return new instance of {@link CovariancePop}.
@@ -155,8 +155,8 @@ public CovariancePop covariancePop(String fieldReference) {
155155
}
156156

157157
/**
158-
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the result of the given
159-
* {@link AggregationExpression expression} to calculate the population covariance of the two.
158+
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the result of the
159+
* given {@link AggregationExpression expression} to calculate the population covariance of the two.
160160
*
161161
* @param expression must not be {@literal null}.
162162
* @return new instance of {@link CovariancePop}.
@@ -171,8 +171,8 @@ private CovariancePop covariancePop() {
171171
}
172172

173173
/**
174-
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the value of the given
175-
* field to calculate the sample covariance of the two.
174+
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the value of the
175+
* given field to calculate the sample covariance of the two.
176176
*
177177
* @param fieldReference must not be {@literal null}.
178178
* @return new instance of {@link CovariancePop}.
@@ -183,8 +183,8 @@ public CovarianceSamp covarianceSamp(String fieldReference) {
183183
}
184184

185185
/**
186-
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the result of the given
187-
* {@link AggregationExpression expression} to calculate the sample covariance of the two.
186+
* Creates new {@link AggregationExpression} that uses the previous input (field/expression) and the result of the
187+
* given {@link AggregationExpression expression} to calculate the sample covariance of the two.
188188
*
189189
* @param expression must not be {@literal null}.
190190
* @return new instance of {@link CovariancePop}.

spring-data-mongodb/src/test/java/org/springframework/data/mongodb/core/aggregation/AccumulatorOperatorsUnitTests.java

+2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@
2727
import org.springframework.data.mongodb.util.aggregation.TestAggregationContext;
2828

2929
/**
30+
* Unit tests for {@link AccumulatorOperators}.
31+
*
3032
* @author Christoph Strobl
3133
*/
3234
class AccumulatorOperatorsUnitTests {

src/main/asciidoc/reference/mongodb.adoc

+4-4
Original file line numberDiff line numberDiff line change
@@ -1002,7 +1002,7 @@ assertThat(upserted.getFirstName()).isEqualTo("Mary");
10021002
assertThat(upserted.getAge()).isOne();
10031003
----
10041004

1005-
[[mongo-template.aggregation-update]]
1005+
= [[mongo-template.aggregation-update]]
10061006
=== Aggregation Pipeline Updates
10071007

10081008
Update methods exposed by `MongoOperations` and `ReactiveMongoOperations` also accept an <<mongo.aggregation, Aggregation Pipeline>> via `AggregationUpdate`.
@@ -2502,8 +2502,8 @@ At the time of this writing, we provide support for the following Aggregation Op
25022502
| Set Aggregation Operators
25032503
| `setEquals`, `setIntersection`, `setUnion`, `setDifference`, `setIsSubset`, `anyElementTrue`, `allElementsTrue`
25042504

2505-
| Group Aggregation Operators
2506-
| `addToSet`, `first`, `last`, `max`, `min`, `avg`, `push`, `sum`, `(*count)`, `stdDevPop`, `stdDevSamp`
2505+
| Group/Accumulator Aggregation Operators
2506+
| `addToSet`, `covariancePop`, `covarianceSamp`, `first`, `last`, `max`, `min`, `avg`, `push`, `sum`, `(*count)`, `stdDevPop`, `stdDevSamp`
25072507

25082508
| Arithmetic Aggregation Operators
25092509
| `abs`, `add` (*via `plus`), `ceil`, `divide`, `exp`, `floor`, `ln`, `log`, `log10`, `mod`, `multiply`, `pow`, `round`, `sqrt`, `subtract` (*via `minus`), `trunc`
@@ -2544,7 +2544,7 @@ At the time of this writing, we provide support for the following Aggregation Op
25442544

25452545
* The operation is mapped or added by Spring Data MongoDB.
25462546

2547-
Note that the aggregation operations not listed here are currently not supported by Spring Data MongoDB. Comparison aggregation operators are expressed as `Criteria` expressions.
2547+
Note that the aggregation operations not listed here are currently not supported by Spring Data MongoDB.Comparison aggregation operators are expressed as `Criteria` expressions.
25482548

25492549
[[mongo.aggregation.projection]]
25502550
=== Projection Expressions

0 commit comments

Comments
 (0)