Class AggregationQuery.Aggregation.Builder (2.30.0)
Stay organized with collections
Save and categorize content based on your preferences.
publicstaticfinalclass AggregationQuery.Aggregation.BuilderextendsGeneratedMessageV3.Builder<AggregationQuery.Aggregation.Builder>implementsAggregationQuery.AggregationOrBuilderDefines an aggregation that produces a single result.
Protobuf type google.datastore.v1.AggregationQuery.Aggregation
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > AggregationQuery.Aggregation.BuilderImplements
AggregationQuery.AggregationOrBuilderInherited Members
Static Methods
getDescriptor()
publicstaticfinalDescriptors.DescriptorgetDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
publicAggregationQuery.Aggregation.BuilderaddRepeatedField(Descriptors.FieldDescriptorfield,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
build()
publicAggregationQuery.Aggregationbuild()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation |
|
buildPartial()
publicAggregationQuery.AggregationbuildPartial()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation |
|
clear()
publicAggregationQuery.Aggregation.Builderclear()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearAlias()
publicAggregationQuery.Aggregation.BuilderclearAlias()Optional. Optional name of the property to store the result of the aggregation.
If not provided, Datastore will pick a default name following the format
property_<incremental_id++>. For example:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2),
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*)
OVER (
...
);
becomes:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2) AS property_1,
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*) AS property_2
OVER (
...
);
Requires:
- Must be unique across all aggregation aliases.
- Conform to entity property name limitations.
string alias = 7 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
This builder for chaining. |
clearAvg()
publicAggregationQuery.Aggregation.BuilderclearAvg()Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearCount()
publicAggregationQuery.Aggregation.BuilderclearCount()Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearField(Descriptors.FieldDescriptor field)
publicAggregationQuery.Aggregation.BuilderclearField(Descriptors.FieldDescriptorfield)| Parameter | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearOneof(Descriptors.OneofDescriptor oneof)
publicAggregationQuery.Aggregation.BuilderclearOneof(Descriptors.OneofDescriptoroneof)| Parameter | |
|---|---|
| Name | Description |
oneof |
OneofDescriptor |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearOperator()
publicAggregationQuery.Aggregation.BuilderclearOperator()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clearSum()
publicAggregationQuery.Aggregation.BuilderclearSum()Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
clone()
publicAggregationQuery.Aggregation.Builderclone()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
getAlias()
publicStringgetAlias()Optional. Optional name of the property to store the result of the aggregation.
If not provided, Datastore will pick a default name following the format
property_<incremental_id++>. For example:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2),
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*)
OVER (
...
);
becomes:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2) AS property_1,
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*) AS property_2
OVER (
...
);
Requires:
- Must be unique across all aggregation aliases.
- Conform to entity property name limitations.
string alias = 7 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
String |
The alias. |
getAliasBytes()
publicByteStringgetAliasBytes()Optional. Optional name of the property to store the result of the aggregation.
If not provided, Datastore will pick a default name following the format
property_<incremental_id++>. For example:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2),
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*)
OVER (
...
);
becomes:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2) AS property_1,
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*) AS property_2
OVER (
...
);
Requires:
- Must be unique across all aggregation aliases.
- Conform to entity property name limitations.
string alias = 7 [(.google.api.field_behavior) = OPTIONAL];
| Returns | |
|---|---|
| Type | Description |
ByteString |
The bytes for alias. |
getAvg()
publicAggregationQuery.Aggregation.AvggetAvg()Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Avg |
The avg. |
getAvgBuilder()
publicAggregationQuery.Aggregation.Avg.BuildergetAvgBuilder()Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Avg.Builder |
|
getAvgOrBuilder()
publicAggregationQuery.Aggregation.AvgOrBuildergetAvgOrBuilder()Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.AvgOrBuilder |
|
getCount()
publicAggregationQuery.Aggregation.CountgetCount()Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Count |
The count. |
getCountBuilder()
publicAggregationQuery.Aggregation.Count.BuildergetCountBuilder()Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Count.Builder |
|
getCountOrBuilder()
publicAggregationQuery.Aggregation.CountOrBuildergetCountOrBuilder()Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.CountOrBuilder |
|
getDefaultInstanceForType()
publicAggregationQuery.AggregationgetDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation |
|
getDescriptorForType()
publicDescriptors.DescriptorgetDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getOperatorCase()
publicAggregationQuery.Aggregation.OperatorCasegetOperatorCase()| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.OperatorCase |
|
getSum()
publicAggregationQuery.Aggregation.SumgetSum()Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Sum |
The sum. |
getSumBuilder()
publicAggregationQuery.Aggregation.Sum.BuildergetSumBuilder()Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Sum.Builder |
|
getSumOrBuilder()
publicAggregationQuery.Aggregation.SumOrBuildergetSumOrBuilder()Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.SumOrBuilder |
|
hasAvg()
publicbooleanhasAvg()Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the avg field is set. |
hasCount()
publicbooleanhasCount()Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the count field is set. |
hasSum()
publicbooleanhasSum()Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Returns | |
|---|---|
| Type | Description |
boolean |
Whether the sum field is set. |
internalGetFieldAccessorTable()
protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
publicfinalbooleanisInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeAvg(AggregationQuery.Aggregation.Avg value)
publicAggregationQuery.Aggregation.BuildermergeAvg(AggregationQuery.Aggregation.Avgvalue)Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Avg |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
mergeCount(AggregationQuery.Aggregation.Count value)
publicAggregationQuery.Aggregation.BuildermergeCount(AggregationQuery.Aggregation.Countvalue)Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Count |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
mergeFrom(AggregationQuery.Aggregation other)
publicAggregationQuery.Aggregation.BuildermergeFrom(AggregationQuery.Aggregationother)| Parameter | |
|---|---|
| Name | Description |
other |
AggregationQuery.Aggregation |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
publicAggregationQuery.Aggregation.BuildermergeFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
publicAggregationQuery.Aggregation.BuildermergeFrom(Messageother)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
mergeSum(AggregationQuery.Aggregation.Sum value)
publicAggregationQuery.Aggregation.BuildermergeSum(AggregationQuery.Aggregation.Sumvalue)Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Sum |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
mergeUnknownFields(UnknownFieldSet unknownFields)
publicfinalAggregationQuery.Aggregation.BuildermergeUnknownFields(UnknownFieldSetunknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setAlias(String value)
publicAggregationQuery.Aggregation.BuildersetAlias(Stringvalue)Optional. Optional name of the property to store the result of the aggregation.
If not provided, Datastore will pick a default name following the format
property_<incremental_id++>. For example:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2),
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*)
OVER (
...
);
becomes:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2) AS property_1,
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*) AS property_2
OVER (
...
);
Requires:
- Must be unique across all aggregation aliases.
- Conform to entity property name limitations.
string alias = 7 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
String The alias to set. |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
This builder for chaining. |
setAliasBytes(ByteString value)
publicAggregationQuery.Aggregation.BuildersetAliasBytes(ByteStringvalue)Optional. Optional name of the property to store the result of the aggregation.
If not provided, Datastore will pick a default name following the format
property_<incremental_id++>. For example:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2),
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*)
OVER (
...
);
becomes:
`
AGGREGATE
COUNT_UP_TO(1) AS count_up_to_1,
COUNT_UP_TO(2) AS property_1,
COUNT_UP_TO(3) AS count_up_to_3,
COUNT(*) AS property_2
OVER (
...
);
Requires:
- Must be unique across all aggregation aliases.
- Conform to entity property name limitations.
string alias = 7 [(.google.api.field_behavior) = OPTIONAL];
| Parameter | |
|---|---|
| Name | Description |
value |
ByteString The bytes for alias to set. |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
This builder for chaining. |
setAvg(AggregationQuery.Aggregation.Avg value)
publicAggregationQuery.Aggregation.BuildersetAvg(AggregationQuery.Aggregation.Avgvalue)Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Avg |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setAvg(AggregationQuery.Aggregation.Avg.Builder builderForValue)
publicAggregationQuery.Aggregation.BuildersetAvg(AggregationQuery.Aggregation.Avg.BuilderbuilderForValue)Average aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Avg avg = 3;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
AggregationQuery.Aggregation.Avg.Builder |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setCount(AggregationQuery.Aggregation.Count value)
publicAggregationQuery.Aggregation.BuildersetCount(AggregationQuery.Aggregation.Countvalue)Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Count |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setCount(AggregationQuery.Aggregation.Count.Builder builderForValue)
publicAggregationQuery.Aggregation.BuildersetCount(AggregationQuery.Aggregation.Count.BuilderbuilderForValue)Count aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Count count = 1;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
AggregationQuery.Aggregation.Count.Builder |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setField(Descriptors.FieldDescriptor field, Object value)
publicAggregationQuery.Aggregation.BuildersetField(Descriptors.FieldDescriptorfield,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
publicAggregationQuery.Aggregation.BuildersetRepeatedField(Descriptors.FieldDescriptorfield,intindex,Objectvalue)| Parameters | |
|---|---|
| Name | Description |
field |
FieldDescriptor |
index |
int |
value |
Object |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setSum(AggregationQuery.Aggregation.Sum value)
publicAggregationQuery.Aggregation.BuildersetSum(AggregationQuery.Aggregation.Sumvalue)Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Parameter | |
|---|---|
| Name | Description |
value |
AggregationQuery.Aggregation.Sum |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setSum(AggregationQuery.Aggregation.Sum.Builder builderForValue)
publicAggregationQuery.Aggregation.BuildersetSum(AggregationQuery.Aggregation.Sum.BuilderbuilderForValue)Sum aggregator.
.google.datastore.v1.AggregationQuery.Aggregation.Sum sum = 2;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
AggregationQuery.Aggregation.Sum.Builder |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|
setUnknownFields(UnknownFieldSet unknownFields)
publicfinalAggregationQuery.Aggregation.BuildersetUnknownFields(UnknownFieldSetunknownFields)| Parameter | |
|---|---|
| Name | Description |
unknownFields |
UnknownFieldSet |
| Returns | |
|---|---|
| Type | Description |
AggregationQuery.Aggregation.Builder |
|