/*
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 { FormatSpecifier } from "./FormatSpecifier";
import { markType } from "./type";
/**
 * @hidden
 */
var DateTimeFormatSpecifier = /** @class */ (function (_super) {
    tslib_1.__extends(DateTimeFormatSpecifier, _super);
    function DateTimeFormatSpecifier() {
        var _this = _super.call(this) || this;
        _this.l = null;
        _this.d = null;
        _this.r = null;
        _this.b = 0;
        _this.c = null;
        _this.f = null;
        _this.p = null;
        _this.m = null;
        _this.s = null;
        _this.j = null;
        _this.k = null;
        _this.h = null;
        _this.u = null;
        _this.g = null;
        _this.v = null;
        _this.o = null;
        _this.e = null;
        _this.i = null;
        _this.n = null;
        _this.q = null;
        _this.t = null;
        _this.b = -1;
        return _this;
    }
    DateTimeFormatSpecifier.prototype.a = function () {
        var a = {};
        if (this.d != null) {
            this.w(a, "dateStyle", this.d);
        }
        if (this.r != null) {
            this.w(a, "timeStyle", this.r);
        }
        if (this.b != -1) {
            this.w(a, "fractionalSecondDigits", this.b);
        }
        if (this.c != null) {
            this.w(a, "calendar", this.c);
        }
        if (this.f != null) {
            this.w(a, "dayPeriod", this.f);
        }
        if (this.p != null) {
            this.w(a, "numberingSystem", this.p);
        }
        if (this.m != null) {
            this.w(a, "localeMatcher", this.m);
        }
        if (this.s != null) {
            this.w(a, "timeZone", this.s);
        }
        if (this.j != null) {
            this.w(a, "hour12", this.j);
        }
        if (this.k != null) {
            this.w(a, "hourCycle", this.k);
        }
        if (this.h != null) {
            this.w(a, "formatMatcher", this.h);
        }
        if (this.u != null) {
            this.w(a, "weekDay", this.u);
        }
        if (this.g != null) {
            this.w(a, "era", this.g);
        }
        if (this.v != null) {
            this.w(a, "year", this.v);
        }
        if (this.o != null) {
            this.w(a, "month", this.o);
        }
        if (this.e != null) {
            this.w(a, "day", this.e);
        }
        if (this.i != null) {
            this.w(a, "hour", this.i);
        }
        if (this.n != null) {
            this.w(a, "minute", this.n);
        }
        if (this.q != null) {
            this.w(a, "second", this.q);
        }
        if (this.t != null) {
            this.w(a, "timeZoneName", this.t);
        }
        var locale_ = this.l;
        var options_ = a;
        return new Intl.DateTimeFormat(locale_, options_);
    };
    DateTimeFormatSpecifier.prototype.w = function (options_, propertyName_, value_) {
        options_[propertyName_] = value_;
    };
    DateTimeFormatSpecifier.$t = markType(DateTimeFormatSpecifier, 'DateTimeFormatSpecifier', FormatSpecifier.$);
    return DateTimeFormatSpecifier;
}(FormatSpecifier));
export { DateTimeFormatSpecifier };
//# sourceMappingURL=DateTimeFormatSpecifier.js.map