/*
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 * as tslib_1 from "tslib";
import { Base, markType } from "igniteui-webcomponents-core";
import { SyncableObservableCollection$2 } from "igniteui-webcomponents-core";
import { ColumnGroupDescription } from "./ColumnGroupDescription";
import { SortDescription } from "igniteui-webcomponents-core";
/**
 * @hidden
 */
var ColumnGroupDescriptionCollection = /** @class */ /*@__PURE__*/ (function (_super) {
    tslib_1.__extends(ColumnGroupDescriptionCollection, _super);
    function ColumnGroupDescriptionCollection() {
        var _this = _super.call(this) || this;
        _this.f = new SyncableObservableCollection$2(ColumnGroupDescription.$, SortDescription.$, 0);
        _this.a = null;
        var a = _this.f;
        a.compare = function (b, c) {
            if (b.f == c.propertyName) {
                return true;
            }
            return false;
        };
        a.createFrom = function (b) { return new ColumnGroupDescription(2, b.propertyName, b.direction); };
        a.createTo = function (b) {
            var c = b.c;
            return SortDescription.create(b.f, c);
        };
        return _this;
    }
    Object.defineProperty(ColumnGroupDescriptionCollection.prototype, "b", {
        get: function () {
            return this.a;
        },
        set: function (a) {
            if (a == null) {
                this.f.syncTarget = null;
                this.a = null;
                return;
            }
            this.a = a;
            this.f.syncTarget = this.a.getInner();
        },
        enumerable: true,
        configurable: true
    });
    ColumnGroupDescriptionCollection.prototype.g = function (a) {
        return this.f.add(a);
    };
    ColumnGroupDescriptionCollection.prototype.n = function (a, b) {
        this.f.add1(a, b);
    };
    ColumnGroupDescriptionCollection.prototype.m = function () {
        this.f.clear();
    };
    ColumnGroupDescriptionCollection.prototype.get = function (a) {
        return this.f.get(a);
    };
    ColumnGroupDescriptionCollection.prototype.j = function (a) {
        return this.f.indexOf(a);
    };
    ColumnGroupDescriptionCollection.prototype.h = function (a) {
        return this.f.remove1(a);
    };
    ColumnGroupDescriptionCollection.prototype.d = function (a) {
        return this.f.remove(a);
    };
    ColumnGroupDescriptionCollection.prototype.set = function (a, b) {
        return this.f.set(a, b);
    };
    ColumnGroupDescriptionCollection.prototype.size = function () {
        return this.f.size();
    };
    ColumnGroupDescriptionCollection.prototype.l = function (a) {
        this.f.addListener(a);
    };
    ColumnGroupDescriptionCollection.prototype.o = function (a) {
        this.f.removeListener(a);
    };
    Object.defineProperty(ColumnGroupDescriptionCollection.prototype, "i", {
        get: function () {
            return this.f.all;
        },
        enumerable: true,
        configurable: true
    });
    ColumnGroupDescriptionCollection.$t = markType(ColumnGroupDescriptionCollection, 'ColumnGroupDescriptionCollection');
    return ColumnGroupDescriptionCollection;
}(Base));
export { ColumnGroupDescriptionCollection };
//# sourceMappingURL=ColumnGroupDescriptionCollection.js.map
