Module org.elasticsearch.compute
Class TimeSeriesGroupingAggregatorEvaluationContext
java.lang.Object
org.elasticsearch.compute.aggregation.GroupingAggregatorEvaluationContext
org.elasticsearch.compute.aggregation.TimeSeriesGroupingAggregatorEvaluationContext
public abstract class TimeSeriesGroupingAggregatorEvaluationContext
extends GroupingAggregatorEvaluationContext
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongroupIdsFromWindow(int startingGroupId, Duration window) Returns the group IDs of subsequent groups that belong to the window starting with thestartingGroupId.abstract longrangeEndInMillis(int groupId) Returns the exclusive end of the time range, in milliseconds, for the specified group ID.abstract longrangeStartInMillis(int groupId) Returns the inclusive start of the time range, in milliseconds, for the specified group ID.Methods inherited from class org.elasticsearch.compute.aggregation.GroupingAggregatorEvaluationContext
blockFactory, driverContext
-
Constructor Details
-
TimeSeriesGroupingAggregatorEvaluationContext
-
-
Method Details
-
rangeStartInMillis
public abstract long rangeStartInMillis(int groupId) Returns the inclusive start of the time range, in milliseconds, for the specified group ID. Data points for this group are within the range [rangeStartInMillis, rangeEndInMillis).- Parameters:
groupId- the group id- Returns:
- the start of the time range in milliseconds (inclusive)
-
rangeEndInMillis
public abstract long rangeEndInMillis(int groupId) Returns the exclusive end of the time range, in milliseconds, for the specified group ID. Data points for this group are within the range [rangeStartInMillis, rangeEndInMillis). -
groupIdsFromWindow
Returns the group IDs of subsequent groups that belong to the window starting with thestartingGroupId. The time ranges of returned group IDs are within the interval[rangeStartInMillis(startingGroupId), rangeStartInMillis(startingGroupId) + window.toMillis()).- Parameters:
startingGroupId- the starting group IDwindow- the window duration- Returns:
- a list of group IDs within the window
-