Class PadReturnTypeInference

java.lang.Object
org.apache.drill.exec.expr.fn.output.PadReturnTypeInference
All Implemented Interfaces:
ReturnTypeInference

public class PadReturnTypeInference extends Object implements ReturnTypeInference
Return type calculation implementation for functions with return type set as FunctionTemplate.ReturnType.PAD.
  • Field Details

  • Constructor Details

    • PadReturnTypeInference

      public PadReturnTypeInference()
  • Method Details

    • getType

      public TypeProtos.MajorType getType(List<LogicalExpression> logicalExpressions, FunctionAttributes attributes)
      Defines function return type and sets precision if it pad length parameter is int expression. If pad length is less than zero, return type precision is 0.
      Specified by:
      getType in interface ReturnTypeInference
      Parameters:
      logicalExpressions - logical expressions
      attributes - function attributes
      Returns:
      return type