"use strict";
var __extends = (this && this.__extends) || (function () {
    var extendStatics = Object.setPrototypeOf ||
        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
    return function (d, b) {
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
var ConfigPreload_1 = require("./ConfigPreload");
var BaseModel_1 = require("./BaseModel");
var Config = /** @class */ (function (_super) {
    __extends(Config, _super);
    function Config() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    Object.defineProperty(Config.prototype, "nextUrl", {
        get: function () {
            return this._getValue('default:nextUrl');
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "enableAutoAdvance", {
        get: function () {
            return this._getValue('default:enableAutoAdvance') === "1";
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "enableChromecast", {
        get: function () {
            return this._getValue('default:enableChromecast') === "1";
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "startTime", {
        get: function () {
            var element = this._getElementOrUndefined('default:startTime');
            if (!element)
                return 0;
            return parseFloat(element.textContent);
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "isAutoPlay", {
        get: function () {
            var element = this._getElementOrUndefined('default:isAutoPlay');
            return !!element;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "isClickThrough", {
        get: function () {
            var element = this._getElementOrUndefined('default:isClickThrough');
            return !!element;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(Config.prototype, "preload", {
        get: function () {
            return new ConfigPreload_1.ConfigPreload(this._getElement('default:preload'));
        },
        enumerable: true,
        configurable: true
    });
    return Config;
}(BaseModel_1.BaseModel));
exports.Config = Config;
//# sourceMappingURL=Config.js.map