/*
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-angular-core";
/**
 * @hidden
 */
var ObjectPool$1 = /** @class */ (function (_super) {
    tslib_1.__extends(ObjectPool$1, _super);
    function ObjectPool$1($t, a) {
        var _this = _super.call(this) || this;
        _this.$t = null;
        _this.a = new Array(1024);
        _this.c = null;
        _this.d = 0;
        _this.$t = $t;
        _this.$type = _this.$type.specialize(_this.$t);
        _this.c = a;
        return _this;
    }
    ObjectPool$1.prototype.b = function () {
        if (this.d == 0) {
            return this.c();
        }
        return this.a[--this.d];
    };
    ObjectPool$1.prototype.f = function (a) {
        if (this.d == 1024) {
            return;
        }
        this.a[this.d++] = a;
    };
    ObjectPool$1.$t = markType(ObjectPool$1, 'ObjectPool$1');
    return ObjectPool$1;
}(Base));
export { ObjectPool$1 };
//# sourceMappingURL=ObjectPool$1.js.map