Class BucketResolver

    • Constructor Detail

      • BucketResolver

        public BucketResolver()
    • Method Detail

      • push

        public BucketResolver push​(ConstantValue<?> val,
                                   boolean inclusive)
        Pushes the given expression onto this bucket resolver. Once all buckets have been pushed using this method, call resolve(GroupingExpression) to retrieve to combined grouping expression.
        val - The expression to push.
        inclusive - Whether or not the value is inclusive or not.
        java.lang.IllegalArgumentException - Thrown if the expression is incompatible.
      • resolve

        public PredefinedFunction resolve​(GroupingExpression exp)
        Resolves and returns the list of grouping expressions that correspond to the previously pushed buckets.
        exp - The expression to assign to the function.
        The list corresponding to the pushed buckets.