all files / diagram/objects/ service.js

100% Statements 11/11
100% Branches 0/0
100% Functions 5/5
100% Lines 11/11
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18   1302×   1302×   51×        
define(["require", "exports"], function (require, exports) {
    "use strict";
    Object.defineProperty(exports, "__esModule", { value: true });
    var ServiceLocator = (function () {
        function ServiceLocator() {
            this.services = {};
        }
        ServiceLocator.prototype.register = function (name, type) {
            this.services["" + name] = type;
        };
        ServiceLocator.prototype.getService = function (name) {
            return this.services["" + name];
        };
        return ServiceLocator;
    }());
    exports.ServiceLocator = ServiceLocator;
});