Constructor
new NestedAgg(innerAgg, nestPath, innerAggName)
Parameters:
Name | Type | Description |
---|---|---|
innerAgg |
Aggregation | Inner aggregation object. |
nestPath |
string | @optional path of nested document fields. If not provided, expects innerAgg to have a 'field' property and will infer. Ex: innerAgg field='x.y.z', path will be 'x.y'. |
innerAggName |
string | @optional Aggregation name for inner agg. |
- Source:
Extends
Methods
getName() → {string}
Get the name of the aggregation object.
- Overrides:
- Source:
Returns:
Name of aggregation. Defers to innerAgg object.
- Type
- string
getName() → {string}
Get the name of the aggregation object.
- Overrides:
- Source:
Returns:
Name of aggregation. Defers to innerAgg object.
- Type
- string
setName(name)
Attach a name to the aggregation object. Can be used when attaching the aggregation to a query. Convenience method to allow responsibility of the name to be given to the creator of the aggregation object. Can be accessed directly but won't show up during serialization.
Parameters:
Name | Type | Description |
---|---|---|
name |
string | Name of aggregation. |
- Overrides:
- Source: