"use strict";
var IOSLogFilter = (function () {
    function IOSLogFilter($loggingLevels) {
        this.$loggingLevels = $loggingLevels;
    }
    IOSLogFilter.prototype.filterData = function (data, logLevel) {
        var specifiedLogLevel = (logLevel || '').toUpperCase();
        if (specifiedLogLevel === this.$loggingLevels.info) {
            var matchingInfoMessage = data.match(IOSLogFilter.INFO_FILTER_REGEX);
            return matchingInfoMessage ? matchingInfoMessage[2] : null;
        }
        return data;
    };
    IOSLogFilter.INFO_FILTER_REGEX = /^.*?(AppBuilder|Cordova|NativeScript).*?(<Notice>:.*?(CONSOLE LOG|JS ERROR).*?|<Warning>:.*?|<Error>:.*?)$/im;
    return IOSLogFilter;
})();
exports.IOSLogFilter = IOSLogFilter;
$injector.register("iOSLogFilter", IOSLogFilter);
