"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
var core_1 = require("@angular/core");
var typescript_angular_utilities_1 = require("typescript-angular-utilities");
var __object = typescript_angular_utilities_1.services.object;
var IsEmptyPipe = (function () {
    function IsEmptyPipe(objectUtility) {
        this.objectUtility = objectUtility;
    }
    IsEmptyPipe.prototype.transform = function (input, trueWhenEmpty) {
        var isEmpty = this.objectUtility.isNullOrEmpty(input);
        if (trueWhenEmpty === false) {
            return !isEmpty;
        }
        return isEmpty;
    };
    return IsEmptyPipe;
}());
IsEmptyPipe = __decorate([
    core_1.Pipe({ name: 'isEmpty' }),
    __metadata("design:paramtypes", [__object.ObjectUtility])
], IsEmptyPipe);
exports.IsEmptyPipe = IsEmptyPipe;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaXNFbXB0eS5waXBlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiaXNFbXB0eS5waXBlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQSxzQ0FBb0Q7QUFFcEQsNkVBQXdEO0FBQ3hELElBQU8sUUFBUSxHQUFHLHVDQUFRLENBQUMsTUFBTSxDQUFDO0FBR2xDLElBQWEsV0FBVztJQUd2QixxQkFBWSxhQUFxQztRQUNoRCxJQUFJLENBQUMsYUFBYSxHQUFHLGFBQWEsQ0FBQztJQUNwQyxDQUFDO0lBQ0QsK0JBQVMsR0FBVCxVQUFVLEtBQVUsRUFBRSxhQUF1QjtRQUM1QyxJQUFJLE9BQU8sR0FBWSxJQUFJLENBQUMsYUFBYSxDQUFDLGFBQWEsQ0FBQyxLQUFLLENBQUMsQ0FBQztRQUUvRCxFQUFFLENBQUMsQ0FBQyxhQUFhLEtBQUssS0FBSyxDQUFDLENBQUMsQ0FBQztZQUM3QixNQUFNLENBQUMsQ0FBQyxPQUFPLENBQUM7UUFDakIsQ0FBQztRQUNELE1BQU0sQ0FBQyxPQUFPLENBQUM7SUFDaEIsQ0FBQztJQUNGLGtCQUFDO0FBQUQsQ0FBQyxBQWRELElBY0M7QUFkWSxXQUFXO0lBRHZCLFdBQUksQ0FBQyxFQUFFLElBQUksRUFBRSxTQUFTLEVBQUUsQ0FBQztxQ0FJRSxRQUFRLENBQUMsYUFBYTtHQUhyQyxXQUFXLENBY3ZCO0FBZFksa0NBQVcifQ==