# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements.  See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership.  The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License.  You may obtain a copy of the License at
#
# http:# www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

{
  aggrtypes: [
    {className: "Min", funcName: "min", types: [
      {inputType: "Bit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "Int", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "BigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableBit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "NullableInt", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "NullableBigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "Float4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "Float8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "NullableFloat8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "Date", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "NullableDate", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "TimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "NullableTimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "Time", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "Integer.MAX_VALUE"},
      {inputType: "NullableTime", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "Integer.MAX_VALUE"},
      {inputType: "IntervalDay", outputType: "NullableIntervalDay", runningType: "BigInt", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "NullableIntervalDay", outputType: "NullableIntervalDay", runningType: "BigInt", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "IntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "Integer.MAX_VALUE"},
      {inputType: "NullableIntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "Integer.MAX_VALUE"},
      {inputType: "Interval", outputType: "NullableInterval", runningType: "BigInt", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "NullableInterval", outputType: "NullableInterval", runningType: "BigInt", major: "Date", initialValue: "Long.MAX_VALUE"},
      {inputType: "VarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes"},
      {inputType: "NullableVarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes"},
      {inputType: "VarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"},
      {inputType: "NullableVarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"}
     ]
    },
    {className: "Max", funcName: "max", types: [
      {inputType: "Bit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "Int", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "BigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableBit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "NullableInt", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "NullableBigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "Float4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "Float8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "NullableFloat8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "Date", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "NullableDate", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "TimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "NullableTimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "Time", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "Integer.MIN_VALUE"},
      {inputType: "NullableTime", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "Integer.MIN_VALUE"},
      {inputType: "IntervalDay", outputType: "NullableIntervalDay", runningType: "BigInt", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "NullableIntervalDay", outputType: "NullableIntervalDay", runningType: "BigInt", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "IntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "Integer.MIN_VALUE"},
      {inputType: "NullableIntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "Integer.MIN_VALUE"},
      {inputType: "Interval", outputType: "NullableInterval", runningType: "BigInt", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "NullableInterval", outputType: "NullableInterval", runningType: "BigInt", major: "Date", initialValue: "Long.MIN_VALUE"},
      {inputType: "VarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes"},
      {inputType: "NullableVarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes"},
      {inputType: "VarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"},
      {inputType: "NullableVarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"}
     ]
    },
    {className: "Sum", funcName: "sum", types: [
      {inputType: "Int", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "BigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableBigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "Float4", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "Float8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat4", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "IntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "IntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "Interval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"},
      {inputType: "NullableInterval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"}
     ]
    },
    {className: "AnyValue", funcName: "any_value", types: [
      {inputType: "Bit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "Int", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "BigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableBit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "NullableInt", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "NullableBigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "Float4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "Float8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "NullableFloat8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "Date", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "0"},
      {inputType: "NullableDate", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "0"},
      {inputType: "TimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "0"},
      {inputType: "NullableTimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "0"},
      {inputType: "Time", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "0"},
      {inputType: "NullableTime", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "0"},
      {inputType: "IntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "IntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "Interval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"},
      {inputType: "NullableInterval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"},
      {inputType: "VarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes", initialValue: ""},
      {inputType: "NullableVarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes", initialValue: ""},
      {inputType: "VarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"},
      {inputType: "NullableVarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"}
      {inputType: "List", outputType: "List", runningType: "List", major: "Complex"}
      {inputType: "Map", outputType: "Map", runningType: "Map", major: "Complex"}
      {inputType: "RepeatedBit", outputType: "RepeatedBit", runningType: "RepeatedBit", major: "Complex"},
      {inputType: "RepeatedInt", outputType: "RepeatedInt", runningType: "RepeatedInt", major: "Complex"},
      {inputType: "RepeatedBigInt", outputType: "RepeatedBigInt", runningType: "RepeatedBigInt", major: "Complex"},
      {inputType: "RepeatedFloat4", outputType: "RepeatedFloat4", runningType: "RepeatedFloat4", major: "Complex"},
      {inputType: "RepeatedFloat8", outputType: "RepeatedFloat8", runningType: "RepeatedFloat8", major: "Complex"},
      {inputType: "RepeatedDate", outputType: "RepeatedDate", runningType: "RepeatedDate", major: "Complex"},
      {inputType: "RepeatedTimeStamp", outputType: "RepeatedTimeStamp", runningType: "RepeatedTimeStamp", major: "Complex"},
      {inputType: "RepeatedTime", outputType: "RepeatedTime", runningType: "RepeatedTime", major: "Complex"},
      {inputType: "RepeatedIntervalDay", outputType: "RepeatedIntervalDay", runningType: "RepeatedIntervalDay", major: "Complex"},
      {inputType: "RepeatedIntervalYear", outputType: "RepeatedIntervalYear", runningType: "RepeatedIntervalYear", major: "Complex"},
      {inputType: "RepeatedInterval", outputType: "RepeatedInterval", runningType: "RepeatedInterval", major: "Complex"},
      {inputType: "RepeatedVarChar", outputType: "RepeatedVarChar", runningType: "RepeatedVarChar", major: "Complex"},
      {inputType: "RepeatedVarBinary", outputType: "RepeatedVarBinary", runningType: "RepeatedVarBinary", major: "Complex"},
      {inputType: "RepeatedVarDecimal", outputType: "RepeatedVarDecimal", runningType: "RepeatedVarDecimal", major: "Complex"},
      {inputType: "RepeatedList", outputType: "RepeatedList", runningType: "RepeatedList", major: "Complex"},
      {inputType: "RepeatedMap", outputType: "RepeatedMap", runningType: "RepeatedMap", major: "Complex"}
     ]
    },
    {className: "SingleValue", funcName: "single_value", types: [
      {inputType: "Bit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "Int", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "BigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "NullableBit", outputType: "NullableBit", runningType: "Bit", major: "Numeric"},
      {inputType: "NullableInt", outputType: "NullableInt", runningType: "Int", major: "Numeric"},
      {inputType: "NullableBigInt", outputType: "NullableBigInt", runningType: "BigInt", major: "Numeric"},
      {inputType: "Float4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "Float8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "NullableFloat4", outputType: "NullableFloat4", runningType: "Float4", major: "Numeric"},
      {inputType: "NullableFloat8", outputType: "NullableFloat8", runningType: "Float8", major: "Numeric"},
      {inputType: "Date", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "0"},
      {inputType: "NullableDate", outputType: "NullableDate", runningType: "Date", major: "Date", initialValue: "0"},
      {inputType: "TimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "0"},
      {inputType: "NullableTimeStamp", outputType: "NullableTimeStamp", runningType: "TimeStamp", major: "Date", initialValue: "0"},
      {inputType: "Time", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "0"},
      {inputType: "NullableTime", outputType: "NullableTime", runningType: "Time", major: "Date", initialValue: "0"},
      {inputType: "IntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalDay", outputType: "NullableIntervalDay", runningType: "IntervalDay", major: "Date", initialValue: "0"},
      {inputType: "IntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "NullableIntervalYear", outputType: "NullableIntervalYear", runningType: "IntervalYear", major: "Date", initialValue: "0"},
      {inputType: "Interval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"},
      {inputType: "NullableInterval", outputType: "NullableInterval", runningType: "Interval", major: "Date", initialValue: "0"},
      {inputType: "VarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes", initialValue: ""},
      {inputType: "NullableVarChar", outputType: "NullableVarChar", runningType: "VarChar", major: "VarBytes", initialValue: ""},
      {inputType: "VarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"},
      {inputType: "NullableVarBinary", outputType: "NullableVarBinary", runningType: "VarBinary", major: "VarBytes"}
      {inputType: "List", outputType: "List", runningType: "List", major: "Complex"}
      {inputType: "Map", outputType: "Map", runningType: "Map", major: "Complex"}
      {inputType: "RepeatedBit", outputType: "RepeatedBit", runningType: "RepeatedBit", major: "Complex"},
      {inputType: "RepeatedInt", outputType: "RepeatedInt", runningType: "RepeatedInt", major: "Complex"},
      {inputType: "RepeatedBigInt", outputType: "RepeatedBigInt", runningType: "RepeatedBigInt", major: "Complex"},
      {inputType: "RepeatedFloat4", outputType: "RepeatedFloat4", runningType: "RepeatedFloat4", major: "Complex"},
      {inputType: "RepeatedFloat8", outputType: "RepeatedFloat8", runningType: "RepeatedFloat8", major: "Complex"},
      {inputType: "RepeatedDate", outputType: "RepeatedDate", runningType: "RepeatedDate", major: "Complex"},
      {inputType: "RepeatedTimeStamp", outputType: "RepeatedTimeStamp", runningType: "RepeatedTimeStamp", major: "Complex"},
      {inputType: "RepeatedTime", outputType: "RepeatedTime", runningType: "RepeatedTime", major: "Complex"},
      {inputType: "RepeatedIntervalDay", outputType: "RepeatedIntervalDay", runningType: "RepeatedIntervalDay", major: "Complex"},
      {inputType: "RepeatedIntervalYear", outputType: "RepeatedIntervalYear", runningType: "RepeatedIntervalYear", major: "Complex"},
      {inputType: "RepeatedInterval", outputType: "RepeatedInterval", runningType: "RepeatedInterval", major: "Complex"},
      {inputType: "RepeatedVarChar", outputType: "RepeatedVarChar", runningType: "RepeatedVarChar", major: "Complex"},
      {inputType: "RepeatedVarBinary", outputType: "RepeatedVarBinary", runningType: "RepeatedVarBinary", major: "Complex"},
      {inputType: "RepeatedVarDecimal", outputType: "RepeatedVarDecimal", runningType: "RepeatedVarDecimal", major: "Complex"},
      {inputType: "RepeatedList", outputType: "RepeatedList", runningType: "RepeatedList", major: "Complex"},
      {inputType: "RepeatedMap", outputType: "RepeatedMap", runningType: "RepeatedMap", major: "Complex"}
     ]
    }
  ]
}
