/*
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 { __extends } from "tslib";
import { UltraCalcConditionalFunctionBase } from "./UltraCalcConditionalFunctionBase";
import { ExcelCalcValue } from "./ExcelCalcValue";
import { ExcelCalcErrorValue } from "./ExcelCalcErrorValue";
import { markType } from "igniteui-angular-core";
/**
 * @hidden
 */
var UltraCalcFunctionAverageIf = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(UltraCalcFunctionAverageIf, _super);
    function UltraCalcFunctionAverageIf() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    UltraCalcFunctionAverageIf.prototype._al = function (a, b) {
        if (b == 0) {
            return new ExcelCalcValue(new ExcelCalcErrorValue(2));
        }
        return new ExcelCalcValue(a / b);
    };
    UltraCalcFunctionAverageIf.prototype.get_name = function () {
        return "averageif";
    };
    Object.defineProperty(UltraCalcFunctionAverageIf.prototype, "name", {
        get: function () {
            return this.get_name();
        },
        enumerable: false,
        configurable: true
    });
    UltraCalcFunctionAverageIf.$t = markType(UltraCalcFunctionAverageIf, 'UltraCalcFunctionAverageIf', UltraCalcConditionalFunctionBase.$);
    return UltraCalcFunctionAverageIf;
}(UltraCalcConditionalFunctionBase));
export { UltraCalcFunctionAverageIf };
