/**
 * @fileoverview added by tsickle
 * @suppress {checkTypes} checked by tsc
 */
import { Directive, Input } from '@angular/core';
import { NG_VALIDATORS } from '@angular/forms';
var CheckboxRequiredValidator = /** @class */ (function () {
    function CheckboxRequiredValidator() {
    }
    Object.defineProperty(CheckboxRequiredValidator.prototype, "required", {
        get: /**
         * @return {?}
         */
        function () {
            return this._required;
        },
        set: /**
         * @param {?} value
         * @return {?}
         */
        function (value) {
            this._required = value !== false && value !== null;
            if (this._onChange) {
                this._onChange();
            }
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} c
     * @return {?}
     */
    CheckboxRequiredValidator.prototype.validate = /**
     * @param {?} c
     * @return {?}
     */
    function (c) {
        if (this.required) {
            return c.value === true ? null : { 'required': true };
        }
        return null;
    };
    /**
     * @param {?} fn
     * @return {?}
     */
    CheckboxRequiredValidator.prototype.registerOnValidatorChange = /**
     * @param {?} fn
     * @return {?}
     */
    function (fn) {
        this._onChange = fn;
    };
    CheckboxRequiredValidator.decorators = [
        { type: Directive, args: [{
                    /* tslint:disable */
                    selector: 'ui-input[required][type=checkbox]',
                    /* tslint:enable */
                    providers: [{
                            provide: NG_VALIDATORS,
                            useExisting: CheckboxRequiredValidator,
                            multi: true
                        }]
                },] },
    ];
    /** @nocollapse */
    CheckboxRequiredValidator.propDecorators = {
        "required": [{ type: Input },],
    };
    return CheckboxRequiredValidator;
}());
export { CheckboxRequiredValidator };
function CheckboxRequiredValidator_tsickle_Closure_declarations() {
    /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
    CheckboxRequiredValidator.decorators;
    /**
     * @nocollapse
     * @type {function(): !Array<(null|{type: ?, decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>)})>}
     */
    CheckboxRequiredValidator.ctorParameters;
    /** @type {!Object<string,!Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
    CheckboxRequiredValidator.propDecorators;
    /** @type {?} */
    CheckboxRequiredValidator.prototype._required;
    /** @type {?} */
    CheckboxRequiredValidator.prototype._onChange;
}
var SwitchRequiredValidator = /** @class */ (function () {
    function SwitchRequiredValidator() {
    }
    Object.defineProperty(SwitchRequiredValidator.prototype, "required", {
        get: /**
         * @return {?}
         */
        function () {
            return this._required;
        },
        set: /**
         * @param {?} value
         * @return {?}
         */
        function (value) {
            this._required = value !== false && value !== null;
            if (this._onChange) {
                this._onChange();
            }
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} c
     * @return {?}
     */
    SwitchRequiredValidator.prototype.validate = /**
     * @param {?} c
     * @return {?}
     */
    function (c) {
        if (this.required) {
            return c.value === true ? null : { 'required': true };
        }
        return null;
    };
    /**
     * @param {?} fn
     * @return {?}
     */
    SwitchRequiredValidator.prototype.registerOnValidatorChange = /**
     * @param {?} fn
     * @return {?}
     */
    function (fn) {
        this._onChange = fn;
    };
    SwitchRequiredValidator.decorators = [
        { type: Directive, args: [{
                    /* tslint:disable */
                    selector: 'ui-switch[required]',
                    /* tslint:enable */
                    providers: [{
                            provide: NG_VALIDATORS,
                            useExisting: SwitchRequiredValidator,
                            multi: true
                        }]
                },] },
    ];
    /** @nocollapse */
    SwitchRequiredValidator.propDecorators = {
        "required": [{ type: Input },],
    };
    return SwitchRequiredValidator;
}());
export { SwitchRequiredValidator };
function SwitchRequiredValidator_tsickle_Closure_declarations() {
    /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
    SwitchRequiredValidator.decorators;
    /**
     * @nocollapse
     * @type {function(): !Array<(null|{type: ?, decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>)})>}
     */
    SwitchRequiredValidator.ctorParameters;
    /** @type {!Object<string,!Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
    SwitchRequiredValidator.propDecorators;
    /** @type {?} */
    SwitchRequiredValidator.prototype._required;
    /** @type {?} */
    SwitchRequiredValidator.prototype._onChange;
}
var RadioRequiredValidator = /** @class */ (function () {
    function RadioRequiredValidator() {
    }
    Object.defineProperty(RadioRequiredValidator.prototype, "required", {
        get: /**
         * @return {?}
         */
        function () {
            return this._required;
        },
        set: /**
         * @param {?} value
         * @return {?}
         */
        function (value) {
            this._required = value !== false && value !== null;
            if (this._onChange) {
                this._onChange();
            }
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} c
     * @return {?}
     */
    RadioRequiredValidator.prototype.validate = /**
     * @param {?} c
     * @return {?}
     */
    function (c) {
        if (this.required) {
            return c.value !== '' && c.value !== undefined && c.value !== null ? null : { 'required': true };
        }
        return null;
    };
    /**
     * @param {?} fn
     * @return {?}
     */
    RadioRequiredValidator.prototype.registerOnValidatorChange = /**
     * @param {?} fn
     * @return {?}
     */
    function (fn) {
        this._onChange = fn;
    };
    RadioRequiredValidator.decorators = [
        { type: Directive, args: [{
                    /* tslint:disable */
                    selector: 'ui-input[required][type=radio]',
                    /* tslint:enable */
                    providers: [{
                            provide: NG_VALIDATORS,
                            useExisting: RadioRequiredValidator,
                            multi: true
                        }]
                },] },
    ];
    /** @nocollapse */
    RadioRequiredValidator.propDecorators = {
        "required": [{ type: Input },],
    };
    return RadioRequiredValidator;
}());
export { RadioRequiredValidator };
function RadioRequiredValidator_tsickle_Closure_declarations() {
    /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
    RadioRequiredValidator.decorators;
    /**
     * @nocollapse
     * @type {function(): !Array<(null|{type: ?, decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>)})>}
     */
    RadioRequiredValidator.ctorParameters;
    /** @type {!Object<string,!Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
    RadioRequiredValidator.propDecorators;
    /** @type {?} */
    RadioRequiredValidator.prototype._required;
    /** @type {?} */
    RadioRequiredValidator.prototype._onChange;
}
var SelectRequiredValidator = /** @class */ (function () {
    function SelectRequiredValidator() {
    }
    Object.defineProperty(SelectRequiredValidator.prototype, "required", {
        get: /**
         * @return {?}
         */
        function () {
            return this._required;
        },
        set: /**
         * @param {?} value
         * @return {?}
         */
        function (value) {
            this._required = value !== false && value !== null;
            if (this._onChange) {
                this._onChange();
            }
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} c
     * @return {?}
     */
    SelectRequiredValidator.prototype.validate = /**
     * @param {?} c
     * @return {?}
     */
    function (c) {
        if (this.required) {
            return c.value !== '' && c.value !== undefined && c.value !== null ? null : { 'required': true };
        }
        return null;
    };
    /**
     * @param {?} fn
     * @return {?}
     */
    SelectRequiredValidator.prototype.registerOnValidatorChange = /**
     * @param {?} fn
     * @return {?}
     */
    function (fn) {
        this._onChange = fn;
    };
    SelectRequiredValidator.decorators = [
        { type: Directive, args: [{
                    /* tslint:disable */
                    selector: 'ui-select[required]',
                    /* tslint:enable */
                    providers: [{
                            provide: NG_VALIDATORS,
                            useExisting: SelectRequiredValidator,
                            multi: true
                        }]
                },] },
    ];
    /** @nocollapse */
    SelectRequiredValidator.propDecorators = {
        "required": [{ type: Input },],
    };
    return SelectRequiredValidator;
}());
export { SelectRequiredValidator };
function SelectRequiredValidator_tsickle_Closure_declarations() {
    /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
    SelectRequiredValidator.decorators;
    /**
     * @nocollapse
     * @type {function(): !Array<(null|{type: ?, decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>)})>}
     */
    SelectRequiredValidator.ctorParameters;
    /** @type {!Object<string,!Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
    SelectRequiredValidator.propDecorators;
    /** @type {?} */
    SelectRequiredValidator.prototype._required;
    /** @type {?} */
    SelectRequiredValidator.prototype._onChange;
}
var DateRequiredValidator = /** @class */ (function () {
    function DateRequiredValidator() {
    }
    Object.defineProperty(DateRequiredValidator.prototype, "required", {
        get: /**
         * @return {?}
         */
        function () {
            return this._required;
        },
        set: /**
         * @param {?} value
         * @return {?}
         */
        function (value) {
            this._required = value !== false && value !== null;
            if (this._onChange) {
                this._onChange();
            }
        },
        enumerable: true,
        configurable: true
    });
    /**
     * @param {?} c
     * @return {?}
     */
    DateRequiredValidator.prototype.validate = /**
     * @param {?} c
     * @return {?}
     */
    function (c) {
        if (this.required) {
            return c.value !== '' && c.value !== undefined && c.value !== null ? null : { 'required': true };
        }
        return null;
    };
    /**
     * @param {?} fn
     * @return {?}
     */
    DateRequiredValidator.prototype.registerOnValidatorChange = /**
     * @param {?} fn
     * @return {?}
     */
    function (fn) {
        this._onChange = fn;
    };
    DateRequiredValidator.decorators = [
        { type: Directive, args: [{
                    /* tslint:disable */
                    selector: 'ui-input[type=date][required]',
                    /* tslint:enable */
                    providers: [{
                            provide: NG_VALIDATORS,
                            useExisting: DateRequiredValidator,
                            multi: true
                        }]
                },] },
    ];
    /** @nocollapse */
    DateRequiredValidator.propDecorators = {
        "required": [{ type: Input },],
    };
    return DateRequiredValidator;
}());
export { DateRequiredValidator };
function DateRequiredValidator_tsickle_Closure_declarations() {
    /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
    DateRequiredValidator.decorators;
    /**
     * @nocollapse
     * @type {function(): !Array<(null|{type: ?, decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>)})>}
     */
    DateRequiredValidator.ctorParameters;
    /** @type {!Object<string,!Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
    DateRequiredValidator.propDecorators;
    /** @type {?} */
    DateRequiredValidator.prototype._required;
    /** @type {?} */
    DateRequiredValidator.prototype._onChange;
}

//# sourceMappingURL=data:application/json;base64, 