Class PredefinedFunction

All Implemented Interfaces:
Iterable<GroupingExpression>
Direct Known Subclasses:
DoublePredefined, LongPredefined, RawPredefined, StringPredefined

public abstract class PredefinedFunction extends FunctionNode
This class represents a predefined bucket-function in a GroupingExpression. It maps the input into one of the given buckets by the result of the argument expression.
Author:
Simon Thoresen Hult
  • Constructor Details

  • Method Details

    • getNumBuckets

      public int getNumBuckets()
      Returns the number of buckets to divide the result into.
      Returns:
      The bucket count.
    • getBucket

      public BucketValue getBucket(int i)
      Returns the bucket at the given index.
      Parameters:
      i - The index of the bucket to return.
      Returns:
      The bucket at the given index.
      Throws:
      IndexOutOfBoundsException - If the index is out of range.