Skip to content

Commit 5306503

Browse files
committed
docsp-33327 - update window api (#502)
(cherry picked from commit 19a6c21)
1 parent e7fa2d2 commit 5306503

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

source/fundamentals/builders/aggregates.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22
Aggregates Builders
33
===================
44

5-
.. default-domain:: mongodb
5+
.. facet::
6+
:name: genre
7+
:values: reference
8+
9+
.. meta::
10+
:keywords: code examples
611

712
.. contents:: On this page
813
:local:

source/includes/fundamentals/code-snippets/builders/AggBuilders.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,8 +93,8 @@ private void setWindowFieldsStage() {
9393
// begin setWindowFields
9494
Window pastMonth = Windows.timeRange(-1, MongoTimeUnit.MONTH, Windows.Bound.CURRENT);
9595
setWindowFields("$localityId", Sorts.ascending("measurementDateTime"),
96-
WindowedComputations.sum("monthlyRainfall", "$rainfall", pastMonth),
97-
WindowedComputations.avg("monthlyAvgTemp", "$temperature", pastMonth));
96+
WindowOutputFields.sum("monthlyRainfall", "$rainfall", pastMonth),
97+
WindowOutputFields.avg("monthlyAvgTemp", "$temperature", pastMonth));
9898
// end setWindowFields
9999
}
100100

0 commit comments

Comments
 (0)