/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE  AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE:  you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { UltraCalcConditionalFunctionBase } from "./UltraCalcConditionalFunctionBase";
import { ExcelCalcValue } from "./ExcelCalcValue";
import { ExcelCalcErrorValue } from "./ExcelCalcErrorValue";
import { markType } from "igniteui-angular-core";
/**
 * @hidden
 */
export let UltraCalcFunctionAverageIf = /*@__PURE__*/ (() => {
    class UltraCalcFunctionAverageIf extends UltraCalcConditionalFunctionBase {
        _al(a, b) {
            if (b == 0) {
                return new ExcelCalcValue(new ExcelCalcErrorValue(2));
            }
            return new ExcelCalcValue(a / b);
        }
        get_name() {
            return "averageif";
        }
        get name() {
            return this.get_name();
        }
    }
    UltraCalcFunctionAverageIf.$t = markType(UltraCalcFunctionAverageIf, 'UltraCalcFunctionAverageIf', UltraCalcConditionalFunctionBase.$);
    return UltraCalcFunctionAverageIf;
})();
