import { BaseInputElement } from "./index";
import { ElementType } from "../../../constants/UIKitConstants";
/**
 * Represents a DateTime input element.
 */
export class DateTimeElement extends BaseInputElement {
    /**
     * The label of the input element.
     */
    label;
    mode;
    timezoneCode;
    to;
    from;
    dateTimeFormat;
    /**
     * The default value to be selected in the DateTime.
     */
    defaultValue;
    /**
     * Creates a new instance of DateTimeInput.
     * @param elementId - The ID of the input element.
     * @param label - The label of the input element.
     * @param options - The options available for the DateTime input element.
     */
    constructor(elementId, json) {
        super(elementId, ElementType.dateTime);
        Object.assign(this, json);
    }
    getTimeZone() {
        return this.timezoneCode;
    }
    setTimeZone(timezoneCode) {
        return (this.timezoneCode = timezoneCode);
    }
    getMode() {
        return this.mode;
    }
    setMode(mode) {
        return (this.mode = mode);
    }
    getToDateTime() {
        return this.to;
    }
    setToDateTime(to) {
        return (this.to = to);
    }
    getFromDateTime() {
        return this.from;
    }
    setFromDateTime(from) {
        return (this.from = from);
    }
    getDateTimeFormat() {
        return this.dateTimeFormat;
    }
    setDateTimeFormat(dateTimeFormat) {
        return (this.dateTimeFormat = dateTimeFormat);
    }
    /**
     * Gets the label of the input element.
     * @returns The label of the input element.
     */
    getLabel() {
        return this.label;
    }
    /**
     * Gets the default value to be selected in the DateTime.
     * @returns The default value to be selected in the DateTime.
     */
    getDefaultValue() {
        return this.defaultValue;
    }
    /**
     * Sets the default value to be selected in the DateTime.
     * @param defaultValue - The default value to be selected in the DateTime.
     */
    setDefaultValue(defaultValue) {
        this.defaultValue = defaultValue;
    }
    static fromJSON(json) {
        const dateTimeElement = new DateTimeElement(json.elementId, json);
        if (json.defaultValue)
            dateTimeElement.setDefaultValue(json.defaultValue);
        return dateTimeElement;
    }
}
//# sourceMappingURL=DateTimeElement.js.map