var uniflash;
(function (uniflash) {
    var Context = (function () {
        function Context(ufSession, $stateParams) {
            this.ufSession = ufSession;
            this.$stateParams = $stateParams;
        }
        Context.prototype.getCurrentCore = function () {
            var cores = this.ufSession.queryConfig().cores;
            var coreName = this.$stateParams.coreName;
            var core = _.find(cores, { name: coreName }) || cores[0];
            return core;
        };
        Context.$inject = ['ufSession', '$stateParams'];
        return Context;
    }());
    uniflash.Context = Context;
    angular.module('uniflash').service('ufContext', Context);
})(uniflash || (uniflash = {}));
