AggregateGroupByDurationRequest


public final class AggregateGroupByDurationRequest


Request object to read time bucketed aggregations for given AggregateMetrics in Android Health Platform.

timeRangeSlicer contains a Duration of fixed physical time intervals, such as per hour, per ten minutes or so. Prefer AggregateGroupByPeriodRequest, if you would like variable length time intervals, such as per day, which may or may not include DST (23 or 25 hour).

Summary

Public constructors

AggregateGroupByDurationRequest(
    @NonNull Set<@NonNull AggregateMetric<@NonNull ?>> metrics,
    @NonNull TimeRangeFilter timeRangeFilter,
    @NonNull Duration timeRangeSlicer,
    @NonNull Set<@NonNull DataOrigin> dataOriginFilter
)

Public methods

boolean
equals(Object other)
int

Public constructors

AggregateGroupByDurationRequest

public AggregateGroupByDurationRequest(
    @NonNull Set<@NonNull AggregateMetric<@NonNull ?>> metrics,
    @NonNull TimeRangeFilter timeRangeFilter,
    @NonNull Duration timeRangeSlicer,
    @NonNull Set<@NonNull DataOrigin> dataOriginFilter
)
Parameters
@NonNull Set<@NonNull AggregateMetric<@NonNull ?>> metrics

Set of AggregateMetrics to aggregate.

@NonNull TimeRangeFilter timeRangeFilter

The TimeRangeFilter to read from.

@NonNull Duration timeRangeSlicer

The bucket size of each returned aggregate row. timeRangeFilter will be sliced into several equal-sized time buckets (except for the last one).

@NonNull Set<@NonNull DataOrigin> dataOriginFilter

Set of DataOrigins to read from, or empty for no filter.

Public methods

equals

public boolean equals(Object other)

hashCode

public int hashCode()