"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 __date = typescript_angular_utilities_1.services.date;
var __string = typescript_angular_utilities_1.services.string;
var __transform = typescript_angular_utilities_1.services.transform;
var cardFilters = require("../filters/index");
var FilterBuilderOld = (function () {
    function FilterBuilderOld(injector, object, string, date, transform) {
        this.injector = injector;
        this.object = object;
        this.date = date;
        this.transformService = transform;
    }
    FilterBuilderOld.prototype.init = function (parent) {
        this.parent = parent;
        this.parent._filters = [];
    };
    FilterBuilderOld.prototype.buildFilterGroup = function (settings) {
        var filter = new cardFilters.FilterGroupOld(settings, this.object);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.buildModeFilterGroup = function (settings) {
        var filter = new cardFilters.ModeFilterGroupOld(settings, this.object, this.transformService);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.buildRangeFilterGroup = function (settings) {
        var filter = new cardFilters.RangeFilterGroupOld(settings, this.object, this.transformService);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.buildSelectFilter = function (settings) {
        var filter = new cardFilters.SelectFilterOld(settings, this.object, this.transformService);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.buildDateFilter = function (settings) {
        var filter = new cardFilters.DateFilterOld(settings, this.date, this.transformService);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.buildColumnSearchFilter = function () {
        var filter = new cardFilters.ColumnSearchFilter(this.object, this.string, this.transformService);
        this.parent._filters.push(filter);
        return filter;
    };
    FilterBuilderOld.prototype.addCustomFilter = function (filter) {
        this.parent._filters.push(filter);
    };
    return FilterBuilderOld;
}());
FilterBuilderOld = __decorate([
    core_1.Injectable(),
    __metadata("design:paramtypes", [core_1.Injector, __object.ObjectUtility, __string.StringUtility, __date.DateUtility, __transform.TransformService])
], FilterBuilderOld);
exports.FilterBuilderOld = FilterBuilderOld;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZmlsdGVyQnVpbGRlck9sZC5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZmlsdGVyQnVpbGRlck9sZC5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7QUFBQSxzQ0FBcUQ7QUFFckQsNkVBQWlFO0FBQ2pFLElBQU8sUUFBUSxHQUFHLHVDQUFRLENBQUMsTUFBTSxDQUFDO0FBQ2xDLElBQU8sTUFBTSxHQUFHLHVDQUFRLENBQUMsSUFBSSxDQUFDO0FBQzlCLElBQU8sUUFBUSxHQUFHLHVDQUFRLENBQUMsTUFBTSxDQUFDO0FBQ2xDLElBQU8sV0FBVyxHQUFHLHVDQUFRLENBQUMsU0FBUyxDQUFDO0FBRXhDLDhDQUFnRDtBQWNoRCxJQUFhLGdCQUFnQjtJQVE1QiwwQkFBWSxRQUFrQixFQUMxQixNQUE4QixFQUM5QixNQUE4QixFQUM5QixJQUF3QixFQUN4QixTQUF1QztRQUMxQyxJQUFJLENBQUMsUUFBUSxHQUFHLFFBQVEsQ0FBQztRQUN6QixJQUFJLENBQUMsTUFBTSxHQUFHLE1BQU0sQ0FBQztRQUNyQixJQUFJLENBQUMsSUFBSSxHQ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