/*eslint no-unused-vars: 0*/
/*eslint strict: 0*/
var $buoop = { vs: {i:9, f:25, o:12.1, s:7}, c:2 };
function $buo_f(){
  var e = document.createElement('script');
  e.src = '//browser-update.org/update.min.js';
  document.body.appendChild(e);
}
try {document.addEventListener('DOMContentLoaded', $buo_f, false);}
catch(e){window.attachEvent('onload', $buo_f);}

/******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};

/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {

/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId])
/******/ 			return installedModules[moduleId].exports;

/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			exports: {},
/******/ 			id: moduleId,
/******/ 			loaded: false
/******/ 		};

/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);

/******/ 		// Flag the module as loaded
/******/ 		module.loaded = true;

/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}


/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;

/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;

/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";

/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ function(module, exports, __webpack_require__) {

	/* WEBPACK VAR INJECTION */(function(global) {"use strict";
	__webpack_require__(1);
	var event_target_1 = __webpack_require__(2);
	var define_property_1 = __webpack_require__(4);
	var register_element_1 = __webpack_require__(5);
	var property_descriptor_1 = __webpack_require__(6);
	var timers_1 = __webpack_require__(8);
	var utils_1 = __webpack_require__(3);
	var set = 'set';
	var clear = 'clear';
	var blockingMethods = ['alert', 'prompt', 'confirm'];
	var _global = typeof window == 'undefined' ? global : window;
	timers_1.patchTimer(_global, set, clear, 'Timeout');
	timers_1.patchTimer(_global, set, clear, 'Interval');
	timers_1.patchTimer(_global, set, clear, 'Immediate');
	timers_1.patchTimer(_global, 'request', 'cancelMacroTask', 'AnimationFrame');
	timers_1.patchTimer(_global, 'mozRequest', 'mozCancel', 'AnimationFrame');
	timers_1.patchTimer(_global, 'webkitRequest', 'webkitCancel', 'AnimationFrame');
	for (var i = 0; i < blockingMethods.length; i++) {
	    var name = blockingMethods[i];
	    utils_1.patchMethod(_global, name, function (delegate, symbol, name) {
	        return function (s, args) {
	            return Zone.current.run(delegate, _global, args, name);
	        };
	    });
	}
	event_target_1.eventTargetPatch(_global);
	property_descriptor_1.propertyDescriptorPatch(_global);
	utils_1.patchClass('MutationObserver');
	utils_1.patchClass('WebKitMutationObserver');
	utils_1.patchClass('FileReader');
	define_property_1.propertyPatch();
	register_element_1.registerElementPatch(_global);
	// Treat XMLHTTPRequest as a macrotask.
	patchXHR(_global);
	var XHR_TASK = utils_1.zoneSymbol('xhrTask');
	function patchXHR(window) {
	    function findPendingTask(target) {
	        var pendingTask = target[XHR_TASK];
	        return pendingTask;
	    }
	    function scheduleTask(task) {
	        var data = task.data;
	        data.target.addEventListener('readystatechange', function () {
	            if (data.target.readyState === XMLHttpRequest.DONE) {
	                if (!data.aborted) {
	                    task.invoke();
	                }
	            }
	        });
	        var storedTask = data.target[XHR_TASK];
	        if (!storedTask) {
	            data.target[XHR_TASK] = task;
	        }
	        setNative.apply(data.target, data.args);
	        return task;
	    }
	    function placeholderCallback() {
	    }
	    function clearTask(task) {
	        var data = task.data;
	        // Note - ideally, we would call data.target.removeEventListener here, but it's too late
	        // to prevent it from firing. So instead, we store info for the event listener.
	        data.aborted = true;
	        return clearNative.apply(data.target, data.args);
	    }
	    var setNative = utils_1.patchMethod(window.XMLHttpRequest.prototype, 'send', function () { return function (self, args) {
	        var zone = Zone.current;
	        var options = {
	            target: self,
	            isPeriodic: false,
	            delay: null,
	            args: args,
	            aborted: false
	        };
	        return zone.scheduleMacroTask('XMLHttpRequest.send', placeholderCallback, options, scheduleTask, clearTask);
	    }; });
	    var clearNative = utils_1.patchMethod(window.XMLHttpRequest.prototype, 'abort', function (delegate) { return function (self, args) {
	        var task = findPendingTask(self);
	        if (task && typeof task.type == 'string') {
	            // If the XHR has already completed, do nothing.
	            if (task.cancelFn == null) {
	                return;
	            }
	            task.zone.cancelTask(task);
	        }
	        // Otherwise, we are trying to abort an XHR which has not yet been sent, so there is no task to cancel. Do nothing.
	    }; });
	}
	/// GEO_LOCATION
	if (_global['navigator'] && _global['navigator'].geolocation) {
	    utils_1.patchPrototype(_global['navigator'].geolocation, [
	        'getCurrentPosition',
	        'watchPosition'
	    ]);
	}

	/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))

/***/ },
/* 1 */
/***/ function(module, exports) {

	/* WEBPACK VAR INJECTION */(function(global) {;
	;
	var Zone = (function (global) {
	    var Zone = (function () {
	        function Zone(parent, zoneSpec) {
	            this._properties = null;
	            this._parent = parent;
	            this._name = zoneSpec ? zoneSpec.name || 'unnamed' : '<root>';
	            this._properties = zoneSpec && zoneSpec.properties || {};
	            this._zoneDelegate = new ZoneDelegate(this, this._parent && this._parent._zoneDelegate, zoneSpec);
	        }
	        Object.defineProperty(Zone, "current", {
	            get: function () { return _currentZone; },
	            enumerable: true,
	            configurable: true
	        });
	        ;
	        Object.defineProperty(Zone, "currentTask", {
	            get: function () { return _currentTask; },
	            enumerable: true,
	            configurable: true
	        });
	        ;
	        Object.defineProperty(Zone.prototype, "parent", {
	            get: function () { return this._parent; },
	            enumerable: true,
	            configurable: true
	        });
	        ;
	        Object.defineProperty(Zone.prototype, "name", {
	            get: function () { return this._name; },
	            enumerable: true,
	            configurable: true
	        });
	        ;
	        Zone.prototype.get = function (key) {
	            var current = this;
	            while (current) {
	                if (current._properties.hasOwnProperty(key)) {
	                    return current._properties[key];
	                }
	                current = current._parent;
	            }
	        };
	        Zone.prototype.fork = function (zoneSpec) {
	            if (!zoneSpec)
	                throw new Error('ZoneSpec required!');
	            return this._zoneDelegate.fork(this, zoneSpec);
	        };
	        Zone.prototype.wrap = function (callback, source) {
	            if (typeof callback !== 'function') {
	                throw new Error('Expecting function got: ' + callback);
	            }
	            var _callback = this._zoneDelegate.intercept(this, callback, source);
	            var zone = this;
	            return function () {
	                return zone.runGuarded(_callback, this, arguments, source);
	            };
	        };
	        Zone.prototype.run = function (callback, applyThis, applyArgs, source) {
	            if (applyThis === void 0) { applyThis = null; }
	            if (applyArgs === void 0) { applyArgs = null; }
	            if (source === void 0) { source = null; }
	            var oldZone = _currentZone;
	            _currentZone = this;
	            try {
	                return this._zoneDelegate.invoke(this, callback, applyThis, applyArgs, source);
	            }
	            finally {
	                _currentZone = oldZone;
	            }
	        };
	        Zone.prototype.runGuarded = function (callback, applyThis, applyArgs, source) {
	            if (applyThis === void 0) { applyThis = null; }
	            if (applyArgs === void 0) { applyArgs = null; }
	            if (source === void 0) { source = null; }
	            var oldZone = _currentZone;
	            _currentZone = this;
	            try {
	                try {
	                    return this._zoneDelegate.invoke(this, callback, applyThis, applyArgs, source);
	                }
	                catch (error) {
	                    if (this._zoneDelegate.handleError(this, error)) {
	                        throw error;
	                    }
	                }
	            }
	            finally {
	                _currentZone = oldZone;
	            }
	        };
	        Zone.prototype.runTask = function (task, applyThis, applyArgs) {
	            task.runCount++;
	            if (task.zone != this)
	                throw new Error('A task can only be run in the zone which created it! (Creation: ' +
	                    task.zone.name + '; Execution: ' + this.name + ')');
	            var previousTask = _currentTask;
	            _currentTask = task;
	            var oldZone = _currentZone;
	            _currentZone = this;
	            try {
	                if (task.type == 'macroTask' && task.data && !task.data.isPeriodic) {
	                    task.cancelFn = null;
	                }
	                try {
	                    return this._zoneDelegate.invokeTask(this, task, applyThis, applyArgs);
	                }
	                catch (error) {
	                    if (this._zoneDelegate.handleError(this, error)) {
	                        throw error;
	                    }
	                }
	            }
	            finally {
	                _currentZone = oldZone;
	                _currentTask = previousTask;
	            }
	        };
	        Zone.prototype.scheduleMicroTask = function (source, callback, data, customSchedule) {
	            return this._zoneDelegate.scheduleTask(this, new ZoneTask('microTask', this, source, callback, data, customSchedule, null));
	        };
	        Zone.prototype.scheduleMacroTask = function (source, callback, data, customSchedule, customCancel) {
	            return this._zoneDelegate.scheduleTask(this, new ZoneTask('macroTask', this, source, callback, data, customSchedule, customCancel));
	        };
	        Zone.prototype.scheduleEventTask = function (source, callback, data, customSchedule, customCancel) {
	            return this._zoneDelegate.scheduleTask(this, new ZoneTask('eventTask', this, source, callback, data, customSchedule, customCancel));
	        };
	        Zone.prototype.cancelTask = function (task) {
	            var value = this._zoneDelegate.cancelTask(this, task);
	            task.runCount = -1;
	            task.cancelFn = null;
	            return value;
	        };
	        Zone.__symbol__ = __symbol__;
	        return Zone;
	    }());
	    ;
	    var ZoneDelegate = (function () {
	        function ZoneDelegate(zone, parentDelegate, zoneSpec) {
	            this._taskCounts = { microTask: 0, macroTask: 0, eventTask: 0 };
	            this.zone = zone;
	            this._parentDelegate = parentDelegate;
	            this._forkZS = zoneSpec && (zoneSpec && zoneSpec.onFork ? zoneSpec : parentDelegate._forkZS);
	            this._forkDlgt = zoneSpec && (zoneSpec.onFork ? parentDelegate : parentDelegate._forkDlgt);
	            this._interceptZS = zoneSpec && (zoneSpec.onIntercept ? zoneSpec : parentDelegate._interceptZS);
	            this._interceptDlgt = zoneSpec && (zoneSpec.onIntercept ? parentDelegate : parentDelegate._interceptDlgt);
	            this._invokeZS = zoneSpec && (zoneSpec.onInvoke ? zoneSpec : parentDelegate._invokeZS);
	            this._invokeDlgt = zoneSpec && (zoneSpec.onInvoke ? parentDelegate : parentDelegate._invokeDlgt);
	            this._handleErrorZS = zoneSpec && (zoneSpec.onHandleError ? zoneSpec : parentDelegate._handleErrorZS);
	            this._handleErrorDlgt = zoneSpec && (zoneSpec.onHandleError ? parentDelegate : parentDelegate._handleErrorDlgt);
	            this._scheduleTaskZS = zoneSpec && (zoneSpec.onScheduleTask ? zoneSpec : parentDelegate._scheduleTaskZS);
	            this._scheduleTaskDlgt = zoneSpec && (zoneSpec.onScheduleTask ? parentDelegate : parentDelegate._scheduleTaskDlgt);
	            this._invokeTaskZS = zoneSpec && (zoneSpec.onInvokeTask ? zoneSpec : parentDelegate._invokeTaskZS);
	            this._invokeTaskDlgt = zoneSpec && (zoneSpec.onInvokeTask ? parentDelegate : parentDelegate._invokeTaskDlgt);
	            this._cancelTaskZS = zoneSpec && (zoneSpec.onCancelTask ? zoneSpec : parentDelegate._cancelTaskZS);
	            this._cancelTaskDlgt = zoneSpec && (zoneSpec.onCancelTask ? parentDelegate : parentDelegate._cancelTaskDlgt);
	            this._hasTaskZS = zoneSpec && (zoneSpec.onHasTask ? zoneSpec : parentDelegate._hasTaskZS);
	            this._hasTaskDlgt = zoneSpec && (zoneSpec.onHasTask ? parentDelegate : parentDelegate._hasTaskDlgt);
	        }
	        ZoneDelegate.prototype.fork = function (targetZone, zoneSpec) {
	            return this._forkZS
	                ? this._forkZS.onFork(this._forkDlgt, this.zone, targetZone, zoneSpec)
	                : new Zone(targetZone, zoneSpec);
	        };
	        ZoneDelegate.prototype.intercept = function (targetZone, callback, source) {
	            return this._interceptZS
	                ? this._interceptZS.onIntercept(this._interceptDlgt, this.zone, targetZone, callback, source)
	                : callback;
	        };
	        ZoneDelegate.prototype.invoke = function (targetZone, callback, applyThis, applyArgs, source) {
	            return this._invokeZS
	                ? this._invokeZS.onInvoke(this._invokeDlgt, this.zone, targetZone, callback, applyThis, applyArgs, source)
	                : callback.apply(applyThis, applyArgs);
	        };
	        ZoneDelegate.prototype.handleError = function (targetZone, error) {
	            return this._handleErrorZS
	                ? this._handleErrorZS.onHandleError(this._handleErrorDlgt, this.zone, targetZone, error)
	                : true;
	        };
	        ZoneDelegate.prototype.scheduleTask = function (targetZone, task) {
	            try {
	                if (this._scheduleTaskZS) {
	                    return this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt, this.zone, targetZone, task);
	                }
	                else if (task.scheduleFn) {
	                    task.scheduleFn(task);
	                }
	                else if (task.type == 'microTask') {
	                    scheduleMicroTask(task);
	                }
	                else {
	                    throw new Error('Task is missing scheduleFn.');
	                }
	                return task;
	            }
	            finally {
	                if (targetZone == this.zone) {
	                    this._updateTaskCount(task.type, 1);
	                }
	            }
	        };
	        ZoneDelegate.prototype.invokeTask = function (targetZone, task, applyThis, applyArgs) {
	            try {
	                return this._invokeTaskZS
	                    ? this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt, this.zone, targetZone, task, applyThis, applyArgs)
	                    : task.callback.apply(applyThis, applyArgs);
	            }
	            finally {
	                if (targetZone == this.zone && (task.type != 'eventTask') && !(task.data && task.data.isPeriodic)) {
	                    this._updateTaskCount(task.type, -1);
	                }
	            }
	        };
	        ZoneDelegate.prototype.cancelTask = function (targetZone, task) {
	            var value;
	            if (this._cancelTaskZS) {
	                value = this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt, this.zone, targetZone, task);
	            }
	            else if (!task.cancelFn) {
	                throw new Error('Task does not support cancellation, or is already canceled.');
	            }
	            else {
	                value = task.cancelFn(task);
	            }
	            if (targetZone == this.zone) {
	                // this should not be in the finally block, because exceptions assume not canceled.
	                this._updateTaskCount(task.type, -1);
	            }
	            return value;
	        };
	        ZoneDelegate.prototype.hasTask = function (targetZone, isEmpty) {
	            return this._hasTaskZS && this._hasTaskZS.onHasTask(this._hasTaskDlgt, this.zone, targetZone, isEmpty);
	        };
	        ZoneDelegate.prototype._updateTaskCount = function (type, count) {
	            var counts = this._taskCounts;
	            var prev = counts[type];
	            var next = counts[type] = prev + count;
	            if (next < 0) {
	                throw new Error('More tasks executed then were scheduled.');
	            }
	            if (prev == 0 || next == 0) {
	                var isEmpty = {
	                    microTask: counts.microTask > 0,
	                    macroTask: counts.macroTask > 0,
	                    eventTask: counts.eventTask > 0,
	                    change: type
	                };
	                try {
	                    this.hasTask(this.zone, isEmpty);
	                }
	                finally {
	                    if (this._parentDelegate) {
	                        this._parentDelegate._updateTaskCount(type, count);
	                    }
	                }
	            }
	        };
	        return ZoneDelegate;
	    }());
	    var ZoneTask = (function () {
	        function ZoneTask(type, zone, source, callback, options, scheduleFn, cancelFn) {
	            this.runCount = 0;
	            this.type = type;
	            this.zone = zone;
	            this.source = source;
	            this.data = options;
	            this.scheduleFn = scheduleFn;
	            this.cancelFn = cancelFn;
	            this.callback = callback;
	            var self = this;
	            this.invoke = function () {
	                try {
	                    return zone.runTask(self, this, arguments);
	                }
	                finally {
	                    drainMicroTaskQueue();
	                }
	            };
	        }
	        return ZoneTask;
	    }());
	    function __symbol__(name) { return '__zone_symbol__' + name; }
	    ;
	    var symbolSetTimeout = __symbol__('setTimeout');
	    var symbolPromise = __symbol__('Promise');
	    var symbolThen = __symbol__('then');
	    var _currentZone = new Zone(null, null);
	    var _currentTask = null;
	    var _microTaskQueue = [];
	    var _isDrainingMicrotaskQueue = false;
	    var _uncaughtPromiseErrors = [];
	    var _drainScheduled = false;
	    function scheduleQueueDrain() {
	        if (!_drainScheduled && !_currentTask && _microTaskQueue.length == 0) {
	            // We are not running in Task, so we need to kickstart the microtask queue.
	            if (global[symbolPromise]) {
	                global[symbolPromise].resolve(0)[symbolThen](drainMicroTaskQueue);
	            }
	            else {
	                global[symbolSetTimeout](drainMicroTaskQueue, 0);
	            }
	        }
	    }
	    function scheduleMicroTask(task) {
	        scheduleQueueDrain();
	        _microTaskQueue.push(task);
	    }
	    function consoleError(e) {
	        var rejection = e && e.rejection;
	        if (rejection) {
	            console.error('Unhandled Promise rejection:', rejection instanceof Error ? rejection.message : rejection, '; Zone:', e.zone.name, '; Task:', e.task && e.task.source, '; Value:', rejection);
	        }
	        console.error(e);
	    }
	    function drainMicroTaskQueue() {
	        if (!_isDrainingMicrotaskQueue) {
	            _isDrainingMicrotaskQueue = true;
	            while (_microTaskQueue.length) {
	                var queue = _microTaskQueue;
	                _microTaskQueue = [];
	                for (var i = 0; i < queue.length; i++) {
	                    var task = queue[i];
	                    try {
	                        task.zone.runTask(task, null, null);
	                    }
	                    catch (e) {
	                        consoleError(e);
	                    }
	                }
	            }
	            while (_uncaughtPromiseErrors.length) {
	                var uncaughtPromiseErrors = _uncaughtPromiseErrors;
	                _uncaughtPromiseErrors = [];
	                var _loop_1 = function(i) {
	                    var uncaughtPromiseError = uncaughtPromiseErrors[i];
	                    try {
	                        uncaughtPromiseError.zone.runGuarded(function () { throw uncaughtPromiseError; });
	                    }
	                    catch (e) {
	                        consoleError(e);
	                    }
	                };
	                for (var i = 0; i < uncaughtPromiseErrors.length; i++) {
	                    _loop_1(i);
	                }
	            }
	            _isDrainingMicrotaskQueue = false;
	            _drainScheduled = false;
	        }
	    }
	    function isThenable(value) {
	        return value && value.then;
	    }
	    function forwardResolution(value) { return value; }
	    function forwardRejection(rejection) { return ZoneAwarePromise.reject(rejection); }
	    var symbolState = __symbol__('state');
	    var symbolValue = __symbol__('value');
	    var source = 'Promise.then';
	    var UNRESOLVED = null;
	    var RESOLVED = true;
	    var REJECTED = false;
	    var REJECTED_NO_CATCH = 0;
	    function makeResolver(promise, state) {
	        return function (v) {
	            resolvePromise(promise, state, v);
	            // Do not return value or you will break the Promise spec.
	        };
	    }
	    function resolvePromise(promise, state, value) {
	        if (promise[symbolState] === UNRESOLVED) {
	            if (value instanceof ZoneAwarePromise && value[symbolState] !== UNRESOLVED) {
	                clearRejectedNoCatch(value);
	                resolvePromise(promise, value[symbolState], value[symbolValue]);
	            }
	            else if (isThenable(value)) {
	                value.then(makeResolver(promise, state), makeResolver(promise, false));
	            }
	            else {
	                promise[symbolState] = state;
	                var queue = promise[symbolValue];
	                promise[symbolValue] = value;
	                for (var i = 0; i < queue.length;) {
	                    scheduleResolveOrReject(promise, queue[i++], queue[i++], queue[i++], queue[i++]);
	                }
	                if (queue.length == 0 && state == REJECTED) {
	                    promise[symbolState] = REJECTED_NO_CATCH;
	                    try {
	                        throw new Error("Uncaught (in promise): " + value);
	                    }
	                    catch (e) {
	                        var error = e;
	                        error.rejection = value;
	                        error.promise = promise;
	                        error.zone = Zone.current;
	                        error.task = Zone.currentTask;
	                        _uncaughtPromiseErrors.push(error);
	                        scheduleQueueDrain();
	                    }
	                }
	            }
	        }
	        // Resolving an already resolved promise is a noop.
	        return promise;
	    }
	    function clearRejectedNoCatch(promise) {
	        if (promise[symbolState] === REJECTED_NO_CATCH) {
	            promise[symbolState] = REJECTED;
	            for (var i = 0; i < _uncaughtPromiseErrors.length; i++) {
	                if (promise === _uncaughtPromiseErrors[i].promise) {
	                    _uncaughtPromiseErrors.splice(i, 1);
	                    break;
	                }
	            }
	        }
	    }
	    function scheduleResolveOrReject(promise, zone, chainPromise, onFulfilled, onRejected) {
	        clearRejectedNoCatch(promise);
	        var delegate = promise[symbolState] ? onFulfilled || forwardResolution : onRejected || forwardRejection;
	        zone.scheduleMicroTask(source, function () {
	            try {
	                resolvePromise(chainPromise, true, zone.run(delegate, null, [promise[symbolValue]]));
	            }
	            catch (error) {
	                resolvePromise(chainPromise, false, error);
	            }
	        });
	    }
	    var ZoneAwarePromise = (function () {
	        function ZoneAwarePromise(executor) {
	            var promise = this;
	            promise[symbolState] = UNRESOLVED;
	            promise[symbolValue] = []; // queue;
	            try {
	                executor && executor(makeResolver(promise, RESOLVED), makeResolver(promise, REJECTED));
	            }
	            catch (e) {
	                resolvePromise(promise, false, e);
	            }
	        }
	        ZoneAwarePromise.resolve = function (value) {
	            return resolvePromise(new this(null), RESOLVED, value);
	        };
	        ZoneAwarePromise.reject = function (error) {
	            return resolvePromise(new this(null), REJECTED, error);
	        };
	        ZoneAwarePromise.race = function (values) {
	            var resolve;
	            var reject;
	            var promise = new this(function (res, rej) { resolve = res; reject = rej; });
	            function onResolve(value) { promise && (promise = null || resolve(value)); }
	            function onReject(error) { promise && (promise = null || reject(error)); }
	            for (var _i = 0, values_1 = values; _i < values_1.length; _i++) {
	                var value = values_1[_i];
	                if (!isThenable(value)) {
	                    value = this.resolve(value);
	                }
	                value.then(onResolve, onReject);
	            }
	            return promise;
	        };
	        ZoneAwarePromise.all = function (values) {
	            var resolve;
	            var reject;
	            var promise = new this(function (res, rej) { resolve = res; reject = rej; });
	            var count = 0;
	            var resolvedValues = [];
	            function onReject(error) { promise && reject(error); promise = null; }
	            for (var _i = 0, values_2 = values; _i < values_2.length; _i++) {
	                var value = values_2[_i];
	                if (!isThenable(value)) {
	                    value = this.resolve(value);
	                }
	                value.then((function (index) { return function (value) {
	                    resolvedValues[index] = value;
	                    count--;
	                    if (promise && !count) {
	                        resolve(resolvedValues);
	                    }
	                    promise == null;
	                }; })(count), onReject);
	                count++;
	            }
	            if (!count)
	                resolve(resolvedValues);
	            return promise;
	        };
	        ZoneAwarePromise.prototype.then = function (onFulfilled, onRejected) {
	            var chainPromise = new ZoneAwarePromise(null);
	            var zone = Zone.current;
	            if (this[symbolState] == UNRESOLVED) {
	                this[symbolValue].push(zone, chainPromise, onFulfilled, onRejected);
	            }
	            else {
	                scheduleResolveOrReject(this, zone, chainPromise, onFulfilled, onRejected);
	            }
	            return chainPromise;
	        };
	        ZoneAwarePromise.prototype.catch = function (onRejected) {
	            return this.then(null, onRejected);
	        };
	        return ZoneAwarePromise;
	    }());
	    var NativePromise = global[__symbol__('Promise')] = global.Promise;
	    global.Promise = ZoneAwarePromise;
	    if (NativePromise) {
	        var NativePromiseProtototype = NativePromise.prototype;
	        var NativePromiseThen_1 = NativePromiseProtototype[__symbol__('then')]
	            = NativePromiseProtototype.then;
	        NativePromiseProtototype.then = function (onResolve, onReject) {
	            var nativePromise = this;
	            return new ZoneAwarePromise(function (resolve, reject) {
	                NativePromiseThen_1.call(nativePromise, resolve, reject);
	            }).then(onResolve, onReject);
	        };
	    }
	    return global.Zone = Zone;
	})(typeof window === 'undefined' ? global : window);

	/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))

/***/ },
/* 2 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var utils_1 = __webpack_require__(3);
	var WTF_ISSUE_555 = 'Anchor,Area,Audio,BR,Base,BaseFont,Body,Button,Canvas,Content,DList,Directory,Div,Embed,FieldSet,Font,Form,Frame,FrameSet,HR,Head,Heading,Html,IFrame,Image,Input,Keygen,LI,Label,Legend,Link,Map,Marquee,Media,Menu,Meta,Meter,Mod,OList,Object,OptGroup,Option,Output,Paragraph,Pre,Progress,Quote,Script,Select,Source,Span,Style,TableCaption,TableCell,TableCol,Table,TableRow,TableSection,TextArea,Title,Track,UList,Unknown,Video';
	var NO_EVENT_TARGET = 'ApplicationCache,EventSource,FileReader,InputMethodContext,MediaController,MessagePort,Node,Performance,SVGElementInstance,SharedWorker,TextTrack,TextTrackCue,TextTrackList,WebKitNamedFlow,Worker,WorkerGlobalScope,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload,IDBRequest,IDBOpenDBRequest,IDBDatabase,IDBTransaction,IDBCursor,DBIndex'.split(',');
	var EVENT_TARGET = 'EventTarget';
	function eventTargetPatch(_global) {
	    var apis = [];
	    var isWtf = _global['wtf'];
	    if (isWtf) {
	        // Workaround for: https://github.com/google/tracing-framework/issues/555
	        apis = WTF_ISSUE_555.split(',').map(function (v) { return 'HTML' + v + 'Element'; }).concat(NO_EVENT_TARGET);
	    }
	    else if (_global[EVENT_TARGET]) {
	        apis.push(EVENT_TARGET);
	    }
	    else {
	        // Note: EventTarget is not available in all browsers,
	        // if it's not available, we instead patch the APIs in the IDL that inherit from EventTarget
	        apis = NO_EVENT_TARGET;
	    }
	    for (var i = 0; i < apis.length; i++) {
	        var type = _global[apis[i]];
	        utils_1.patchEventTargetMethods(type && type.prototype);
	    }
	}
	exports.eventTargetPatch = eventTargetPatch;


/***/ },
/* 3 */
/***/ function(module, exports) {

	/* WEBPACK VAR INJECTION */(function(global) {/**
	 * Suppress closure compiler errors about unknown 'process' variable
	 * @fileoverview
	 * @suppress {undefinedVars}
	 */
	"use strict";
	exports.zoneSymbol = Zone['__symbol__'];
	var _global = typeof window == 'undefined' ? global : window;
	function bindArguments(args, source) {
	    for (var i = args.length - 1; i >= 0; i--) {
	        if (typeof args[i] === 'function') {
	            args[i] = Zone.current.wrap(args[i], source + '_' + i);
	        }
	    }
	    return args;
	}
	exports.bindArguments = bindArguments;
	;
	function patchPrototype(prototype, fnNames) {
	    var source = prototype.constructor['name'];
	    var _loop_1 = function(i) {
	        var name_1 = fnNames[i];
	        var delegate = prototype[name_1];
	        if (delegate) {
	            prototype[name_1] = (function (delegate) {
	                return function () {
	                    return delegate.apply(this, bindArguments(arguments, source + '.' + name_1));
	                };
	            })(delegate);
	        }
	    };
	    for (var i = 0; i < fnNames.length; i++) {
	        _loop_1(i);
	    }
	}
	exports.patchPrototype = patchPrototype;
	;
	exports.isWebWorker = (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope);
	exports.isNode = (typeof process !== 'undefined' && {}.toString.call(process) === '[object process]');
	exports.isBrowser = !exports.isNode && !exports.isWebWorker && !!(typeof window !== 'undefined' && window['HTMLElement']);
	function patchProperty(obj, prop) {
	    var desc = Object.getOwnPropertyDescriptor(obj, prop) || {
	        enumerable: true,
	        configurable: true
	    };
	    // A property descriptor cannot have getter/setter and be writable
	    // deleting the writable and value properties avoids this error:
	    //
	    // TypeError: property descriptors must not specify a value or be writable when a
	    // getter or setter has been specified
	    delete desc.writable;
	    delete desc.value;
	    // substr(2) cuz 'onclick' -> 'click', etc
	    var eventName = prop.substr(2);
	    var _prop = '_' + prop;
	    desc.set = function (fn) {
	        if (this[_prop]) {
	            this.removeEventListener(eventName, this[_prop]);
	        }
	        if (typeof fn === 'function') {
	            var wrapFn = function (event) {
	                var result;
	                result = fn.apply(this, arguments);
	                if (result != undefined && !result)
	                    event.preventDefault();
	            };
	            this[_prop] = wrapFn;
	            this.addEventListener(eventName, wrapFn, false);
	        }
	        else {
	            this[_prop] = null;
	        }
	    };
	    desc.get = function () {
	        return this[_prop];
	    };
	    Object.defineProperty(obj, prop, desc);
	}
	exports.patchProperty = patchProperty;
	;
	function patchOnProperties(obj, properties) {
	    var onProperties = [];
	    for (var prop in obj) {
	        if (prop.substr(0, 2) == 'on') {
	            onProperties.push(prop);
	        }
	    }
	    for (var j = 0; j < onProperties.length; j++) {
	        patchProperty(obj, onProperties[j]);
	    }
	    if (properties) {
	        for (var i = 0; i < properties.length; i++) {
	            patchProperty(obj, 'on' + properties[i]);
	        }
	    }
	}
	exports.patchOnProperties = patchOnProperties;
	;
	var EVENT_TASKS = exports.zoneSymbol('eventTasks');
	var ADD_EVENT_LISTENER = 'addEventListener';
	var REMOVE_EVENT_LISTENER = 'removeEventListener';
	var SYMBOL_ADD_EVENT_LISTENER = exports.zoneSymbol(ADD_EVENT_LISTENER);
	var SYMBOL_REMOVE_EVENT_LISTENER = exports.zoneSymbol(REMOVE_EVENT_LISTENER);
	function findExistingRegisteredTask(target, handler, name, capture, remove) {
	    var eventTasks = target[EVENT_TASKS];
	    if (eventTasks) {
	        for (var i = 0; i < eventTasks.length; i++) {
	            var eventTask = eventTasks[i];
	            var data = eventTask.data;
	            if (data.handler === handler
	                && data.useCapturing === capture
	                && data.eventName === name) {
	                if (remove) {
	                    eventTasks.splice(i, 1);
	                }
	                return eventTask;
	            }
	        }
	    }
	    return null;
	}
	function attachRegisteredEvent(target, eventTask) {
	    var eventTasks = target[EVENT_TASKS];
	    if (!eventTasks) {
	        eventTasks = target[EVENT_TASKS] = [];
	    }
	    eventTasks.push(eventTask);
	}
	function scheduleEventListener(eventTask) {
	    var meta = eventTask.data;
	    attachRegisteredEvent(meta.target, eventTask);
	    return meta.target[SYMBOL_ADD_EVENT_LISTENER](meta.eventName, eventTask.invoke, meta.useCapturing);
	}
	function cancelEventListener(eventTask) {
	    var meta = eventTask.data;
	    findExistingRegisteredTask(meta.target, eventTask.invoke, meta.eventName, meta.useCapturing, true);
	    meta.target[SYMBOL_REMOVE_EVENT_LISTENER](meta.eventName, eventTask.invoke, meta.useCapturing);
	}
	function zoneAwareAddEventListener(self, args) {
	    var eventName = args[0];
	    var handler = args[1];
	    var useCapturing = args[2] || false;
	    // - Inside a Web Worker, `this` is undefined, the context is `global`
	    // - When `addEventListener` is called on the global context in strict mode, `this` is undefined
	    // see https://github.com/angular/zone.js/issues/190
	    var target = self || _global;
	    var delegate = null;
	    if (typeof handler == 'function') {
	        delegate = handler;
	    }
	    else if (handler && handler.handleEvent) {
	        delegate = function (event) { return handler.handleEvent(event); };
	    }
	    var validZoneHandler = false;
	    try {
	        // In cross site contexts (such as WebDriver frameworks like Selenium),
	        // accessing the handler object here will cause an exception to be thrown which
	        // will fail tests prematurely.
	        validZoneHandler = handler && handler.toString() === "[object FunctionWrapper]";
	    }
	    catch (e) {
	        // Returning nothing here is fine, because objects in a cross-site context are unusable
	        return;
	    }
	    // Ignore special listeners of IE11 & Edge dev tools, see https://github.com/angular/zone.js/issues/150
	    if (!delegate || validZoneHandler) {
	        return target[SYMBOL_ADD_EVENT_LISTENER](eventName, handler, useCapturing);
	    }
	    var eventTask = findExistingRegisteredTask(target, handler, eventName, useCapturing, false);
	    if (eventTask) {
	        // we already registered, so this will have noop.
	        return target[SYMBOL_ADD_EVENT_LISTENER](eventName, eventTask.invoke, useCapturing);
	    }
	    var zone = Zone.current;
	    var source = target.constructor['name'] + '.addEventListener:' + eventName;
	    var data = {
	        target: target,
	        eventName: eventName,
	        name: eventName,
	        useCapturing: useCapturing,
	        handler: handler
	    };
	    zone.scheduleEventTask(source, delegate, data, scheduleEventListener, cancelEventListener);
	}
	function zoneAwareRemoveEventListener(self, args) {
	    var eventName = args[0];
	    var handler = args[1];
	    var useCapturing = args[2] || false;
	    // - Inside a Web Worker, `this` is undefined, the context is `global`
	    // - When `addEventListener` is called on the global context in strict mode, `this` is undefined
	    // see https://github.com/angular/zone.js/issues/190
	    var target = self || _global;
	    var eventTask = findExistingRegisteredTask(target, handler, eventName, useCapturing, true);
	    if (eventTask) {
	        eventTask.zone.cancelTask(eventTask);
	    }
	    else {
	        target[SYMBOL_REMOVE_EVENT_LISTENER](eventName, handler, useCapturing);
	    }
	}
	function patchEventTargetMethods(obj) {
	    if (obj && obj.addEventListener) {
	        patchMethod(obj, ADD_EVENT_LISTENER, function () { return zoneAwareAddEventListener; });
	        patchMethod(obj, REMOVE_EVENT_LISTENER, function () { return zoneAwareRemoveEventListener; });
	        return true;
	    }
	    else {
	        return false;
	    }
	}
	exports.patchEventTargetMethods = patchEventTargetMethods;
	;
	var originalInstanceKey = exports.zoneSymbol('originalInstance');
	// wrap some native API on `window`
	function patchClass(className) {
	    var OriginalClass = _global[className];
	    if (!OriginalClass)
	        return;
	    _global[className] = function () {
	        var a = bindArguments(arguments, className);
	        switch (a.length) {
	            case 0:
	                this[originalInstanceKey] = new OriginalClass();
	                break;
	            case 1:
	                this[originalInstanceKey] = new OriginalClass(a[0]);
	                break;
	            case 2:
	                this[originalInstanceKey] = new OriginalClass(a[0], a[1]);
	                break;
	            case 3:
	                this[originalInstanceKey] = new OriginalClass(a[0], a[1], a[2]);
	                break;
	            case 4:
	                this[originalInstanceKey] = new OriginalClass(a[0], a[1], a[2], a[3]);
	                break;
	            default: throw new Error('Arg list too long.');
	        }
	    };
	    var instance = new OriginalClass(function () { });
	    var prop;
	    for (prop in instance) {
	        (function (prop) {
	            if (typeof instance[prop] === 'function') {
	                _global[className].prototype[prop] = function () {
	                    return this[originalInstanceKey][prop].apply(this[originalInstanceKey], arguments);
	                };
	            }
	            else {
	                Object.defineProperty(_global[className].prototype, prop, {
	                    set: function (fn) {
	                        if (typeof fn === 'function') {
	                            this[originalInstanceKey][prop] = Zone.current.wrap(fn, className + '.' + prop);
	                        }
	                        else {
	                            this[originalInstanceKey][prop] = fn;
	                        }
	                    },
	                    get: function () {
	                        return this[originalInstanceKey][prop];
	                    }
	                });
	            }
	        }(prop));
	    }
	    for (prop in OriginalClass) {
	        if (prop !== 'prototype' && OriginalClass.hasOwnProperty(prop)) {
	            _global[className][prop] = OriginalClass[prop];
	        }
	    }
	}
	exports.patchClass = patchClass;
	;
	function createNamedFn(name, delegate) {
	    try {
	        return (Function('f', "return function " + name + "(){return f(this, arguments)}"))(delegate);
	    }
	    catch (e) {
	        // if we fail, we must be CSP, just return delegate.
	        return function () {
	            return delegate(this, arguments);
	        };
	    }
	}
	exports.createNamedFn = createNamedFn;
	function patchMethod(target, name, patchFn) {
	    var proto = target;
	    while (proto && !proto.hasOwnProperty(name)) {
	        proto = Object.getPrototypeOf(proto);
	    }
	    if (!proto && target[name]) {
	        // somehow we did not find it, but we can see it. This happens on IE for Window properties.
	        proto = target;
	    }
	    var delegateName = exports.zoneSymbol(name);
	    var delegate;
	    if (proto && !(delegate = proto[delegateName])) {
	        delegate = proto[delegateName] = proto[name];
	        proto[name] = createNamedFn(name, patchFn(delegate, delegateName, name));
	    }
	    return delegate;
	}
	exports.patchMethod = patchMethod;

	/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))

/***/ },
/* 4 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var utils_1 = __webpack_require__(3);
	/*
	 * This is necessary for Chrome and Chrome mobile, to enable
	 * things like redefining `createdCallback` on an element.
	 */
	var _defineProperty = Object.defineProperty;
	var _getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
	var _create = Object.create;
	var unconfigurablesKey = utils_1.zoneSymbol('unconfigurables');
	function propertyPatch() {
	    Object.defineProperty = function (obj, prop, desc) {
	        if (isUnconfigurable(obj, prop)) {
	            throw new TypeError('Cannot assign to read only property \'' + prop + '\' of ' + obj);
	        }
	        if (prop !== 'prototype') {
	            desc = rewriteDescriptor(obj, prop, desc);
	        }
	        return _defineProperty(obj, prop, desc);
	    };
	    Object.defineProperties = function (obj, props) {
	        Object.keys(props).forEach(function (prop) {
	            Object.defineProperty(obj, prop, props[prop]);
	        });
	        return obj;
	    };
	    Object.create = function (obj, proto) {
	        if (typeof proto === 'object') {
	            Object.keys(proto).forEach(function (prop) {
	                proto[prop] = rewriteDescriptor(obj, prop, proto[prop]);
	            });
	        }
	        return _create(obj, proto);
	    };
	    Object.getOwnPropertyDescriptor = function (obj, prop) {
	        var desc = _getOwnPropertyDescriptor(obj, prop);
	        if (isUnconfigurable(obj, prop)) {
	            desc.configurable = false;
	        }
	        return desc;
	    };
	}
	exports.propertyPatch = propertyPatch;
	;
	function _redefineProperty(obj, prop, desc) {
	    desc = rewriteDescriptor(obj, prop, desc);
	    return _defineProperty(obj, prop, desc);
	}
	exports._redefineProperty = _redefineProperty;
	;
	function isUnconfigurable(obj, prop) {
	    return obj && obj[unconfigurablesKey] && obj[unconfigurablesKey][prop];
	}
	function rewriteDescriptor(obj, prop, desc) {
	    desc.configurable = true;
	    if (!desc.configurable) {
	        if (!obj[unconfigurablesKey]) {
	            _defineProperty(obj, unconfigurablesKey, { writable: true, value: {} });
	        }
	        obj[unconfigurablesKey][prop] = true;
	    }
	    return desc;
	}


/***/ },
/* 5 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var define_property_1 = __webpack_require__(4);
	var utils_1 = __webpack_require__(3);
	function registerElementPatch(_global) {
	    if (!utils_1.isBrowser || !('registerElement' in _global.document)) {
	        return;
	    }
	    var _registerElement = document.registerElement;
	    var callbacks = [
	        'createdCallback',
	        'attachedCallback',
	        'detachedCallback',
	        'attributeChangedCallback'
	    ];
	    document.registerElement = function (name, opts) {
	        if (opts && opts.prototype) {
	            callbacks.forEach(function (callback) {
	                var source = 'Document.registerElement::' + callback;
	                if (opts.prototype.hasOwnProperty(callback)) {
	                    var descriptor = Object.getOwnPropertyDescriptor(opts.prototype, callback);
	                    if (descriptor && descriptor.value) {
	                        descriptor.value = Zone.current.wrap(descriptor.value, source);
	                        define_property_1._redefineProperty(opts.prototype, callback, descriptor);
	                    }
	                    else {
	                        opts.prototype[callback] = Zone.current.wrap(opts.prototype[callback], source);
	                    }
	                }
	                else if (opts.prototype[callback]) {
	                    opts.prototype[callback] = Zone.current.wrap(opts.prototype[callback], source);
	                }
	            });
	        }
	        return _registerElement.apply(document, [name, opts]);
	    };
	}
	exports.registerElementPatch = registerElementPatch;


/***/ },
/* 6 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var webSocketPatch = __webpack_require__(7);
	var utils_1 = __webpack_require__(3);
	var eventNames = 'copy cut paste abort blur focus canplay canplaythrough change click contextmenu dblclick drag dragend dragenter dragleave dragover dragstart drop durationchange emptied ended input invalid keydown keypress keyup load loadeddata loadedmetadata loadstart message mousedown mouseenter mouseleave mousemove mouseout mouseover mouseup pause play playing progress ratechange reset scroll seeked seeking select show stalled submit suspend timeupdate volumechange waiting mozfullscreenchange mozfullscreenerror mozpointerlockchange mozpointerlockerror error webglcontextrestored webglcontextlost webglcontextcreationerror'.split(' ');
	function propertyDescriptorPatch(_global) {
	    if (utils_1.isNode) {
	        return;
	    }
	    var supportsWebSocket = typeof WebSocket !== 'undefined';
	    if (canPatchViaPropertyDescriptor()) {
	        // for browsers that we can patch the descriptor:  Chrome & Firefox
	        if (utils_1.isBrowser) {
	            utils_1.patchOnProperties(HTMLElement.prototype, eventNames);
	        }
	        utils_1.patchOnProperties(XMLHttpRequest.prototype, null);
	        if (typeof IDBIndex !== 'undefined') {
	            utils_1.patchOnProperties(IDBIndex.prototype, null);
	            utils_1.patchOnProperties(IDBRequest.prototype, null);
	            utils_1.patchOnProperties(IDBOpenDBRequest.prototype, null);
	            utils_1.patchOnProperties(IDBDatabase.prototype, null);
	            utils_1.patchOnProperties(IDBTransaction.prototype, null);
	            utils_1.patchOnProperties(IDBCursor.prototype, null);
	        }
	        if (supportsWebSocket) {
	            utils_1.patchOnProperties(WebSocket.prototype, null);
	        }
	    }
	    else {
	        // Safari, Android browsers (Jelly Bean)
	        patchViaCapturingAllTheEvents();
	        utils_1.patchClass('XMLHttpRequest');
	        if (supportsWebSocket) {
	            webSocketPatch.apply(_global);
	        }
	    }
	}
	exports.propertyDescriptorPatch = propertyDescriptorPatch;
	function canPatchViaPropertyDescriptor() {
	    if (utils_1.isBrowser && !Object.getOwnPropertyDescriptor(HTMLElement.prototype, 'onclick')
	        && typeof Element !== 'undefined') {
	        // WebKit https://bugs.webkit.org/show_bug.cgi?id=134364
	        // IDL interface attributes are not configurable
	        var desc = Object.getOwnPropertyDescriptor(Element.prototype, 'onclick');
	        if (desc && !desc.configurable)
	            return false;
	    }
	    Object.defineProperty(XMLHttpRequest.prototype, 'onreadystatechange', {
	        get: function () {
	            return true;
	        }
	    });
	    var req = new XMLHttpRequest();
	    var result = !!req.onreadystatechange;
	    Object.defineProperty(XMLHttpRequest.prototype, 'onreadystatechange', {});
	    return result;
	}
	;
	var unboundKey = utils_1.zoneSymbol('unbound');
	// Whenever any eventListener fires, we check the eventListener target and all parents
	// for `onwhatever` properties and replace them with zone-bound functions
	// - Chrome (for now)
	function patchViaCapturingAllTheEvents() {
	    var _loop_1 = function(i) {
	        var property = eventNames[i];
	        var onproperty = 'on' + property;
	        document.addEventListener(property, function (event) {
	            var elt = event.target, bound, source;
	            if (elt) {
	                source = elt.constructor['name'] + '.' + onproperty;
	            }
	            else {
	                source = 'unknown.' + onproperty;
	            }
	            while (elt) {
	                if (elt[onproperty] && !elt[onproperty][unboundKey]) {
	                    bound = Zone.current.wrap(elt[onproperty], source);
	                    bound[unboundKey] = elt[onproperty];
	                    elt[onproperty] = bound;
	                }
	                elt = elt.parentElement;
	            }
	        }, true);
	    };
	    for (var i = 0; i < eventNames.length; i++) {
	        _loop_1(i);
	    }
	    ;
	}
	;


/***/ },
/* 7 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var utils_1 = __webpack_require__(3);
	// we have to patch the instance since the proto is non-configurable
	function apply(_global) {
	    var WS = _global.WebSocket;
	    // On Safari window.EventTarget doesn't exist so need to patch WS add/removeEventListener
	    // On older Chrome, no need since EventTarget was already patched
	    if (!_global.EventTarget) {
	        utils_1.patchEventTargetMethods(WS.prototype);
	    }
	    _global.WebSocket = function (a, b) {
	        var socket = arguments.length > 1 ? new WS(a, b) : new WS(a);
	        var proxySocket;
	        // Safari 7.0 has non-configurable own 'onmessage' and friends properties on the socket instance
	        var onmessageDesc = Object.getOwnPropertyDescriptor(socket, 'onmessage');
	        if (onmessageDesc && onmessageDesc.configurable === false) {
	            proxySocket = Object.create(socket);
	            ['addEventListener', 'removeEventListener', 'send', 'close'].forEach(function (propName) {
	                proxySocket[propName] = function () {
	                    return socket[propName].apply(socket, arguments);
	                };
	            });
	        }
	        else {
	            // we can patch the real socket
	            proxySocket = socket;
	        }
	        utils_1.patchOnProperties(proxySocket, ['close', 'error', 'message', 'open']);
	        return proxySocket;
	    };
	    for (var prop in WS) {
	        _global.WebSocket[prop] = WS[prop];
	    }
	}
	exports.apply = apply;


/***/ },
/* 8 */
/***/ function(module, exports, __webpack_require__) {

	"use strict";
	var utils_1 = __webpack_require__(3);
	function patchTimer(window, setName, cancelName, nameSuffix) {
	    var setNative = null;
	    var clearNative = null;
	    setName += nameSuffix;
	    cancelName += nameSuffix;
	    function scheduleTask(task) {
	        var data = task.data;
	        data.args[0] = task.invoke;
	        data.handleId = setNative.apply(window, data.args);
	        return task;
	    }
	    function clearTask(task) {
	        return clearNative(task.data.handleId);
	    }
	    setNative = utils_1.patchMethod(window, setName, function (delegate) { return function (self, args) {
	        if (typeof args[0] === 'function') {
	            var zone = Zone.current;
	            var options = {
	                handleId: null,
	                isPeriodic: nameSuffix === 'Interval',
	                delay: (nameSuffix === 'Timeout' || nameSuffix === 'Interval') ? args[1] || 0 : null,
	                args: args
	            };
	            return zone.scheduleMacroTask(setName, args[0], options, scheduleTask, clearTask);
	        }
	        else {
	            // cause an error by calling it directly.
	            return delegate.apply(window, args);
	        }
	    }; });
	    clearNative = utils_1.patchMethod(window, cancelName, function (delegate) { return function (self, args) {
	        var task = args[0];
	        if (task && typeof task.type === 'string') {
	            if (task.cancelFn && task.data.isPeriodic || task.runCount === 0) {
	                // Do not cancel already canceled functions
	                task.zone.cancelTask(task);
	            }
	        }
	        else {
	            // cause an error by calling it directly.
	            delegate.apply(window, args);
	        }
	    }; });
	}
	exports.patchTimer = patchTimer;


/***/ }
/******/ ]);
/******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};

/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {

/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId])
/******/ 			return installedModules[moduleId].exports;

/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			exports: {},
/******/ 			id: moduleId,
/******/ 			loaded: false
/******/ 		};

/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);

/******/ 		// Flag the module as loaded
/******/ 		module.loaded = true;

/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}


/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;

/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;

/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";

/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ function(module, exports) {

	'use strict';
	(function () {
	    var NEWLINE = '\n';
	    var SEP = '  -------------  ';
	    var IGNORE_FRAMES = [];
	    var creationTrace = '__creationTrace__';
	    var LongStackTrace = (function () {
	        function LongStackTrace() {
	            this.error = getStacktrace();
	            this.timestamp = new Date();
	        }
	        return LongStackTrace;
	    }());
	    function getStacktraceWithUncaughtError() {
	        return new Error('STACKTRACE TRACKING');
	    }
	    function getStacktraceWithCaughtError() {
	        try {
	            throw getStacktraceWithUncaughtError();
	        }
	        catch (e) {
	            return e;
	        }
	    }
	    // Some implementations of exception handling don't create a stack trace if the exception
	    // isn't thrown, however it's faster not to actually throw the exception.
	    var error = getStacktraceWithUncaughtError();
	    var coughtError = getStacktraceWithCaughtError();
	    var getStacktrace = error.stack
	        ? getStacktraceWithUncaughtError
	        : (coughtError.stack ? getStacktraceWithCaughtError : getStacktraceWithUncaughtError);
	    function getFrames(error) {
	        return error.stack ? error.stack.split(NEWLINE) : [];
	    }
	    function addErrorStack(lines, error) {
	        var trace = getFrames(error);
	        for (var i = 0; i < trace.length; i++) {
	            var frame = trace[i];
	            // Filter out the Frames which are part of stack capturing.
	            if (!(i < IGNORE_FRAMES.length && IGNORE_FRAMES[i] === frame)) {
	                lines.push(trace[i]);
	            }
	        }
	    }
	    function renderLongStackTrace(frames, stack) {
	        var longTrace = [stack];
	        if (frames) {
	            var timestamp = new Date().getTime();
	            for (var i = 0; i < frames.length; i++) {
	                var traceFrames = frames[i];
	                var lastTime = traceFrames.timestamp;
	                longTrace.push(SEP + " Elapsed: " + (timestamp - lastTime.getTime()) + " ms; At: " + lastTime + " " + SEP);
	                addErrorStack(longTrace, traceFrames.error);
	                timestamp = lastTime.getTime();
	            }
	        }
	        return longTrace.join(NEWLINE);
	    }
	    Zone['longStackTraceZoneSpec'] = {
	        name: 'long-stack-trace',
	        longStackTraceLimit: 10,
	        onScheduleTask: function (parentZoneDelegate, currentZone, targetZone, task) {
	            var currentTask = Zone.currentTask;
	            var trace = currentTask && currentTask.data && currentTask.data[creationTrace] || [];
	            trace = [new LongStackTrace()].concat(trace);
	            if (trace.length > this.longStackTraceLimit) {
	                trace.length = this.longStackTraceLimit;
	            }
	            if (!task.data)
	                task.data = {};
	            task.data[creationTrace] = trace;
	            return parentZoneDelegate.scheduleTask(targetZone, task);
	        },
	        onHandleError: function (parentZoneDelegate, currentZone, targetZone, error) {
	            var parentTask = Zone.currentTask;
	            if (error instanceof Error && parentTask) {
	                var descriptor = Object.getOwnPropertyDescriptor(error, 'stack');
	                if (descriptor) {
	                    var delegateGet_1 = descriptor.get;
	                    var value_1 = descriptor.value;
	                    descriptor = {
	                        get: function () {
	                            return renderLongStackTrace(parentTask.data && parentTask.data[creationTrace], delegateGet_1 ? delegateGet_1.apply(this) : value_1);
	                        }
	                    };
	                    Object.defineProperty(error, 'stack', descriptor);
	                }
	                else {
	                    error.stack = renderLongStackTrace(parentTask.data && parentTask.data[creationTrace], error.stack);
	                }
	            }
	            return parentZoneDelegate.handleError(targetZone, error);
	        }
	    };
	    function captureStackTraces(stackTraces, count) {
	        if (count > 0) {
	            stackTraces.push(getFrames((new LongStackTrace()).error));
	            captureStackTraces(stackTraces, count - 1);
	        }
	    }
	    function computeIgnoreFrames() {
	        var frames = [];
	        captureStackTraces(frames, 2);
	        var frames1 = frames[0];
	        var frames2 = frames[1];
	        for (var i = 0; i < frames1.length; i++) {
	            var frame1 = frames1[i];
	            var frame2 = frames2[i];
	            if (frame1 === frame2) {
	                IGNORE_FRAMES.push(frame1);
	            }
	            else {
	                break;
	            }
	        }
	    }
	    computeIgnoreFrames();
	})();


/***/ }
/******/ ]);
/*! *****************************************************************************
Copyright (C) Microsoft. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
License at http://www.apache.org/licenses/LICENSE-2.0

THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABLITY OR NON-INFRINGEMENT.

See the Apache Version 2.0 License for specific language governing permissions
and limitations under the License.
***************************************************************************** */
var Reflect;
(function (Reflect) {
    "use strict";
    // Load global or shim versions of Map, Set, and WeakMap
    var functionPrototype = Object.getPrototypeOf(Function);
    var _Map = typeof Map === "function" ? Map : CreateMapPolyfill();
    var _Set = typeof Set === "function" ? Set : CreateSetPolyfill();
    var _WeakMap = typeof WeakMap === "function" ? WeakMap : CreateWeakMapPolyfill();
    // [[Metadata]] internal slot
    var __Metadata__ = new _WeakMap();
    /**
      * Applies a set of decorators to a property of a target object.
      * @param decorators An array of decorators.
      * @param target The target object.
      * @param targetKey (Optional) The property key to decorate.
      * @param targetDescriptor (Optional) The property descriptor for the target key
      * @remarks Decorators are applied in reverse order.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     C = Reflect.decorate(decoratorsArray, C);
      *
      *     // property (on constructor)
      *     Reflect.decorate(decoratorsArray, C, "staticProperty");
      *
      *     // property (on prototype)
      *     Reflect.decorate(decoratorsArray, C.prototype, "property");
      *
      *     // method (on constructor)
      *     Object.defineProperty(C, "staticMethod",
      *         Reflect.decorate(decoratorsArray, C, "staticMethod",
      *             Object.getOwnPropertyDescriptor(C, "staticMethod")));
      *
      *     // method (on prototype)
      *     Object.defineProperty(C.prototype, "method",
      *         Reflect.decorate(decoratorsArray, C.prototype, "method",
      *             Object.getOwnPropertyDescriptor(C.prototype, "method")));
      *
      */
    function decorate(decorators, target, targetKey, targetDescriptor) {
        if (!IsUndefined(targetDescriptor)) {
            if (!IsArray(decorators)) {
                throw new TypeError();
            }
            else if (!IsObject(target)) {
                throw new TypeError();
            }
            else if (IsUndefined(targetKey)) {
                throw new TypeError();
            }
            else if (!IsObject(targetDescriptor)) {
                throw new TypeError();
            }
            targetKey = ToPropertyKey(targetKey);
            return DecoratePropertyWithDescriptor(decorators, target, targetKey, targetDescriptor);
        }
        else if (!IsUndefined(targetKey)) {
            if (!IsArray(decorators)) {
                throw new TypeError();
            }
            else if (!IsObject(target)) {
                throw new TypeError();
            }
            targetKey = ToPropertyKey(targetKey);
            return DecoratePropertyWithoutDescriptor(decorators, target, targetKey);
        }
        else {
            if (!IsArray(decorators)) {
                throw new TypeError();
            }
            else if (!IsConstructor(target)) {
                throw new TypeError();
            }
            return DecorateConstructor(decorators, target);
        }
    }
    Reflect.decorate = decorate;
    /**
      * A default metadata decorator factory that can be used on a class, class member, or parameter.
      * @param metadataKey The key for the metadata entry.
      * @param metadataValue The value for the metadata entry.
      * @returns A decorator function.
      * @remarks
      * If `metadataKey` is already defined for the target and target key, the
      * metadataValue for that key will be overwritten.
      * @example
      *
      *     // constructor
      *     @Reflect.metadata(key, value)
      *     class C {
      *     }
      *
      *     // property (on constructor, TypeScript only)
      *     class C {
      *         @Reflect.metadata(key, value)
      *         static staticProperty;
      *     }
      *
      *     // property (on prototype, TypeScript only)
      *     class C {
      *         @Reflect.metadata(key, value)
      *         property;
      *     }
      *
      *     // method (on constructor)
      *     class C {
      *         @Reflect.metadata(key, value)
      *         static staticMethod() { }
      *     }
      *
      *     // method (on prototype)
      *     class C {
      *         @Reflect.metadata(key, value)
      *         method() { }
      *     }
      *
      */
    function metadata(metadataKey, metadataValue) {
        function decorator(target, targetKey) {
            if (!IsUndefined(targetKey)) {
                if (!IsObject(target)) {
                    throw new TypeError();
                }
                targetKey = ToPropertyKey(targetKey);
                OrdinaryDefineOwnMetadata(metadataKey, metadataValue, target, targetKey);
            }
            else {
                if (!IsConstructor(target)) {
                    throw new TypeError();
                }
                OrdinaryDefineOwnMetadata(metadataKey, metadataValue, target, /*targetKey*/ undefined);
            }
        }
        return decorator;
    }
    Reflect.metadata = metadata;
    /**
      * Define a unique metadata entry on the target.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param metadataValue A value that contains attached metadata.
      * @param target The target object on which to define metadata.
      * @param targetKey (Optional) The property key for the target.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     Reflect.defineMetadata("custom:annotation", options, C);
      *
      *     // property (on constructor)
      *     Reflect.defineMetadata("custom:annotation", options, C, "staticProperty");
      *
      *     // property (on prototype)
      *     Reflect.defineMetadata("custom:annotation", options, C.prototype, "property");
      *
      *     // method (on constructor)
      *     Reflect.defineMetadata("custom:annotation", options, C, "staticMethod");
      *
      *     // method (on prototype)
      *     Reflect.defineMetadata("custom:annotation", options, C.prototype, "method");
      *
      *     // decorator factory as metadata-producing annotation.
      *     function MyAnnotation(options): Decorator {
      *         return (target, key?) => Reflect.defineMetadata("custom:annotation", options, target, key);
      *     }
      *
      */
    function defineMetadata(metadataKey, metadataValue, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryDefineOwnMetadata(metadataKey, metadataValue, target, targetKey);
    }
    Reflect.defineMetadata = defineMetadata;
    /**
      * Gets a value indicating whether the target object or its prototype chain has the provided metadata key defined.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns `true` if the metadata key was defined on the target object or its prototype chain; otherwise, `false`.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.hasMetadata("custom:annotation", C);
      *
      *     // property (on constructor)
      *     result = Reflect.hasMetadata("custom:annotation", C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.hasMetadata("custom:annotation", C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.hasMetadata("custom:annotation", C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.hasMetadata("custom:annotation", C.prototype, "method");
      *
      */
    function hasMetadata(metadataKey, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryHasMetadata(metadataKey, target, targetKey);
    }
    Reflect.hasMetadata = hasMetadata;
    /**
      * Gets a value indicating whether the target object has the provided metadata key defined.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns `true` if the metadata key was defined on the target object; otherwise, `false`.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.hasOwnMetadata("custom:annotation", C);
      *
      *     // property (on constructor)
      *     result = Reflect.hasOwnMetadata("custom:annotation", C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.hasOwnMetadata("custom:annotation", C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.hasOwnMetadata("custom:annotation", C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.hasOwnMetadata("custom:annotation", C.prototype, "method");
      *
      */
    function hasOwnMetadata(metadataKey, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryHasOwnMetadata(metadataKey, target, targetKey);
    }
    Reflect.hasOwnMetadata = hasOwnMetadata;
    /**
      * Gets the metadata value for the provided metadata key on the target object or its prototype chain.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns The metadata value for the metadata key if found; otherwise, `undefined`.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.getMetadata("custom:annotation", C);
      *
      *     // property (on constructor)
      *     result = Reflect.getMetadata("custom:annotation", C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.getMetadata("custom:annotation", C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.getMetadata("custom:annotation", C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.getMetadata("custom:annotation", C.prototype, "method");
      *
      */
    function getMetadata(metadataKey, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryGetMetadata(metadataKey, target, targetKey);
    }
    Reflect.getMetadata = getMetadata;
    /**
      * Gets the metadata value for the provided metadata key on the target object.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns The metadata value for the metadata key if found; otherwise, `undefined`.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.getOwnMetadata("custom:annotation", C);
      *
      *     // property (on constructor)
      *     result = Reflect.getOwnMetadata("custom:annotation", C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.getOwnMetadata("custom:annotation", C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.getOwnMetadata("custom:annotation", C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.getOwnMetadata("custom:annotation", C.prototype, "method");
      *
      */
    function getOwnMetadata(metadataKey, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryGetOwnMetadata(metadataKey, target, targetKey);
    }
    Reflect.getOwnMetadata = getOwnMetadata;
    /**
      * Gets the metadata keys defined on the target object or its prototype chain.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns An array of unique metadata keys.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.getMetadataKeys(C);
      *
      *     // property (on constructor)
      *     result = Reflect.getMetadataKeys(C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.getMetadataKeys(C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.getMetadataKeys(C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.getMetadataKeys(C.prototype, "method");
      *
      */
    function getMetadataKeys(target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryMetadataKeys(target, targetKey);
    }
    Reflect.getMetadataKeys = getMetadataKeys;
    /**
      * Gets the unique metadata keys defined on the target object.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns An array of unique metadata keys.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.getOwnMetadataKeys(C);
      *
      *     // property (on constructor)
      *     result = Reflect.getOwnMetadataKeys(C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.getOwnMetadataKeys(C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.getOwnMetadataKeys(C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.getOwnMetadataKeys(C.prototype, "method");
      *
      */
    function getOwnMetadataKeys(target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        return OrdinaryOwnMetadataKeys(target, targetKey);
    }
    Reflect.getOwnMetadataKeys = getOwnMetadataKeys;
    /**
      * Deletes the metadata entry from the target object with the provided key.
      * @param metadataKey A key used to store and retrieve metadata.
      * @param target The target object on which the metadata is defined.
      * @param targetKey (Optional) The property key for the target.
      * @returns `true` if the metadata entry was found and deleted; otherwise, false.
      * @example
      *
      *     class C {
      *         // property declarations are not part of ES6, though they are valid in TypeScript:
      *         // static staticProperty;
      *         // property;
      *
      *         constructor(p) { }
      *         static staticMethod(p) { }
      *         method(p) { }
      *     }
      *
      *     // constructor
      *     result = Reflect.deleteMetadata("custom:annotation", C);
      *
      *     // property (on constructor)
      *     result = Reflect.deleteMetadata("custom:annotation", C, "staticProperty");
      *
      *     // property (on prototype)
      *     result = Reflect.deleteMetadata("custom:annotation", C.prototype, "property");
      *
      *     // method (on constructor)
      *     result = Reflect.deleteMetadata("custom:annotation", C, "staticMethod");
      *
      *     // method (on prototype)
      *     result = Reflect.deleteMetadata("custom:annotation", C.prototype, "method");
      *
      */
    function deleteMetadata(metadataKey, target, targetKey) {
        if (!IsObject(target)) {
            throw new TypeError();
        }
        else if (!IsUndefined(targetKey)) {
            targetKey = ToPropertyKey(targetKey);
        }
        // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#deletemetadata-metadatakey-p-
        var metadataMap = GetOrCreateMetadataMap(target, targetKey, /*create*/ false);
        if (IsUndefined(metadataMap)) {
            return false;
        }
        if (!metadataMap.delete(metadataKey)) {
            return false;
        }
        if (metadataMap.size > 0) {
            return true;
        }
        var targetMetadata = __Metadata__.get(target);
        targetMetadata.delete(targetKey);
        if (targetMetadata.size > 0) {
            return true;
        }
        __Metadata__.delete(target);
        return true;
    }
    Reflect.deleteMetadata = deleteMetadata;
    function DecorateConstructor(decorators, target) {
        for (var i = decorators.length - 1; i >= 0; --i) {
            var decorator = decorators[i];
            var decorated = decorator(target);
            if (!IsUndefined(decorated)) {
                if (!IsConstructor(decorated)) {
                    throw new TypeError();
                }
                target = decorated;
            }
        }
        return target;
    }
    function DecoratePropertyWithDescriptor(decorators, target, propertyKey, descriptor) {
        for (var i = decorators.length - 1; i >= 0; --i) {
            var decorator = decorators[i];
            var decorated = decorator(target, propertyKey, descriptor);
            if (!IsUndefined(decorated)) {
                if (!IsObject(decorated)) {
                    throw new TypeError();
                }
                descriptor = decorated;
            }
        }
        return descriptor;
    }
    function DecoratePropertyWithoutDescriptor(decorators, target, propertyKey) {
        for (var i = decorators.length - 1; i >= 0; --i) {
            var decorator = decorators[i];
            decorator(target, propertyKey);
        }
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#getorcreatemetadatamap--o-p-create-
    function GetOrCreateMetadataMap(target, targetKey, create) {
        var targetMetadata = __Metadata__.get(target);
        if (!targetMetadata) {
            if (!create) {
                return undefined;
            }
            targetMetadata = new _Map();
            __Metadata__.set(target, targetMetadata);
        }
        var keyMetadata = targetMetadata.get(targetKey);
        if (!keyMetadata) {
            if (!create) {
                return undefined;
            }
            keyMetadata = new _Map();
            targetMetadata.set(targetKey, keyMetadata);
        }
        return keyMetadata;
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinaryhasmetadata--metadatakey-o-p-
    function OrdinaryHasMetadata(MetadataKey, O, P) {
        var hasOwn = OrdinaryHasOwnMetadata(MetadataKey, O, P);
        if (hasOwn) {
            return true;
        }
        var parent = GetPrototypeOf(O);
        if (parent !== null) {
            return OrdinaryHasMetadata(MetadataKey, parent, P);
        }
        return false;
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinaryhasownmetadata--metadatakey-o-p-
    function OrdinaryHasOwnMetadata(MetadataKey, O, P) {
        var metadataMap = GetOrCreateMetadataMap(O, P, /*create*/ false);
        if (metadataMap === undefined) {
            return false;
        }
        return Boolean(metadataMap.has(MetadataKey));
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinarygetmetadata--metadatakey-o-p-
    function OrdinaryGetMetadata(MetadataKey, O, P) {
        var hasOwn = OrdinaryHasOwnMetadata(MetadataKey, O, P);
        if (hasOwn) {
            return OrdinaryGetOwnMetadata(MetadataKey, O, P);
        }
        var parent = GetPrototypeOf(O);
        if (parent !== null) {
            return OrdinaryGetMetadata(MetadataKey, parent, P);
        }
        return undefined;
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinarygetownmetadata--metadatakey-o-p-
    function OrdinaryGetOwnMetadata(MetadataKey, O, P) {
        var metadataMap = GetOrCreateMetadataMap(O, P, /*create*/ false);
        if (metadataMap === undefined) {
            return undefined;
        }
        return metadataMap.get(MetadataKey);
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinarydefineownmetadata--metadatakey-metadatavalue-o-p-
    function OrdinaryDefineOwnMetadata(MetadataKey, MetadataValue, O, P) {
        var metadataMap = GetOrCreateMetadataMap(O, P, /*create*/ true);
        metadataMap.set(MetadataKey, MetadataValue);
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinarymetadatakeys--o-p-
    function OrdinaryMetadataKeys(O, P) {
        var ownKeys = OrdinaryOwnMetadataKeys(O, P);
        var parent = GetPrototypeOf(O);
        if (parent === null) {
            return ownKeys;
        }
        var parentKeys = OrdinaryMetadataKeys(parent, P);
        if (parentKeys.length <= 0) {
            return ownKeys;
        }
        if (ownKeys.length <= 0) {
            return parentKeys;
        }
        var set = new _Set();
        var keys = [];
        for (var _i = 0; _i < ownKeys.length; _i++) {
            var key = ownKeys[_i];
            var hasKey = set.has(key);
            if (!hasKey) {
                set.add(key);
                keys.push(key);
            }
        }
        for (var _a = 0; _a < parentKeys.length; _a++) {
            var key = parentKeys[_a];
            var hasKey = set.has(key);
            if (!hasKey) {
                set.add(key);
                keys.push(key);
            }
        }
        return keys;
    }
    // https://github.com/jonathandturner/decorators/blob/master/specs/metadata.md#ordinaryownmetadatakeys--o-p-
    function OrdinaryOwnMetadataKeys(target, targetKey) {
        var metadataMap = GetOrCreateMetadataMap(target, targetKey, /*create*/ false);
        var keys = [];
        if (metadataMap) {
            metadataMap.forEach(function (_, key) { return keys.push(key); });
        }
        return keys;
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-ecmascript-language-types-undefined-type
    function IsUndefined(x) {
        return x === undefined;
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-isarray
    function IsArray(x) {
        return Array.isArray(x);
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-object-type
    function IsObject(x) {
        return typeof x === "object" ? x !== null : typeof x === "function";
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-isconstructor
    function IsConstructor(x) {
        return typeof x === "function";
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-ecmascript-language-types-symbol-type
    function IsSymbol(x) {
        return typeof x === "symbol";
    }
    // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-topropertykey
    function ToPropertyKey(value) {
        if (IsSymbol(value)) {
            return value;
        }
        return String(value);
    }
    function GetPrototypeOf(O) {
        var proto = Object.getPrototypeOf(O);
        if (typeof O !== "function" || O === functionPrototype) {
            return proto;
        }
        // TypeScript doesn't set __proto__ in ES5, as it's non-standard. 
        // Try to determine the superclass constructor. Compatible implementations
        // must either set __proto__ on a subclass constructor to the superclass constructor,
        // or ensure each class has a valid `constructor` property on its prototype that
        // points back to the constructor.
        // If this is not the same as Function.[[Prototype]], then this is definately inherited.
        // This is the case when in ES6 or when using __proto__ in a compatible browser.
        if (proto !== functionPrototype) {
            return proto;
        }
        // If the super prototype is Object.prototype, null, or undefined, then we cannot determine the heritage.
        var prototype = O.prototype;
        var prototypeProto = Object.getPrototypeOf(prototype);
        if (prototypeProto == null || prototypeProto === Object.prototype) {
            return proto;
        }
        // if the constructor was not a function, then we cannot determine the heritage.
        var constructor = prototypeProto.constructor;
        if (typeof constructor !== "function") {
            return proto;
        }
        // if we have some kind of self-reference, then we cannot determine the heritage.
        if (constructor === O) {
            return proto;
        }
        // we have a pretty good guess at the heritage.
        return constructor;
    }
    // naive Map shim
    function CreateMapPolyfill() {
        var cacheSentinel = {};
        function Map() {
            this._keys = [];
            this._values = [];
            this._cache = cacheSentinel;
        }
        Map.prototype = {
            get size() {
                return this._keys.length;
            },
            has: function (key) {
                if (key === this._cache) {
                    return true;
                }
                if (this._find(key) >= 0) {
                    this._cache = key;
                    return true;
                }
                return false;
            },
            get: function (key) {
                var index = this._find(key);
                if (index >= 0) {
                    this._cache = key;
                    return this._values[index];
                }
                return undefined;
            },
            set: function (key, value) {
                this.delete(key);
                this._keys.push(key);
                this._values.push(value);
                this._cache = key;
                return this;
            },
            delete: function (key) {
                var index = this._find(key);
                if (index >= 0) {
                    this._keys.splice(index, 1);
                    this._values.splice(index, 1);
                    this._cache = cacheSentinel;
                    return true;
                }
                return false;
            },
            clear: function () {
                this._keys.length = 0;
                this._values.length = 0;
                this._cache = cacheSentinel;
            },
            forEach: function (callback, thisArg) {
                var size = this.size;
                for (var i = 0; i < size; ++i) {
                    var key = this._keys[i];
                    var value = this._values[i];
                    this._cache = key;
                    callback.call(this, value, key, this);
                }
            },
            _find: function (key) {
                var keys = this._keys;
                var size = keys.length;
                for (var i = 0; i < size; ++i) {
                    if (keys[i] === key) {
                        return i;
                    }
                }
                return -1;
            }
        };
        return Map;
    }
    // naive Set shim
    function CreateSetPolyfill() {
        var cacheSentinel = {};
        function Set() {
            this._map = new _Map();
        }
        Set.prototype = {
            get size() {
                return this._map.length;
            },
            has: function (value) {
                return this._map.has(value);
            },
            add: function (value) {
                this._map.set(value, value);
                return this;
            },
            delete: function (value) {
                return this._map.delete(value);
            },
            clear: function () {
                this._map.clear();
            },
            forEach: function (callback, thisArg) {
                this._map.forEach(callback, thisArg);
            }
        };
        return Set;
    }
    // naive WeakMap shim
    function CreateWeakMapPolyfill() {
        var UUID_SIZE = 16;
        var isNode = typeof global !== "undefined" && Object.prototype.toString.call(global.process) === '[object process]';
        var nodeCrypto = isNode && require("crypto");
        var hasOwn = Object.prototype.hasOwnProperty;
        var keys = {};
        var rootKey = CreateUniqueKey();
        function WeakMap() {
            this._key = CreateUniqueKey();
        }
        WeakMap.prototype = {
            has: function (target) {
                var table = GetOrCreateWeakMapTable(target, /*create*/ false);
                if (table) {
                    return this._key in table;
                }
                return false;
            },
            get: function (target) {
                var table = GetOrCreateWeakMapTable(target, /*create*/ false);
                if (table) {
                    return table[this._key];
                }
                return undefined;
            },
            set: function (target, value) {
                var table = GetOrCreateWeakMapTable(target, /*create*/ true);
                table[this._key] = value;
                return this;
            },
            delete: function (target) {
                var table = GetOrCreateWeakMapTable(target, /*create*/ false);
                if (table && this._key in table) {
                    return delete table[this._key];
                }
                return false;
            },
            clear: function () {
                // NOTE: not a real clear, just makes the previous data unreachable
                this._key = CreateUniqueKey();
            }
        };
        function FillRandomBytes(buffer, size) {
            for (var i = 0; i < size; ++i) {
                buffer[i] = Math.random() * 255 | 0;
            }
        }
        function GenRandomBytes(size) {
            if (nodeCrypto) {
                var data = nodeCrypto.randomBytes(size);
                return data;
            }
            else if (typeof Uint8Array === "function") {
                var data = new Uint8Array(size);
                if (typeof crypto !== "undefined") {
                    crypto.getRandomValues(data);
                }
                else if (typeof msCrypto !== "undefined") {
                    msCrypto.getRandomValues(data);
                }
                else {
                    FillRandomBytes(data, size);
                }
                return data;
            }
            else {
                var data = new Array(size);
                FillRandomBytes(data, size);
                return data;
            }
        }
        function CreateUUID() {
            var data = GenRandomBytes(UUID_SIZE);
            // mark as random - RFC 4122 § 4.4
            data[6] = data[6] & 0x4f | 0x40;
            data[8] = data[8] & 0xbf | 0x80;
            var result = "";
            for (var offset = 0; offset < UUID_SIZE; ++offset) {
                var byte = data[offset];
                if (offset === 4 || offset === 6 || offset === 8) {
                    result += "-";
                }
                if (byte < 16) {
                    result += "0";
                }
                result += byte.toString(16).toLowerCase();
            }
            return result;
        }
        function CreateUniqueKey() {
            var key;
            do {
                key = "@@WeakMap@@" + CreateUUID();
            } while (hasOwn.call(keys, key));
            keys[key] = true;
            return key;
        }
        function GetOrCreateWeakMapTable(target, create) {
            if (!hasOwn.call(target, rootKey)) {
                if (!create) {
                    return undefined;
                }
                Object.defineProperty(target, rootKey, { value: Object.create(null) });
            }
            return target[rootKey];
        }
        return WeakMap;
    }
    // hook global Reflect
    (function (__global) {
        if (typeof __global.Reflect !== "undefined") {
            if (__global.Reflect !== Reflect) {
                for (var p in Reflect) {
                    __global.Reflect[p] = Reflect[p];
                }
            }
        }
        else {
            __global.Reflect = Reflect;
        }
    })(typeof window !== "undefined" ? window :
        typeof WorkerGlobalScope !== "undefined" ? self :
            typeof global !== "undefined" ? global :
                Function("return this;")());
})(Reflect || (Reflect = {}));

(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){
(function (global){
"use strict";

_dereq_(189);

_dereq_(2);

if (global._babelPolyfill) {
  throw new Error("only one instance of babel-polyfill is allowed");
}
global._babelPolyfill = true;
}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
},{"189":189,"2":2}],2:[function(_dereq_,module,exports){
module.exports = _dereq_(190);
},{"190":190}],3:[function(_dereq_,module,exports){
module.exports = function(it){
  if(typeof it != 'function')throw TypeError(it + ' is not a function!');
  return it;
};
},{}],4:[function(_dereq_,module,exports){
// 22.1.3.31 Array.prototype[@@unscopables]
var UNSCOPABLES = _dereq_(84)('unscopables')
  , ArrayProto  = Array.prototype;
if(ArrayProto[UNSCOPABLES] == undefined)_dereq_(32)(ArrayProto, UNSCOPABLES, {});
module.exports = function(key){
  ArrayProto[UNSCOPABLES][key] = true;
};
},{"32":32,"84":84}],5:[function(_dereq_,module,exports){
var isObject = _dereq_(39);
module.exports = function(it){
  if(!isObject(it))throw TypeError(it + ' is not an object!');
  return it;
};
},{"39":39}],6:[function(_dereq_,module,exports){
// 22.1.3.3 Array.prototype.copyWithin(target, start, end = this.length)
'use strict';
var toObject = _dereq_(81)
  , toIndex  = _dereq_(77)
  , toLength = _dereq_(80);

module.exports = [].copyWithin || function copyWithin(target/*= 0*/, start/*= 0, end = @length*/){
  var O     = toObject(this)
    , len   = toLength(O.length)
    , to    = toIndex(target, len)
    , from  = toIndex(start, len)
    , $$    = arguments
    , end   = $$.length > 2 ? $$[2] : undefined
    , count = Math.min((end === undefined ? len : toIndex(end, len)) - from, len - to)
    , inc   = 1;
  if(from < to && to < from + count){
    inc  = -1;
    from += count - 1;
    to   += count - 1;
  }
  while(count-- > 0){
    if(from in O)O[to] = O[from];
    else delete O[to];
    to   += inc;
    from += inc;
  } return O;
};
},{"77":77,"80":80,"81":81}],7:[function(_dereq_,module,exports){
// 22.1.3.6 Array.prototype.fill(value, start = 0, end = this.length)
'use strict';
var toObject = _dereq_(81)
  , toIndex  = _dereq_(77)
  , toLength = _dereq_(80);
module.exports = [].fill || function fill(value /*, start = 0, end = @length */){
  var O      = toObject(this)
    , length = toLength(O.length)
    , $$     = arguments
    , $$len  = $$.length
    , index  = toIndex($$len > 1 ? $$[1] : undefined, length)
    , end    = $$len > 2 ? $$[2] : undefined
    , endPos = end === undefined ? length : toIndex(end, length);
  while(endPos > index)O[index++] = value;
  return O;
};
},{"77":77,"80":80,"81":81}],8:[function(_dereq_,module,exports){
// false -> Array#indexOf
// true  -> Array#includes
var toIObject = _dereq_(79)
  , toLength  = _dereq_(80)
  , toIndex   = _dereq_(77);
module.exports = function(IS_INCLUDES){
  return function($this, el, fromIndex){
    var O      = toIObject($this)
      , length = toLength(O.length)
      , index  = toIndex(fromIndex, length)
      , value;
    // Array#includes uses SameValueZero equality algorithm
    if(IS_INCLUDES && el != el)while(length > index){
      value = O[index++];
      if(value != value)return true;
    // Array#toIndex ignores holes, Array#includes - not
    } else for(;length > index; index++)if(IS_INCLUDES || index in O){
      if(O[index] === el)return IS_INCLUDES || index;
    } return !IS_INCLUDES && -1;
  };
};
},{"77":77,"79":79,"80":80}],9:[function(_dereq_,module,exports){
// 0 -> Array#forEach
// 1 -> Array#map
// 2 -> Array#filter
// 3 -> Array#some
// 4 -> Array#every
// 5 -> Array#find
// 6 -> Array#findIndex
var ctx      = _dereq_(18)
  , IObject  = _dereq_(35)
  , toObject = _dereq_(81)
  , toLength = _dereq_(80)
  , asc      = _dereq_(10);
module.exports = function(TYPE){
  var IS_MAP        = TYPE == 1
    , IS_FILTER     = TYPE == 2
    , IS_SOME       = TYPE == 3
    , IS_EVERY      = TYPE == 4
    , IS_FIND_INDEX = TYPE == 6
    , NO_HOLES      = TYPE == 5 || IS_FIND_INDEX;
  return function($this, callbackfn, that){
    var O      = toObject($this)
      , self   = IObject(O)
      , f      = ctx(callbackfn, that, 3)
      , length = toLength(self.length)
      , index  = 0
      , result = IS_MAP ? asc($this, length) : IS_FILTER ? asc($this, 0) : undefined
      , val, res;
    for(;length > index; index++)if(NO_HOLES || index in self){
      val = self[index];
      res = f(val, index, O);
      if(TYPE){
        if(IS_MAP)result[index] = res;            // map
        else if(res)switch(TYPE){
          case 3: return true;                    // some
          case 5: return val;                     // find
          case 6: return index;                   // findIndex
          case 2: result.push(val);               // filter
        } else if(IS_EVERY)return false;          // every
      }
    }
    return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : result;
  };
};
},{"10":10,"18":18,"35":35,"80":80,"81":81}],10:[function(_dereq_,module,exports){
// 9.4.2.3 ArraySpeciesCreate(originalArray, length)
var isObject = _dereq_(39)
  , isArray  = _dereq_(37)
  , SPECIES  = _dereq_(84)('species');
module.exports = function(original, length){
  var C;
  if(isArray(original)){
    C = original.constructor;
    // cross-realm fallback
    if(typeof C == 'function' && (C === Array || isArray(C.prototype)))C = undefined;
    if(isObject(C)){
      C = C[SPECIES];
      if(C === null)C = undefined;
    }
  } return new (C === undefined ? Array : C)(length);
};
},{"37":37,"39":39,"84":84}],11:[function(_dereq_,module,exports){
// getting tag from 19.1.3.6 Object.prototype.toString()
var cof = _dereq_(12)
  , TAG = _dereq_(84)('toStringTag')
  // ES3 wrong here
  , ARG = cof(function(){ return arguments; }()) == 'Arguments';

module.exports = function(it){
  var O, T, B;
  return it === undefined ? 'Undefined' : it === null ? 'Null'
    // @@toStringTag case
    : typeof (T = (O = Object(it))[TAG]) == 'string' ? T
    // builtinTag case
    : ARG ? cof(O)
    // ES3 arguments fallback
    : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;
};
},{"12":12,"84":84}],12:[function(_dereq_,module,exports){
var toString = {}.toString;

module.exports = function(it){
  return toString.call(it).slice(8, -1);
};
},{}],13:[function(_dereq_,module,exports){
'use strict';
var $            = _dereq_(47)
  , hide         = _dereq_(32)
  , redefineAll  = _dereq_(61)
  , ctx          = _dereq_(18)
  , strictNew    = _dereq_(70)
  , defined      = _dereq_(19)
  , forOf        = _dereq_(28)
  , $iterDefine  = _dereq_(43)
  , step         = _dereq_(45)
  , ID           = _dereq_(83)('id')
  , $has         = _dereq_(31)
  , isObject     = _dereq_(39)
  , setSpecies   = _dereq_(66)
  , DESCRIPTORS  = _dereq_(20)
  , isExtensible = Object.isExtensible || isObject
  , SIZE         = DESCRIPTORS ? '_s' : 'size'
  , id           = 0;

var fastKey = function(it, create){
  // return primitive with prefix
  if(!isObject(it))return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
  if(!$has(it, ID)){
    // can't set id to frozen object
    if(!isExtensible(it))return 'F';
    // not necessary to add id
    if(!create)return 'E';
    // add missing object id
    hide(it, ID, ++id);
  // return object id with prefix
  } return 'O' + it[ID];
};

var getEntry = function(that, key){
  // fast case
  var index = fastKey(key), entry;
  if(index !== 'F')return that._i[index];
  // frozen object case
  for(entry = that._f; entry; entry = entry.n){
    if(entry.k == key)return entry;
  }
};

module.exports = {
  getConstructor: function(wrapper, NAME, IS_MAP, ADDER){
    var C = wrapper(function(that, iterable){
      strictNew(that, C, NAME);
      that._i = $.create(null); // index
      that._f = undefined;      // first entry
      that._l = undefined;      // last entry
      that[SIZE] = 0;           // size
      if(iterable != undefined)forOf(iterable, IS_MAP, that[ADDER], that);
    });
    redefineAll(C.prototype, {
      // 23.1.3.1 Map.prototype.clear()
      // 23.2.3.2 Set.prototype.clear()
      clear: function clear(){
        for(var that = this, data = that._i, entry = that._f; entry; entry = entry.n){
          entry.r = true;
          if(entry.p)entry.p = entry.p.n = undefined;
          delete data[entry.i];
        }
        that._f = that._l = undefined;
        that[SIZE] = 0;
      },
      // 23.1.3.3 Map.prototype.delete(key)
      // 23.2.3.4 Set.prototype.delete(value)
      'delete': function(key){
        var that  = this
          , entry = getEntry(that, key);
        if(entry){
          var next = entry.n
            , prev = entry.p;
          delete that._i[entry.i];
          entry.r = true;
          if(prev)prev.n = next;
          if(next)next.p = prev;
          if(that._f == entry)that._f = next;
          if(that._l == entry)that._l = prev;
          that[SIZE]--;
        } return !!entry;
      },
      // 23.2.3.6 Set.prototype.forEach(callbackfn, thisArg = undefined)
      // 23.1.3.5 Map.prototype.forEach(callbackfn, thisArg = undefined)
      forEach: function forEach(callbackfn /*, that = undefined */){
        var f = ctx(callbackfn, arguments.length > 1 ? arguments[1] : undefined, 3)
          , entry;
        while(entry = entry ? entry.n : this._f){
          f(entry.v, entry.k, this);
          // revert to the last existing entry
          while(entry && entry.r)entry = entry.p;
        }
      },
      // 23.1.3.7 Map.prototype.has(key)
      // 23.2.3.7 Set.prototype.has(value)
      has: function has(key){
        return !!getEntry(this, key);
      }
    });
    if(DESCRIPTORS)$.setDesc(C.prototype, 'size', {
      get: function(){
        return defined(this[SIZE]);
      }
    });
    return C;
  },
  def: function(that, key, value){
    var entry = getEntry(that, key)
      , prev, index;
    // change existing entry
    if(entry){
      entry.v = value;
    // create new entry
    } else {
      that._l = entry = {
        i: index = fastKey(key, true), // <- index
        k: key,                        // <- key
        v: value,                      // <- value
        p: prev = that._l,             // <- previous entry
        n: undefined,                  // <- next entry
        r: false                       // <- removed
      };
      if(!that._f)that._f = entry;
      if(prev)prev.n = entry;
      that[SIZE]++;
      // add to index
      if(index !== 'F')that._i[index] = entry;
    } return that;
  },
  getEntry: getEntry,
  setStrong: function(C, NAME, IS_MAP){
    // add .keys, .values, .entries, [@@iterator]
    // 23.1.3.4, 23.1.3.8, 23.1.3.11, 23.1.3.12, 23.2.3.5, 23.2.3.8, 23.2.3.10, 23.2.3.11
    $iterDefine(C, NAME, function(iterated, kind){
      this._t = iterated;  // target
      this._k = kind;      // kind
      this._l = undefined; // previous
    }, function(){
      var that  = this
        , kind  = that._k
        , entry = that._l;
      // revert to the last existing entry
      while(entry && entry.r)entry = entry.p;
      // get next entry
      if(!that._t || !(that._l = entry = entry ? entry.n : that._t._f)){
        // or finish the iteration
        that._t = undefined;
        return step(1);
      }
      // return step by kind
      if(kind == 'keys'  )return step(0, entry.k);
      if(kind == 'values')return step(0, entry.v);
      return step(0, [entry.k, entry.v]);
    }, IS_MAP ? 'entries' : 'values' , !IS_MAP, true);

    // add [@@species], 23.1.2.2, 23.2.2.2
    setSpecies(NAME);
  }
};
},{"18":18,"19":19,"20":20,"28":28,"31":31,"32":32,"39":39,"43":43,"45":45,"47":47,"61":61,"66":66,"70":70,"83":83}],14:[function(_dereq_,module,exports){
// https://github.com/DavidBruant/Map-Set.prototype.toJSON
var forOf   = _dereq_(28)
  , classof = _dereq_(11);
module.exports = function(NAME){
  return function toJSON(){
    if(classof(this) != NAME)throw TypeError(NAME + "#toJSON isn't generic");
    var arr = [];
    forOf(this, false, arr.push, arr);
    return arr;
  };
};
},{"11":11,"28":28}],15:[function(_dereq_,module,exports){
'use strict';
var hide              = _dereq_(32)
  , redefineAll       = _dereq_(61)
  , anObject          = _dereq_(5)
  , isObject          = _dereq_(39)
  , strictNew         = _dereq_(70)
  , forOf             = _dereq_(28)
  , createArrayMethod = _dereq_(9)
  , $has              = _dereq_(31)
  , WEAK              = _dereq_(83)('weak')
  , isExtensible      = Object.isExtensible || isObject
  , arrayFind         = createArrayMethod(5)
  , arrayFindIndex    = createArrayMethod(6)
  , id                = 0;

// fallback for frozen keys
var frozenStore = function(that){
  return that._l || (that._l = new FrozenStore);
};
var FrozenStore = function(){
  this.a = [];
};
var findFrozen = function(store, key){
  return arrayFind(store.a, function(it){
    return it[0] === key;
  });
};
FrozenStore.prototype = {
  get: function(key){
    var entry = findFrozen(this, key);
    if(entry)return entry[1];
  },
  has: function(key){
    return !!findFrozen(this, key);
  },
  set: function(key, value){
    var entry = findFrozen(this, key);
    if(entry)entry[1] = value;
    else this.a.push([key, value]);
  },
  'delete': function(key){
    var index = arrayFindIndex(this.a, function(it){
      return it[0] === key;
    });
    if(~index)this.a.splice(index, 1);
    return !!~index;
  }
};

module.exports = {
  getConstructor: function(wrapper, NAME, IS_MAP, ADDER){
    var C = wrapper(function(that, iterable){
      strictNew(that, C, NAME);
      that._i = id++;      // collection id
      that._l = undefined; // leak store for frozen objects
      if(iterable != undefined)forOf(iterable, IS_MAP, that[ADDER], that);
    });
    redefineAll(C.prototype, {
      // 23.3.3.2 WeakMap.prototype.delete(key)
      // 23.4.3.3 WeakSet.prototype.delete(value)
      'delete': function(key){
        if(!isObject(key))return false;
        if(!isExtensible(key))return frozenStore(this)['delete'](key);
        return $has(key, WEAK) && $has(key[WEAK], this._i) && delete key[WEAK][this._i];
      },
      // 23.3.3.4 WeakMap.prototype.has(key)
      // 23.4.3.4 WeakSet.prototype.has(value)
      has: function has(key){
        if(!isObject(key))return false;
        if(!isExtensible(key))return frozenStore(this).has(key);
        return $has(key, WEAK) && $has(key[WEAK], this._i);
      }
    });
    return C;
  },
  def: function(that, key, value){
    if(!isExtensible(anObject(key))){
      frozenStore(that).set(key, value);
    } else {
      $has(key, WEAK) || hide(key, WEAK, {});
      key[WEAK][that._i] = value;
    } return that;
  },
  frozenStore: frozenStore,
  WEAK: WEAK
};
},{"28":28,"31":31,"32":32,"39":39,"5":5,"61":61,"70":70,"83":83,"9":9}],16:[function(_dereq_,module,exports){
'use strict';
var global         = _dereq_(30)
  , $export        = _dereq_(23)
  , redefine       = _dereq_(62)
  , redefineAll    = _dereq_(61)
  , forOf          = _dereq_(28)
  , strictNew      = _dereq_(70)
  , isObject       = _dereq_(39)
  , fails          = _dereq_(25)
  , $iterDetect    = _dereq_(44)
  , setToStringTag = _dereq_(67);

module.exports = function(NAME, wrapper, methods, common, IS_MAP, IS_WEAK){
  var Base  = global[NAME]
    , C     = Base
    , ADDER = IS_MAP ? 'set' : 'add'
    , proto = C && C.prototype
    , O     = {};
  var fixMethod = function(KEY){
    var fn = proto[KEY];
    redefine(proto, KEY,
      KEY == 'delete' ? function(a){
        return IS_WEAK && !isObject(a) ? false : fn.call(this, a === 0 ? 0 : a);
      } : KEY == 'has' ? function has(a){
        return IS_WEAK && !isObject(a) ? false : fn.call(this, a === 0 ? 0 : a);
      } : KEY == 'get' ? function get(a){
        return IS_WEAK && !isObject(a) ? undefined : fn.call(this, a === 0 ? 0 : a);
      } : KEY == 'add' ? function add(a){ fn.call(this, a === 0 ? 0 : a); return this; }
        : function set(a, b){ fn.call(this, a === 0 ? 0 : a, b); return this; }
    );
  };
  if(typeof C != 'function' || !(IS_WEAK || proto.forEach && !fails(function(){
    new C().entries().next();
  }))){
    // create collection constructor
    C = common.getConstructor(wrapper, NAME, IS_MAP, ADDER);
    redefineAll(C.prototype, methods);
  } else {
    var instance             = new C
      // early implementations not supports chaining
      , HASNT_CHAINING       = instance[ADDER](IS_WEAK ? {} : -0, 1) != instance
      // V8 ~  Chromium 40- weak-collections throws on primitives, but should return false
      , THROWS_ON_PRIMITIVES = fails(function(){ instance.has(1); })
      // most early implementations doesn't supports iterables, most modern - not close it correctly
      , ACCEPT_ITERABLES     = $iterDetect(function(iter){ new C(iter); }) // eslint-disable-line no-new
      // for early implementations -0 and +0 not the same
      , BUGGY_ZERO;
    if(!ACCEPT_ITERABLES){ 
      C = wrapper(function(target, iterable){
        strictNew(target, C, NAME);
        var that = new Base;
        if(iterable != undefined)forOf(iterable, IS_MAP, that[ADDER], that);
        return that;
      });
      C.prototype = proto;
      proto.constructor = C;
    }
    IS_WEAK || instance.forEach(function(val, key){
      BUGGY_ZERO = 1 / key === -Infinity;
    });
    if(THROWS_ON_PRIMITIVES || BUGGY_ZERO){
      fixMethod('delete');
      fixMethod('has');
      IS_MAP && fixMethod('get');
    }
    if(BUGGY_ZERO || HASNT_CHAINING)fixMethod(ADDER);
    // weak collections should not contains .clear method
    if(IS_WEAK && proto.clear)delete proto.clear;
  }

  setToStringTag(C, NAME);

  O[NAME] = C;
  $export($export.G + $export.W + $export.F * (C != Base), O);

  if(!IS_WEAK)common.setStrong(C, NAME, IS_MAP);

  return C;
};
},{"23":23,"25":25,"28":28,"30":30,"39":39,"44":44,"61":61,"62":62,"67":67,"70":70}],17:[function(_dereq_,module,exports){
var core = module.exports = {version: '1.2.6'};
if(typeof __e == 'number')__e = core; // eslint-disable-line no-undef
},{}],18:[function(_dereq_,module,exports){
// optional / simple context binding
var aFunction = _dereq_(3);
module.exports = function(fn, that, length){
  aFunction(fn);
  if(that === undefined)return fn;
  switch(length){
    case 1: return function(a){
      return fn.call(that, a);
    };
    case 2: return function(a, b){
      return fn.call(that, a, b);
    };
    case 3: return function(a, b, c){
      return fn.call(that, a, b, c);
    };
  }
  return function(/* ...args */){
    return fn.apply(that, arguments);
  };
};
},{"3":3}],19:[function(_dereq_,module,exports){
// 7.2.1 RequireObjectCoercible(argument)
module.exports = function(it){
  if(it == undefined)throw TypeError("Can't call method on  " + it);
  return it;
};
},{}],20:[function(_dereq_,module,exports){
// Thank's IE8 for his funny defineProperty
module.exports = !_dereq_(25)(function(){
  return Object.defineProperty({}, 'a', {get: function(){ return 7; }}).a != 7;
});
},{"25":25}],21:[function(_dereq_,module,exports){
var isObject = _dereq_(39)
  , document = _dereq_(30).document
  // in old IE typeof document.createElement is 'object'
  , is = isObject(document) && isObject(document.createElement);
module.exports = function(it){
  return is ? document.createElement(it) : {};
};
},{"30":30,"39":39}],22:[function(_dereq_,module,exports){
// all enumerable object keys, includes symbols
var $ = _dereq_(47);
module.exports = function(it){
  var keys       = $.getKeys(it)
    , getSymbols = $.getSymbols;
  if(getSymbols){
    var symbols = getSymbols(it)
      , isEnum  = $.isEnum
      , i       = 0
      , key;
    while(symbols.length > i)if(isEnum.call(it, key = symbols[i++]))keys.push(key);
  }
  return keys;
};
},{"47":47}],23:[function(_dereq_,module,exports){
var global    = _dereq_(30)
  , core      = _dereq_(17)
  , hide      = _dereq_(32)
  , redefine  = _dereq_(62)
  , ctx       = _dereq_(18)
  , PROTOTYPE = 'prototype';

var $export = function(type, name, source){
  var IS_FORCED = type & $export.F
    , IS_GLOBAL = type & $export.G
    , IS_STATIC = type & $export.S
    , IS_PROTO  = type & $export.P
    , IS_BIND   = type & $export.B
    , target    = IS_GLOBAL ? global : IS_STATIC ? global[name] || (global[name] = {}) : (global[name] || {})[PROTOTYPE]
    , exports   = IS_GLOBAL ? core : core[name] || (core[name] = {})
    , expProto  = exports[PROTOTYPE] || (exports[PROTOTYPE] = {})
    , key, own, out, exp;
  if(IS_GLOBAL)source = name;
  for(key in source){
    // contains in native
    own = !IS_FORCED && target && key in target;
    // export native or passed
    out = (own ? target : source)[key];
    // bind timers to global for call from export context
    exp = IS_BIND && own ? ctx(out, global) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
    // extend global
    if(target && !own)redefine(target, key, out);
    // export
    if(exports[key] != out)hide(exports, key, exp);
    if(IS_PROTO && expProto[key] != out)expProto[key] = out;
  }
};
global.core = core;
// type bitmap
$export.F = 1;  // forced
$export.G = 2;  // global
$export.S = 4;  // static
$export.P = 8;  // proto
$export.B = 16; // bind
$export.W = 32; // wrap
module.exports = $export;
},{"17":17,"18":18,"30":30,"32":32,"62":62}],24:[function(_dereq_,module,exports){
var MATCH = _dereq_(84)('match');
module.exports = function(KEY){
  var re = /./;
  try {
    '/./'[KEY](re);
  } catch(e){
    try {
      re[MATCH] = false;
      return !'/./'[KEY](re);
    } catch(f){ /* empty */ }
  } return true;
};
},{"84":84}],25:[function(_dereq_,module,exports){
module.exports = function(exec){
  try {
    return !!exec();
  } catch(e){
    return true;
  }
};
},{}],26:[function(_dereq_,module,exports){
'use strict';
var hide     = _dereq_(32)
  , redefine = _dereq_(62)
  , fails    = _dereq_(25)
  , defined  = _dereq_(19)
  , wks      = _dereq_(84);

module.exports = function(KEY, length, exec){
  var SYMBOL   = wks(KEY)
    , original = ''[KEY];
  if(fails(function(){
    var O = {};
    O[SYMBOL] = function(){ return 7; };
    return ''[KEY](O) != 7;
  })){
    redefine(String.prototype, KEY, exec(defined, SYMBOL, original));
    hide(RegExp.prototype, SYMBOL, length == 2
      // 21.2.5.8 RegExp.prototype[@@replace](string, replaceValue)
      // 21.2.5.11 RegExp.prototype[@@split](string, limit)
      ? function(string, arg){ return original.call(string, this, arg); }
      // 21.2.5.6 RegExp.prototype[@@match](string)
      // 21.2.5.9 RegExp.prototype[@@search](string)
      : function(string){ return original.call(string, this); }
    );
  }
};
},{"19":19,"25":25,"32":32,"62":62,"84":84}],27:[function(_dereq_,module,exports){
'use strict';
// 21.2.5.3 get RegExp.prototype.flags
var anObject = _dereq_(5);
module.exports = function(){
  var that   = anObject(this)
    , result = '';
  if(that.global)     result += 'g';
  if(that.ignoreCase) result += 'i';
  if(that.multiline)  result += 'm';
  if(that.unicode)    result += 'u';
  if(that.sticky)     result += 'y';
  return result;
};
},{"5":5}],28:[function(_dereq_,module,exports){
var ctx         = _dereq_(18)
  , call        = _dereq_(41)
  , isArrayIter = _dereq_(36)
  , anObject    = _dereq_(5)
  , toLength    = _dereq_(80)
  , getIterFn   = _dereq_(85);
module.exports = function(iterable, entries, fn, that){
  var iterFn = getIterFn(iterable)
    , f      = ctx(fn, that, entries ? 2 : 1)
    , index  = 0
    , length, step, iterator;
  if(typeof iterFn != 'function')throw TypeError(iterable + ' is not iterable!');
  // fast case for arrays with default iterator
  if(isArrayIter(iterFn))for(length = toLength(iterable.length); length > index; index++){
    entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);
  } else for(iterator = iterFn.call(iterable); !(step = iterator.next()).done; ){
    call(iterator, f, step.value, entries);
  }
};
},{"18":18,"36":36,"41":41,"5":5,"80":80,"85":85}],29:[function(_dereq_,module,exports){
// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
var toIObject = _dereq_(79)
  , getNames  = _dereq_(47).getNames
  , toString  = {}.toString;

var windowNames = typeof window == 'object' && Object.getOwnPropertyNames
  ? Object.getOwnPropertyNames(window) : [];

var getWindowNames = function(it){
  try {
    return getNames(it);
  } catch(e){
    return windowNames.slice();
  }
};

module.exports.get = function getOwnPropertyNames(it){
  if(windowNames && toString.call(it) == '[object Window]')return getWindowNames(it);
  return getNames(toIObject(it));
};
},{"47":47,"79":79}],30:[function(_dereq_,module,exports){
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
var global = module.exports = typeof window != 'undefined' && window.Math == Math
  ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')();
if(typeof __g == 'number')__g = global; // eslint-disable-line no-undef
},{}],31:[function(_dereq_,module,exports){
var hasOwnProperty = {}.hasOwnProperty;
module.exports = function(it, key){
  return hasOwnProperty.call(it, key);
};
},{}],32:[function(_dereq_,module,exports){
var $          = _dereq_(47)
  , createDesc = _dereq_(60);
module.exports = _dereq_(20) ? function(object, key, value){
  return $.setDesc(object, key, createDesc(1, value));
} : function(object, key, value){
  object[key] = value;
  return object;
};
},{"20":20,"47":47,"60":60}],33:[function(_dereq_,module,exports){
module.exports = _dereq_(30).document && document.documentElement;
},{"30":30}],34:[function(_dereq_,module,exports){
// fast apply, http://jsperf.lnkit.com/fast-apply/5
module.exports = function(fn, args, that){
  var un = that === undefined;
  switch(args.length){
    case 0: return un ? fn()
                      : fn.call(that);
    case 1: return un ? fn(args[0])
                      : fn.call(that, args[0]);
    case 2: return un ? fn(args[0], args[1])
                      : fn.call(that, args[0], args[1]);
    case 3: return un ? fn(args[0], args[1], args[2])
                      : fn.call(that, args[0], args[1], args[2]);
    case 4: return un ? fn(args[0], args[1], args[2], args[3])
                      : fn.call(that, args[0], args[1], args[2], args[3]);
  } return              fn.apply(that, args);
};
},{}],35:[function(_dereq_,module,exports){
// fallback for non-array-like ES3 and non-enumerable old V8 strings
var cof = _dereq_(12);
module.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it){
  return cof(it) == 'String' ? it.split('') : Object(it);
};
},{"12":12}],36:[function(_dereq_,module,exports){
// check on default Array iterator
var Iterators  = _dereq_(46)
  , ITERATOR   = _dereq_(84)('iterator')
  , ArrayProto = Array.prototype;

module.exports = function(it){
  return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
};
},{"46":46,"84":84}],37:[function(_dereq_,module,exports){
// 7.2.2 IsArray(argument)
var cof = _dereq_(12);
module.exports = Array.isArray || function(arg){
  return cof(arg) == 'Array';
};
},{"12":12}],38:[function(_dereq_,module,exports){
// 20.1.2.3 Number.isInteger(number)
var isObject = _dereq_(39)
  , floor    = Math.floor;
module.exports = function isInteger(it){
  return !isObject(it) && isFinite(it) && floor(it) === it;
};
},{"39":39}],39:[function(_dereq_,module,exports){
module.exports = function(it){
  return typeof it === 'object' ? it !== null : typeof it === 'function';
};
},{}],40:[function(_dereq_,module,exports){
// 7.2.8 IsRegExp(argument)
var isObject = _dereq_(39)
  , cof      = _dereq_(12)
  , MATCH    = _dereq_(84)('match');
module.exports = function(it){
  var isRegExp;
  return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : cof(it) == 'RegExp');
};
},{"12":12,"39":39,"84":84}],41:[function(_dereq_,module,exports){
// call something on iterator step with safe closing on error
var anObject = _dereq_(5);
module.exports = function(iterator, fn, value, entries){
  try {
    return entries ? fn(anObject(value)[0], value[1]) : fn(value);
  // 7.4.6 IteratorClose(iterator, completion)
  } catch(e){
    var ret = iterator['return'];
    if(ret !== undefined)anObject(ret.call(iterator));
    throw e;
  }
};
},{"5":5}],42:[function(_dereq_,module,exports){
'use strict';
var $              = _dereq_(47)
  , descriptor     = _dereq_(60)
  , setToStringTag = _dereq_(67)
  , IteratorPrototype = {};

// 25.1.2.1.1 %IteratorPrototype%[@@iterator]()
_dereq_(32)(IteratorPrototype, _dereq_(84)('iterator'), function(){ return this; });

module.exports = function(Constructor, NAME, next){
  Constructor.prototype = $.create(IteratorPrototype, {next: descriptor(1, next)});
  setToStringTag(Constructor, NAME + ' Iterator');
};
},{"32":32,"47":47,"60":60,"67":67,"84":84}],43:[function(_dereq_,module,exports){
'use strict';
var LIBRARY        = _dereq_(49)
  , $export        = _dereq_(23)
  , redefine       = _dereq_(62)
  , hide           = _dereq_(32)
  , has            = _dereq_(31)
  , Iterators      = _dereq_(46)
  , $iterCreate    = _dereq_(42)
  , setToStringTag = _dereq_(67)
  , getProto       = _dereq_(47).getProto
  , ITERATOR       = _dereq_(84)('iterator')
  , BUGGY          = !([].keys && 'next' in [].keys()) // Safari has buggy iterators w/o `next`
  , FF_ITERATOR    = '@@iterator'
  , KEYS           = 'keys'
  , VALUES         = 'values';

var returnThis = function(){ return this; };

module.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED){
  $iterCreate(Constructor, NAME, next);
  var getMethod = function(kind){
    if(!BUGGY && kind in proto)return proto[kind];
    switch(kind){
      case KEYS: return function keys(){ return new Constructor(this, kind); };
      case VALUES: return function values(){ return new Constructor(this, kind); };
    } return function entries(){ return new Constructor(this, kind); };
  };
  var TAG        = NAME + ' Iterator'
    , DEF_VALUES = DEFAULT == VALUES
    , VALUES_BUG = false
    , proto      = Base.prototype
    , $native    = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT]
    , $default   = $native || getMethod(DEFAULT)
    , methods, key;
  // Fix native
  if($native){
    var IteratorPrototype = getProto($default.call(new Base));
    // Set @@toStringTag to native iterators
    setToStringTag(IteratorPrototype, TAG, true);
    // FF fix
    if(!LIBRARY && has(proto, FF_ITERATOR))hide(IteratorPrototype, ITERATOR, returnThis);
    // fix Array#{values, @@iterator}.name in V8 / FF
    if(DEF_VALUES && $native.name !== VALUES){
      VALUES_BUG = true;
      $default = function values(){ return $native.call(this); };
    }
  }
  // Define iterator
  if((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])){
    hide(proto, ITERATOR, $default);
  }
  // Plug for library
  Iterators[NAME] = $default;
  Iterators[TAG]  = returnThis;
  if(DEFAULT){
    methods = {
      values:  DEF_VALUES  ? $default : getMethod(VALUES),
      keys:    IS_SET      ? $default : getMethod(KEYS),
      entries: !DEF_VALUES ? $default : getMethod('entries')
    };
    if(FORCED)for(key in methods){
      if(!(key in proto))redefine(proto, key, methods[key]);
    } else $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
  }
  return methods;
};
},{"23":23,"31":31,"32":32,"42":42,"46":46,"47":47,"49":49,"62":62,"67":67,"84":84}],44:[function(_dereq_,module,exports){
var ITERATOR     = _dereq_(84)('iterator')
  , SAFE_CLOSING = false;

try {
  var riter = [7][ITERATOR]();
  riter['return'] = function(){ SAFE_CLOSING = true; };
  Array.from(riter, function(){ throw 2; });
} catch(e){ /* empty */ }

module.exports = function(exec, skipClosing){
  if(!skipClosing && !SAFE_CLOSING)return false;
  var safe = false;
  try {
    var arr  = [7]
      , iter = arr[ITERATOR]();
    iter.next = function(){ safe = true; };
    arr[ITERATOR] = function(){ return iter; };
    exec(arr);
  } catch(e){ /* empty */ }
  return safe;
};
},{"84":84}],45:[function(_dereq_,module,exports){
module.exports = function(done, value){
  return {value: value, done: !!done};
};
},{}],46:[function(_dereq_,module,exports){
module.exports = {};
},{}],47:[function(_dereq_,module,exports){
var $Object = Object;
module.exports = {
  create:     $Object.create,
  getProto:   $Object.getPrototypeOf,
  isEnum:     {}.propertyIsEnumerable,
  getDesc:    $Object.getOwnPropertyDescriptor,
  setDesc:    $Object.defineProperty,
  setDescs:   $Object.defineProperties,
  getKeys:    $Object.keys,
  getNames:   $Object.getOwnPropertyNames,
  getSymbols: $Object.getOwnPropertySymbols,
  each:       [].forEach
};
},{}],48:[function(_dereq_,module,exports){
var $         = _dereq_(47)
  , toIObject = _dereq_(79);
module.exports = function(object, el){
  var O      = toIObject(object)
    , keys   = $.getKeys(O)
    , length = keys.length
    , index  = 0
    , key;
  while(length > index)if(O[key = keys[index++]] === el)return key;
};
},{"47":47,"79":79}],49:[function(_dereq_,module,exports){
module.exports = false;
},{}],50:[function(_dereq_,module,exports){
// 20.2.2.14 Math.expm1(x)
module.exports = Math.expm1 || function expm1(x){
  return (x = +x) == 0 ? x : x > -1e-6 && x < 1e-6 ? x + x * x / 2 : Math.exp(x) - 1;
};
},{}],51:[function(_dereq_,module,exports){
// 20.2.2.20 Math.log1p(x)
module.exports = Math.log1p || function log1p(x){
  return (x = +x) > -1e-8 && x < 1e-8 ? x - x * x / 2 : Math.log(1 + x);
};
},{}],52:[function(_dereq_,module,exports){
// 20.2.2.28 Math.sign(x)
module.exports = Math.sign || function sign(x){
  return (x = +x) == 0 || x != x ? x : x < 0 ? -1 : 1;
};
},{}],53:[function(_dereq_,module,exports){
var global    = _dereq_(30)
  , macrotask = _dereq_(76).set
  , Observer  = global.MutationObserver || global.WebKitMutationObserver
  , process   = global.process
  , Promise   = global.Promise
  , isNode    = _dereq_(12)(process) == 'process'
  , head, last, notify;

var flush = function(){
  var parent, domain, fn;
  if(isNode && (parent = process.domain)){
    process.domain = null;
    parent.exit();
  }
  while(head){
    domain = head.domain;
    fn     = head.fn;
    if(domain)domain.enter();
    fn(); // <- currently we use it only for Promise - try / catch not required
    if(domain)domain.exit();
    head = head.next;
  } last = undefined;
  if(parent)parent.enter();
};

// Node.js
if(isNode){
  notify = function(){
    process.nextTick(flush);
  };
// browsers with MutationObserver
} else if(Observer){
  var toggle = 1
    , node   = document.createTextNode('');
  new Observer(flush).observe(node, {characterData: true}); // eslint-disable-line no-new
  notify = function(){
    node.data = toggle = -toggle;
  };
// environments with maybe non-completely correct, but existent Promise
} else if(Promise && Promise.resolve){
  notify = function(){
    Promise.resolve().then(flush);
  };
// for other environments - macrotask based on:
// - setImmediate
// - MessageChannel
// - window.postMessag
// - onreadystatechange
// - setTimeout
} else {
  notify = function(){
    // strange IE + webpack dev server bug - use .call(global)
    macrotask.call(global, flush);
  };
}

module.exports = function asap(fn){
  var task = {fn: fn, next: undefined, domain: isNode && process.domain};
  if(last)last.next = task;
  if(!head){
    head = task;
    notify();
  } last = task;
};
},{"12":12,"30":30,"76":76}],54:[function(_dereq_,module,exports){
// 19.1.2.1 Object.assign(target, source, ...)
var $        = _dereq_(47)
  , toObject = _dereq_(81)
  , IObject  = _dereq_(35);

// should work with symbols and should have deterministic property order (V8 bug)
module.exports = _dereq_(25)(function(){
  var a = Object.assign
    , A = {}
    , B = {}
    , S = Symbol()
    , K = 'abcdefghijklmnopqrst';
  A[S] = 7;
  K.split('').forEach(function(k){ B[k] = k; });
  return a({}, A)[S] != 7 || Object.keys(a({}, B)).join('') != K;
}) ? function assign(target, source){ // eslint-disable-line no-unused-vars
  var T     = toObject(target)
    , $$    = arguments
    , $$len = $$.length
    , index = 1
    , getKeys    = $.getKeys
    , getSymbols = $.getSymbols
    , isEnum     = $.isEnum;
  while($$len > index){
    var S      = IObject($$[index++])
      , keys   = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S)
      , length = keys.length
      , j      = 0
      , key;
    while(length > j)if(isEnum.call(S, key = keys[j++]))T[key] = S[key];
  }
  return T;
} : Object.assign;
},{"25":25,"35":35,"47":47,"81":81}],55:[function(_dereq_,module,exports){
// most Object methods by ES6 should accept primitives
var $export = _dereq_(23)
  , core    = _dereq_(17)
  , fails   = _dereq_(25);
module.exports = function(KEY, exec){
  var fn  = (core.Object || {})[KEY] || Object[KEY]
    , exp = {};
  exp[KEY] = exec(fn);
  $export($export.S + $export.F * fails(function(){ fn(1); }), 'Object', exp);
};
},{"17":17,"23":23,"25":25}],56:[function(_dereq_,module,exports){
var $         = _dereq_(47)
  , toIObject = _dereq_(79)
  , isEnum    = $.isEnum;
module.exports = function(isEntries){
  return function(it){
    var O      = toIObject(it)
      , keys   = $.getKeys(O)
      , length = keys.length
      , i      = 0
      , result = []
      , key;
    while(length > i)if(isEnum.call(O, key = keys[i++])){
      result.push(isEntries ? [key, O[key]] : O[key]);
    } return result;
  };
};
},{"47":47,"79":79}],57:[function(_dereq_,module,exports){
// all object keys, includes non-enumerable and symbols
var $        = _dereq_(47)
  , anObject = _dereq_(5)
  , Reflect  = _dereq_(30).Reflect;
module.exports = Reflect && Reflect.ownKeys || function ownKeys(it){
  var keys       = $.getNames(anObject(it))
    , getSymbols = $.getSymbols;
  return getSymbols ? keys.concat(getSymbols(it)) : keys;
};
},{"30":30,"47":47,"5":5}],58:[function(_dereq_,module,exports){
'use strict';
var path      = _dereq_(59)
  , invoke    = _dereq_(34)
  , aFunction = _dereq_(3);
module.exports = function(/* ...pargs */){
  var fn     = aFunction(this)
    , length = arguments.length
    , pargs  = Array(length)
    , i      = 0
    , _      = path._
    , holder = false;
  while(length > i)if((pargs[i] = arguments[i++]) === _)holder = true;
  return function(/* ...args */){
    var that  = this
      , $$    = arguments
      , $$len = $$.length
      , j = 0, k = 0, args;
    if(!holder && !$$len)return invoke(fn, pargs, that);
    args = pargs.slice();
    if(holder)for(;length > j; j++)if(args[j] === _)args[j] = $$[k++];
    while($$len > k)args.push($$[k++]);
    return invoke(fn, args, that);
  };
};
},{"3":3,"34":34,"59":59}],59:[function(_dereq_,module,exports){
module.exports = _dereq_(30);
},{"30":30}],60:[function(_dereq_,module,exports){
module.exports = function(bitmap, value){
  return {
    enumerable  : !(bitmap & 1),
    configurable: !(bitmap & 2),
    writable    : !(bitmap & 4),
    value       : value
  };
};
},{}],61:[function(_dereq_,module,exports){
var redefine = _dereq_(62);
module.exports = function(target, src){
  for(var key in src)redefine(target, key, src[key]);
  return target;
};
},{"62":62}],62:[function(_dereq_,module,exports){
// add fake Function#toString
// for correct work wrapped methods / constructors with methods like LoDash isNative
var global    = _dereq_(30)
  , hide      = _dereq_(32)
  , SRC       = _dereq_(83)('src')
  , TO_STRING = 'toString'
  , $toString = Function[TO_STRING]
  , TPL       = ('' + $toString).split(TO_STRING);

_dereq_(17).inspectSource = function(it){
  return $toString.call(it);
};

(module.exports = function(O, key, val, safe){
  if(typeof val == 'function'){
    val.hasOwnProperty(SRC) || hide(val, SRC, O[key] ? '' + O[key] : TPL.join(String(key)));
    val.hasOwnProperty('name') || hide(val, 'name', key);
  }
  if(O === global){
    O[key] = val;
  } else {
    if(!safe)delete O[key];
    hide(O, key, val);
  }
})(Function.prototype, TO_STRING, function toString(){
  return typeof this == 'function' && this[SRC] || $toString.call(this);
});
},{"17":17,"30":30,"32":32,"83":83}],63:[function(_dereq_,module,exports){
module.exports = function(regExp, replace){
  var replacer = replace === Object(replace) ? function(part){
    return replace[part];
  } : replace;
  return function(it){
    return String(it).replace(regExp, replacer);
  };
};
},{}],64:[function(_dereq_,module,exports){
// 7.2.9 SameValue(x, y)
module.exports = Object.is || function is(x, y){
  return x === y ? x !== 0 || 1 / x === 1 / y : x != x && y != y;
};
},{}],65:[function(_dereq_,module,exports){
// Works with __proto__ only. Old v8 can't work with null proto objects.
/* eslint-disable no-proto */
var getDesc  = _dereq_(47).getDesc
  , isObject = _dereq_(39)
  , anObject = _dereq_(5);
var check = function(O, proto){
  anObject(O);
  if(!isObject(proto) && proto !== null)throw TypeError(proto + ": can't set as prototype!");
};
module.exports = {
  set: Object.setPrototypeOf || ('__proto__' in {} ? // eslint-disable-line
    function(test, buggy, set){
      try {
        set = _dereq_(18)(Function.call, getDesc(Object.prototype, '__proto__').set, 2);
        set(test, []);
        buggy = !(test instanceof Array);
      } catch(e){ buggy = true; }
      return function setPrototypeOf(O, proto){
        check(O, proto);
        if(buggy)O.__proto__ = proto;
        else set(O, proto);
        return O;
      };
    }({}, false) : undefined),
  check: check
};
},{"18":18,"39":39,"47":47,"5":5}],66:[function(_dereq_,module,exports){
'use strict';
var global      = _dereq_(30)
  , $           = _dereq_(47)
  , DESCRIPTORS = _dereq_(20)
  , SPECIES     = _dereq_(84)('species');

module.exports = function(KEY){
  var C = global[KEY];
  if(DESCRIPTORS && C && !C[SPECIES])$.setDesc(C, SPECIES, {
    configurable: true,
    get: function(){ return this; }
  });
};
},{"20":20,"30":30,"47":47,"84":84}],67:[function(_dereq_,module,exports){
var def = _dereq_(47).setDesc
  , has = _dereq_(31)
  , TAG = _dereq_(84)('toStringTag');

module.exports = function(it, tag, stat){
  if(it && !has(it = stat ? it : it.prototype, TAG))def(it, TAG, {configurable: true, value: tag});
};
},{"31":31,"47":47,"84":84}],68:[function(_dereq_,module,exports){
var global = _dereq_(30)
  , SHARED = '__core-js_shared__'
  , store  = global[SHARED] || (global[SHARED] = {});
module.exports = function(key){
  return store[key] || (store[key] = {});
};
},{"30":30}],69:[function(_dereq_,module,exports){
// 7.3.20 SpeciesConstructor(O, defaultConstructor)
var anObject  = _dereq_(5)
  , aFunction = _dereq_(3)
  , SPECIES   = _dereq_(84)('species');
module.exports = function(O, D){
  var C = anObject(O).constructor, S;
  return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);
};
},{"3":3,"5":5,"84":84}],70:[function(_dereq_,module,exports){
module.exports = function(it, Constructor, name){
  if(!(it instanceof Constructor))throw TypeError(name + ": use the 'new' operator!");
  return it;
};
},{}],71:[function(_dereq_,module,exports){
var toInteger = _dereq_(78)
  , defined   = _dereq_(19);
// true  -> String#at
// false -> String#codePointAt
module.exports = function(TO_STRING){
  return function(that, pos){
    var s = String(defined(that))
      , i = toInteger(pos)
      , l = s.length
      , a, b;
    if(i < 0 || i >= l)return TO_STRING ? '' : undefined;
    a = s.charCodeAt(i);
    return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff
      ? TO_STRING ? s.charAt(i) : a
      : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
  };
};
},{"19":19,"78":78}],72:[function(_dereq_,module,exports){
// helper for String#{startsWith, endsWith, includes}
var isRegExp = _dereq_(40)
  , defined  = _dereq_(19);

module.exports = function(that, searchString, NAME){
  if(isRegExp(searchString))throw TypeError('String#' + NAME + " doesn't accept regex!");
  return String(defined(that));
};
},{"19":19,"40":40}],73:[function(_dereq_,module,exports){
// https://github.com/ljharb/proposal-string-pad-left-right
var toLength = _dereq_(80)
  , repeat   = _dereq_(74)
  , defined  = _dereq_(19);

module.exports = function(that, maxLength, fillString, left){
  var S            = String(defined(that))
    , stringLength = S.length
    , fillStr      = fillString === undefined ? ' ' : String(fillString)
    , intMaxLength = toLength(maxLength);
  if(intMaxLength <= stringLength)return S;
  if(fillStr == '')fillStr = ' ';
  var fillLen = intMaxLength - stringLength
    , stringFiller = repeat.call(fillStr, Math.ceil(fillLen / fillStr.length));
  if(stringFiller.length > fillLen)stringFiller = stringFiller.slice(0, fillLen);
  return left ? stringFiller + S : S + stringFiller;
};
},{"19":19,"74":74,"80":80}],74:[function(_dereq_,module,exports){
'use strict';
var toInteger = _dereq_(78)
  , defined   = _dereq_(19);

module.exports = function repeat(count){
  var str = String(defined(this))
    , res = ''
    , n   = toInteger(count);
  if(n < 0 || n == Infinity)throw RangeError("Count can't be negative");
  for(;n > 0; (n >>>= 1) && (str += str))if(n & 1)res += str;
  return res;
};
},{"19":19,"78":78}],75:[function(_dereq_,module,exports){
var $export = _dereq_(23)
  , defined = _dereq_(19)
  , fails   = _dereq_(25)
  , spaces  = '\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003' +
      '\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF'
  , space   = '[' + spaces + ']'
  , non     = '\u200b\u0085'
  , ltrim   = RegExp('^' + space + space + '*')
  , rtrim   = RegExp(space + space + '*$');

var exporter = function(KEY, exec){
  var exp  = {};
  exp[KEY] = exec(trim);
  $export($export.P + $export.F * fails(function(){
    return !!spaces[KEY]() || non[KEY]() != non;
  }), 'String', exp);
};

// 1 -> String#trimLeft
// 2 -> String#trimRight
// 3 -> String#trim
var trim = exporter.trim = function(string, TYPE){
  string = String(defined(string));
  if(TYPE & 1)string = string.replace(ltrim, '');
  if(TYPE & 2)string = string.replace(rtrim, '');
  return string;
};

module.exports = exporter;
},{"19":19,"23":23,"25":25}],76:[function(_dereq_,module,exports){
var ctx                = _dereq_(18)
  , invoke             = _dereq_(34)
  , html               = _dereq_(33)
  , cel                = _dereq_(21)
  , global             = _dereq_(30)
  , process            = global.process
  , setTask            = global.setImmediate
  , clearTask          = global.clearImmediate
  , MessageChannel     = global.MessageChannel
  , counter            = 0
  , queue              = {}
  , ONREADYSTATECHANGE = 'onreadystatechange'
  , defer, channel, port;
var run = function(){
  var id = +this;
  if(queue.hasOwnProperty(id)){
    var fn = queue[id];
    delete queue[id];
    fn();
  }
};
var listner = function(event){
  run.call(event.data);
};
// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
if(!setTask || !clearTask){
  setTask = function setImmediate(fn){
    var args = [], i = 1;
    while(arguments.length > i)args.push(arguments[i++]);
    queue[++counter] = function(){
      invoke(typeof fn == 'function' ? fn : Function(fn), args);
    };
    defer(counter);
    return counter;
  };
  clearTask = function clearImmediate(id){
    delete queue[id];
  };
  // Node.js 0.8-
  if(_dereq_(12)(process) == 'process'){
    defer = function(id){
      process.nextTick(ctx(run, id, 1));
    };
  // Browsers with MessageChannel, includes WebWorkers
  } else if(MessageChannel){
    channel = new MessageChannel;
    port    = channel.port2;
    channel.port1.onmessage = listner;
    defer = ctx(port.postMessage, port, 1);
  // Browsers with postMessage, skip WebWorkers
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
  } else if(global.addEventListener && typeof postMessage == 'function' && !global.importScripts){
    defer = function(id){
      global.postMessage(id + '', '*');
    };
    global.addEventListener('message', listner, false);
  // IE8-
  } else if(ONREADYSTATECHANGE in cel('script')){
    defer = function(id){
      html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function(){
        html.removeChild(this);
        run.call(id);
      };
    };
  // Rest old browsers
  } else {
    defer = function(id){
      setTimeout(ctx(run, id, 1), 0);
    };
  }
}
module.exports = {
  set:   setTask,
  clear: clearTask
};
},{"12":12,"18":18,"21":21,"30":30,"33":33,"34":34}],77:[function(_dereq_,module,exports){
var toInteger = _dereq_(78)
  , max       = Math.max
  , min       = Math.min;
module.exports = function(index, length){
  index = toInteger(index);
  return index < 0 ? max(index + length, 0) : min(index, length);
};
},{"78":78}],78:[function(_dereq_,module,exports){
// 7.1.4 ToInteger
var ceil  = Math.ceil
  , floor = Math.floor;
module.exports = function(it){
  return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
};
},{}],79:[function(_dereq_,module,exports){
// to indexed object, toObject with fallback for non-array-like ES3 strings
var IObject = _dereq_(35)
  , defined = _dereq_(19);
module.exports = function(it){
  return IObject(defined(it));
};
},{"19":19,"35":35}],80:[function(_dereq_,module,exports){
// 7.1.15 ToLength
var toInteger = _dereq_(78)
  , min       = Math.min;
module.exports = function(it){
  return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0; // pow(2, 53) - 1 == 9007199254740991
};
},{"78":78}],81:[function(_dereq_,module,exports){
// 7.1.13 ToObject(argument)
var defined = _dereq_(19);
module.exports = function(it){
  return Object(defined(it));
};
},{"19":19}],82:[function(_dereq_,module,exports){
// 7.1.1 ToPrimitive(input [, PreferredType])
var isObject = _dereq_(39);
// instead of the ES6 spec version, we didn't implement @@toPrimitive case
// and the second argument - flag - preferred type is a string
module.exports = function(it, S){
  if(!isObject(it))return it;
  var fn, val;
  if(S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val;
  if(typeof (fn = it.valueOf) == 'function' && !isObject(val = fn.call(it)))return val;
  if(!S && typeof (fn = it.toString) == 'function' && !isObject(val = fn.call(it)))return val;
  throw TypeError("Can't convert object to primitive value");
};
},{"39":39}],83:[function(_dereq_,module,exports){
var id = 0
  , px = Math.random();
module.exports = function(key){
  return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
};
},{}],84:[function(_dereq_,module,exports){
var store  = _dereq_(68)('wks')
  , uid    = _dereq_(83)
  , Symbol = _dereq_(30).Symbol;
module.exports = function(name){
  return store[name] || (store[name] =
    Symbol && Symbol[name] || (Symbol || uid)('Symbol.' + name));
};
},{"30":30,"68":68,"83":83}],85:[function(_dereq_,module,exports){
var classof   = _dereq_(11)
  , ITERATOR  = _dereq_(84)('iterator')
  , Iterators = _dereq_(46);
module.exports = _dereq_(17).getIteratorMethod = function(it){
  if(it != undefined)return it[ITERATOR]
    || it['@@iterator']
    || Iterators[classof(it)];
};
},{"11":11,"17":17,"46":46,"84":84}],86:[function(_dereq_,module,exports){
'use strict';
var $                 = _dereq_(47)
  , $export           = _dereq_(23)
  , DESCRIPTORS       = _dereq_(20)
  , createDesc        = _dereq_(60)
  , html              = _dereq_(33)
  , cel               = _dereq_(21)
  , has               = _dereq_(31)
  , cof               = _dereq_(12)
  , invoke            = _dereq_(34)
  , fails             = _dereq_(25)
  , anObject          = _dereq_(5)
  , aFunction         = _dereq_(3)
  , isObject          = _dereq_(39)
  , toObject          = _dereq_(81)
  , toIObject         = _dereq_(79)
  , toInteger         = _dereq_(78)
  , toIndex           = _dereq_(77)
  , toLength          = _dereq_(80)
  , IObject           = _dereq_(35)
  , IE_PROTO          = _dereq_(83)('__proto__')
  , createArrayMethod = _dereq_(9)
  , arrayIndexOf      = _dereq_(8)(false)
  , ObjectProto       = Object.prototype
  , ArrayProto        = Array.prototype
  , arraySlice        = ArrayProto.slice
  , arrayJoin         = ArrayProto.join
  , defineProperty    = $.setDesc
  , getOwnDescriptor  = $.getDesc
  , defineProperties  = $.setDescs
  , factories         = {}
  , IE8_DOM_DEFINE;

if(!DESCRIPTORS){
  IE8_DOM_DEFINE = !fails(function(){
    return defineProperty(cel('div'), 'a', {get: function(){ return 7; }}).a != 7;
  });
  $.setDesc = function(O, P, Attributes){
    if(IE8_DOM_DEFINE)try {
      return defineProperty(O, P, Attributes);
    } catch(e){ /* empty */ }
    if('get' in Attributes || 'set' in Attributes)throw TypeError('Accessors not supported!');
    if('value' in Attributes)anObject(O)[P] = Attributes.value;
    return O;
  };
  $.getDesc = function(O, P){
    if(IE8_DOM_DEFINE)try {
      return getOwnDescriptor(O, P);
    } catch(e){ /* empty */ }
    if(has(O, P))return createDesc(!ObjectProto.propertyIsEnumerable.call(O, P), O[P]);
  };
  $.setDescs = defineProperties = function(O, Properties){
    anObject(O);
    var keys   = $.getKeys(Properties)
      , length = keys.length
      , i = 0
      , P;
    while(length > i)$.setDesc(O, P = keys[i++], Properties[P]);
    return O;
  };
}
$export($export.S + $export.F * !DESCRIPTORS, 'Object', {
  // 19.1.2.6 / 15.2.3.3 Object.getOwnPropertyDescriptor(O, P)
  getOwnPropertyDescriptor: $.getDesc,
  // 19.1.2.4 / 15.2.3.6 Object.defineProperty(O, P, Attributes)
  defineProperty: $.setDesc,
  // 19.1.2.3 / 15.2.3.7 Object.defineProperties(O, Properties)
  defineProperties: defineProperties
});

  // IE 8- don't enum bug keys
var keys1 = ('constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,' +
            'toLocaleString,toString,valueOf').split(',')
  // Additional keys for getOwnPropertyNames
  , keys2 = keys1.concat('length', 'prototype')
  , keysLen1 = keys1.length;

// Create object with `null` prototype: use iframe Object with cleared prototype
var createDict = function(){
  // Thrash, waste and sodomy: IE GC bug
  var iframe = cel('iframe')
    , i      = keysLen1
    , gt     = '>'
    , iframeDocument;
  iframe.style.display = 'none';
  html.appendChild(iframe);
  iframe.src = 'javascript:'; // eslint-disable-line no-script-url
  // createDict = iframe.contentWindow.Object;
  // html.removeChild(iframe);
  iframeDocument = iframe.contentWindow.document;
  iframeDocument.open();
  iframeDocument.write('<script>document.F=Object</script' + gt);
  iframeDocument.close();
  createDict = iframeDocument.F;
  while(i--)delete createDict.prototype[keys1[i]];
  return createDict();
};
var createGetKeys = function(names, length){
  return function(object){
    var O      = toIObject(object)
      , i      = 0
      , result = []
      , key;
    for(key in O)if(key != IE_PROTO)has(O, key) && result.push(key);
    // Don't enum bug & hidden keys
    while(length > i)if(has(O, key = names[i++])){
      ~arrayIndexOf(result, key) || result.push(key);
    }
    return result;
  };
};
var Empty = function(){};
$export($export.S, 'Object', {
  // 19.1.2.9 / 15.2.3.2 Object.getPrototypeOf(O)
  getPrototypeOf: $.getProto = $.getProto || function(O){
    O = toObject(O);
    if(has(O, IE_PROTO))return O[IE_PROTO];
    if(typeof O.constructor == 'function' && O instanceof O.constructor){
      return O.constructor.prototype;
    } return O instanceof Object ? ObjectProto : null;
  },
  // 19.1.2.7 / 15.2.3.4 Object.getOwnPropertyNames(O)
  getOwnPropertyNames: $.getNames = $.getNames || createGetKeys(keys2, keys2.length, true),
  // 19.1.2.2 / 15.2.3.5 Object.create(O [, Properties])
  create: $.create = $.create || function(O, /*?*/Properties){
    var result;
    if(O !== null){
      Empty.prototype = anObject(O);
      result = new Empty();
      Empty.prototype = null;
      // add "__proto__" for Object.getPrototypeOf shim
      result[IE_PROTO] = O;
    } else result = createDict();
    return Properties === undefined ? result : defineProperties(result, Properties);
  },
  // 19.1.2.14 / 15.2.3.14 Object.keys(O)
  keys: $.getKeys = $.getKeys || createGetKeys(keys1, keysLen1, false)
});

var construct = function(F, len, args){
  if(!(len in factories)){
    for(var n = [], i = 0; i < len; i++)n[i] = 'a[' + i + ']';
    factories[len] = Function('F,a', 'return new F(' + n.join(',') + ')');
  }
  return factories[len](F, args);
};

// 19.2.3.2 / 15.3.4.5 Function.prototype.bind(thisArg, args...)
$export($export.P, 'Function', {
  bind: function bind(that /*, args... */){
    var fn       = aFunction(this)
      , partArgs = arraySlice.call(arguments, 1);
    var bound = function(/* args... */){
      var args = partArgs.concat(arraySlice.call(arguments));
      return this instanceof bound ? construct(fn, args.length, args) : invoke(fn, args, that);
    };
    if(isObject(fn.prototype))bound.prototype = fn.prototype;
    return bound;
  }
});

// fallback for not array-like ES3 strings and DOM objects
$export($export.P + $export.F * fails(function(){
  if(html)arraySlice.call(html);
}), 'Array', {
  slice: function(begin, end){
    var len   = toLength(this.length)
      , klass = cof(this);
    end = end === undefined ? len : end;
    if(klass == 'Array')return arraySlice.call(this, begin, end);
    var start  = toIndex(begin, len)
      , upTo   = toIndex(end, len)
      , size   = toLength(upTo - start)
      , cloned = Array(size)
      , i      = 0;
    for(; i < size; i++)cloned[i] = klass == 'String'
      ? this.charAt(start + i)
      : this[start + i];
    return cloned;
  }
});
$export($export.P + $export.F * (IObject != Object), 'Array', {
  join: function join(separator){
    return arrayJoin.call(IObject(this), separator === undefined ? ',' : separator);
  }
});

// 22.1.2.2 / 15.4.3.2 Array.isArray(arg)
$export($export.S, 'Array', {isArray: _dereq_(37)});

var createArrayReduce = function(isRight){
  return function(callbackfn, memo){
    aFunction(callbackfn);
    var O      = IObject(this)
      , length = toLength(O.length)
      , index  = isRight ? length - 1 : 0
      , i      = isRight ? -1 : 1;
    if(arguments.length < 2)for(;;){
      if(index in O){
        memo = O[index];
        index += i;
        break;
      }
      index += i;
      if(isRight ? index < 0 : length <= index){
        throw TypeError('Reduce of empty array with no initial value');
      }
    }
    for(;isRight ? index >= 0 : length > index; index += i)if(index in O){
      memo = callbackfn(memo, O[index], index, this);
    }
    return memo;
  };
};

var methodize = function($fn){
  return function(arg1/*, arg2 = undefined */){
    return $fn(this, arg1, arguments[1]);
  };
};

$export($export.P, 'Array', {
  // 22.1.3.10 / 15.4.4.18 Array.prototype.forEach(callbackfn [, thisArg])
  forEach: $.each = $.each || methodize(createArrayMethod(0)),
  // 22.1.3.15 / 15.4.4.19 Array.prototype.map(callbackfn [, thisArg])
  map: methodize(createArrayMethod(1)),
  // 22.1.3.7 / 15.4.4.20 Array.prototype.filter(callbackfn [, thisArg])
  filter: methodize(createArrayMethod(2)),
  // 22.1.3.23 / 15.4.4.17 Array.prototype.some(callbackfn [, thisArg])
  some: methodize(createArrayMethod(3)),
  // 22.1.3.5 / 15.4.4.16 Array.prototype.every(callbackfn [, thisArg])
  every: methodize(createArrayMethod(4)),
  // 22.1.3.18 / 15.4.4.21 Array.prototype.reduce(callbackfn [, initialValue])
  reduce: createArrayReduce(false),
  // 22.1.3.19 / 15.4.4.22 Array.prototype.reduceRight(callbackfn [, initialValue])
  reduceRight: createArrayReduce(true),
  // 22.1.3.11 / 15.4.4.14 Array.prototype.indexOf(searchElement [, fromIndex])
  indexOf: methodize(arrayIndexOf),
  // 22.1.3.14 / 15.4.4.15 Array.prototype.lastIndexOf(searchElement [, fromIndex])
  lastIndexOf: function(el, fromIndex /* = @[*-1] */){
    var O      = toIObject(this)
      , length = toLength(O.length)
      , index  = length - 1;
    if(arguments.length > 1)index = Math.min(index, toInteger(fromIndex));
    if(index < 0)index = toLength(length + index);
    for(;index >= 0; index--)if(index in O)if(O[index] === el)return index;
    return -1;
  }
});

// 20.3.3.1 / 15.9.4.4 Date.now()
$export($export.S, 'Date', {now: function(){ return +new Date; }});

var lz = function(num){
  return num > 9 ? num : '0' + num;
};

// 20.3.4.36 / 15.9.5.43 Date.prototype.toISOString()
// PhantomJS / old WebKit has a broken implementations
$export($export.P + $export.F * (fails(function(){
  return new Date(-5e13 - 1).toISOString() != '0385-07-25T07:06:39.999Z';
}) || !fails(function(){
  new Date(NaN).toISOString();
})), 'Date', {
  toISOString: function toISOString(){
    if(!isFinite(this))throw RangeError('Invalid time value');
    var d = this
      , y = d.getUTCFullYear()
      , m = d.getUTCMilliseconds()
      , s = y < 0 ? '-' : y > 9999 ? '+' : '';
    return s + ('00000' + Math.abs(y)).slice(s ? -6 : -4) +
      '-' + lz(d.getUTCMonth() + 1) + '-' + lz(d.getUTCDate()) +
      'T' + lz(d.getUTCHours()) + ':' + lz(d.getUTCMinutes()) +
      ':' + lz(d.getUTCSeconds()) + '.' + (m > 99 ? m : '0' + lz(m)) + 'Z';
  }
});
},{"12":12,"20":20,"21":21,"23":23,"25":25,"3":3,"31":31,"33":33,"34":34,"35":35,"37":37,"39":39,"47":47,"5":5,"60":60,"77":77,"78":78,"79":79,"8":8,"80":80,"81":81,"83":83,"9":9}],87:[function(_dereq_,module,exports){
// 22.1.3.3 Array.prototype.copyWithin(target, start, end = this.length)
var $export = _dereq_(23);

$export($export.P, 'Array', {copyWithin: _dereq_(6)});

_dereq_(4)('copyWithin');
},{"23":23,"4":4,"6":6}],88:[function(_dereq_,module,exports){
// 22.1.3.6 Array.prototype.fill(value, start = 0, end = this.length)
var $export = _dereq_(23);

$export($export.P, 'Array', {fill: _dereq_(7)});

_dereq_(4)('fill');
},{"23":23,"4":4,"7":7}],89:[function(_dereq_,module,exports){
'use strict';
// 22.1.3.9 Array.prototype.findIndex(predicate, thisArg = undefined)
var $export = _dereq_(23)
  , $find   = _dereq_(9)(6)
  , KEY     = 'findIndex'
  , forced  = true;
// Shouldn't skip holes
if(KEY in [])Array(1)[KEY](function(){ forced = false; });
$export($export.P + $export.F * forced, 'Array', {
  findIndex: function findIndex(callbackfn/*, that = undefined */){
    return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
  }
});
_dereq_(4)(KEY);
},{"23":23,"4":4,"9":9}],90:[function(_dereq_,module,exports){
'use strict';
// 22.1.3.8 Array.prototype.find(predicate, thisArg = undefined)
var $export = _dereq_(23)
  , $find   = _dereq_(9)(5)
  , KEY     = 'find'
  , forced  = true;
// Shouldn't skip holes
if(KEY in [])Array(1)[KEY](function(){ forced = false; });
$export($export.P + $export.F * forced, 'Array', {
  find: function find(callbackfn/*, that = undefined */){
    return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
  }
});
_dereq_(4)(KEY);
},{"23":23,"4":4,"9":9}],91:[function(_dereq_,module,exports){
'use strict';
var ctx         = _dereq_(18)
  , $export     = _dereq_(23)
  , toObject    = _dereq_(81)
  , call        = _dereq_(41)
  , isArrayIter = _dereq_(36)
  , toLength    = _dereq_(80)
  , getIterFn   = _dereq_(85);
$export($export.S + $export.F * !_dereq_(44)(function(iter){ Array.from(iter); }), 'Array', {
  // 22.1.2.1 Array.from(arrayLike, mapfn = undefined, thisArg = undefined)
  from: function from(arrayLike/*, mapfn = undefined, thisArg = undefined*/){
    var O       = toObject(arrayLike)
      , C       = typeof this == 'function' ? this : Array
      , $$      = arguments
      , $$len   = $$.length
      , mapfn   = $$len > 1 ? $$[1] : undefined
      , mapping = mapfn !== undefined
      , index   = 0
      , iterFn  = getIterFn(O)
      , length, result, step, iterator;
    if(mapping)mapfn = ctx(mapfn, $$len > 2 ? $$[2] : undefined, 2);
    // if object isn't iterable or it's array with default iterator - use simple case
    if(iterFn != undefined && !(C == Array && isArrayIter(iterFn))){
      for(iterator = iterFn.call(O), result = new C; !(step = iterator.next()).done; index++){
        result[index] = mapping ? call(iterator, mapfn, [step.value, index], true) : step.value;
      }
    } else {
      length = toLength(O.length);
      for(result = new C(length); length > index; index++){
        result[index] = mapping ? mapfn(O[index], index) : O[index];
      }
    }
    result.length = index;
    return result;
  }
});

},{"18":18,"23":23,"36":36,"41":41,"44":44,"80":80,"81":81,"85":85}],92:[function(_dereq_,module,exports){
'use strict';
var addToUnscopables = _dereq_(4)
  , step             = _dereq_(45)
  , Iterators        = _dereq_(46)
  , toIObject        = _dereq_(79);

// 22.1.3.4 Array.prototype.entries()
// 22.1.3.13 Array.prototype.keys()
// 22.1.3.29 Array.prototype.values()
// 22.1.3.30 Array.prototype[@@iterator]()
module.exports = _dereq_(43)(Array, 'Array', function(iterated, kind){
  this._t = toIObject(iterated); // target
  this._i = 0;                   // next index
  this._k = kind;                // kind
// 22.1.5.2.1 %ArrayIteratorPrototype%.next()
}, function(){
  var O     = this._t
    , kind  = this._k
    , index = this._i++;
  if(!O || index >= O.length){
    this._t = undefined;
    return step(1);
  }
  if(kind == 'keys'  )return step(0, index);
  if(kind == 'values')return step(0, O[index]);
  return step(0, [index, O[index]]);
}, 'values');

// argumentsList[@@iterator] is %ArrayProto_values% (9.4.4.6, 9.4.4.7)
Iterators.Arguments = Iterators.Array;

addToUnscopables('keys');
addToUnscopables('values');
addToUnscopables('entries');
},{"4":4,"43":43,"45":45,"46":46,"79":79}],93:[function(_dereq_,module,exports){
'use strict';
var $export = _dereq_(23);

// WebKit Array.of isn't generic
$export($export.S + $export.F * _dereq_(25)(function(){
  function F(){}
  return !(Array.of.call(F) instanceof F);
}), 'Array', {
  // 22.1.2.3 Array.of( ...items)
  of: function of(/* ...args */){
    var index  = 0
      , $$     = arguments
      , $$len  = $$.length
      , result = new (typeof this == 'function' ? this : Array)($$len);
    while($$len > index)result[index] = $$[index++];
    result.length = $$len;
    return result;
  }
});
},{"23":23,"25":25}],94:[function(_dereq_,module,exports){
_dereq_(66)('Array');
},{"66":66}],95:[function(_dereq_,module,exports){
'use strict';
var $             = _dereq_(47)
  , isObject      = _dereq_(39)
  , HAS_INSTANCE  = _dereq_(84)('hasInstance')
  , FunctionProto = Function.prototype;
// 19.2.3.6 Function.prototype[@@hasInstance](V)
if(!(HAS_INSTANCE in FunctionProto))$.setDesc(FunctionProto, HAS_INSTANCE, {value: function(O){
  if(typeof this != 'function' || !isObject(O))return false;
  if(!isObject(this.prototype))return O instanceof this;
  // for environment w/o native `@@hasInstance` logic enough `instanceof`, but add this:
  while(O = $.getProto(O))if(this.prototype === O)return true;
  return false;
}});
},{"39":39,"47":47,"84":84}],96:[function(_dereq_,module,exports){
var setDesc    = _dereq_(47).setDesc
  , createDesc = _dereq_(60)
  , has        = _dereq_(31)
  , FProto     = Function.prototype
  , nameRE     = /^\s*function ([^ (]*)/
  , NAME       = 'name';
// 19.2.4.2 name
NAME in FProto || _dereq_(20) && setDesc(FProto, NAME, {
  configurable: true,
  get: function(){
    var match = ('' + this).match(nameRE)
      , name  = match ? match[1] : '';
    has(this, NAME) || setDesc(this, NAME, createDesc(5, name));
    return name;
  }
});
},{"20":20,"31":31,"47":47,"60":60}],97:[function(_dereq_,module,exports){
'use strict';
var strong = _dereq_(13);

// 23.1 Map Objects
_dereq_(16)('Map', function(get){
  return function Map(){ return get(this, arguments.length > 0 ? arguments[0] : undefined); };
}, {
  // 23.1.3.6 Map.prototype.get(key)
  get: function get(key){
    var entry = strong.getEntry(this, key);
    return entry && entry.v;
  },
  // 23.1.3.9 Map.prototype.set(key, value)
  set: function set(key, value){
    return strong.def(this, key === 0 ? 0 : key, value);
  }
}, strong, true);
},{"13":13,"16":16}],98:[function(_dereq_,module,exports){
// 20.2.2.3 Math.acosh(x)
var $export = _dereq_(23)
  , log1p   = _dereq_(51)
  , sqrt    = Math.sqrt
  , $acosh  = Math.acosh;

// V8 bug https://code.google.com/p/v8/issues/detail?id=3509
$export($export.S + $export.F * !($acosh && Math.floor($acosh(Number.MAX_VALUE)) == 710), 'Math', {
  acosh: function acosh(x){
    return (x = +x) < 1 ? NaN : x > 94906265.62425156
      ? Math.log(x) + Math.LN2
      : log1p(x - 1 + sqrt(x - 1) * sqrt(x + 1));
  }
});
},{"23":23,"51":51}],99:[function(_dereq_,module,exports){
// 20.2.2.5 Math.asinh(x)
var $export = _dereq_(23);

function asinh(x){
  return !isFinite(x = +x) || x == 0 ? x : x < 0 ? -asinh(-x) : Math.log(x + Math.sqrt(x * x + 1));
}

$export($export.S, 'Math', {asinh: asinh});
},{"23":23}],100:[function(_dereq_,module,exports){
// 20.2.2.7 Math.atanh(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {
  atanh: function atanh(x){
    return (x = +x) == 0 ? x : Math.log((1 + x) / (1 - x)) / 2;
  }
});
},{"23":23}],101:[function(_dereq_,module,exports){
// 20.2.2.9 Math.cbrt(x)
var $export = _dereq_(23)
  , sign    = _dereq_(52);

$export($export.S, 'Math', {
  cbrt: function cbrt(x){
    return sign(x = +x) * Math.pow(Math.abs(x), 1 / 3);
  }
});
},{"23":23,"52":52}],102:[function(_dereq_,module,exports){
// 20.2.2.11 Math.clz32(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {
  clz32: function clz32(x){
    return (x >>>= 0) ? 31 - Math.floor(Math.log(x + 0.5) * Math.LOG2E) : 32;
  }
});
},{"23":23}],103:[function(_dereq_,module,exports){
// 20.2.2.12 Math.cosh(x)
var $export = _dereq_(23)
  , exp     = Math.exp;

$export($export.S, 'Math', {
  cosh: function cosh(x){
    return (exp(x = +x) + exp(-x)) / 2;
  }
});
},{"23":23}],104:[function(_dereq_,module,exports){
// 20.2.2.14 Math.expm1(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {expm1: _dereq_(50)});
},{"23":23,"50":50}],105:[function(_dereq_,module,exports){
// 20.2.2.16 Math.fround(x)
var $export   = _dereq_(23)
  , sign      = _dereq_(52)
  , pow       = Math.pow
  , EPSILON   = pow(2, -52)
  , EPSILON32 = pow(2, -23)
  , MAX32     = pow(2, 127) * (2 - EPSILON32)
  , MIN32     = pow(2, -126);

var roundTiesToEven = function(n){
  return n + 1 / EPSILON - 1 / EPSILON;
};


$export($export.S, 'Math', {
  fround: function fround(x){
    var $abs  = Math.abs(x)
      , $sign = sign(x)
      , a, result;
    if($abs < MIN32)return $sign * roundTiesToEven($abs / MIN32 / EPSILON32) * MIN32 * EPSILON32;
    a = (1 + EPSILON32 / EPSILON) * $abs;
    result = a - (a - $abs);
    if(result > MAX32 || result != result)return $sign * Infinity;
    return $sign * result;
  }
});
},{"23":23,"52":52}],106:[function(_dereq_,module,exports){
// 20.2.2.17 Math.hypot([value1[, value2[, … ]]])
var $export = _dereq_(23)
  , abs     = Math.abs;

$export($export.S, 'Math', {
  hypot: function hypot(value1, value2){ // eslint-disable-line no-unused-vars
    var sum   = 0
      , i     = 0
      , $$    = arguments
      , $$len = $$.length
      , larg  = 0
      , arg, div;
    while(i < $$len){
      arg = abs($$[i++]);
      if(larg < arg){
        div  = larg / arg;
        sum  = sum * div * div + 1;
        larg = arg;
      } else if(arg > 0){
        div  = arg / larg;
        sum += div * div;
      } else sum += arg;
    }
    return larg === Infinity ? Infinity : larg * Math.sqrt(sum);
  }
});
},{"23":23}],107:[function(_dereq_,module,exports){
// 20.2.2.18 Math.imul(x, y)
var $export = _dereq_(23)
  , $imul   = Math.imul;

// some WebKit versions fails with big numbers, some has wrong arity
$export($export.S + $export.F * _dereq_(25)(function(){
  return $imul(0xffffffff, 5) != -5 || $imul.length != 2;
}), 'Math', {
  imul: function imul(x, y){
    var UINT16 = 0xffff
      , xn = +x
      , yn = +y
      , xl = UINT16 & xn
      , yl = UINT16 & yn;
    return 0 | xl * yl + ((UINT16 & xn >>> 16) * yl + xl * (UINT16 & yn >>> 16) << 16 >>> 0);
  }
});
},{"23":23,"25":25}],108:[function(_dereq_,module,exports){
// 20.2.2.21 Math.log10(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {
  log10: function log10(x){
    return Math.log(x) / Math.LN10;
  }
});
},{"23":23}],109:[function(_dereq_,module,exports){
// 20.2.2.20 Math.log1p(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {log1p: _dereq_(51)});
},{"23":23,"51":51}],110:[function(_dereq_,module,exports){
// 20.2.2.22 Math.log2(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {
  log2: function log2(x){
    return Math.log(x) / Math.LN2;
  }
});
},{"23":23}],111:[function(_dereq_,module,exports){
// 20.2.2.28 Math.sign(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {sign: _dereq_(52)});
},{"23":23,"52":52}],112:[function(_dereq_,module,exports){
// 20.2.2.30 Math.sinh(x)
var $export = _dereq_(23)
  , expm1   = _dereq_(50)
  , exp     = Math.exp;

// V8 near Chromium 38 has a problem with very small numbers
$export($export.S + $export.F * _dereq_(25)(function(){
  return !Math.sinh(-2e-17) != -2e-17;
}), 'Math', {
  sinh: function sinh(x){
    return Math.abs(x = +x) < 1
      ? (expm1(x) - expm1(-x)) / 2
      : (exp(x - 1) - exp(-x - 1)) * (Math.E / 2);
  }
});
},{"23":23,"25":25,"50":50}],113:[function(_dereq_,module,exports){
// 20.2.2.33 Math.tanh(x)
var $export = _dereq_(23)
  , expm1   = _dereq_(50)
  , exp     = Math.exp;

$export($export.S, 'Math', {
  tanh: function tanh(x){
    var a = expm1(x = +x)
      , b = expm1(-x);
    return a == Infinity ? 1 : b == Infinity ? -1 : (a - b) / (exp(x) + exp(-x));
  }
});
},{"23":23,"50":50}],114:[function(_dereq_,module,exports){
// 20.2.2.34 Math.trunc(x)
var $export = _dereq_(23);

$export($export.S, 'Math', {
  trunc: function trunc(it){
    return (it > 0 ? Math.floor : Math.ceil)(it);
  }
});
},{"23":23}],115:[function(_dereq_,module,exports){
'use strict';
var $           = _dereq_(47)
  , global      = _dereq_(30)
  , has         = _dereq_(31)
  , cof         = _dereq_(12)
  , toPrimitive = _dereq_(82)
  , fails       = _dereq_(25)
  , $trim       = _dereq_(75).trim
  , NUMBER      = 'Number'
  , $Number     = global[NUMBER]
  , Base        = $Number
  , proto       = $Number.prototype
  // Opera ~12 has broken Object#toString
  , BROKEN_COF  = cof($.create(proto)) == NUMBER
  , TRIM        = 'trim' in String.prototype;

// 7.1.3 ToNumber(argument)
var toNumber = function(argument){
  var it = toPrimitive(argument, false);
  if(typeof it == 'string' && it.length > 2){
    it = TRIM ? it.trim() : $trim(it, 3);
    var first = it.charCodeAt(0)
      , third, radix, maxCode;
    if(first === 43 || first === 45){
      third = it.charCodeAt(2);
      if(third === 88 || third === 120)return NaN; // Number('+0x1') should be NaN, old V8 fix
    } else if(first === 48){
      switch(it.charCodeAt(1)){
        case 66 : case 98  : radix = 2; maxCode = 49; break; // fast equal /^0b[01]+$/i
        case 79 : case 111 : radix = 8; maxCode = 55; break; // fast equal /^0o[0-7]+$/i
        default : return +it;
      }
      for(var digits = it.slice(2), i = 0, l = digits.length, code; i < l; i++){
        code = digits.charCodeAt(i);
        // parseInt parses a string to a first unavailable symbol
        // but ToNumber should return NaN if a string contains unavailable symbols
        if(code < 48 || code > maxCode)return NaN;
      } return parseInt(digits, radix);
    }
  } return +it;
};

if(!$Number(' 0o1') || !$Number('0b1') || $Number('+0x1')){
  $Number = function Number(value){
    var it = arguments.length < 1 ? 0 : value
      , that = this;
    return that instanceof $Number
      // check on 1..constructor(foo) case
      && (BROKEN_COF ? fails(function(){ proto.valueOf.call(that); }) : cof(that) != NUMBER)
        ? new Base(toNumber(it)) : toNumber(it);
  };
  $.each.call(_dereq_(20) ? $.getNames(Base) : (
    // ES3:
    'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +
    // ES6 (in case, if modules with ES6 Number statics required before):
    'EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,' +
    'MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger'
  ).split(','), function(key){
    if(has(Base, key) && !has($Number, key)){
      $.setDesc($Number, key, $.getDesc(Base, key));
    }
  });
  $Number.prototype = proto;
  proto.constructor = $Number;
  _dereq_(62)(global, NUMBER, $Number);
}
},{"12":12,"20":20,"25":25,"30":30,"31":31,"47":47,"62":62,"75":75,"82":82}],116:[function(_dereq_,module,exports){
// 20.1.2.1 Number.EPSILON
var $export = _dereq_(23);

$export($export.S, 'Number', {EPSILON: Math.pow(2, -52)});
},{"23":23}],117:[function(_dereq_,module,exports){
// 20.1.2.2 Number.isFinite(number)
var $export   = _dereq_(23)
  , _isFinite = _dereq_(30).isFinite;

$export($export.S, 'Number', {
  isFinite: function isFinite(it){
    return typeof it == 'number' && _isFinite(it);
  }
});
},{"23":23,"30":30}],118:[function(_dereq_,module,exports){
// 20.1.2.3 Number.isInteger(number)
var $export = _dereq_(23);

$export($export.S, 'Number', {isInteger: _dereq_(38)});
},{"23":23,"38":38}],119:[function(_dereq_,module,exports){
// 20.1.2.4 Number.isNaN(number)
var $export = _dereq_(23);

$export($export.S, 'Number', {
  isNaN: function isNaN(number){
    return number != number;
  }
});
},{"23":23}],120:[function(_dereq_,module,exports){
// 20.1.2.5 Number.isSafeInteger(number)
var $export   = _dereq_(23)
  , isInteger = _dereq_(38)
  , abs       = Math.abs;

$export($export.S, 'Number', {
  isSafeInteger: function isSafeInteger(number){
    return isInteger(number) && abs(number) <= 0x1fffffffffffff;
  }
});
},{"23":23,"38":38}],121:[function(_dereq_,module,exports){
// 20.1.2.6 Number.MAX_SAFE_INTEGER
var $export = _dereq_(23);

$export($export.S, 'Number', {MAX_SAFE_INTEGER: 0x1fffffffffffff});
},{"23":23}],122:[function(_dereq_,module,exports){
// 20.1.2.10 Number.MIN_SAFE_INTEGER
var $export = _dereq_(23);

$export($export.S, 'Number', {MIN_SAFE_INTEGER: -0x1fffffffffffff});
},{"23":23}],123:[function(_dereq_,module,exports){
// 20.1.2.12 Number.parseFloat(string)
var $export = _dereq_(23);

$export($export.S, 'Number', {parseFloat: parseFloat});
},{"23":23}],124:[function(_dereq_,module,exports){
// 20.1.2.13 Number.parseInt(string, radix)
var $export = _dereq_(23);

$export($export.S, 'Number', {parseInt: parseInt});
},{"23":23}],125:[function(_dereq_,module,exports){
// 19.1.3.1 Object.assign(target, source)
var $export = _dereq_(23);

$export($export.S + $export.F, 'Object', {assign: _dereq_(54)});
},{"23":23,"54":54}],126:[function(_dereq_,module,exports){
// 19.1.2.5 Object.freeze(O)
var isObject = _dereq_(39);

_dereq_(55)('freeze', function($freeze){
  return function freeze(it){
    return $freeze && isObject(it) ? $freeze(it) : it;
  };
});
},{"39":39,"55":55}],127:[function(_dereq_,module,exports){
// 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
var toIObject = _dereq_(79);

_dereq_(55)('getOwnPropertyDescriptor', function($getOwnPropertyDescriptor){
  return function getOwnPropertyDescriptor(it, key){
    return $getOwnPropertyDescriptor(toIObject(it), key);
  };
});
},{"55":55,"79":79}],128:[function(_dereq_,module,exports){
// 19.1.2.7 Object.getOwnPropertyNames(O)
_dereq_(55)('getOwnPropertyNames', function(){
  return _dereq_(29).get;
});
},{"29":29,"55":55}],129:[function(_dereq_,module,exports){
// 19.1.2.9 Object.getPrototypeOf(O)
var toObject = _dereq_(81);

_dereq_(55)('getPrototypeOf', function($getPrototypeOf){
  return function getPrototypeOf(it){
    return $getPrototypeOf(toObject(it));
  };
});
},{"55":55,"81":81}],130:[function(_dereq_,module,exports){
// 19.1.2.11 Object.isExtensible(O)
var isObject = _dereq_(39);

_dereq_(55)('isExtensible', function($isExtensible){
  return function isExtensible(it){
    return isObject(it) ? $isExtensible ? $isExtensible(it) : true : false;
  };
});
},{"39":39,"55":55}],131:[function(_dereq_,module,exports){
// 19.1.2.12 Object.isFrozen(O)
var isObject = _dereq_(39);

_dereq_(55)('isFrozen', function($isFrozen){
  return function isFrozen(it){
    return isObject(it) ? $isFrozen ? $isFrozen(it) : false : true;
  };
});
},{"39":39,"55":55}],132:[function(_dereq_,module,exports){
// 19.1.2.13 Object.isSealed(O)
var isObject = _dereq_(39);

_dereq_(55)('isSealed', function($isSealed){
  return function isSealed(it){
    return isObject(it) ? $isSealed ? $isSealed(it) : false : true;
  };
});
},{"39":39,"55":55}],133:[function(_dereq_,module,exports){
// 19.1.3.10 Object.is(value1, value2)
var $export = _dereq_(23);
$export($export.S, 'Object', {is: _dereq_(64)});
},{"23":23,"64":64}],134:[function(_dereq_,module,exports){
// 19.1.2.14 Object.keys(O)
var toObject = _dereq_(81);

_dereq_(55)('keys', function($keys){
  return function keys(it){
    return $keys(toObject(it));
  };
});
},{"55":55,"81":81}],135:[function(_dereq_,module,exports){
// 19.1.2.15 Object.preventExtensions(O)
var isObject = _dereq_(39);

_dereq_(55)('preventExtensions', function($preventExtensions){
  return function preventExtensions(it){
    return $preventExtensions && isObject(it) ? $preventExtensions(it) : it;
  };
});
},{"39":39,"55":55}],136:[function(_dereq_,module,exports){
// 19.1.2.17 Object.seal(O)
var isObject = _dereq_(39);

_dereq_(55)('seal', function($seal){
  return function seal(it){
    return $seal && isObject(it) ? $seal(it) : it;
  };
});
},{"39":39,"55":55}],137:[function(_dereq_,module,exports){
// 19.1.3.19 Object.setPrototypeOf(O, proto)
var $export = _dereq_(23);
$export($export.S, 'Object', {setPrototypeOf: _dereq_(65).set});
},{"23":23,"65":65}],138:[function(_dereq_,module,exports){
'use strict';
// 19.1.3.6 Object.prototype.toString()
var classof = _dereq_(11)
  , test    = {};
test[_dereq_(84)('toStringTag')] = 'z';
if(test + '' != '[object z]'){
  _dereq_(62)(Object.prototype, 'toString', function toString(){
    return '[object ' + classof(this) + ']';
  }, true);
}
},{"11":11,"62":62,"84":84}],139:[function(_dereq_,module,exports){
'use strict';
var $          = _dereq_(47)
  , LIBRARY    = _dereq_(49)
  , global     = _dereq_(30)
  , ctx        = _dereq_(18)
  , classof    = _dereq_(11)
  , $export    = _dereq_(23)
  , isObject   = _dereq_(39)
  , anObject   = _dereq_(5)
  , aFunction  = _dereq_(3)
  , strictNew  = _dereq_(70)
  , forOf      = _dereq_(28)
  , setProto   = _dereq_(65).set
  , same       = _dereq_(64)
  , SPECIES    = _dereq_(84)('species')
  , speciesConstructor = _dereq_(69)
  , asap       = _dereq_(53)
  , PROMISE    = 'Promise'
  , process    = global.process
  , isNode     = classof(process) == 'process'
  , P          = global[PROMISE]
  , Wrapper;

var testResolve = function(sub){
  var test = new P(function(){});
  if(sub)test.constructor = Object;
  return P.resolve(test) === test;
};

var USE_NATIVE = function(){
  var works = false;
  function P2(x){
    var self = new P(x);
    setProto(self, P2.prototype);
    return self;
  }
  try {
    works = P && P.resolve && testResolve();
    setProto(P2, P);
    P2.prototype = $.create(P.prototype, {constructor: {value: P2}});
    // actual Firefox has broken subclass support, test that
    if(!(P2.resolve(5).then(function(){}) instanceof P2)){
      works = false;
    }
    // actual V8 bug, https://code.google.com/p/v8/issues/detail?id=4162
    if(works && _dereq_(20)){
      var thenableThenGotten = false;
      P.resolve($.setDesc({}, 'then', {
        get: function(){ thenableThenGotten = true; }
      }));
      works = thenableThenGotten;
    }
  } catch(e){ works = false; }
  return works;
}();

// helpers
var sameConstructor = function(a, b){
  // library wrapper special case
  if(LIBRARY && a === P && b === Wrapper)return true;
  return same(a, b);
};
var getConstructor = function(C){
  var S = anObject(C)[SPECIES];
  return S != undefined ? S : C;
};
var isThenable = function(it){
  var then;
  return isObject(it) && typeof (then = it.then) == 'function' ? then : false;
};
var PromiseCapability = function(C){
  var resolve, reject;
  this.promise = new C(function($$resolve, $$reject){
    if(resolve !== undefined || reject !== undefined)throw TypeError('Bad Promise constructor');
    resolve = $$resolve;
    reject  = $$reject;
  });
  this.resolve = aFunction(resolve),
  this.reject  = aFunction(reject)
};
var perform = function(exec){
  try {
    exec();
  } catch(e){
    return {error: e};
  }
};
var notify = function(record, isReject){
  if(record.n)return;
  record.n = true;
  var chain = record.c;
  asap(function(){
    var value = record.v
      , ok    = record.s == 1
      , i     = 0;
    var run = function(reaction){
      var handler = ok ? reaction.ok : reaction.fail
        , resolve = reaction.resolve
        , reject  = reaction.reject
        , result, then;
      try {
        if(handler){
          if(!ok)record.h = true;
          result = handler === true ? value : handler(value);
          if(result === reaction.promise){
            reject(TypeError('Promise-chain cycle'));
          } else if(then = isThenable(result)){
            then.call(result, resolve, reject);
          } else resolve(result);
        } else reject(value);
      } catch(e){
        reject(e);
      }
    };
    while(chain.length > i)run(chain[i++]); // variable length - can't use forEach
    chain.length = 0;
    record.n = false;
    if(isReject)setTimeout(function(){
      var promise = record.p
        , handler, console;
      if(isUnhandled(promise)){
        if(isNode){
          process.emit('unhandledRejection', value, promise);
        } else if(handler = global.onunhandledrejection){
          handler({promise: promise, reason: value});
        } else if((console = global.console) && console.error){
          console.error('Unhandled promise rejection', value);
        }
      } record.a = undefined;
    }, 1);
  });
};
var isUnhandled = function(promise){
  var record = promise._d
    , chain  = record.a || record.c
    , i      = 0
    , reaction;
  if(record.h)return false;
  while(chain.length > i){
    reaction = chain[i++];
    if(reaction.fail || !isUnhandled(reaction.promise))return false;
  } return true;
};
var $reject = function(value){
  var record = this;
  if(record.d)return;
  record.d = true;
  record = record.r || record; // unwrap
  record.v = value;
  record.s = 2;
  record.a = record.c.slice();
  notify(record, true);
};
var $resolve = function(value){
  var record = this
    , then;
  if(record.d)return;
  record.d = true;
  record = record.r || record; // unwrap
  try {
    if(record.p === value)throw TypeError("Promise can't be resolved itself");
    if(then = isThenable(value)){
      asap(function(){
        var wrapper = {r: record, d: false}; // wrap
        try {
          then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));
        } catch(e){
          $reject.call(wrapper, e);
        }
      });
    } else {
      record.v = value;
      record.s = 1;
      notify(record, false);
    }
  } catch(e){
    $reject.call({r: record, d: false}, e); // wrap
  }
};

// constructor polyfill
if(!USE_NATIVE){
  // 25.4.3.1 Promise(executor)
  P = function Promise(executor){
    aFunction(executor);
    var record = this._d = {
      p: strictNew(this, P, PROMISE),         // <- promise
      c: [],                                  // <- awaiting reactions
      a: undefined,                           // <- checked in isUnhandled reactions
      s: 0,                                   // <- state
      d: false,                               // <- done
      v: undefined,                           // <- value
      h: false,                               // <- handled rejection
      n: false                                // <- notify
    };
    try {
      executor(ctx($resolve, record, 1), ctx($reject, record, 1));
    } catch(err){
      $reject.call(record, err);
    }
  };
  _dereq_(61)(P.prototype, {
    // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected)
    then: function then(onFulfilled, onRejected){
      var reaction = new PromiseCapability(speciesConstructor(this, P))
        , promise  = reaction.promise
        , record   = this._d;
      reaction.ok   = typeof onFulfilled == 'function' ? onFulfilled : true;
      reaction.fail = typeof onRejected == 'function' && onRejected;
      record.c.push(reaction);
      if(record.a)record.a.push(reaction);
      if(record.s)notify(record, false);
      return promise;
    },
    // 25.4.5.1 Promise.prototype.catch(onRejected)
    'catch': function(onRejected){
      return this.then(undefined, onRejected);
    }
  });
}

$export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: P});
_dereq_(67)(P, PROMISE);
_dereq_(66)(PROMISE);
Wrapper = _dereq_(17)[PROMISE];

// statics
$export($export.S + $export.F * !USE_NATIVE, PROMISE, {
  // 25.4.4.5 Promise.reject(r)
  reject: function reject(r){
    var capability = new PromiseCapability(this)
      , $$reject   = capability.reject;
    $$reject(r);
    return capability.promise;
  }
});
$export($export.S + $export.F * (!USE_NATIVE || testResolve(true)), PROMISE, {
  // 25.4.4.6 Promise.resolve(x)
  resolve: function resolve(x){
    // instanceof instead of internal slot check because we should fix it without replacement native Promise core
    if(x instanceof P && sameConstructor(x.constructor, this))return x;
    var capability = new PromiseCapability(this)
      , $$resolve  = capability.resolve;
    $$resolve(x);
    return capability.promise;
  }
});
$export($export.S + $export.F * !(USE_NATIVE && _dereq_(44)(function(iter){
  P.all(iter)['catch'](function(){});
})), PROMISE, {
  // 25.4.4.1 Promise.all(iterable)
  all: function all(iterable){
    var C          = getConstructor(this)
      , capability = new PromiseCapability(C)
      , resolve    = capability.resolve
      , reject     = capability.reject
      , values     = [];
    var abrupt = perform(function(){
      forOf(iterable, false, values.push, values);
      var remaining = values.length
        , results   = Array(remaining);
      if(remaining)$.each.call(values, function(promise, index){
        var alreadyCalled = false;
        C.resolve(promise).then(function(value){
          if(alreadyCalled)return;
          alreadyCalled = true;
          results[index] = value;
          --remaining || resolve(results);
        }, reject);
      });
      else resolve(results);
    });
    if(abrupt)reject(abrupt.error);
    return capability.promise;
  },
  // 25.4.4.4 Promise.race(iterable)
  race: function race(iterable){
    var C          = getConstructor(this)
      , capability = new PromiseCapability(C)
      , reject     = capability.reject;
    var abrupt = perform(function(){
      forOf(iterable, false, function(promise){
        C.resolve(promise).then(capability.resolve, reject);
      });
    });
    if(abrupt)reject(abrupt.error);
    return capability.promise;
  }
});
},{"11":11,"17":17,"18":18,"20":20,"23":23,"28":28,"3":3,"30":30,"39":39,"44":44,"47":47,"49":49,"5":5,"53":53,"61":61,"64":64,"65":65,"66":66,"67":67,"69":69,"70":70,"84":84}],140:[function(_dereq_,module,exports){
// 26.1.1 Reflect.apply(target, thisArgument, argumentsList)
var $export = _dereq_(23)
  , _apply  = Function.apply;

$export($export.S, 'Reflect', {
  apply: function apply(target, thisArgument, argumentsList){
    return _apply.call(target, thisArgument, argumentsList);
  }
});
},{"23":23}],141:[function(_dereq_,module,exports){
// 26.1.2 Reflect.construct(target, argumentsList [, newTarget])
var $         = _dereq_(47)
  , $export   = _dereq_(23)
  , aFunction = _dereq_(3)
  , anObject  = _dereq_(5)
  , isObject  = _dereq_(39)
  , bind      = Function.bind || _dereq_(17).Function.prototype.bind;

// MS Edge supports only 2 arguments
// FF Nightly sets third argument as `new.target`, but does not create `this` from it
$export($export.S + $export.F * _dereq_(25)(function(){
  function F(){}
  return !(Reflect.construct(function(){}, [], F) instanceof F);
}), 'Reflect', {
  construct: function construct(Target, args /*, newTarget*/){
    aFunction(Target);
    var newTarget = arguments.length < 3 ? Target : aFunction(arguments[2]);
    if(Target == newTarget){
      // w/o altered newTarget, optimization for 0-4 arguments
      if(args != undefined)switch(anObject(args).length){
        case 0: return new Target;
        case 1: return new Target(args[0]);
        case 2: return new Target(args[0], args[1]);
        case 3: return new Target(args[0], args[1], args[2]);
        case 4: return new Target(args[0], args[1], args[2], args[3]);
      }
      // w/o altered newTarget, lot of arguments case
      var $args = [null];
      $args.push.apply($args, args);
      return new (bind.apply(Target, $args));
    }
    // with altered newTarget, not support built-in constructors
    var proto    = newTarget.prototype
      , instance = $.create(isObject(proto) ? proto : Object.prototype)
      , result   = Function.apply.call(Target, instance, args);
    return isObject(result) ? result : instance;
  }
});
},{"17":17,"23":23,"25":25,"3":3,"39":39,"47":47,"5":5}],142:[function(_dereq_,module,exports){
// 26.1.3 Reflect.defineProperty(target, propertyKey, attributes)
var $        = _dereq_(47)
  , $export  = _dereq_(23)
  , anObject = _dereq_(5);

// MS Edge has broken Reflect.defineProperty - throwing instead of returning false
$export($export.S + $export.F * _dereq_(25)(function(){
  Reflect.defineProperty($.setDesc({}, 1, {value: 1}), 1, {value: 2});
}), 'Reflect', {
  defineProperty: function defineProperty(target, propertyKey, attributes){
    anObject(target);
    try {
      $.setDesc(target, propertyKey, attributes);
      return true;
    } catch(e){
      return false;
    }
  }
});
},{"23":23,"25":25,"47":47,"5":5}],143:[function(_dereq_,module,exports){
// 26.1.4 Reflect.deleteProperty(target, propertyKey)
var $export  = _dereq_(23)
  , getDesc  = _dereq_(47).getDesc
  , anObject = _dereq_(5);

$export($export.S, 'Reflect', {
  deleteProperty: function deleteProperty(target, propertyKey){
    var desc = getDesc(anObject(target), propertyKey);
    return desc && !desc.configurable ? false : delete target[propertyKey];
  }
});
},{"23":23,"47":47,"5":5}],144:[function(_dereq_,module,exports){
'use strict';
// 26.1.5 Reflect.enumerate(target)
var $export  = _dereq_(23)
  , anObject = _dereq_(5);
var Enumerate = function(iterated){
  this._t = anObject(iterated); // target
  this._i = 0;                  // next index
  var keys = this._k = []       // keys
    , key;
  for(key in iterated)keys.push(key);
};
_dereq_(42)(Enumerate, 'Object', function(){
  var that = this
    , keys = that._k
    , key;
  do {
    if(that._i >= keys.length)return {value: undefined, done: true};
  } while(!((key = keys[that._i++]) in that._t));
  return {value: key, done: false};
});

$export($export.S, 'Reflect', {
  enumerate: function enumerate(target){
    return new Enumerate(target);
  }
});
},{"23":23,"42":42,"5":5}],145:[function(_dereq_,module,exports){
// 26.1.7 Reflect.getOwnPropertyDescriptor(target, propertyKey)
var $        = _dereq_(47)
  , $export  = _dereq_(23)
  , anObject = _dereq_(5);

$export($export.S, 'Reflect', {
  getOwnPropertyDescriptor: function getOwnPropertyDescriptor(target, propertyKey){
    return $.getDesc(anObject(target), propertyKey);
  }
});
},{"23":23,"47":47,"5":5}],146:[function(_dereq_,module,exports){
// 26.1.8 Reflect.getPrototypeOf(target)
var $export  = _dereq_(23)
  , getProto = _dereq_(47).getProto
  , anObject = _dereq_(5);

$export($export.S, 'Reflect', {
  getPrototypeOf: function getPrototypeOf(target){
    return getProto(anObject(target));
  }
});
},{"23":23,"47":47,"5":5}],147:[function(_dereq_,module,exports){
// 26.1.6 Reflect.get(target, propertyKey [, receiver])
var $        = _dereq_(47)
  , has      = _dereq_(31)
  , $export  = _dereq_(23)
  , isObject = _dereq_(39)
  , anObject = _dereq_(5);

function get(target, propertyKey/*, receiver*/){
  var receiver = arguments.length < 3 ? target : arguments[2]
    , desc, proto;
  if(anObject(target) === receiver)return target[propertyKey];
  if(desc = $.getDesc(target, propertyKey))return has(desc, 'value')
    ? desc.value
    : desc.get !== undefined
      ? desc.get.call(receiver)
      : undefined;
  if(isObject(proto = $.getProto(target)))return get(proto, propertyKey, receiver);
}

$export($export.S, 'Reflect', {get: get});
},{"23":23,"31":31,"39":39,"47":47,"5":5}],148:[function(_dereq_,module,exports){
// 26.1.9 Reflect.has(target, propertyKey)
var $export = _dereq_(23);

$export($export.S, 'Reflect', {
  has: function has(target, propertyKey){
    return propertyKey in target;
  }
});
},{"23":23}],149:[function(_dereq_,module,exports){
// 26.1.10 Reflect.isExtensible(target)
var $export       = _dereq_(23)
  , anObject      = _dereq_(5)
  , $isExtensible = Object.isExtensible;

$export($export.S, 'Reflect', {
  isExtensible: function isExtensible(target){
    anObject(target);
    return $isExtensible ? $isExtensible(target) : true;
  }
});
},{"23":23,"5":5}],150:[function(_dereq_,module,exports){
// 26.1.11 Reflect.ownKeys(target)
var $export = _dereq_(23);

$export($export.S, 'Reflect', {ownKeys: _dereq_(57)});
},{"23":23,"57":57}],151:[function(_dereq_,module,exports){
// 26.1.12 Reflect.preventExtensions(target)
var $export            = _dereq_(23)
  , anObject           = _dereq_(5)
  , $preventExtensions = Object.preventExtensions;

$export($export.S, 'Reflect', {
  preventExtensions: function preventExtensions(target){
    anObject(target);
    try {
      if($preventExtensions)$preventExtensions(target);
      return true;
    } catch(e){
      return false;
    }
  }
});
},{"23":23,"5":5}],152:[function(_dereq_,module,exports){
// 26.1.14 Reflect.setPrototypeOf(target, proto)
var $export  = _dereq_(23)
  , setProto = _dereq_(65);

if(setProto)$export($export.S, 'Reflect', {
  setPrototypeOf: function setPrototypeOf(target, proto){
    setProto.check(target, proto);
    try {
      setProto.set(target, proto);
      return true;
    } catch(e){
      return false;
    }
  }
});
},{"23":23,"65":65}],153:[function(_dereq_,module,exports){
// 26.1.13 Reflect.set(target, propertyKey, V [, receiver])
var $          = _dereq_(47)
  , has        = _dereq_(31)
  , $export    = _dereq_(23)
  , createDesc = _dereq_(60)
  , anObject   = _dereq_(5)
  , isObject   = _dereq_(39);

function set(target, propertyKey, V/*, receiver*/){
  var receiver = arguments.length < 4 ? target : arguments[3]
    , ownDesc  = $.getDesc(anObject(target), propertyKey)
    , existingDescriptor, proto;
  if(!ownDesc){
    if(isObject(proto = $.getProto(target))){
      return set(proto, propertyKey, V, receiver);
    }
    ownDesc = createDesc(0);
  }
  if(has(ownDesc, 'value')){
    if(ownDesc.writable === false || !isObject(receiver))return false;
    existingDescriptor = $.getDesc(receiver, propertyKey) || createDesc(0);
    existingDescriptor.value = V;
    $.setDesc(receiver, propertyKey, existingDescriptor);
    return true;
  }
  return ownDesc.set === undefined ? false : (ownDesc.set.call(receiver, V), true);
}

$export($export.S, 'Reflect', {set: set});
},{"23":23,"31":31,"39":39,"47":47,"5":5,"60":60}],154:[function(_dereq_,module,exports){
var $        = _dereq_(47)
  , global   = _dereq_(30)
  , isRegExp = _dereq_(40)
  , $flags   = _dereq_(27)
  , $RegExp  = global.RegExp
  , Base     = $RegExp
  , proto    = $RegExp.prototype
  , re1      = /a/g
  , re2      = /a/g
  // "new" creates a new object, old webkit buggy here
  , CORRECT_NEW = new $RegExp(re1) !== re1;

if(_dereq_(20) && (!CORRECT_NEW || _dereq_(25)(function(){
  re2[_dereq_(84)('match')] = false;
  // RegExp constructor can alter flags and IsRegExp works correct with @@match
  return $RegExp(re1) != re1 || $RegExp(re2) == re2 || $RegExp(re1, 'i') != '/a/i';
}))){
  $RegExp = function RegExp(p, f){
    var piRE = isRegExp(p)
      , fiU  = f === undefined;
    return !(this instanceof $RegExp) && piRE && p.constructor === $RegExp && fiU ? p
      : CORRECT_NEW
        ? new Base(piRE && !fiU ? p.source : p, f)
        : Base((piRE = p instanceof $RegExp) ? p.source : p, piRE && fiU ? $flags.call(p) : f);
  };
  $.each.call($.getNames(Base), function(key){
    key in $RegExp || $.setDesc($RegExp, key, {
      configurable: true,
      get: function(){ return Base[key]; },
      set: function(it){ Base[key] = it; }
    });
  });
  proto.constructor = $RegExp;
  $RegExp.prototype = proto;
  _dereq_(62)(global, 'RegExp', $RegExp);
}

_dereq_(66)('RegExp');
},{"20":20,"25":25,"27":27,"30":30,"40":40,"47":47,"62":62,"66":66,"84":84}],155:[function(_dereq_,module,exports){
// 21.2.5.3 get RegExp.prototype.flags()
var $ = _dereq_(47);
if(_dereq_(20) && /./g.flags != 'g')$.setDesc(RegExp.prototype, 'flags', {
  configurable: true,
  get: _dereq_(27)
});
},{"20":20,"27":27,"47":47}],156:[function(_dereq_,module,exports){
// @@match logic
_dereq_(26)('match', 1, function(defined, MATCH){
  // 21.1.3.11 String.prototype.match(regexp)
  return function match(regexp){
    'use strict';
    var O  = defined(this)
      , fn = regexp == undefined ? undefined : regexp[MATCH];
    return fn !== undefined ? fn.call(regexp, O) : new RegExp(regexp)[MATCH](String(O));
  };
});
},{"26":26}],157:[function(_dereq_,module,exports){
// @@replace logic
_dereq_(26)('replace', 2, function(defined, REPLACE, $replace){
  // 21.1.3.14 String.prototype.replace(searchValue, replaceValue)
  return function replace(searchValue, replaceValue){
    'use strict';
    var O  = defined(this)
      , fn = searchValue == undefined ? undefined : searchValue[REPLACE];
    return fn !== undefined
      ? fn.call(searchValue, O, replaceValue)
      : $replace.call(String(O), searchValue, replaceValue);
  };
});
},{"26":26}],158:[function(_dereq_,module,exports){
// @@search logic
_dereq_(26)('search', 1, function(defined, SEARCH){
  // 21.1.3.15 String.prototype.search(regexp)
  return function search(regexp){
    'use strict';
    var O  = defined(this)
      , fn = regexp == undefined ? undefined : regexp[SEARCH];
    return fn !== undefined ? fn.call(regexp, O) : new RegExp(regexp)[SEARCH](String(O));
  };
});
},{"26":26}],159:[function(_dereq_,module,exports){
// @@split logic
_dereq_(26)('split', 2, function(defined, SPLIT, $split){
  // 21.1.3.17 String.prototype.split(separator, limit)
  return function split(separator, limit){
    'use strict';
    var O  = defined(this)
      , fn = separator == undefined ? undefined : separator[SPLIT];
    return fn !== undefined
      ? fn.call(separator, O, limit)
      : $split.call(String(O), separator, limit);
  };
});
},{"26":26}],160:[function(_dereq_,module,exports){
'use strict';
var strong = _dereq_(13);

// 23.2 Set Objects
_dereq_(16)('Set', function(get){
  return function Set(){ return get(this, arguments.length > 0 ? arguments[0] : undefined); };
}, {
  // 23.2.3.1 Set.prototype.add(value)
  add: function add(value){
    return strong.def(this, value = value === 0 ? 0 : value, value);
  }
}, strong);
},{"13":13,"16":16}],161:[function(_dereq_,module,exports){
'use strict';
var $export = _dereq_(23)
  , $at     = _dereq_(71)(false);
$export($export.P, 'String', {
  // 21.1.3.3 String.prototype.codePointAt(pos)
  codePointAt: function codePointAt(pos){
    return $at(this, pos);
  }
});
},{"23":23,"71":71}],162:[function(_dereq_,module,exports){
// 21.1.3.6 String.prototype.endsWith(searchString [, endPosition])
'use strict';
var $export   = _dereq_(23)
  , toLength  = _dereq_(80)
  , context   = _dereq_(72)
  , ENDS_WITH = 'endsWith'
  , $endsWith = ''[ENDS_WITH];

$export($export.P + $export.F * _dereq_(24)(ENDS_WITH), 'String', {
  endsWith: function endsWith(searchString /*, endPosition = @length */){
    var that = context(this, searchString, ENDS_WITH)
      , $$   = arguments
      , endPosition = $$.length > 1 ? $$[1] : undefined
      , len    = toLength(that.length)
      , end    = endPosition === undefined ? len : Math.min(toLength(endPosition), len)
      , search = String(searchString);
    return $endsWith
      ? $endsWith.call(that, search, end)
      : that.slice(end - search.length, end) === search;
  }
});
},{"23":23,"24":24,"72":72,"80":80}],163:[function(_dereq_,module,exports){
var $export        = _dereq_(23)
  , toIndex        = _dereq_(77)
  , fromCharCode   = String.fromCharCode
  , $fromCodePoint = String.fromCodePoint;

// length should be 1, old FF problem
$export($export.S + $export.F * (!!$fromCodePoint && $fromCodePoint.length != 1), 'String', {
  // 21.1.2.2 String.fromCodePoint(...codePoints)
  fromCodePoint: function fromCodePoint(x){ // eslint-disable-line no-unused-vars
    var res   = []
      , $$    = arguments
      , $$len = $$.length
      , i     = 0
      , code;
    while($$len > i){
      code = +$$[i++];
      if(toIndex(code, 0x10ffff) !== code)throw RangeError(code + ' is not a valid code point');
      res.push(code < 0x10000
        ? fromCharCode(code)
        : fromCharCode(((code -= 0x10000) >> 10) + 0xd800, code % 0x400 + 0xdc00)
      );
    } return res.join('');
  }
});
},{"23":23,"77":77}],164:[function(_dereq_,module,exports){
// 21.1.3.7 String.prototype.includes(searchString, position = 0)
'use strict';
var $export  = _dereq_(23)
  , context  = _dereq_(72)
  , INCLUDES = 'includes';

$export($export.P + $export.F * _dereq_(24)(INCLUDES), 'String', {
  includes: function includes(searchString /*, position = 0 */){
    return !!~context(this, searchString, INCLUDES)
      .indexOf(searchString, arguments.length > 1 ? arguments[1] : undefined);
  }
});
},{"23":23,"24":24,"72":72}],165:[function(_dereq_,module,exports){
'use strict';
var $at  = _dereq_(71)(true);

// 21.1.3.27 String.prototype[@@iterator]()
_dereq_(43)(String, 'String', function(iterated){
  this._t = String(iterated); // target
  this._i = 0;                // next index
// 21.1.5.2.1 %StringIteratorPrototype%.next()
}, function(){
  var O     = this._t
    , index = this._i
    , point;
  if(index >= O.length)return {value: undefined, done: true};
  point = $at(O, index);
  this._i += point.length;
  return {value: point, done: false};
});
},{"43":43,"71":71}],166:[function(_dereq_,module,exports){
var $export   = _dereq_(23)
  , toIObject = _dereq_(79)
  , toLength  = _dereq_(80);

$export($export.S, 'String', {
  // 21.1.2.4 String.raw(callSite, ...substitutions)
  raw: function raw(callSite){
    var tpl   = toIObject(callSite.raw)
      , len   = toLength(tpl.length)
      , $$    = arguments
      , $$len = $$.length
      , res   = []
      , i     = 0;
    while(len > i){
      res.push(String(tpl[i++]));
      if(i < $$len)res.push(String($$[i]));
    } return res.join('');
  }
});
},{"23":23,"79":79,"80":80}],167:[function(_dereq_,module,exports){
var $export = _dereq_(23);

$export($export.P, 'String', {
  // 21.1.3.13 String.prototype.repeat(count)
  repeat: _dereq_(74)
});
},{"23":23,"74":74}],168:[function(_dereq_,module,exports){
// 21.1.3.18 String.prototype.startsWith(searchString [, position ])
'use strict';
var $export     = _dereq_(23)
  , toLength    = _dereq_(80)
  , context     = _dereq_(72)
  , STARTS_WITH = 'startsWith'
  , $startsWith = ''[STARTS_WITH];

$export($export.P + $export.F * _dereq_(24)(STARTS_WITH), 'String', {
  startsWith: function startsWith(searchString /*, position = 0 */){
    var that   = context(this, searchString, STARTS_WITH)
      , $$     = arguments
      , index  = toLength(Math.min($$.length > 1 ? $$[1] : undefined, that.length))
      , search = String(searchString);
    return $startsWith
      ? $startsWith.call(that, search, index)
      : that.slice(index, index + search.length) === search;
  }
});
},{"23":23,"24":24,"72":72,"80":80}],169:[function(_dereq_,module,exports){
'use strict';
// 21.1.3.25 String.prototype.trim()
_dereq_(75)('trim', function($trim){
  return function trim(){
    return $trim(this, 3);
  };
});
},{"75":75}],170:[function(_dereq_,module,exports){
'use strict';
// ECMAScript 6 symbols shim
var $              = _dereq_(47)
  , global         = _dereq_(30)
  , has            = _dereq_(31)
  , DESCRIPTORS    = _dereq_(20)
  , $export        = _dereq_(23)
  , redefine       = _dereq_(62)
  , $fails         = _dereq_(25)
  , shared         = _dereq_(68)
  , setToStringTag = _dereq_(67)
  , uid            = _dereq_(83)
  , wks            = _dereq_(84)
  , keyOf          = _dereq_(48)
  , $names         = _dereq_(29)
  , enumKeys       = _dereq_(22)
  , isArray        = _dereq_(37)
  , anObject       = _dereq_(5)
  , toIObject      = _dereq_(79)
  , createDesc     = _dereq_(60)
  , getDesc        = $.getDesc
  , setDesc        = $.setDesc
  , _create        = $.create
  , getNames       = $names.get
  , $Symbol        = global.Symbol
  , $JSON          = global.JSON
  , _stringify     = $JSON && $JSON.stringify
  , setter         = false
  , HIDDEN         = wks('_hidden')
  , isEnum         = $.isEnum
  , SymbolRegistry = shared('symbol-registry')
  , AllSymbols     = shared('symbols')
  , useNative      = typeof $Symbol == 'function'
  , ObjectProto    = Object.prototype;

// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
var setSymbolDesc = DESCRIPTORS && $fails(function(){
  return _create(setDesc({}, 'a', {
    get: function(){ return setDesc(this, 'a', {value: 7}).a; }
  })).a != 7;
}) ? function(it, key, D){
  var protoDesc = getDesc(ObjectProto, key);
  if(protoDesc)delete ObjectProto[key];
  setDesc(it, key, D);
  if(protoDesc && it !== ObjectProto)setDesc(ObjectProto, key, protoDesc);
} : setDesc;

var wrap = function(tag){
  var sym = AllSymbols[tag] = _create($Symbol.prototype);
  sym._k = tag;
  DESCRIPTORS && setter && setSymbolDesc(ObjectProto, tag, {
    configurable: true,
    set: function(value){
      if(has(this, HIDDEN) && has(this[HIDDEN], tag))this[HIDDEN][tag] = false;
      setSymbolDesc(this, tag, createDesc(1, value));
    }
  });
  return sym;
};

var isSymbol = function(it){
  return typeof it == 'symbol';
};

var $defineProperty = function defineProperty(it, key, D){
  if(D && has(AllSymbols, key)){
    if(!D.enumerable){
      if(!has(it, HIDDEN))setDesc(it, HIDDEN, createDesc(1, {}));
      it[HIDDEN][key] = true;
    } else {
      if(has(it, HIDDEN) && it[HIDDEN][key])it[HIDDEN][key] = false;
      D = _create(D, {enumerable: createDesc(0, false)});
    } return setSymbolDesc(it, key, D);
  } return setDesc(it, key, D);
};
var $defineProperties = function defineProperties(it, P){
  anObject(it);
  var keys = enumKeys(P = toIObject(P))
    , i    = 0
    , l = keys.length
    , key;
  while(l > i)$defineProperty(it, key = keys[i++], P[key]);
  return it;
};
var $create = function create(it, P){
  return P === undefined ? _create(it) : $defineProperties(_create(it), P);
};
var $propertyIsEnumerable = function propertyIsEnumerable(key){
  var E = isEnum.call(this, key);
  return E || !has(this, key) || !has(AllSymbols, key) || has(this, HIDDEN) && this[HIDDEN][key]
    ? E : true;
};
var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(it, key){
  var D = getDesc(it = toIObject(it), key);
  if(D && has(AllSymbols, key) && !(has(it, HIDDEN) && it[HIDDEN][key]))D.enumerable = true;
  return D;
};
var $getOwnPropertyNames = function getOwnPropertyNames(it){
  var names  = getNames(toIObject(it))
    , result = []
    , i      = 0
    , key;
  while(names.length > i)if(!has(AllSymbols, key = names[i++]) && key != HIDDEN)result.push(key);
  return result;
};
var $getOwnPropertySymbols = function getOwnPropertySymbols(it){
  var names  = getNames(toIObject(it))
    , result = []
    , i      = 0
    , key;
  while(names.length > i)if(has(AllSymbols, key = names[i++]))result.push(AllSymbols[key]);
  return result;
};
var $stringify = function stringify(it){
  if(it === undefined || isSymbol(it))return; // IE8 returns string on undefined
  var args = [it]
    , i    = 1
    , $$   = arguments
    , replacer, $replacer;
  while($$.length > i)args.push($$[i++]);
  replacer = args[1];
  if(typeof replacer == 'function')$replacer = replacer;
  if($replacer || !isArray(replacer))replacer = function(key, value){
    if($replacer)value = $replacer.call(this, key, value);
    if(!isSymbol(value))return value;
  };
  args[1] = replacer;
  return _stringify.apply($JSON, args);
};
var buggyJSON = $fails(function(){
  var S = $Symbol();
  // MS Edge converts symbol values to JSON as {}
  // WebKit converts symbol values to JSON as null
  // V8 throws on boxed symbols
  return _stringify([S]) != '[null]' || _stringify({a: S}) != '{}' || _stringify(Object(S)) != '{}';
});

// 19.4.1.1 Symbol([description])
if(!useNative){
  $Symbol = function Symbol(){
    if(isSymbol(this))throw TypeError('Symbol is not a constructor');
    return wrap(uid(arguments.length > 0 ? arguments[0] : undefined));
  };
  redefine($Symbol.prototype, 'toString', function toString(){
    return this._k;
  });

  isSymbol = function(it){
    return it instanceof $Symbol;
  };

  $.create     = $create;
  $.isEnum     = $propertyIsEnumerable;
  $.getDesc    = $getOwnPropertyDescriptor;
  $.setDesc    = $defineProperty;
  $.setDescs   = $defineProperties;
  $.getNames   = $names.get = $getOwnPropertyNames;
  $.getSymbols = $getOwnPropertySymbols;

  if(DESCRIPTORS && !_dereq_(49)){
    redefine(ObjectProto, 'propertyIsEnumerable', $propertyIsEnumerable, true);
  }
}

var symbolStatics = {
  // 19.4.2.1 Symbol.for(key)
  'for': function(key){
    return has(SymbolRegistry, key += '')
      ? SymbolRegistry[key]
      : SymbolRegistry[key] = $Symbol(key);
  },
  // 19.4.2.5 Symbol.keyFor(sym)
  keyFor: function keyFor(key){
    return keyOf(SymbolRegistry, key);
  },
  useSetter: function(){ setter = true; },
  useSimple: function(){ setter = false; }
};
// 19.4.2.2 Symbol.hasInstance
// 19.4.2.3 Symbol.isConcatSpreadable
// 19.4.2.4 Symbol.iterator
// 19.4.2.6 Symbol.match
// 19.4.2.8 Symbol.replace
// 19.4.2.9 Symbol.search
// 19.4.2.10 Symbol.species
// 19.4.2.11 Symbol.split
// 19.4.2.12 Symbol.toPrimitive
// 19.4.2.13 Symbol.toStringTag
// 19.4.2.14 Symbol.unscopables
$.each.call((
  'hasInstance,isConcatSpreadable,iterator,match,replace,search,' +
  'species,split,toPrimitive,toStringTag,unscopables'
).split(','), function(it){
  var sym = wks(it);
  symbolStatics[it] = useNative ? sym : wrap(sym);
});

setter = true;

$export($export.G + $export.W, {Symbol: $Symbol});

$export($export.S, 'Symbol', symbolStatics);

$export($export.S + $export.F * !useNative, 'Object', {
  // 19.1.2.2 Object.create(O [, Properties])
  create: $create,
  // 19.1.2.4 Object.defineProperty(O, P, Attributes)
  defineProperty: $defineProperty,
  // 19.1.2.3 Object.defineProperties(O, Properties)
  defineProperties: $defineProperties,
  // 19.1.2.6 Object.getOwnPropertyDescriptor(O, P)
  getOwnPropertyDescriptor: $getOwnPropertyDescriptor,
  // 19.1.2.7 Object.getOwnPropertyNames(O)
  getOwnPropertyNames: $getOwnPropertyNames,
  // 19.1.2.8 Object.getOwnPropertySymbols(O)
  getOwnPropertySymbols: $getOwnPropertySymbols
});

// 24.3.2 JSON.stringify(value [, replacer [, space]])
$JSON && $export($export.S + $export.F * (!useNative || buggyJSON), 'JSON', {stringify: $stringify});

// 19.4.3.5 Symbol.prototype[@@toStringTag]
setToStringTag($Symbol, 'Symbol');
// 20.2.1.9 Math[@@toStringTag]
setToStringTag(Math, 'Math', true);
// 24.3.3 JSON[@@toStringTag]
setToStringTag(global.JSON, 'JSON', true);
},{"20":20,"22":22,"23":23,"25":25,"29":29,"30":30,"31":31,"37":37,"47":47,"48":48,"49":49,"5":5,"60":60,"62":62,"67":67,"68":68,"79":79,"83":83,"84":84}],171:[function(_dereq_,module,exports){
'use strict';
var $            = _dereq_(47)
  , redefine     = _dereq_(62)
  , weak         = _dereq_(15)
  , isObject     = _dereq_(39)
  , has          = _dereq_(31)
  , frozenStore  = weak.frozenStore
  , WEAK         = weak.WEAK
  , isExtensible = Object.isExtensible || isObject
  , tmp          = {};

// 23.3 WeakMap Objects
var $WeakMap = _dereq_(16)('WeakMap', function(get){
  return function WeakMap(){ return get(this, arguments.length > 0 ? arguments[0] : undefined); };
}, {
  // 23.3.3.3 WeakMap.prototype.get(key)
  get: function get(key){
    if(isObject(key)){
      if(!isExtensible(key))return frozenStore(this).get(key);
      if(has(key, WEAK))return key[WEAK][this._i];
    }
  },
  // 23.3.3.5 WeakMap.prototype.set(key, value)
  set: function set(key, value){
    return weak.def(this, key, value);
  }
}, weak, true, true);

// IE11 WeakMap frozen keys fix
if(new $WeakMap().set((Object.freeze || Object)(tmp), 7).get(tmp) != 7){
  $.each.call(['delete', 'has', 'get', 'set'], function(key){
    var proto  = $WeakMap.prototype
      , method = proto[key];
    redefine(proto, key, function(a, b){
      // store frozen objects on leaky map
      if(isObject(a) && !isExtensible(a)){
        var result = frozenStore(this)[key](a, b);
        return key == 'set' ? this : result;
      // store all the rest on native weakmap
      } return method.call(this, a, b);
    });
  });
}
},{"15":15,"16":16,"31":31,"39":39,"47":47,"62":62}],172:[function(_dereq_,module,exports){
'use strict';
var weak = _dereq_(15);

// 23.4 WeakSet Objects
_dereq_(16)('WeakSet', function(get){
  return function WeakSet(){ return get(this, arguments.length > 0 ? arguments[0] : undefined); };
}, {
  // 23.4.3.1 WeakSet.prototype.add(value)
  add: function add(value){
    return weak.def(this, value, true);
  }
}, weak, false, true);
},{"15":15,"16":16}],173:[function(_dereq_,module,exports){
'use strict';
var $export   = _dereq_(23)
  , $includes = _dereq_(8)(true);

$export($export.P, 'Array', {
  // https://github.com/domenic/Array.prototype.includes
  includes: function includes(el /*, fromIndex = 0 */){
    return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined);
  }
});

_dereq_(4)('includes');
},{"23":23,"4":4,"8":8}],174:[function(_dereq_,module,exports){
// https://github.com/DavidBruant/Map-Set.prototype.toJSON
var $export  = _dereq_(23);

$export($export.P, 'Map', {toJSON: _dereq_(14)('Map')});
},{"14":14,"23":23}],175:[function(_dereq_,module,exports){
// http://goo.gl/XkBrjD
var $export  = _dereq_(23)
  , $entries = _dereq_(56)(true);

$export($export.S, 'Object', {
  entries: function entries(it){
    return $entries(it);
  }
});
},{"23":23,"56":56}],176:[function(_dereq_,module,exports){
// https://gist.github.com/WebReflection/9353781
var $          = _dereq_(47)
  , $export    = _dereq_(23)
  , ownKeys    = _dereq_(57)
  , toIObject  = _dereq_(79)
  , createDesc = _dereq_(60);

$export($export.S, 'Object', {
  getOwnPropertyDescriptors: function getOwnPropertyDescriptors(object){
    var O       = toIObject(object)
      , setDesc = $.setDesc
      , getDesc = $.getDesc
      , keys    = ownKeys(O)
      , result  = {}
      , i       = 0
      , key, D;
    while(keys.length > i){
      D = getDesc(O, key = keys[i++]);
      if(key in result)setDesc(result, key, createDesc(0, D));
      else result[key] = D;
    } return result;
  }
});
},{"23":23,"47":47,"57":57,"60":60,"79":79}],177:[function(_dereq_,module,exports){
// http://goo.gl/XkBrjD
var $export = _dereq_(23)
  , $values = _dereq_(56)(false);

$export($export.S, 'Object', {
  values: function values(it){
    return $values(it);
  }
});
},{"23":23,"56":56}],178:[function(_dereq_,module,exports){
// https://github.com/benjamingr/RexExp.escape
var $export = _dereq_(23)
  , $re     = _dereq_(63)(/[\\^$*+?.()|[\]{}]/g, '\\$&');

$export($export.S, 'RegExp', {escape: function escape(it){ return $re(it); }});

},{"23":23,"63":63}],179:[function(_dereq_,module,exports){
// https://github.com/DavidBruant/Map-Set.prototype.toJSON
var $export  = _dereq_(23);

$export($export.P, 'Set', {toJSON: _dereq_(14)('Set')});
},{"14":14,"23":23}],180:[function(_dereq_,module,exports){
'use strict';
// https://github.com/mathiasbynens/String.prototype.at
var $export = _dereq_(23)
  , $at     = _dereq_(71)(true);

$export($export.P, 'String', {
  at: function at(pos){
    return $at(this, pos);
  }
});
},{"23":23,"71":71}],181:[function(_dereq_,module,exports){
'use strict';
var $export = _dereq_(23)
  , $pad    = _dereq_(73);

$export($export.P, 'String', {
  padLeft: function padLeft(maxLength /*, fillString = ' ' */){
    return $pad(this, maxLength, arguments.length > 1 ? arguments[1] : undefined, true);
  }
});
},{"23":23,"73":73}],182:[function(_dereq_,module,exports){
'use strict';
var $export = _dereq_(23)
  , $pad    = _dereq_(73);

$export($export.P, 'String', {
  padRight: function padRight(maxLength /*, fillString = ' ' */){
    return $pad(this, maxLength, arguments.length > 1 ? arguments[1] : undefined, false);
  }
});
},{"23":23,"73":73}],183:[function(_dereq_,module,exports){
'use strict';
// https://github.com/sebmarkbage/ecmascript-string-left-right-trim
_dereq_(75)('trimLeft', function($trim){
  return function trimLeft(){
    return $trim(this, 1);
  };
});
},{"75":75}],184:[function(_dereq_,module,exports){
'use strict';
// https://github.com/sebmarkbage/ecmascript-string-left-right-trim
_dereq_(75)('trimRight', function($trim){
  return function trimRight(){
    return $trim(this, 2);
  };
});
},{"75":75}],185:[function(_dereq_,module,exports){
// JavaScript 1.6 / Strawman array statics shim
var $       = _dereq_(47)
  , $export = _dereq_(23)
  , $ctx    = _dereq_(18)
  , $Array  = _dereq_(17).Array || Array
  , statics = {};
var setStatics = function(keys, length){
  $.each.call(keys.split(','), function(key){
    if(length == undefined && key in $Array)statics[key] = $Array[key];
    else if(key in [])statics[key] = $ctx(Function.call, [][key], length);
  });
};
setStatics('pop,reverse,shift,keys,values,entries', 1);
setStatics('indexOf,every,some,forEach,map,filter,find,findIndex,includes', 3);
setStatics('join,slice,concat,push,splice,unshift,sort,lastIndexOf,' +
           'reduce,reduceRight,copyWithin,fill');
$export($export.S, 'Array', statics);
},{"17":17,"18":18,"23":23,"47":47}],186:[function(_dereq_,module,exports){
_dereq_(92);
var global      = _dereq_(30)
  , hide        = _dereq_(32)
  , Iterators   = _dereq_(46)
  , ITERATOR    = _dereq_(84)('iterator')
  , NL          = global.NodeList
  , HTC         = global.HTMLCollection
  , NLProto     = NL && NL.prototype
  , HTCProto    = HTC && HTC.prototype
  , ArrayValues = Iterators.NodeList = Iterators.HTMLCollection = Iterators.Array;
if(NLProto && !NLProto[ITERATOR])hide(NLProto, ITERATOR, ArrayValues);
if(HTCProto && !HTCProto[ITERATOR])hide(HTCProto, ITERATOR, ArrayValues);
},{"30":30,"32":32,"46":46,"84":84,"92":92}],187:[function(_dereq_,module,exports){
var $export = _dereq_(23)
  , $task   = _dereq_(76);
$export($export.G + $export.B, {
  setImmediate:   $task.set,
  clearImmediate: $task.clear
});
},{"23":23,"76":76}],188:[function(_dereq_,module,exports){
// ie9- setTimeout & setInterval additional parameters fix
var global     = _dereq_(30)
  , $export    = _dereq_(23)
  , invoke     = _dereq_(34)
  , partial    = _dereq_(58)
  , navigator  = global.navigator
  , MSIE       = !!navigator && /MSIE .\./.test(navigator.userAgent); // <- dirty ie9- check
var wrap = function(set){
  return MSIE ? function(fn, time /*, ...args */){
    return set(invoke(
      partial,
      [].slice.call(arguments, 2),
      typeof fn == 'function' ? fn : Function(fn)
    ), time);
  } : set;
};
$export($export.G + $export.B + $export.F * MSIE, {
  setTimeout:  wrap(global.setTimeout),
  setInterval: wrap(global.setInterval)
});
},{"23":23,"30":30,"34":34,"58":58}],189:[function(_dereq_,module,exports){
_dereq_(86);
_dereq_(170);
_dereq_(125);
_dereq_(133);
_dereq_(137);
_dereq_(138);
_dereq_(126);
_dereq_(136);
_dereq_(135);
_dereq_(131);
_dereq_(132);
_dereq_(130);
_dereq_(127);
_dereq_(129);
_dereq_(134);
_dereq_(128);
_dereq_(96);
_dereq_(95);
_dereq_(115);
_dereq_(116);
_dereq_(117);
_dereq_(118);
_dereq_(119);
_dereq_(120);
_dereq_(121);
_dereq_(122);
_dereq_(123);
_dereq_(124);
_dereq_(98);
_dereq_(99);
_dereq_(100);
_dereq_(101);
_dereq_(102);
_dereq_(103);
_dereq_(104);
_dereq_(105);
_dereq_(106);
_dereq_(107);
_dereq_(108);
_dereq_(109);
_dereq_(110);
_dereq_(111);
_dereq_(112);
_dereq_(113);
_dereq_(114);
_dereq_(163);
_dereq_(166);
_dereq_(169);
_dereq_(165);
_dereq_(161);
_dereq_(162);
_dereq_(164);
_dereq_(167);
_dereq_(168);
_dereq_(91);
_dereq_(93);
_dereq_(92);
_dereq_(94);
_dereq_(87);
_dereq_(88);
_dereq_(90);
_dereq_(89);
_dereq_(154);
_dereq_(155);
_dereq_(156);
_dereq_(157);
_dereq_(158);
_dereq_(159);
_dereq_(139);
_dereq_(97);
_dereq_(160);
_dereq_(171);
_dereq_(172);
_dereq_(140);
_dereq_(141);
_dereq_(142);
_dereq_(143);
_dereq_(144);
_dereq_(147);
_dereq_(145);
_dereq_(146);
_dereq_(148);
_dereq_(149);
_dereq_(150);
_dereq_(151);
_dereq_(153);
_dereq_(152);
_dereq_(173);
_dereq_(180);
_dereq_(181);
_dereq_(182);
_dereq_(183);
_dereq_(184);
_dereq_(178);
_dereq_(176);
_dereq_(177);
_dereq_(175);
_dereq_(174);
_dereq_(179);
_dereq_(185);
_dereq_(188);
_dereq_(187);
_dereq_(186);
module.exports = _dereq_(17);
},{"100":100,"101":101,"102":102,"103":103,"104":104,"105":105,"106":106,"107":107,"108":108,"109":109,"110":110,"111":111,"112":112,"113":113,"114":114,"115":115,"116":116,"117":117,"118":118,"119":119,"120":120,"121":121,"122":122,"123":123,"124":124,"125":125,"126":126,"127":127,"128":128,"129":129,"130":130,"131":131,"132":132,"133":133,"134":134,"135":135,"136":136,"137":137,"138":138,"139":139,"140":140,"141":141,"142":142,"143":143,"144":144,"145":145,"146":146,"147":147,"148":148,"149":149,"150":150,"151":151,"152":152,"153":153,"154":154,"155":155,"156":156,"157":157,"158":158,"159":159,"160":160,"161":161,"162":162,"163":163,"164":164,"165":165,"166":166,"167":167,"168":168,"169":169,"17":17,"170":170,"171":171,"172":172,"173":173,"174":174,"175":175,"176":176,"177":177,"178":178,"179":179,"180":180,"181":181,"182":182,"183":183,"184":184,"185":185,"186":186,"187":187,"188":188,"86":86,"87":87,"88":88,"89":89,"90":90,"91":91,"92":92,"93":93,"94":94,"95":95,"96":96,"97":97,"98":98,"99":99}],190:[function(_dereq_,module,exports){
(function (global){
/**
 * Copyright (c) 2014, Facebook, Inc.
 * All rights reserved.
 *
 * This source code is licensed under the BSD-style license found in the
 * https://raw.github.com/facebook/regenerator/master/LICENSE file. An
 * additional grant of patent rights can be found in the PATENTS file in
 * the same directory.
 */

!(function(global) {
  "use strict";

  var hasOwn = Object.prototype.hasOwnProperty;
  var undefined; // More compressible than void 0.
  var iteratorSymbol =
    typeof Symbol === "function" && Symbol.iterator || "@@iterator";

  var inModule = typeof module === "object";
  var runtime = global.regeneratorRuntime;
  if (runtime) {
    if (inModule) {
      // If regeneratorRuntime is defined globally and we're in a module,
      // make the exports object identical to regeneratorRuntime.
      module.exports = runtime;
    }
    // Don't bother evaluating the rest of this file if the runtime was
    // already defined globally.
    return;
  }

  // Define the runtime globally (as expected by generated code) as either
  // module.exports (if we're in a module) or a new, empty object.
  runtime = global.regeneratorRuntime = inModule ? module.exports : {};

  function wrap(innerFn, outerFn, self, tryLocsList) {
    // If outerFn provided, then outerFn.prototype instanceof Generator.
    var generator = Object.create((outerFn || Generator).prototype);
    var context = new Context(tryLocsList || []);

    // The ._invoke method unifies the implementations of the .next,
    // .throw, and .return methods.
    generator._invoke = makeInvokeMethod(innerFn, self, context);

    return generator;
  }
  runtime.wrap = wrap;

  // Try/catch helper to minimize deoptimizations. Returns a completion
  // record like context.tryEntries[i].completion. This interface could
  // have been (and was previously) designed to take a closure to be
  // invoked without arguments, but in all the cases we care about we
  // already have an existing method we want to call, so there's no need
  // to create a new function object. We can even get away with assuming
  // the method takes exactly one argument, since that happens to be true
  // in every case, so we don't have to touch the arguments object. The
  // only additional allocation required is the completion record, which
  // has a stable shape and so hopefully should be cheap to allocate.
  function tryCatch(fn, obj, arg) {
    try {
      return { type: "normal", arg: fn.call(obj, arg) };
    } catch (err) {
      return { type: "throw", arg: err };
    }
  }

  var GenStateSuspendedStart = "suspendedStart";
  var GenStateSuspendedYield = "suspendedYield";
  var GenStateExecuting = "executing";
  var GenStateCompleted = "completed";

  // Returning this object from the innerFn has the same effect as
  // breaking out of the dispatch switch statement.
  var ContinueSentinel = {};

  // Dummy constructor functions that we use as the .constructor and
  // .constructor.prototype properties for functions that return Generator
  // objects. For full spec compliance, you may wish to configure your
  // minifier not to mangle the names of these two functions.
  function Generator() {}
  function GeneratorFunction() {}
  function GeneratorFunctionPrototype() {}

  var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype;
  GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;
  GeneratorFunctionPrototype.constructor = GeneratorFunction;
  GeneratorFunction.displayName = "GeneratorFunction";

  // Helper for defining the .next, .throw, and .return methods of the
  // Iterator interface in terms of a single ._invoke method.
  function defineIteratorMethods(prototype) {
    ["next", "throw", "return"].forEach(function(method) {
      prototype[method] = function(arg) {
        return this._invoke(method, arg);
      };
    });
  }

  runtime.isGeneratorFunction = function(genFun) {
    var ctor = typeof genFun === "function" && genFun.constructor;
    return ctor
      ? ctor === GeneratorFunction ||
        // For the native GeneratorFunction constructor, the best we can
        // do is to check its .name property.
        (ctor.displayName || ctor.name) === "GeneratorFunction"
      : false;
  };

  runtime.mark = function(genFun) {
    if (Object.setPrototypeOf) {
      Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
    } else {
      genFun.__proto__ = GeneratorFunctionPrototype;
    }
    genFun.prototype = Object.create(Gp);
    return genFun;
  };

  // Within the body of any async function, `await x` is transformed to
  // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
  // `value instanceof AwaitArgument` to determine if the yielded value is
  // meant to be awaited. Some may consider the name of this method too
  // cutesy, but they are curmudgeons.
  runtime.awrap = function(arg) {
    return new AwaitArgument(arg);
  };

  function AwaitArgument(arg) {
    this.arg = arg;
  }

  function AsyncIterator(generator) {
    // This invoke function is written in a style that assumes some
    // calling function (or Promise) will handle exceptions.
    function invoke(method, arg) {
      var result = generator[method](arg);
      var value = result.value;
      return value instanceof AwaitArgument
        ? Promise.resolve(value.arg).then(invokeNext, invokeThrow)
        : Promise.resolve(value).then(function(unwrapped) {
            // When a yielded Promise is resolved, its final value becomes
            // the .value of the Promise<{value,done}> result for the
            // current iteration. If the Promise is rejected, however, the
            // result for this iteration will be rejected with the same
            // reason. Note that rejections of yielded Promises are not
            // thrown back into the generator function, as is the case
            // when an awaited Promise is rejected. This difference in
            // behavior between yield and await is important, because it
            // allows the consumer to decide what to do with the yielded
            // rejection (swallow it and continue, manually .throw it back
            // into the generator, abandon iteration, whatever). With
            // await, by contrast, there is no opportunity to examine the
            // rejection reason outside the generator function, so the
            // only option is to throw it from the await expression, and
            // let the generator function handle the exception.
            result.value = unwrapped;
            return result;
          });
    }

    if (typeof process === "object" && process.domain) {
      invoke = process.domain.bind(invoke);
    }

    var invokeNext = invoke.bind(generator, "next");
    var invokeThrow = invoke.bind(generator, "throw");
    var invokeReturn = invoke.bind(generator, "return");
    var previousPromise;

    function enqueue(method, arg) {
      function callInvokeWithMethodAndArg() {
        return invoke(method, arg);
      }

      return previousPromise =
        // If enqueue has been called before, then we want to wait until
        // all previous Promises have been resolved before calling invoke,
        // so that results are always delivered in the correct order. If
        // enqueue has not been called before, then it is important to
        // call invoke immediately, without waiting on a callback to fire,
        // so that the async generator function has the opportunity to do
        // any necessary setup in a predictable way. This predictability
        // is why the Promise constructor synchronously invokes its
        // executor callback, and why async functions synchronously
        // execute code before the first await. Since we implement simple
        // async functions in terms of async generators, it is especially
        // important to get this right, even though it requires care.
        previousPromise ? previousPromise.then(
          callInvokeWithMethodAndArg,
          // Avoid propagating failures to Promises returned by later
          // invocations of the iterator.
          callInvokeWithMethodAndArg
        ) : new Promise(function (resolve) {
          resolve(callInvokeWithMethodAndArg());
        });
    }

    // Define the unified helper method that is used to implement .next,
    // .throw, and .return (see defineIteratorMethods).
    this._invoke = enqueue;
  }

  defineIteratorMethods(AsyncIterator.prototype);

  // Note that simple async functions are implemented on top of
  // AsyncIterator objects; they just return a Promise for the value of
  // the final result produced by the iterator.
  runtime.async = function(innerFn, outerFn, self, tryLocsList) {
    var iter = new AsyncIterator(
      wrap(innerFn, outerFn, self, tryLocsList)
    );

    return runtime.isGeneratorFunction(outerFn)
      ? iter // If outerFn is a generator, return the full iterator.
      : iter.next().then(function(result) {
          return result.done ? result.value : iter.next();
        });
  };

  function makeInvokeMethod(innerFn, self, context) {
    var state = GenStateSuspendedStart;

    return function invoke(method, arg) {
      if (state === GenStateExecuting) {
        throw new Error("Generator is already running");
      }

      if (state === GenStateCompleted) {
        if (method === "throw") {
          throw arg;
        }

        // Be forgiving, per 25.3.3.3.3 of the spec:
        // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
        return doneResult();
      }

      while (true) {
        var delegate = context.delegate;
        if (delegate) {
          if (method === "return" ||
              (method === "throw" && delegate.iterator[method] === undefined)) {
            // A return or throw (when the delegate iterator has no throw
            // method) always terminates the yield* loop.
            context.delegate = null;

            // If the delegate iterator has a return method, give it a
            // chance to clean up.
            var returnMethod = delegate.iterator["return"];
            if (returnMethod) {
              var record = tryCatch(returnMethod, delegate.iterator, arg);
              if (record.type === "throw") {
                // If the return method threw an exception, let that
                // exception prevail over the original return or throw.
                method = "throw";
                arg = record.arg;
                continue;
              }
            }

            if (method === "return") {
              // Continue with the outer return, now that the delegate
              // iterator has been terminated.
              continue;
            }
          }

          var record = tryCatch(
            delegate.iterator[method],
            delegate.iterator,
            arg
          );

          if (record.type === "throw") {
            context.delegate = null;

            // Like returning generator.throw(uncaught), but without the
            // overhead of an extra function call.
            method = "throw";
            arg = record.arg;
            continue;
          }

          // Delegate generator ran and handled its own exceptions so
          // regardless of what the method was, we continue as if it is
          // "next" with an undefined arg.
          method = "next";
          arg = undefined;

          var info = record.arg;
          if (info.done) {
            context[delegate.resultName] = info.value;
            context.next = delegate.nextLoc;
          } else {
            state = GenStateSuspendedYield;
            return info;
          }

          context.delegate = null;
        }

        if (method === "next") {
          context._sent = arg;

          if (state === GenStateSuspendedYield) {
            context.sent = arg;
          } else {
            context.sent = undefined;
          }
        } else if (method === "throw") {
          if (state === GenStateSuspendedStart) {
            state = GenStateCompleted;
            throw arg;
          }

          if (context.dispatchException(arg)) {
            // If the dispatched exception was caught by a catch block,
            // then let that catch block handle the exception normally.
            method = "next";
            arg = undefined;
          }

        } else if (method === "return") {
          context.abrupt("return", arg);
        }

        state = GenStateExecuting;

        var record = tryCatch(innerFn, self, context);
        if (record.type === "normal") {
          // If an exception is thrown from innerFn, we leave state ===
          // GenStateExecuting and loop back for another invocation.
          state = context.done
            ? GenStateCompleted
            : GenStateSuspendedYield;

          var info = {
            value: record.arg,
            done: context.done
          };

          if (record.arg === ContinueSentinel) {
            if (context.delegate && method === "next") {
              // Deliberately forget the last sent value so that we don't
              // accidentally pass it on to the delegate.
              arg = undefined;
            }
          } else {
            return info;
          }

        } else if (record.type === "throw") {
          state = GenStateCompleted;
          // Dispatch the exception by looping back around to the
          // context.dispatchException(arg) call above.
          method = "throw";
          arg = record.arg;
        }
      }
    };
  }

  // Define Generator.prototype.{next,throw,return} in terms of the
  // unified ._invoke helper method.
  defineIteratorMethods(Gp);

  Gp[iteratorSymbol] = function() {
    return this;
  };

  Gp.toString = function() {
    return "[object Generator]";
  };

  function pushTryEntry(locs) {
    var entry = { tryLoc: locs[0] };

    if (1 in locs) {
      entry.catchLoc = locs[1];
    }

    if (2 in locs) {
      entry.finallyLoc = locs[2];
      entry.afterLoc = locs[3];
    }

    this.tryEntries.push(entry);
  }

  function resetTryEntry(entry) {
    var record = entry.completion || {};
    record.type = "normal";
    delete record.arg;
    entry.completion = record;
  }

  function Context(tryLocsList) {
    // The root entry object (effectively a try statement without a catch
    // or a finally block) gives us a place to store values thrown from
    // locations where there is no enclosing try statement.
    this.tryEntries = [{ tryLoc: "root" }];
    tryLocsList.forEach(pushTryEntry, this);
    this.reset(true);
  }

  runtime.keys = function(object) {
    var keys = [];
    for (var key in object) {
      keys.push(key);
    }
    keys.reverse();

    // Rather than returning an object with a next method, we keep
    // things simple and return the next function itself.
    return function next() {
      while (keys.length) {
        var key = keys.pop();
        if (key in object) {
          next.value = key;
          next.done = false;
          return next;
        }
      }

      // To avoid creating an additional object, we just hang the .value
      // and .done properties off the next function object itself. This
      // also ensures that the minifier will not anonymize the function.
      next.done = true;
      return next;
    };
  };

  function values(iterable) {
    if (iterable) {
      var iteratorMethod = iterable[iteratorSymbol];
      if (iteratorMethod) {
        return iteratorMethod.call(iterable);
      }

      if (typeof iterable.next === "function") {
        return iterable;
      }

      if (!isNaN(iterable.length)) {
        var i = -1, next = function next() {
          while (++i < iterable.length) {
            if (hasOwn.call(iterable, i)) {
              next.value = iterable[i];
              next.done = false;
              return next;
            }
          }

          next.value = undefined;
          next.done = true;

          return next;
        };

        return next.next = next;
      }
    }

    // Return an iterator with no values.
    return { next: doneResult };
  }
  runtime.values = values;

  function doneResult() {
    return { value: undefined, done: true };
  }

  Context.prototype = {
    constructor: Context,

    reset: function(skipTempReset) {
      this.prev = 0;
      this.next = 0;
      this.sent = undefined;
      this.done = false;
      this.delegate = null;

      this.tryEntries.forEach(resetTryEntry);

      if (!skipTempReset) {
        for (var name in this) {
          // Not sure about the optimal order of these conditions:
          if (name.charAt(0) === "t" &&
              hasOwn.call(this, name) &&
              !isNaN(+name.slice(1))) {
            this[name] = undefined;
          }
        }
      }
    },

    stop: function() {
      this.done = true;

      var rootEntry = this.tryEntries[0];
      var rootRecord = rootEntry.completion;
      if (rootRecord.type === "throw") {
        throw rootRecord.arg;
      }

      return this.rval;
    },

    dispatchException: function(exception) {
      if (this.done) {
        throw exception;
      }

      var context = this;
      function handle(loc, caught) {
        record.type = "throw";
        record.arg = exception;
        context.next = loc;
        return !!caught;
      }

      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        var record = entry.completion;

        if (entry.tryLoc === "root") {
          // Exception thrown outside of any try block that could handle
          // it, so set the completion value of the entire function to
          // throw the exception.
          return handle("end");
        }

        if (entry.tryLoc <= this.prev) {
          var hasCatch = hasOwn.call(entry, "catchLoc");
          var hasFinally = hasOwn.call(entry, "finallyLoc");

          if (hasCatch && hasFinally) {
            if (this.prev < entry.catchLoc) {
              return handle(entry.catchLoc, true);
            } else if (this.prev < entry.finallyLoc) {
              return handle(entry.finallyLoc);
            }

          } else if (hasCatch) {
            if (this.prev < entry.catchLoc) {
              return handle(entry.catchLoc, true);
            }

          } else if (hasFinally) {
            if (this.prev < entry.finallyLoc) {
              return handle(entry.finallyLoc);
            }

          } else {
            throw new Error("try statement without catch or finally");
          }
        }
      }
    },

    abrupt: function(type, arg) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.tryLoc <= this.prev &&
            hasOwn.call(entry, "finallyLoc") &&
            this.prev < entry.finallyLoc) {
          var finallyEntry = entry;
          break;
        }
      }

      if (finallyEntry &&
          (type === "break" ||
           type === "continue") &&
          finallyEntry.tryLoc <= arg &&
          arg <= finallyEntry.finallyLoc) {
        // Ignore the finally entry if control is not jumping to a
        // location outside the try/catch block.
        finallyEntry = null;
      }

      var record = finallyEntry ? finallyEntry.completion : {};
      record.type = type;
      record.arg = arg;

      if (finallyEntry) {
        this.next = finallyEntry.finallyLoc;
      } else {
        this.complete(record);
      }

      return ContinueSentinel;
    },

    complete: function(record, afterLoc) {
      if (record.type === "throw") {
        throw record.arg;
      }

      if (record.type === "break" ||
          record.type === "continue") {
        this.next = record.arg;
      } else if (record.type === "return") {
        this.rval = record.arg;
        this.next = "end";
      } else if (record.type === "normal" && afterLoc) {
        this.next = afterLoc;
      }
    },

    finish: function(finallyLoc) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.finallyLoc === finallyLoc) {
          this.complete(entry.completion, entry.afterLoc);
          resetTryEntry(entry);
          return ContinueSentinel;
        }
      }
    },

    "catch": function(tryLoc) {
      for (var i = this.tryEntries.length - 1; i >= 0; --i) {
        var entry = this.tryEntries[i];
        if (entry.tryLoc === tryLoc) {
          var record = entry.completion;
          if (record.type === "throw") {
            var thrown = record.arg;
            resetTryEntry(entry);
          }
          return thrown;
        }
      }

      // The context.catch method must only be called with a location
      // argument that corresponds to a known catch block.
      throw new Error("illegal catch attempt");
    },

    delegateYield: function(iterable, resultName, nextLoc) {
      this.delegate = {
        iterator: values(iterable),
        resultName: resultName,
        nextLoc: nextLoc
      };

      return ContinueSentinel;
    }
  };
})(
  // Among the various tricks for obtaining a reference to the global
  // object, this seems to be the most reliable technique that does not
  // use indirect eval (which violates Content Security Policy).
  typeof global === "object" ? global :
  typeof window === "object" ? window :
  typeof self === "object" ? self : this
);

}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
},{}]},{},[1]);

!function(e){function r(e,r,o){return 4===arguments.length?t.apply(this,arguments):void n(e,{declarative:!0,deps:r,declare:o})}function t(e,r,t,o){n(e,{declarative:!1,deps:r,executingRequire:t,execute:o})}function n(e,r){r.name=e,e in g||(g[e]=r),r.normalizedDeps=r.deps}function o(e,r){if(r[e.groupIndex]=r[e.groupIndex]||[],-1==m.call(r[e.groupIndex],e)){r[e.groupIndex].push(e);for(var t=0,n=e.normalizedDeps.length;n>t;t++){var a=e.normalizedDeps[t],u=g[a];if(u&&!u.evaluated){var d=e.groupIndex+(u.declarative!=e.declarative);if(void 0===u.groupIndex||u.groupIndex<d){if(void 0!==u.groupIndex&&(r[u.groupIndex].splice(m.call(r[u.groupIndex],u),1),0==r[u.groupIndex].length))throw new TypeError("Mixed dependency cycle detected");u.groupIndex=d}o(u,r)}}}}function a(e){var r=g[e];r.groupIndex=0;var t=[];o(r,t);for(var n=!!r.declarative==t.length%2,a=t.length-1;a>=0;a--){for(var u=t[a],i=0;i<u.length;i++){var s=u[i];n?d(s):l(s)}n=!n}}function u(e){return D[e]||(D[e]={name:e,dependencies:[],exports:{},importers:[]})}function d(r){if(!r.module){var t=r.module=u(r.name),n=r.module.exports,o=r.declare.call(e,function(e,r){if(t.locked=!0,"object"==typeof e)for(var o in e)n[o]=e[o];else n[e]=r;for(var a=0,u=t.importers.length;u>a;a++){var d=t.importers[a];if(!d.locked)for(var i=0;i<d.dependencies.length;++i)d.dependencies[i]===t&&d.setters[i](n)}return t.locked=!1,r},r.name);t.setters=o.setters,t.execute=o.execute;for(var a=0,i=r.normalizedDeps.length;i>a;a++){var l,s=r.normalizedDeps[a],c=g[s],f=D[s];f?l=f.exports:c&&!c.declarative?l=c.esModule:c?(d(c),f=c.module,l=f.exports):l=v(s),f&&f.importers?(f.importers.push(t),t.dependencies.push(f)):t.dependencies.push(null),t.setters[a]&&t.setters[a](l)}}}function i(e){var r,t=g[e];if(t)t.declarative?p(e,[]):t.evaluated||l(t),r=t.module.exports;else if(r=v(e),!r)throw new Error("Unable to load dependency "+e+".");return(!t||t.declarative)&&r&&r.__useDefault?r["default"]:r}function l(r){if(!r.module){var t={},n=r.module={exports:t,id:r.name};if(!r.executingRequire)for(var o=0,a=r.normalizedDeps.length;a>o;o++){var u=r.normalizedDeps[o],d=g[u];d&&l(d)}r.evaluated=!0;var c=r.execute.call(e,function(e){for(var t=0,n=r.deps.length;n>t;t++)if(r.deps[t]==e)return i(r.normalizedDeps[t]);throw new TypeError("Module "+e+" not declared as a dependency.")},t,n);c&&(n.exports=c),t=n.exports,t&&t.__esModule?r.esModule=t:r.esModule=s(t)}}function s(e){var r={};if("object"==typeof e||"function"==typeof e){var t=e&&e.hasOwnProperty;if(h)for(var n in e)f(r,e,n)||c(r,e,n,t);else for(var n in e)c(r,e,n,t)}return r["default"]=e,y(r,"__useDefault",{value:!0}),r}function c(e,r,t,n){(!n||r.hasOwnProperty(t))&&(e[t]=r[t])}function f(e,r,t){try{var n;return(n=Object.getOwnPropertyDescriptor(r,t))&&y(e,t,n),!0}catch(o){return!1}}function p(r,t){var n=g[r];if(n&&!n.evaluated&&n.declarative){t.push(r);for(var o=0,a=n.normalizedDeps.length;a>o;o++){var u=n.normalizedDeps[o];-1==m.call(t,u)&&(g[u]?p(u,t):v(u))}n.evaluated||(n.evaluated=!0,n.module.execute.call(e))}}function v(e){if(I[e])return I[e];if("@node/"==e.substr(0,6))return _(e.substr(6));var r=g[e];if(!r)throw"Module "+e+" not present.";return a(e),p(e,[]),g[e]=void 0,r.declarative&&y(r.module.exports,"__esModule",{value:!0}),I[e]=r.declarative?r.module.exports:r.esModule}var g={},m=Array.prototype.indexOf||function(e){for(var r=0,t=this.length;t>r;r++)if(this[r]===e)return r;return-1},h=!0;try{Object.getOwnPropertyDescriptor({a:0},"a")}catch(x){h=!1}var y;!function(){try{Object.defineProperty({},"a",{})&&(y=Object.defineProperty)}catch(e){y=function(e,r,t){try{e[r]=t.value||t.get.call(e)}catch(n){}}}}();var D={},_="undefined"!=typeof System&&System._nodeRequire||"undefined"!=typeof require&&require.resolve&&"undefined"!=typeof process&&require,I={"@empty":{}};return function(e,n,o){return function(a){a(function(a){for(var u={_nodeRequire:_,register:r,registerDynamic:t,get:v,set:function(e,r){I[e]=r},newModule:function(e){return e}},d=0;d<n.length;d++)(function(e,r){r&&r.__esModule?I[e]=r:I[e]=s(r)})(n[d],arguments[d]);o(u);var i=v(e[0]);if(e.length>1)for(var d=1;d<e.length;d++)v(e[d]);return i.__useDefault?i["default"]:i})}}}("undefined"!=typeof self?self:global)

(["1","2"], [], function($__System) {
var require = this.require, exports = this.exports, module = this.module;
!function(e){function r(e,r){for(var n=e.split(".");n.length;)r=r[n.shift()];return r}function n(n){if("string"==typeof n)return r(n,e);if(!(n instanceof Array))throw new Error("Global exports must be a string or array.");for(var t={},o=!0,f=0;f<n.length;f++){var i=r(n[f],e);o&&(t["default"]=i,o=!1),t[n[f].split(".").pop()]=i}return t}function t(r){if(Object.keys)Object.keys(e).forEach(r);else for(var n in e)a.call(e,n)&&r(n)}function o(r){t(function(n){if(-1==l.call(s,n)){try{var t=e[n]}catch(o){s.push(n)}r(n,t)}})}var f,i=$__System,a=Object.prototype.hasOwnProperty,l=Array.prototype.indexOf||function(e){for(var r=0,n=this.length;n>r;r++)if(this[r]===e)return r;return-1},s=["_g","sessionStorage","localStorage","clipboardData","frames","frameElement","external","mozAnimationStartTime","webkitStorageInfo","webkitIndexedDB","mozInnerScreenY","mozInnerScreenX"];i.set("@@global-helpers",i.newModule({prepareGlobal:function(r,t,i){var a=e.define;e.define=void 0;var l;if(i){l={};for(var s in i)l[s]=e[s],e[s]=i[s]}return t||(f={},o(function(e,r){f[e]=r})),function(){var r;if(t)r=n(t);else{r={};var i,s;o(function(e,n){f[e]!==n&&"undefined"!=typeof n&&(r[e]=n,"undefined"!=typeof i?s||i===n||(s=!0):i=n)}),r=s?r:i}if(l)for(var u in l)e[u]=l[u];return e.define=a,r}}}))}("undefined"!=typeof self?self:global);
$__System.registerDynamic("3", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var BaseWrappedException = (function(_super) {
    __extends(BaseWrappedException, _super);
    function BaseWrappedException(message) {
      _super.call(this, message);
    }
    Object.defineProperty(BaseWrappedException.prototype, "wrapperMessage", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "wrapperStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalException", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "context", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "message", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    return BaseWrappedException;
  }(Error));
  exports.BaseWrappedException = BaseWrappedException;
  return module.exports;
});

$__System.registerDynamic("4", ["5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('5');
  exports.Map = lang_1.global.Map;
  exports.Set = lang_1.global.Set;
  var createMapFromPairs = (function() {
    try {
      if (new exports.Map([[1, 2]]).size === 1) {
        return function createMapFromPairs(pairs) {
          return new exports.Map(pairs);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromPairs(pairs) {
      var map = new exports.Map();
      for (var i = 0; i < pairs.length; i++) {
        var pair = pairs[i];
        map.set(pair[0], pair[1]);
      }
      return map;
    };
  })();
  var createMapFromMap = (function() {
    try {
      if (new exports.Map(new exports.Map())) {
        return function createMapFromMap(m) {
          return new exports.Map(m);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromMap(m) {
      var map = new exports.Map();
      m.forEach(function(v, k) {
        map.set(k, v);
      });
      return map;
    };
  })();
  var _clearValues = (function() {
    if ((new exports.Map()).keys().next) {
      return function _clearValues(m) {
        var keyIterator = m.keys();
        var k;
        while (!((k = keyIterator.next()).done)) {
          m.set(k.value, null);
        }
      };
    } else {
      return function _clearValuesWithForeEach(m) {
        m.forEach(function(v, k) {
          m.set(k, null);
        });
      };
    }
  })();
  var _arrayFromMap = (function() {
    try {
      if ((new exports.Map()).values().next) {
        return function createArrayFromMap(m, getValues) {
          return getValues ? Array.from(m.values()) : Array.from(m.keys());
        };
      }
    } catch (e) {}
    return function createArrayFromMapWithForeach(m, getValues) {
      var res = ListWrapper.createFixedSize(m.size),
          i = 0;
      m.forEach(function(v, k) {
        res[i] = getValues ? v : k;
        i++;
      });
      return res;
    };
  })();
  var MapWrapper = (function() {
    function MapWrapper() {}
    MapWrapper.clone = function(m) {
      return createMapFromMap(m);
    };
    MapWrapper.createFromStringMap = function(stringMap) {
      var result = new exports.Map();
      for (var prop in stringMap) {
        result.set(prop, stringMap[prop]);
      }
      return result;
    };
    MapWrapper.toStringMap = function(m) {
      var r = {};
      m.forEach(function(v, k) {
        return r[k] = v;
      });
      return r;
    };
    MapWrapper.createFromPairs = function(pairs) {
      return createMapFromPairs(pairs);
    };
    MapWrapper.clearValues = function(m) {
      _clearValues(m);
    };
    MapWrapper.iterable = function(m) {
      return m;
    };
    MapWrapper.keys = function(m) {
      return _arrayFromMap(m, false);
    };
    MapWrapper.values = function(m) {
      return _arrayFromMap(m, true);
    };
    return MapWrapper;
  }());
  exports.MapWrapper = MapWrapper;
  var StringMapWrapper = (function() {
    function StringMapWrapper() {}
    StringMapWrapper.create = function() {
      return {};
    };
    StringMapWrapper.contains = function(map, key) {
      return map.hasOwnProperty(key);
    };
    StringMapWrapper.get = function(map, key) {
      return map.hasOwnProperty(key) ? map[key] : undefined;
    };
    StringMapWrapper.set = function(map, key, value) {
      map[key] = value;
    };
    StringMapWrapper.keys = function(map) {
      return Object.keys(map);
    };
    StringMapWrapper.values = function(map) {
      return Object.keys(map).reduce(function(r, a) {
        r.push(map[a]);
        return r;
      }, []);
    };
    StringMapWrapper.isEmpty = function(map) {
      for (var prop in map) {
        return false;
      }
      return true;
    };
    StringMapWrapper.delete = function(map, key) {
      delete map[key];
    };
    StringMapWrapper.forEach = function(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    };
    StringMapWrapper.merge = function(m1, m2) {
      var m = {};
      for (var attr in m1) {
        if (m1.hasOwnProperty(attr)) {
          m[attr] = m1[attr];
        }
      }
      for (var attr in m2) {
        if (m2.hasOwnProperty(attr)) {
          m[attr] = m2[attr];
        }
      }
      return m;
    };
    StringMapWrapper.equals = function(m1, m2) {
      var k1 = Object.keys(m1);
      var k2 = Object.keys(m2);
      if (k1.length != k2.length) {
        return false;
      }
      var key;
      for (var i = 0; i < k1.length; i++) {
        key = k1[i];
        if (m1[key] !== m2[key]) {
          return false;
        }
      }
      return true;
    };
    return StringMapWrapper;
  }());
  exports.StringMapWrapper = StringMapWrapper;
  var ListWrapper = (function() {
    function ListWrapper() {}
    ListWrapper.createFixedSize = function(size) {
      return new Array(size);
    };
    ListWrapper.createGrowableSize = function(size) {
      return new Array(size);
    };
    ListWrapper.clone = function(array) {
      return array.slice(0);
    };
    ListWrapper.forEachWithIndex = function(array, fn) {
      for (var i = 0; i < array.length; i++) {
        fn(array[i], i);
      }
    };
    ListWrapper.first = function(array) {
      if (!array)
        return null;
      return array[0];
    };
    ListWrapper.last = function(array) {
      if (!array || array.length == 0)
        return null;
      return array[array.length - 1];
    };
    ListWrapper.indexOf = function(array, value, startIndex) {
      if (startIndex === void 0) {
        startIndex = 0;
      }
      return array.indexOf(value, startIndex);
    };
    ListWrapper.contains = function(list, el) {
      return list.indexOf(el) !== -1;
    };
    ListWrapper.reversed = function(array) {
      var a = ListWrapper.clone(array);
      return a.reverse();
    };
    ListWrapper.concat = function(a, b) {
      return a.concat(b);
    };
    ListWrapper.insert = function(list, index, value) {
      list.splice(index, 0, value);
    };
    ListWrapper.removeAt = function(list, index) {
      var res = list[index];
      list.splice(index, 1);
      return res;
    };
    ListWrapper.removeAll = function(list, items) {
      for (var i = 0; i < items.length; ++i) {
        var index = list.indexOf(items[i]);
        list.splice(index, 1);
      }
    };
    ListWrapper.remove = function(list, el) {
      var index = list.indexOf(el);
      if (index > -1) {
        list.splice(index, 1);
        return true;
      }
      return false;
    };
    ListWrapper.clear = function(list) {
      list.length = 0;
    };
    ListWrapper.isEmpty = function(list) {
      return list.length == 0;
    };
    ListWrapper.fill = function(list, value, start, end) {
      if (start === void 0) {
        start = 0;
      }
      if (end === void 0) {
        end = null;
      }
      list.fill(value, start, end === null ? list.length : end);
    };
    ListWrapper.equals = function(a, b) {
      if (a.length != b.length)
        return false;
      for (var i = 0; i < a.length; ++i) {
        if (a[i] !== b[i])
          return false;
      }
      return true;
    };
    ListWrapper.slice = function(l, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return l.slice(from, to === null ? undefined : to);
    };
    ListWrapper.splice = function(l, from, length) {
      return l.splice(from, length);
    };
    ListWrapper.sort = function(l, compareFn) {
      if (lang_1.isPresent(compareFn)) {
        l.sort(compareFn);
      } else {
        l.sort();
      }
    };
    ListWrapper.toString = function(l) {
      return l.toString();
    };
    ListWrapper.toJSON = function(l) {
      return JSON.stringify(l);
    };
    ListWrapper.maximum = function(list, predicate) {
      if (list.length == 0) {
        return null;
      }
      var solution = null;
      var maxValue = -Infinity;
      for (var index = 0; index < list.length; index++) {
        var candidate = list[index];
        if (lang_1.isBlank(candidate)) {
          continue;
        }
        var candidateValue = predicate(candidate);
        if (candidateValue > maxValue) {
          solution = candidate;
          maxValue = candidateValue;
        }
      }
      return solution;
    };
    ListWrapper.flatten = function(list) {
      var target = [];
      _flattenArray(list, target);
      return target;
    };
    ListWrapper.addAll = function(list, source) {
      for (var i = 0; i < source.length; i++) {
        list.push(source[i]);
      }
    };
    return ListWrapper;
  }());
  exports.ListWrapper = ListWrapper;
  function _flattenArray(source, target) {
    if (lang_1.isPresent(source)) {
      for (var i = 0; i < source.length; i++) {
        var item = source[i];
        if (lang_1.isArray(item)) {
          _flattenArray(item, target);
        } else {
          target.push(item);
        }
      }
    }
    return target;
  }
  function isListLikeIterable(obj) {
    if (!lang_1.isJsObject(obj))
      return false;
    return lang_1.isArray(obj) || (!(obj instanceof exports.Map) && lang_1.getSymbolIterator() in obj);
  }
  exports.isListLikeIterable = isListLikeIterable;
  function areIterablesEqual(a, b, comparator) {
    var iterator1 = a[lang_1.getSymbolIterator()]();
    var iterator2 = b[lang_1.getSymbolIterator()]();
    while (true) {
      var item1 = iterator1.next();
      var item2 = iterator2.next();
      if (item1.done && item2.done)
        return true;
      if (item1.done || item2.done)
        return false;
      if (!comparator(item1.value, item2.value))
        return false;
    }
  }
  exports.areIterablesEqual = areIterablesEqual;
  function iterateListLike(obj, fn) {
    if (lang_1.isArray(obj)) {
      for (var i = 0; i < obj.length; i++) {
        fn(obj[i]);
      }
    } else {
      var iterator = obj[lang_1.getSymbolIterator()]();
      var item;
      while (!((item = iterator.next()).done)) {
        fn(item.value);
      }
    }
  }
  exports.iterateListLike = iterateListLike;
  var createSetFromList = (function() {
    var test = new exports.Set([1, 2, 3]);
    if (test.size === 3) {
      return function createSetFromList(lst) {
        return new exports.Set(lst);
      };
    } else {
      return function createSetAndPopulateFromList(lst) {
        var res = new exports.Set(lst);
        if (res.size !== lst.length) {
          for (var i = 0; i < lst.length; i++) {
            res.add(lst[i]);
          }
        }
        return res;
      };
    }
  })();
  var SetWrapper = (function() {
    function SetWrapper() {}
    SetWrapper.createFromList = function(lst) {
      return createSetFromList(lst);
    };
    SetWrapper.has = function(s, key) {
      return s.has(key);
    };
    SetWrapper.delete = function(m, k) {
      m.delete(k);
    };
    return SetWrapper;
  }());
  exports.SetWrapper = SetWrapper;
  return module.exports;
});

$__System.registerDynamic("6", ["5", "3", "4"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('5');
  var base_wrapped_exception_1 = $__require('3');
  var collection_1 = $__require('4');
  var _ArrayLogger = (function() {
    function _ArrayLogger() {
      this.res = [];
    }
    _ArrayLogger.prototype.log = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logError = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroup = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroupEnd = function() {};
    ;
    return _ArrayLogger;
  }());
  var ExceptionHandler = (function() {
    function ExceptionHandler(_logger, _rethrowException) {
      if (_rethrowException === void 0) {
        _rethrowException = true;
      }
      this._logger = _logger;
      this._rethrowException = _rethrowException;
    }
    ExceptionHandler.exceptionToString = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var l = new _ArrayLogger();
      var e = new ExceptionHandler(l, false);
      e.call(exception, stackTrace, reason);
      return l.res.join("\n");
    };
    ExceptionHandler.prototype.call = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var originalException = this._findOriginalException(exception);
      var originalStack = this._findOriginalStack(exception);
      var context = this._findContext(exception);
      this._logger.logGroup("EXCEPTION: " + this._extractMessage(exception));
      if (lang_1.isPresent(stackTrace) && lang_1.isBlank(originalStack)) {
        this._logger.logError("STACKTRACE:");
        this._logger.logError(this._longStackTrace(stackTrace));
      }
      if (lang_1.isPresent(reason)) {
        this._logger.logError("REASON: " + reason);
      }
      if (lang_1.isPresent(originalException)) {
        this._logger.logError("ORIGINAL EXCEPTION: " + this._extractMessage(originalException));
      }
      if (lang_1.isPresent(originalStack)) {
        this._logger.logError("ORIGINAL STACKTRACE:");
        this._logger.logError(this._longStackTrace(originalStack));
      }
      if (lang_1.isPresent(context)) {
        this._logger.logError("ERROR CONTEXT:");
        this._logger.logError(context);
      }
      this._logger.logGroupEnd();
      if (this._rethrowException)
        throw exception;
    };
    ExceptionHandler.prototype._extractMessage = function(exception) {
      return exception instanceof base_wrapped_exception_1.BaseWrappedException ? exception.wrapperMessage : exception.toString();
    };
    ExceptionHandler.prototype._longStackTrace = function(stackTrace) {
      return collection_1.isListLikeIterable(stackTrace) ? stackTrace.join("\n\n-----async gap-----\n") : stackTrace.toString();
    };
    ExceptionHandler.prototype._findContext = function(exception) {
      try {
        if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
          return null;
        return lang_1.isPresent(exception.context) ? exception.context : this._findContext(exception.originalException);
      } catch (e) {
        return null;
      }
    };
    ExceptionHandler.prototype._findOriginalException = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception.originalException;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
      }
      return e;
    };
    ExceptionHandler.prototype._findOriginalStack = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception;
      var stack = exception.originalStack;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
        if (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
          stack = e.originalStack;
        }
      }
      return stack;
    };
    return ExceptionHandler;
  }());
  exports.ExceptionHandler = ExceptionHandler;
  return module.exports;
});

$__System.registerDynamic("7", ["3", "6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var base_wrapped_exception_1 = $__require('3');
  var exception_handler_1 = $__require('6');
  var exception_handler_2 = $__require('6');
  exports.ExceptionHandler = exception_handler_2.ExceptionHandler;
  var BaseException = (function(_super) {
    __extends(BaseException, _super);
    function BaseException(message) {
      if (message === void 0) {
        message = "--";
      }
      _super.call(this, message);
      this.message = message;
      this.stack = (new Error(message)).stack;
    }
    BaseException.prototype.toString = function() {
      return this.message;
    };
    return BaseException;
  }(Error));
  exports.BaseException = BaseException;
  var WrappedException = (function(_super) {
    __extends(WrappedException, _super);
    function WrappedException(_wrapperMessage, _originalException, _originalStack, _context) {
      _super.call(this, _wrapperMessage);
      this._wrapperMessage = _wrapperMessage;
      this._originalException = _originalException;
      this._originalStack = _originalStack;
      this._context = _context;
      this._wrapperStack = (new Error(_wrapperMessage)).stack;
    }
    Object.defineProperty(WrappedException.prototype, "wrapperMessage", {
      get: function() {
        return this._wrapperMessage;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "wrapperStack", {
      get: function() {
        return this._wrapperStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalException", {
      get: function() {
        return this._originalException;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalStack", {
      get: function() {
        return this._originalStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "context", {
      get: function() {
        return this._context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "message", {
      get: function() {
        return exception_handler_1.ExceptionHandler.exceptionToString(this);
      },
      enumerable: true,
      configurable: true
    });
    WrappedException.prototype.toString = function() {
      return this.message;
    };
    return WrappedException;
  }(base_wrapped_exception_1.BaseWrappedException));
  exports.WrappedException = WrappedException;
  function makeTypeError(message) {
    return new TypeError(message);
  }
  exports.makeTypeError = makeTypeError;
  function unimplemented() {
    throw new BaseException('unimplemented');
  }
  exports.unimplemented = unimplemented;
  return module.exports;
});

$__System.registerDynamic("8", ["a", "7", "5", "9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var compiler_1 = $__require('a');
  var exceptions_1 = $__require('7');
  var lang_1 = $__require('5');
  var promise_1 = $__require('9');
  var CachedXHR = (function(_super) {
    __extends(CachedXHR, _super);
    function CachedXHR() {
      _super.call(this);
      this._cache = lang_1.global.$templateCache;
      if (this._cache == null) {
        throw new exceptions_1.BaseException('CachedXHR: Template cache was not found in $templateCache.');
      }
    }
    CachedXHR.prototype.get = function(url) {
      if (this._cache.hasOwnProperty(url)) {
        return promise_1.PromiseWrapper.resolve(this._cache[url]);
      } else {
        return promise_1.PromiseWrapper.reject('CachedXHR: Did not find cached template for ' + url, null);
      }
    };
    return CachedXHR;
  }(compiler_1.XHR));
  exports.CachedXHR = CachedXHR;
  return module.exports;
});

$__System.registerDynamic("b", ["11", "c", "d", "e", "f", "10"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var compile_metadata_1 = $__require('c');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var util_1 = $__require('10');
  var _COMPONENT_FACTORY_IDENTIFIER = new compile_metadata_1.CompileIdentifierMetadata({
    name: 'ComponentFactory',
    runtime: core_1.ComponentFactory,
    moduleUrl: util_1.assetUrl('core', 'linker/component_factory')
  });
  var SourceModule = (function() {
    function SourceModule(moduleUrl, source) {
      this.moduleUrl = moduleUrl;
      this.source = source;
    }
    return SourceModule;
  }());
  exports.SourceModule = SourceModule;
  var StyleSheetSourceWithImports = (function() {
    function StyleSheetSourceWithImports(source, importedUrls) {
      this.source = source;
      this.importedUrls = importedUrls;
    }
    return StyleSheetSourceWithImports;
  }());
  exports.StyleSheetSourceWithImports = StyleSheetSourceWithImports;
  var NormalizedComponentWithViewDirectives = (function() {
    function NormalizedComponentWithViewDirectives(component, directives, pipes) {
      this.component = component;
      this.directives = directives;
      this.pipes = pipes;
    }
    return NormalizedComponentWithViewDirectives;
  }());
  exports.NormalizedComponentWithViewDirectives = NormalizedComponentWithViewDirectives;
  var OfflineCompiler = (function() {
    function OfflineCompiler(_directiveNormalizer, _templateParser, _styleCompiler, _viewCompiler, _outputEmitter, _xhr) {
      this._directiveNormalizer = _directiveNormalizer;
      this._templateParser = _templateParser;
      this._styleCompiler = _styleCompiler;
      this._viewCompiler = _viewCompiler;
      this._outputEmitter = _outputEmitter;
      this._xhr = _xhr;
    }
    OfflineCompiler.prototype.normalizeDirectiveMetadata = function(directive) {
      return this._directiveNormalizer.normalizeDirective(directive);
    };
    OfflineCompiler.prototype.compileTemplates = function(components) {
      var _this = this;
      if (components.length === 0) {
        throw new exceptions_1.BaseException('No components given');
      }
      var statements = [];
      var exportedVars = [];
      var moduleUrl = _templateModuleUrl(components[0].component);
      components.forEach(function(componentWithDirs) {
        var compMeta = componentWithDirs.component;
        _assertComponent(compMeta);
        var compViewFactoryVar = _this._compileComponent(compMeta, componentWithDirs.directives, componentWithDirs.pipes, statements);
        exportedVars.push(compViewFactoryVar);
        var hostMeta = compile_metadata_1.createHostComponentMeta(compMeta.type, compMeta.selector);
        var hostViewFactoryVar = _this._compileComponent(hostMeta, [compMeta], [], statements);
        var compFactoryVar = compMeta.type.name + "NgFactory";
        statements.push(o.variable(compFactoryVar).set(o.importExpr(_COMPONENT_FACTORY_IDENTIFIER, [o.importType(compMeta.type)]).instantiate([o.literal(compMeta.selector), o.variable(hostViewFactoryVar), o.importExpr(compMeta.type)], o.importType(_COMPONENT_FACTORY_IDENTIFIER, [o.importType(compMeta.type)], [o.TypeModifier.Const]))).toDeclStmt(null, [o.StmtModifier.Final]));
        exportedVars.push(compFactoryVar);
      });
      return this._codegenSourceModule(moduleUrl, statements, exportedVars);
    };
    OfflineCompiler.prototype.loadAndCompileStylesheet = function(stylesheetUrl, shim, suffix) {
      var _this = this;
      return this._xhr.get(stylesheetUrl).then(function(cssText) {
        var compileResult = _this._styleCompiler.compileStylesheet(stylesheetUrl, cssText, shim);
        var importedUrls = [];
        compileResult.dependencies.forEach(function(dep) {
          importedUrls.push(dep.moduleUrl);
          dep.valuePlaceholder.moduleUrl = _stylesModuleUrl(dep.moduleUrl, dep.isShimmed, suffix);
        });
        return new StyleSheetSourceWithImports(_this._codgenStyles(stylesheetUrl, shim, suffix, compileResult), importedUrls);
      });
    };
    OfflineCompiler.prototype._compileComponent = function(compMeta, directives, pipes, targetStatements) {
      var styleResult = this._styleCompiler.compileComponent(compMeta);
      var parsedTemplate = this._templateParser.parse(compMeta, compMeta.template.template, directives, pipes, compMeta.type.name);
      var viewResult = this._viewCompiler.compileComponent(compMeta, parsedTemplate, o.variable(styleResult.stylesVar), pipes);
      collection_1.ListWrapper.addAll(targetStatements, _resolveStyleStatements(compMeta.type.moduleUrl, styleResult));
      collection_1.ListWrapper.addAll(targetStatements, _resolveViewStatements(viewResult));
      return viewResult.viewFactoryVar;
    };
    OfflineCompiler.prototype._codgenStyles = function(inputUrl, shim, suffix, stylesCompileResult) {
      return this._codegenSourceModule(_stylesModuleUrl(inputUrl, shim, suffix), stylesCompileResult.statements, [stylesCompileResult.stylesVar]);
    };
    OfflineCompiler.prototype._codegenSourceModule = function(moduleUrl, statements, exportedVars) {
      return new SourceModule(moduleUrl, this._outputEmitter.emitStatements(moduleUrl, statements, exportedVars));
    };
    return OfflineCompiler;
  }());
  exports.OfflineCompiler = OfflineCompiler;
  function _resolveViewStatements(compileResult) {
    compileResult.dependencies.forEach(function(dep) {
      dep.factoryPlaceholder.moduleUrl = _templateModuleUrl(dep.comp);
    });
    return compileResult.statements;
  }
  function _resolveStyleStatements(containingModuleUrl, compileResult) {
    var containingSuffix = _splitSuffix(containingModuleUrl)[1];
    compileResult.dependencies.forEach(function(dep) {
      dep.valuePlaceholder.moduleUrl = _stylesModuleUrl(dep.moduleUrl, dep.isShimmed, containingSuffix);
    });
    return compileResult.statements;
  }
  function _templateModuleUrl(comp) {
    var urlWithSuffix = _splitSuffix(comp.type.moduleUrl);
    return urlWithSuffix[0] + ".ngfactory" + urlWithSuffix[1];
  }
  function _stylesModuleUrl(stylesheetUrl, shim, suffix) {
    return shim ? stylesheetUrl + ".shim" + suffix : "" + stylesheetUrl + suffix;
  }
  function _assertComponent(meta) {
    if (!meta.isComponent) {
      throw new exceptions_1.BaseException("Could not compile '" + meta.type.name + "' because it is not a component.");
    }
  }
  function _splitSuffix(path) {
    var lastDot = path.lastIndexOf('.');
    if (lastDot !== -1) {
      return [path.substring(0, lastDot), path.substring(lastDot)];
    } else {
      return [path, ''];
    }
  }
  return module.exports;
});

$__System.registerDynamic("12", ["13", "e", "14", "c", "15", "16"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var template_ast_1 = $__require('14');
  var compile_metadata_1 = $__require('c');
  var identifiers_1 = $__require('15');
  var parse_util_1 = $__require('16');
  var ProviderError = (function(_super) {
    __extends(ProviderError, _super);
    function ProviderError(message, span) {
      _super.call(this, span, message);
    }
    return ProviderError;
  }(parse_util_1.ParseError));
  exports.ProviderError = ProviderError;
  var ProviderViewContext = (function() {
    function ProviderViewContext(component, sourceSpan) {
      var _this = this;
      this.component = component;
      this.sourceSpan = sourceSpan;
      this.errors = [];
      this.viewQueries = _getViewQueries(component);
      this.viewProviders = new compile_metadata_1.CompileTokenMap();
      _normalizeProviders(component.viewProviders, sourceSpan, this.errors).forEach(function(provider) {
        if (lang_1.isBlank(_this.viewProviders.get(provider.token))) {
          _this.viewProviders.add(provider.token, true);
        }
      });
    }
    return ProviderViewContext;
  }());
  exports.ProviderViewContext = ProviderViewContext;
  var ProviderElementContext = (function() {
    function ProviderElementContext(_viewContext, _parent, _isViewRoot, _directiveAsts, attrs, refs, _sourceSpan) {
      var _this = this;
      this._viewContext = _viewContext;
      this._parent = _parent;
      this._isViewRoot = _isViewRoot;
      this._directiveAsts = _directiveAsts;
      this._sourceSpan = _sourceSpan;
      this._transformedProviders = new compile_metadata_1.CompileTokenMap();
      this._seenProviders = new compile_metadata_1.CompileTokenMap();
      this._hasViewContainer = false;
      this._attrs = {};
      attrs.forEach(function(attrAst) {
        return _this._attrs[attrAst.name] = attrAst.value;
      });
      var directivesMeta = _directiveAsts.map(function(directiveAst) {
        return directiveAst.directive;
      });
      this._allProviders = _resolveProvidersFromDirectives(directivesMeta, _sourceSpan, _viewContext.errors);
      this._contentQueries = _getContentQueries(directivesMeta);
      var queriedTokens = new compile_metadata_1.CompileTokenMap();
      this._allProviders.values().forEach(function(provider) {
        _this._addQueryReadsTo(provider.token, queriedTokens);
      });
      refs.forEach(function(refAst) {
        _this._addQueryReadsTo(new compile_metadata_1.CompileTokenMetadata({value: refAst.name}), queriedTokens);
      });
      if (lang_1.isPresent(queriedTokens.get(identifiers_1.identifierToken(identifiers_1.Identifiers.ViewContainerRef)))) {
        this._hasViewContainer = true;
      }
      this._allProviders.values().forEach(function(provider) {
        var eager = provider.eager || lang_1.isPresent(queriedTokens.get(provider.token));
        if (eager) {
          _this._getOrCreateLocalProvider(provider.providerType, provider.token, true);
        }
      });
    }
    ProviderElementContext.prototype.afterElement = function() {
      var _this = this;
      this._allProviders.values().forEach(function(provider) {
        _this._getOrCreateLocalProvider(provider.providerType, provider.token, false);
      });
    };
    Object.defineProperty(ProviderElementContext.prototype, "transformProviders", {
      get: function() {
        return this._transformedProviders.values();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ProviderElementContext.prototype, "transformedDirectiveAsts", {
      get: function() {
        var sortedProviderTypes = this._transformedProviders.values().map(function(provider) {
          return provider.token.identifier;
        });
        var sortedDirectives = collection_1.ListWrapper.clone(this._directiveAsts);
        collection_1.ListWrapper.sort(sortedDirectives, function(dir1, dir2) {
          return sortedProviderTypes.indexOf(dir1.directive.type) - sortedProviderTypes.indexOf(dir2.directive.type);
        });
        return sortedDirectives;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ProviderElementContext.prototype, "transformedHasViewContainer", {
      get: function() {
        return this._hasViewContainer;
      },
      enumerable: true,
      configurable: true
    });
    ProviderElementContext.prototype._addQueryReadsTo = function(token, queryReadTokens) {
      this._getQueriesFor(token).forEach(function(query) {
        var queryReadToken = lang_1.isPresent(query.read) ? query.read : token;
        if (lang_1.isBlank(queryReadTokens.get(queryReadToken))) {
          queryReadTokens.add(queryReadToken, true);
        }
      });
    };
    ProviderElementContext.prototype._getQueriesFor = function(token) {
      var result = [];
      var currentEl = this;
      var distance = 0;
      var queries;
      while (currentEl !== null) {
        queries = currentEl._contentQueries.get(token);
        if (lang_1.isPresent(queries)) {
          collection_1.ListWrapper.addAll(result, queries.filter(function(query) {
            return query.descendants || distance <= 1;
          }));
        }
        if (currentEl._directiveAsts.length > 0) {
          distance++;
        }
        currentEl = currentEl._parent;
      }
      queries = this._viewContext.viewQueries.get(token);
      if (lang_1.isPresent(queries)) {
        collection_1.ListWrapper.addAll(result, queries);
      }
      return result;
    };
    ProviderElementContext.prototype._getOrCreateLocalProvider = function(requestingProviderType, token, eager) {
      var _this = this;
      var resolvedProvider = this._allProviders.get(token);
      if (lang_1.isBlank(resolvedProvider) || ((requestingProviderType === template_ast_1.ProviderAstType.Directive || requestingProviderType === template_ast_1.ProviderAstType.PublicService) && resolvedProvider.providerType === template_ast_1.ProviderAstType.PrivateService) || ((requestingProviderType === template_ast_1.ProviderAstType.PrivateService || requestingProviderType === template_ast_1.ProviderAstType.PublicService) && resolvedProvider.providerType === template_ast_1.ProviderAstType.Builtin)) {
        return null;
      }
      var transformedProviderAst = this._transformedProviders.get(token);
      if (lang_1.isPresent(transformedProviderAst)) {
        return transformedProviderAst;
      }
      if (lang_1.isPresent(this._seenProviders.get(token))) {
        this._viewContext.errors.push(new ProviderError("Cannot instantiate cyclic dependency! " + token.name, this._sourceSpan));
        return null;
      }
      this._seenProviders.add(token, true);
      var transformedProviders = resolvedProvider.providers.map(function(provider) {
        var transformedUseValue = provider.useValue;
        var transformedUseExisting = provider.useExisting;
        var transformedDeps;
        if (lang_1.isPresent(provider.useExisting)) {
          var existingDiDep = _this._getDependency(resolvedProvider.providerType, new compile_metadata_1.CompileDiDependencyMetadata({token: provider.useExisting}), eager);
          if (lang_1.isPresent(existingDiDep.token)) {
            transformedUseExisting = existingDiDep.token;
          } else {
            transformedUseExisting = null;
            transformedUseValue = existingDiDep.value;
          }
        } else if (lang_1.isPresent(provider.useFactory)) {
          var deps = lang_1.isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
          transformedDeps = deps.map(function(dep) {
            return _this._getDependency(resolvedProvider.providerType, dep, eager);
          });
        } else if (lang_1.isPresent(provider.useClass)) {
          var deps = lang_1.isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
          transformedDeps = deps.map(function(dep) {
            return _this._getDependency(resolvedProvider.providerType, dep, eager);
          });
        }
        return _transformProvider(provider, {
          useExisting: transformedUseExisting,
          useValue: transformedUseValue,
          deps: transformedDeps
        });
      });
      transformedProviderAst = _transformProviderAst(resolvedProvider, {
        eager: eager,
        providers: transformedProviders
      });
      this._transformedProviders.add(token, transformedProviderAst);
      return transformedProviderAst;
    };
    ProviderElementContext.prototype._getLocalDependency = function(requestingProviderType, dep, eager) {
      if (eager === void 0) {
        eager = null;
      }
      if (dep.isAttribute) {
        var attrValue = this._attrs[dep.token.value];
        return new compile_metadata_1.CompileDiDependencyMetadata({
          isValue: true,
          value: lang_1.normalizeBlank(attrValue)
        });
      }
      if (lang_1.isPresent(dep.query) || lang_1.isPresent(dep.viewQuery)) {
        return dep;
      }
      if (lang_1.isPresent(dep.token)) {
        if ((requestingProviderType === template_ast_1.ProviderAstType.Directive || requestingProviderType === template_ast_1.ProviderAstType.Component)) {
          if (dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.Renderer)) || dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.ElementRef)) || dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.ChangeDetectorRef)) || dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.TemplateRef))) {
            return dep;
          }
          if (dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.ViewContainerRef))) {
            this._hasViewContainer = true;
          }
        }
        if (dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.Injector))) {
          return dep;
        }
        if (lang_1.isPresent(this._getOrCreateLocalProvider(requestingProviderType, dep.token, eager))) {
          return dep;
        }
      }
      return null;
    };
    ProviderElementContext.prototype._getDependency = function(requestingProviderType, dep, eager) {
      if (eager === void 0) {
        eager = null;
      }
      var currElement = this;
      var currEager = eager;
      var result = null;
      if (!dep.isSkipSelf) {
        result = this._getLocalDependency(requestingProviderType, dep, eager);
      }
      if (dep.isSelf) {
        if (lang_1.isBlank(result) && dep.isOptional) {
          result = new compile_metadata_1.CompileDiDependencyMetadata({
            isValue: true,
            value: null
          });
        }
      } else {
        while (lang_1.isBlank(result) && lang_1.isPresent(currElement._parent)) {
          var prevElement = currElement;
          currElement = currElement._parent;
          if (prevElement._isViewRoot) {
            currEager = false;
          }
          result = currElement._getLocalDependency(template_ast_1.ProviderAstType.PublicService, dep, currEager);
        }
        if (lang_1.isBlank(result)) {
          if (!dep.isHost || this._viewContext.component.type.isHost || identifiers_1.identifierToken(this._viewContext.component.type).equalsTo(dep.token) || lang_1.isPresent(this._viewContext.viewProviders.get(dep.token))) {
            result = dep;
          } else {
            result = dep.isOptional ? result = new compile_metadata_1.CompileDiDependencyMetadata({
              isValue: true,
              value: null
            }) : null;
          }
        }
      }
      if (lang_1.isBlank(result)) {
        this._viewContext.errors.push(new ProviderError("No provider for " + dep.token.name, this._sourceSpan));
      }
      return result;
    };
    return ProviderElementContext;
  }());
  exports.ProviderElementContext = ProviderElementContext;
  function _transformProvider(provider, _a) {
    var useExisting = _a.useExisting,
        useValue = _a.useValue,
        deps = _a.deps;
    return new compile_metadata_1.CompileProviderMetadata({
      token: provider.token,
      useClass: provider.useClass,
      useExisting: useExisting,
      useFactory: provider.useFactory,
      useValue: useValue,
      deps: deps,
      multi: provider.multi
    });
  }
  function _transformProviderAst(provider, _a) {
    var eager = _a.eager,
        providers = _a.providers;
    return new template_ast_1.ProviderAst(provider.token, provider.multiProvider, provider.eager || eager, providers, provider.providerType, provider.sourceSpan);
  }
  function _normalizeProviders(providers, sourceSpan, targetErrors, targetProviders) {
    if (targetProviders === void 0) {
      targetProviders = null;
    }
    if (lang_1.isBlank(targetProviders)) {
      targetProviders = [];
    }
    if (lang_1.isPresent(providers)) {
      providers.forEach(function(provider) {
        if (lang_1.isArray(provider)) {
          _normalizeProviders(provider, sourceSpan, targetErrors, targetProviders);
        } else {
          var normalizeProvider;
          if (provider instanceof compile_metadata_1.CompileProviderMetadata) {
            normalizeProvider = provider;
          } else if (provider instanceof compile_metadata_1.CompileTypeMetadata) {
            normalizeProvider = new compile_metadata_1.CompileProviderMetadata({
              token: new compile_metadata_1.CompileTokenMetadata({identifier: provider}),
              useClass: provider
            });
          } else {
            targetErrors.push(new ProviderError("Unknown provider type " + provider, sourceSpan));
          }
          if (lang_1.isPresent(normalizeProvider)) {
            targetProviders.push(normalizeProvider);
          }
        }
      });
    }
    return targetProviders;
  }
  function _resolveProvidersFromDirectives(directives, sourceSpan, targetErrors) {
    var providersByToken = new compile_metadata_1.CompileTokenMap();
    directives.forEach(function(directive) {
      var dirProvider = new compile_metadata_1.CompileProviderMetadata({
        token: new compile_metadata_1.CompileTokenMetadata({identifier: directive.type}),
        useClass: directive.type
      });
      _resolveProviders([dirProvider], directive.isComponent ? template_ast_1.ProviderAstType.Component : template_ast_1.ProviderAstType.Directive, true, sourceSpan, targetErrors, providersByToken);
    });
    var directivesWithComponentFirst = directives.filter(function(dir) {
      return dir.isComponent;
    }).concat(directives.filter(function(dir) {
      return !dir.isComponent;
    }));
    directivesWithComponentFirst.forEach(function(directive) {
      _resolveProviders(_normalizeProviders(directive.providers, sourceSpan, targetErrors), template_ast_1.ProviderAstType.PublicService, false, sourceSpan, targetErrors, providersByToken);
      _resolveProviders(_normalizeProviders(directive.viewProviders, sourceSpan, targetErrors), template_ast_1.ProviderAstType.PrivateService, false, sourceSpan, targetErrors, providersByToken);
    });
    return providersByToken;
  }
  function _resolveProviders(providers, providerType, eager, sourceSpan, targetErrors, targetProvidersByToken) {
    providers.forEach(function(provider) {
      var resolvedProvider = targetProvidersByToken.get(provider.token);
      if (lang_1.isPresent(resolvedProvider) && resolvedProvider.multiProvider !== provider.multi) {
        targetErrors.push(new ProviderError("Mixing multi and non multi provider is not possible for token " + resolvedProvider.token.name, sourceSpan));
      }
      if (lang_1.isBlank(resolvedProvider)) {
        resolvedProvider = new template_ast_1.ProviderAst(provider.token, provider.multi, eager, [provider], providerType, sourceSpan);
        targetProvidersByToken.add(provider.token, resolvedProvider);
      } else {
        if (!provider.multi) {
          collection_1.ListWrapper.clear(resolvedProvider.providers);
        }
        resolvedProvider.providers.push(provider);
      }
    });
  }
  function _getViewQueries(component) {
    var viewQueries = new compile_metadata_1.CompileTokenMap();
    if (lang_1.isPresent(component.viewQueries)) {
      component.viewQueries.forEach(function(query) {
        return _addQueryToTokenMap(viewQueries, query);
      });
    }
    component.type.diDeps.forEach(function(dep) {
      if (lang_1.isPresent(dep.viewQuery)) {
        _addQueryToTokenMap(viewQueries, dep.viewQuery);
      }
    });
    return viewQueries;
  }
  function _getContentQueries(directives) {
    var contentQueries = new compile_metadata_1.CompileTokenMap();
    directives.forEach(function(directive) {
      if (lang_1.isPresent(directive.queries)) {
        directive.queries.forEach(function(query) {
          return _addQueryToTokenMap(contentQueries, query);
        });
      }
      directive.type.diDeps.forEach(function(dep) {
        if (lang_1.isPresent(dep.query)) {
          _addQueryToTokenMap(contentQueries, dep.query);
        }
      });
    });
    return contentQueries;
  }
  function _addQueryToTokenMap(map, query) {
    query.selectors.forEach(function(token) {
      var entry = map.get(token);
      if (lang_1.isBlank(entry)) {
        entry = [];
        map.add(token, entry);
      }
      entry.push(query);
    });
  }
  return module.exports;
});

$__System.registerDynamic("17", ["11", "18", "e", "13", "d", "19", "1a", "1b", "1c", "16", "14", "1d", "1e", "1f", "20", "21", "10", "15", "12", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var __extends = (this && this.__extends) || function(d, b) {
      for (var p in b)
        if (b.hasOwnProperty(p))
          d[p] = b[p];
      function __() {
        this.constructor = d;
      }
      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
    var core_1 = $__require('11');
    var core_private_1 = $__require('18');
    var collection_1 = $__require('e');
    var lang_1 = $__require('13');
    var exceptions_1 = $__require('d');
    var ast_1 = $__require('19');
    var parser_1 = $__require('1a');
    var html_parser_1 = $__require('1b');
    var html_tags_1 = $__require('1c');
    var parse_util_1 = $__require('16');
    var template_ast_1 = $__require('14');
    var selector_1 = $__require('1d');
    var element_schema_registry_1 = $__require('1e');
    var template_preparser_1 = $__require('1f');
    var style_url_resolver_1 = $__require('20');
    var html_ast_1 = $__require('21');
    var util_1 = $__require('10');
    var identifiers_1 = $__require('15');
    var provider_parser_1 = $__require('12');
    var BIND_NAME_REGEXP = /^(?:(?:(?:(bind-)|(var-)|(let-)|(ref-|#)|(on-)|(bindon-))(.+))|\[\(([^\)]+)\)\]|\[([^\]]+)\]|\(([^\)]+)\))$/g;
    var TEMPLATE_ELEMENT = 'template';
    var TEMPLATE_ATTR = 'template';
    var TEMPLATE_ATTR_PREFIX = '*';
    var CLASS_ATTR = 'class';
    var PROPERTY_PARTS_SEPARATOR = '.';
    var ATTRIBUTE_PREFIX = 'attr';
    var CLASS_PREFIX = 'class';
    var STYLE_PREFIX = 'style';
    var TEXT_CSS_SELECTOR = selector_1.CssSelector.parse('*')[0];
    exports.TEMPLATE_TRANSFORMS = new core_1.OpaqueToken('TemplateTransforms');
    var TemplateParseError = (function(_super) {
      __extends(TemplateParseError, _super);
      function TemplateParseError(message, span, level) {
        _super.call(this, span, message, level);
      }
      return TemplateParseError;
    }(parse_util_1.ParseError));
    exports.TemplateParseError = TemplateParseError;
    var TemplateParseResult = (function() {
      function TemplateParseResult(templateAst, errors) {
        this.templateAst = templateAst;
        this.errors = errors;
      }
      return TemplateParseResult;
    }());
    exports.TemplateParseResult = TemplateParseResult;
    var TemplateParser = (function() {
      function TemplateParser(_exprParser, _schemaRegistry, _htmlParser, _console, transforms) {
        this._exprParser = _exprParser;
        this._schemaRegistry = _schemaRegistry;
        this._htmlParser = _htmlParser;
        this._console = _console;
        this.transforms = transforms;
      }
      TemplateParser.prototype.parse = function(component, template, directives, pipes, templateUrl) {
        var result = this.tryParse(component, template, directives, pipes, templateUrl);
        var warnings = result.errors.filter(function(error) {
          return error.level === parse_util_1.ParseErrorLevel.WARNING;
        });
        var errors = result.errors.filter(function(error) {
          return error.level === parse_util_1.ParseErrorLevel.FATAL;
        });
        if (warnings.length > 0) {
          this._console.warn("Template parse warnings:\n" + warnings.join('\n'));
        }
        if (errors.length > 0) {
          var errorString = errors.join('\n');
          throw new exceptions_1.BaseException("Template parse errors:\n" + errorString);
        }
        return result.templateAst;
      };
      TemplateParser.prototype.tryParse = function(component, template, directives, pipes, templateUrl) {
        var htmlAstWithErrors = this._htmlParser.parse(template, templateUrl);
        var errors = htmlAstWithErrors.errors;
        var result;
        if (htmlAstWithErrors.rootNodes.length > 0) {
          var uniqDirectives = removeDuplicates(directives);
          var uniqPipes = removeDuplicates(pipes);
          var providerViewContext = new provider_parser_1.ProviderViewContext(component, htmlAstWithErrors.rootNodes[0].sourceSpan);
          var parseVisitor = new TemplateParseVisitor(providerViewContext, uniqDirectives, uniqPipes, this._exprParser, this._schemaRegistry);
          result = html_ast_1.htmlVisitAll(parseVisitor, htmlAstWithErrors.rootNodes, EMPTY_ELEMENT_CONTEXT);
          errors = errors.concat(parseVisitor.errors).concat(providerViewContext.errors);
        } else {
          result = [];
        }
        if (errors.length > 0) {
          return new TemplateParseResult(result, errors);
        }
        if (lang_1.isPresent(this.transforms)) {
          this.transforms.forEach(function(transform) {
            result = template_ast_1.templateVisitAll(transform, result);
          });
        }
        return new TemplateParseResult(result, errors);
      };
      TemplateParser.decorators = [{type: core_1.Injectable}];
      TemplateParser.ctorParameters = [{type: parser_1.Parser}, {type: element_schema_registry_1.ElementSchemaRegistry}, {type: html_parser_1.HtmlParser}, {type: core_private_1.Console}, {
        type: undefined,
        decorators: [{type: core_1.Optional}, {
          type: core_1.Inject,
          args: [exports.TEMPLATE_TRANSFORMS]
        }]
      }];
      return TemplateParser;
    }());
    exports.TemplateParser = TemplateParser;
    var TemplateParseVisitor = (function() {
      function TemplateParseVisitor(providerViewContext, directives, pipes, _exprParser, _schemaRegistry) {
        var _this = this;
        this.providerViewContext = providerViewContext;
        this._exprParser = _exprParser;
        this._schemaRegistry = _schemaRegistry;
        this.errors = [];
        this.directivesIndex = new Map();
        this.ngContentCount = 0;
        this.selectorMatcher = new selector_1.SelectorMatcher();
        collection_1.ListWrapper.forEachWithIndex(directives, function(directive, index) {
          var selector = selector_1.CssSelector.parse(directive.selector);
          _this.selectorMatcher.addSelectables(selector, directive);
          _this.directivesIndex.set(directive, index);
        });
        this.pipesByName = new Map();
        pipes.forEach(function(pipe) {
          return _this.pipesByName.set(pipe.name, pipe);
        });
      }
      TemplateParseVisitor.prototype._reportError = function(message, sourceSpan, level) {
        if (level === void 0) {
          level = parse_util_1.ParseErrorLevel.FATAL;
        }
        this.errors.push(new TemplateParseError(message, sourceSpan, level));
      };
      TemplateParseVisitor.prototype._parseInterpolation = function(value, sourceSpan) {
        var sourceInfo = sourceSpan.start.toString();
        try {
          var ast = this._exprParser.parseInterpolation(value, sourceInfo);
          this._checkPipes(ast, sourceSpan);
          if (lang_1.isPresent(ast) && ast.ast.expressions.length > core_private_1.MAX_INTERPOLATION_VALUES) {
            throw new exceptions_1.BaseException("Only support at most " + core_private_1.MAX_INTERPOLATION_VALUES + " interpolation values!");
          }
          return ast;
        } catch (e) {
          this._reportError("" + e, sourceSpan);
          return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo);
        }
      };
      TemplateParseVisitor.prototype._parseAction = function(value, sourceSpan) {
        var sourceInfo = sourceSpan.start.toString();
        try {
          var ast = this._exprParser.parseAction(value, sourceInfo);
          this._checkPipes(ast, sourceSpan);
          return ast;
        } catch (e) {
          this._reportError("" + e, sourceSpan);
          return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo);
        }
      };
      TemplateParseVisitor.prototype._parseBinding = function(value, sourceSpan) {
        var sourceInfo = sourceSpan.start.toString();
        try {
          var ast = this._exprParser.parseBinding(value, sourceInfo);
          this._checkPipes(ast, sourceSpan);
          return ast;
        } catch (e) {
          this._reportError("" + e, sourceSpan);
          return this._exprParser.wrapLiteralPrimitive('ERROR', sourceInfo);
        }
      };
      TemplateParseVisitor.prototype._parseTemplateBindings = function(value, sourceSpan) {
        var _this = this;
        var sourceInfo = sourceSpan.start.toString();
        try {
          var bindingsResult = this._exprParser.parseTemplateBindings(value, sourceInfo);
          bindingsResult.templateBindings.forEach(function(binding) {
            if (lang_1.isPresent(binding.expression)) {
              _this._checkPipes(binding.expression, sourceSpan);
            }
          });
          bindingsResult.warnings.forEach(function(warning) {
            _this._reportError(warning, sourceSpan, parse_util_1.ParseErrorLevel.WARNING);
          });
          return bindingsResult.templateBindings;
        } catch (e) {
          this._reportError("" + e, sourceSpan);
          return [];
        }
      };
      TemplateParseVisitor.prototype._checkPipes = function(ast, sourceSpan) {
        var _this = this;
        if (lang_1.isPresent(ast)) {
          var collector = new PipeCollector();
          ast.visit(collector);
          collector.pipes.forEach(function(pipeName) {
            if (!_this.pipesByName.has(pipeName)) {
              _this._reportError("The pipe '" + pipeName + "' could not be found", sourceSpan);
            }
          });
        }
      };
      TemplateParseVisitor.prototype.visitExpansion = function(ast, context) {
        return null;
      };
      TemplateParseVisitor.prototype.visitExpansionCase = function(ast, context) {
        return null;
      };
      TemplateParseVisitor.prototype.visitText = function(ast, parent) {
        var ngContentIndex = parent.findNgContentIndex(TEXT_CSS_SELECTOR);
        var expr = this._parseInterpolation(ast.value, ast.sourceSpan);
        if (lang_1.isPresent(expr)) {
          return new template_ast_1.BoundTextAst(expr, ngContentIndex, ast.sourceSpan);
        } else {
          return new template_ast_1.TextAst(ast.value, ngContentIndex, ast.sourceSpan);
        }
      };
      TemplateParseVisitor.prototype.visitAttr = function(ast, contex) {
        return new template_ast_1.AttrAst(ast.name, ast.value, ast.sourceSpan);
      };
      TemplateParseVisitor.prototype.visitComment = function(ast, context) {
        return null;
      };
      TemplateParseVisitor.prototype.visitElement = function(element, parent) {
        var _this = this;
        var nodeName = element.name;
        var preparsedElement = template_preparser_1.preparseElement(element);
        if (preparsedElement.type === template_preparser_1.PreparsedElementType.SCRIPT || preparsedElement.type === template_preparser_1.PreparsedElementType.STYLE) {
          return null;
        }
        if (preparsedElement.type === template_preparser_1.PreparsedElementType.STYLESHEET && style_url_resolver_1.isStyleUrlResolvable(preparsedElement.hrefAttr)) {
          return null;
        }
        var matchableAttrs = [];
        var elementOrDirectiveProps = [];
        var elementOrDirectiveRefs = [];
        var elementVars = [];
        var events = [];
        var templateElementOrDirectiveProps = [];
        var templateMatchableAttrs = [];
        var templateElementVars = [];
        var hasInlineTemplates = false;
        var attrs = [];
        var lcElName = html_tags_1.splitNsName(nodeName.toLowerCase())[1];
        var isTemplateElement = lcElName == TEMPLATE_ELEMENT;
        element.attrs.forEach(function(attr) {
          var hasBinding = _this._parseAttr(isTemplateElement, attr, matchableAttrs, elementOrDirectiveProps, events, elementOrDirectiveRefs, elementVars);
          var hasTemplateBinding = _this._parseInlineTemplateBinding(attr, templateMatchableAttrs, templateElementOrDirectiveProps, templateElementVars);
          if (!hasBinding && !hasTemplateBinding) {
            attrs.push(_this.visitAttr(attr, null));
            matchableAttrs.push([attr.name, attr.value]);
          }
          if (hasTemplateBinding) {
            hasInlineTemplates = true;
          }
        });
        var elementCssSelector = createElementCssSelector(nodeName, matchableAttrs);
        var directiveMetas = this._parseDirectives(this.selectorMatcher, elementCssSelector);
        var references = [];
        var directiveAsts = this._createDirectiveAsts(isTemplateElement, element.name, directiveMetas, elementOrDirectiveProps, elementOrDirectiveRefs, element.sourceSpan, references);
        var elementProps = this._createElementPropertyAsts(element.name, elementOrDirectiveProps, directiveAsts);
        var isViewRoot = parent.isTemplateElement || hasInlineTemplates;
        var providerContext = new provider_parser_1.ProviderElementContext(this.providerViewContext, parent.providerContext, isViewRoot, directiveAsts, attrs, references, element.sourceSpan);
        var children = html_ast_1.htmlVisitAll(preparsedElement.nonBindable ? NON_BINDABLE_VISITOR : this, element.children, ElementContext.create(isTemplateElement, directiveAsts, isTemplateElement ? parent.providerContext : providerContext));
        providerContext.afterElement();
        var projectionSelector = lang_1.isPresent(preparsedElement.projectAs) ? selector_1.CssSelector.parse(preparsedElement.projectAs)[0] : elementCssSelector;
        var ngContentIndex = parent.findNgContentIndex(projectionSelector);
        var parsedElement;
        if (preparsedElement.type === template_preparser_1.PreparsedElementType.NG_CONTENT) {
          if (lang_1.isPresent(element.children) && element.children.length > 0) {
            this._reportError("<ng-content> element cannot have content. <ng-content> must be immediately followed by </ng-content>", element.sourceSpan);
          }
          parsedElement = new template_ast_1.NgContentAst(this.ngContentCount++, hasInlineTemplates ? null : ngContentIndex, element.sourceSpan);
        } else if (isTemplateElement) {
          this._assertAllEventsPublishedByDirectives(directiveAsts, events);
          this._assertNoComponentsNorElementBindingsOnTemplate(directiveAsts, elementProps, element.sourceSpan);
          parsedElement = new template_ast_1.EmbeddedTemplateAst(attrs, events, references, elementVars, providerContext.transformedDirectiveAsts, providerContext.transformProviders, providerContext.transformedHasViewContainer, children, hasInlineTemplates ? null : ngContentIndex, element.sourceSpan);
        } else {
          this._assertOnlyOneComponent(directiveAsts, element.sourceSpan);
          var ngContentIndex_1 = hasInlineTemplates ? null : parent.findNgContentIndex(projectionSelector);
          parsedElement = new template_ast_1.ElementAst(nodeName, attrs, elementProps, events, references, providerContext.transformedDirectiveAsts, providerContext.transformProviders, providerContext.transformedHasViewContainer, children, hasInlineTemplates ? null : ngContentIndex_1, element.sourceSpan);
        }
        if (hasInlineTemplates) {
          var templateCssSelector = createElementCssSelector(TEMPLATE_ELEMENT, templateMatchableAttrs);
          var templateDirectiveMetas = this._parseDirectives(this.selectorMatcher, templateCssSelector);
          var templateDirectiveAsts = this._createDirectiveAsts(true, element.name, templateDirectiveMetas, templateElementOrDirectiveProps, [], element.sourceSpan, []);
          var templateElementProps = this._createElementPropertyAsts(element.name, templateElementOrDirectiveProps, templateDirectiveAsts);
          this._assertNoComponentsNorElementBindingsOnTemplate(templateDirectiveAsts, templateElementProps, element.sourceSpan);
          var templateProviderContext = new provider_parser_1.ProviderElementContext(this.providerViewContext, parent.providerContext, parent.isTemplateElement, templateDirectiveAsts, [], [], element.sourceSpan);
          templateProviderContext.afterElement();
          parsedElement = new template_ast_1.EmbeddedTemplateAst([], [], [], templateElementVars, templateProviderContext.transformedDirectiveAsts, templateProviderContext.transformProviders, templateProviderContext.transformedHasViewContainer, [parsedElement], ngContentIndex, element.sourceSpan);
        }
        return parsedElement;
      };
      TemplateParseVisitor.prototype._parseInlineTemplateBinding = function(attr, targetMatchableAttrs, targetProps, targetVars) {
        var templateBindingsSource = null;
        if (attr.name == TEMPLATE_ATTR) {
          templateBindingsSource = attr.value;
        } else if (attr.name.startsWith(TEMPLATE_ATTR_PREFIX)) {
          var key = attr.name.substring(TEMPLATE_ATTR_PREFIX.length);
          templateBindingsSource = (attr.value.length == 0) ? key : key + ' ' + attr.value;
        }
        if (lang_1.isPresent(templateBindingsSource)) {
          var bindings = this._parseTemplateBindings(templateBindingsSource, attr.sourceSpan);
          for (var i = 0; i < bindings.length; i++) {
            var binding = bindings[i];
            if (binding.keyIsVar) {
              targetVars.push(new template_ast_1.VariableAst(binding.key, binding.name, attr.sourceSpan));
            } else if (lang_1.isPresent(binding.expression)) {
              this._parsePropertyAst(binding.key, binding.expression, attr.sourceSpan, targetMatchableAttrs, targetProps);
            } else {
              targetMatchableAttrs.push([binding.key, '']);
              this._parseLiteralAttr(binding.key, null, attr.sourceSpan, targetProps);
            }
          }
          return true;
        }
        return false;
      };
      TemplateParseVisitor.prototype._parseAttr = function(isTemplateElement, attr, targetMatchableAttrs, targetProps, targetEvents, targetRefs, targetVars) {
        var attrName = this._normalizeAttributeName(attr.name);
        var attrValue = attr.value;
        var bindParts = lang_1.RegExpWrapper.firstMatch(BIND_NAME_REGEXP, attrName);
        var hasBinding = false;
        if (lang_1.isPresent(bindParts)) {
          hasBinding = true;
          if (lang_1.isPresent(bindParts[1])) {
            this._parseProperty(bindParts[7], attrValue, attr.sourceSpan, targetMatchableAttrs, targetProps);
          } else if (lang_1.isPresent(bindParts[2])) {
            var identifier = bindParts[7];
            if (isTemplateElement) {
              this._reportError("\"var-\" on <template> elements is deprecated. Use \"let-\" instead!", attr.sourceSpan, parse_util_1.ParseErrorLevel.WARNING);
              this._parseVariable(identifier, attrValue, attr.sourceSpan, targetVars);
            } else {
              this._reportError("\"var-\" on non <template> elements is deprecated. Use \"ref-\" instead!", attr.sourceSpan, parse_util_1.ParseErrorLevel.WARNING);
              this._parseReference(identifier, attrValue, attr.sourceSpan, targetRefs);
            }
          } else if (lang_1.isPresent(bindParts[3])) {
            if (isTemplateElement) {
              var identifier = bindParts[7];
              this._parseVariable(identifier, attrValue, attr.sourceSpan, targetVars);
            } else {
              this._reportError("\"let-\" is only supported on template elements.", attr.sourceSpan);
            }
          } else if (lang_1.isPresent(bindParts[4])) {
            var identifier = bindParts[7];
            this._parseReference(identifier, attrValue, attr.sourceSpan, targetRefs);
          } else if (lang_1.isPresent(bindParts[5])) {
            this._parseEvent(bindParts[7], attrValue, attr.sourceSpan, targetMatchableAttrs, targetEvents);
          } else if (lang_1.isPresent(bindParts[6])) {
            this._parseProperty(bindParts[7], attrValue, attr.sourceSpan, targetMatchableAttrs, targetProps);
            this._parseAssignmentEvent(bindParts[7], attrValue, attr.sourceSpan, targetMatchableAttrs, targetEvents);
          } else if (lang_1.isPresent(bindParts[8])) {
            this._parseProperty(bindParts[8], attrValue, attr.sourceSpan, targetMatchableAttrs, targetProps);
            this._parseAssignmentEvent(bindParts[8], attrValue, attr.sourceSpan, targetMatchableAttrs, targetEvents);
          } else if (lang_1.isPresent(bindParts[9])) {
            this._parseProperty(bindParts[9], attrValue, attr.sourceSpan, targetMatchableAttrs, targetProps);
          } else if (lang_1.isPresent(bindParts[10])) {
            this._parseEvent(bindParts[10], attrValue, attr.sourceSpan, targetMatchableAttrs, targetEvents);
          }
        } else {
          hasBinding = this._parsePropertyInterpolation(attrName, attrValue, attr.sourceSpan, targetMatchableAttrs, targetProps);
        }
        if (!hasBinding) {
          this._parseLiteralAttr(attrName, attrValue, attr.sourceSpan, targetProps);
        }
        return hasBinding;
      };
      TemplateParseVisitor.prototype._normalizeAttributeName = function(attrName) {
        return attrName.toLowerCase().startsWith('data-') ? attrName.substring(5) : attrName;
      };
      TemplateParseVisitor.prototype._parseVariable = function(identifier, value, sourceSpan, targetVars) {
        if (identifier.indexOf('-') > -1) {
          this._reportError("\"-\" is not allowed in variable names", sourceSpan);
        }
        targetVars.push(new template_ast_1.VariableAst(identifier, value, sourceSpan));
      };
      TemplateParseVisitor.prototype._parseReference = function(identifier, value, sourceSpan, targetRefs) {
        if (identifier.indexOf('-') > -1) {
          this._reportError("\"-\" is not allowed in reference names", sourceSpan);
        }
        targetRefs.push(new ElementOrDirectiveRef(identifier, value, sourceSpan));
      };
      TemplateParseVisitor.prototype._parseProperty = function(name, expression, sourceSpan, targetMatchableAttrs, targetProps) {
        this._parsePropertyAst(name, this._parseBinding(expression, sourceSpan), sourceSpan, targetMatchableAttrs, targetProps);
      };
      TemplateParseVisitor.prototype._parsePropertyInterpolation = function(name, value, sourceSpan, targetMatchableAttrs, targetProps) {
        var expr = this._parseInterpolation(value, sourceSpan);
        if (lang_1.isPresent(expr)) {
          this._parsePropertyAst(name, expr, sourceSpan, targetMatchableAttrs, targetProps);
          return true;
        }
        return false;
      };
      TemplateParseVisitor.prototype._parsePropertyAst = function(name, ast, sourceSpan, targetMatchableAttrs, targetProps) {
        targetMatchableAttrs.push([name, ast.source]);
        targetProps.push(new BoundElementOrDirectiveProperty(name, ast, false, sourceSpan));
      };
      TemplateParseVisitor.prototype._parseAssignmentEvent = function(name, expression, sourceSpan, targetMatchableAttrs, targetEvents) {
        this._parseEvent(name + "Change", expression + "=$event", sourceSpan, targetMatchableAttrs, targetEvents);
      };
      TemplateParseVisitor.prototype._parseEvent = function(name, expression, sourceSpan, targetMatchableAttrs, targetEvents) {
        var parts = util_1.splitAtColon(name, [null, name]);
        var target = parts[0];
        var eventName = parts[1];
        var ast = this._parseAction(expression, sourceSpan);
        targetMatchableAttrs.push([name, ast.source]);
        targetEvents.push(new template_ast_1.BoundEventAst(eventName, target, ast, sourceSpan));
      };
      TemplateParseVisitor.prototype._parseLiteralAttr = function(name, value, sourceSpan, targetProps) {
        targetProps.push(new BoundElementOrDirectiveProperty(name, this._exprParser.wrapLiteralPrimitive(value, ''), true, sourceSpan));
      };
      TemplateParseVisitor.prototype._parseDirectives = function(selectorMatcher, elementCssSelector) {
        var _this = this;
        var directives = collection_1.ListWrapper.createFixedSize(this.directivesIndex.size);
        selectorMatcher.match(elementCssSelector, function(selector, directive) {
          directives[_this.directivesIndex.get(directive)] = directive;
        });
        return directives.filter(function(dir) {
          return lang_1.isPresent(dir);
        });
      };
      TemplateParseVisitor.prototype._createDirectiveAsts = function(isTemplateElement, elementName, directives, props, elementOrDirectiveRefs, sourceSpan, targetReferences) {
        var _this = this;
        var matchedReferences = new Set();
        var component = null;
        var directiveAsts = directives.map(function(directive) {
          if (directive.isComponent) {
            component = directive;
          }
          var hostProperties = [];
          var hostEvents = [];
          var directiveProperties = [];
          _this._createDirectiveHostPropertyAsts(elementName, directive.hostProperties, sourceSpan, hostProperties);
          _this._createDirectiveHostEventAsts(directive.hostListeners, sourceSpan, hostEvents);
          _this._createDirectivePropertyAsts(directive.inputs, props, directiveProperties);
          elementOrDirectiveRefs.forEach(function(elOrDirRef) {
            if ((elOrDirRef.value.length === 0 && directive.isComponent) || (directive.exportAs == elOrDirRef.value)) {
              targetReferences.push(new template_ast_1.ReferenceAst(elOrDirRef.name, identifiers_1.identifierToken(directive.type), elOrDirRef.sourceSpan));
              matchedReferences.add(elOrDirRef.name);
            }
          });
          return new template_ast_1.DirectiveAst(directive, directiveProperties, hostProperties, hostEvents, sourceSpan);
        });
        elementOrDirectiveRefs.forEach(function(elOrDirRef) {
          if (elOrDirRef.value.length > 0) {
            if (!collection_1.SetWrapper.has(matchedReferences, elOrDirRef.name)) {
              _this._reportError("There is no directive with \"exportAs\" set to \"" + elOrDirRef.value + "\"", elOrDirRef.sourceSpan);
            }
            ;
          } else if (lang_1.isBlank(component)) {
            var refToken = null;
            if (isTemplateElement) {
              refToken = identifiers_1.identifierToken(identifiers_1.Identifiers.TemplateRef);
            }
            targetReferences.push(new template_ast_1.ReferenceAst(elOrDirRef.name, refToken, elOrDirRef.sourceSpan));
          }
        });
        return directiveAsts;
      };
      TemplateParseVisitor.prototype._createDirectiveHostPropertyAsts = function(elementName, hostProps, sourceSpan, targetPropertyAsts) {
        var _this = this;
        if (lang_1.isPresent(hostProps)) {
          collection_1.StringMapWrapper.forEach(hostProps, function(expression, propName) {
            var exprAst = _this._parseBinding(expression, sourceSpan);
            targetPropertyAsts.push(_this._createElementPropertyAst(elementName, propName, exprAst, sourceSpan));
          });
        }
      };
      TemplateParseVisitor.prototype._createDirectiveHostEventAsts = function(hostListeners, sourceSpan, targetEventAsts) {
        var _this = this;
        if (lang_1.isPresent(hostListeners)) {
          collection_1.StringMapWrapper.forEach(hostListeners, function(expression, propName) {
            _this._parseEvent(propName, expression, sourceSpan, [], targetEventAsts);
          });
        }
      };
      TemplateParseVisitor.prototype._createDirectivePropertyAsts = function(directiveProperties, boundProps, targetBoundDirectiveProps) {
        if (lang_1.isPresent(directiveProperties)) {
          var boundPropsByName = new Map();
          boundProps.forEach(function(boundProp) {
            var prevValue = boundPropsByName.get(boundProp.name);
            if (lang_1.isBlank(prevValue) || prevValue.isLiteral) {
              boundPropsByName.set(boundProp.name, boundProp);
            }
          });
          collection_1.StringMapWrapper.forEach(directiveProperties, function(elProp, dirProp) {
            var boundProp = boundPropsByName.get(elProp);
            if (lang_1.isPresent(boundProp)) {
              targetBoundDirectiveProps.push(new template_ast_1.BoundDirectivePropertyAst(dirProp, boundProp.name, boundProp.expression, boundProp.sourceSpan));
            }
          });
        }
      };
      TemplateParseVisitor.prototype._createElementPropertyAsts = function(elementName, props, directives) {
        var _this = this;
        var boundElementProps = [];
        var boundDirectivePropsIndex = new Map();
        directives.forEach(function(directive) {
          directive.inputs.forEach(function(prop) {
            boundDirectivePropsIndex.set(prop.templateName, prop);
          });
        });
        props.forEach(function(prop) {
          if (!prop.isLiteral && lang_1.isBlank(boundDirectivePropsIndex.get(prop.name))) {
            boundElementProps.push(_this._createElementPropertyAst(elementName, prop.name, prop.expression, prop.sourceSpan));
          }
        });
        return boundElementProps;
      };
      TemplateParseVisitor.prototype._createElementPropertyAst = function(elementName, name, ast, sourceSpan) {
        var unit = null;
        var bindingType;
        var boundPropertyName;
        var parts = name.split(PROPERTY_PARTS_SEPARATOR);
        var securityContext;
        if (parts.length === 1) {
          boundPropertyName = this._schemaRegistry.getMappedPropName(parts[0]);
          securityContext = this._schemaRegistry.securityContext(elementName, boundPropertyName);
          bindingType = template_ast_1.PropertyBindingType.Property;
          if (!this._schemaRegistry.hasProperty(elementName, boundPropertyName)) {
            this._reportError("Can't bind to '" + boundPropertyName + "' since it isn't a known native property", sourceSpan);
          }
        } else {
          if (parts[0] == ATTRIBUTE_PREFIX) {
            boundPropertyName = parts[1];
            if (boundPropertyName.toLowerCase().startsWith('on')) {
              this._reportError(("Binding to event attribute '" + boundPropertyName + "' is disallowed ") + ("for security reasons, please use (" + boundPropertyName.slice(2) + ")=..."), sourceSpan);
            }
            securityContext = this._schemaRegistry.securityContext(elementName, this._schemaRegistry.getMappedPropName(boundPropertyName));
            var nsSeparatorIdx = boundPropertyName.indexOf(':');
            if (nsSeparatorIdx > -1) {
              var ns = boundPropertyName.substring(0, nsSeparatorIdx);
              var name_1 = boundPropertyName.substring(nsSeparatorIdx + 1);
              boundPropertyName = html_tags_1.mergeNsAndName(ns, name_1);
            }
            bindingType = template_ast_1.PropertyBindingType.Attribute;
          } else if (parts[0] == CLASS_PREFIX) {
            boundPropertyName = parts[1];
            bindingType = template_ast_1.PropertyBindingType.Class;
            securityContext = core_private_1.SecurityContext.NONE;
          } else if (parts[0] == STYLE_PREFIX) {
            unit = parts.length > 2 ? parts[2] : null;
            boundPropertyName = parts[1];
            bindingType = template_ast_1.PropertyBindingType.Style;
            securityContext = core_private_1.SecurityContext.STYLE;
          } else {
            this._reportError("Invalid property name '" + name + "'", sourceSpan);
            bindingType = null;
            securityContext = null;
          }
        }
        return new template_ast_1.BoundElementPropertyAst(boundPropertyName, bindingType, securityContext, ast, unit, sourceSpan);
      };
      TemplateParseVisitor.prototype._findComponentDirectiveNames = function(directives) {
        var componentTypeNames = [];
        directives.forEach(function(directive) {
          var typeName = directive.directive.type.name;
          if (directive.directive.isComponent) {
            componentTypeNames.push(typeName);
          }
        });
        return componentTypeNames;
      };
      TemplateParseVisitor.prototype._assertOnlyOneComponent = function(directives, sourceSpan) {
        var componentTypeNames = this._findComponentDirectiveNames(directives);
        if (componentTypeNames.length > 1) {
          this._reportError("More than one component: " + componentTypeNames.join(','), sourceSpan);
        }
      };
      TemplateParseVisitor.prototype._assertNoComponentsNorElementBindingsOnTemplate = function(directives, elementProps, sourceSpan) {
        var _this = this;
        var componentTypeNames = this._findComponentDirectiveNames(directives);
        if (componentTypeNames.length > 0) {
          this._reportError("Components on an embedded template: " + componentTypeNames.join(','), sourceSpan);
        }
        elementProps.forEach(function(prop) {
          _this._reportError("Property binding " + prop.name + " not used by any directive on an embedded template", sourceSpan);
        });
      };
      TemplateParseVisitor.prototype._assertAllEventsPublishedByDirectives = function(directives, events) {
        var _this = this;
        var allDirectiveEvents = new Set();
        directives.forEach(function(directive) {
          collection_1.StringMapWrapper.forEach(directive.directive.outputs, function(eventName, _) {
            allDirectiveEvents.add(eventName);
          });
        });
        events.forEach(function(event) {
          if (lang_1.isPresent(event.target) || !collection_1.SetWrapper.has(allDirectiveEvents, event.name)) {
            _this._reportError("Event binding " + event.fullName + " not emitted by any directive on an embedded template", event.sourceSpan);
          }
        });
      };
      return TemplateParseVisitor;
    }());
    var NonBindableVisitor = (function() {
      function NonBindableVisitor() {}
      NonBindableVisitor.prototype.visitElement = function(ast, parent) {
        var preparsedElement = template_preparser_1.preparseElement(ast);
        if (preparsedElement.type === template_preparser_1.PreparsedElementType.SCRIPT || preparsedElement.type === template_preparser_1.PreparsedElementType.STYLE || preparsedElement.type === template_preparser_1.PreparsedElementType.STYLESHEET) {
          return null;
        }
        var attrNameAndValues = ast.attrs.map(function(attrAst) {
          return [attrAst.name, attrAst.value];
        });
        var selector = createElementCssSelector(ast.name, attrNameAndValues);
        var ngContentIndex = parent.findNgContentIndex(selector);
        var children = html_ast_1.htmlVisitAll(this, ast.children, EMPTY_ELEMENT_CONTEXT);
        return new template_ast_1.ElementAst(ast.name, html_ast_1.htmlVisitAll(this, ast.attrs), [], [], [], [], [], false, children, ngContentIndex, ast.sourceSpan);
      };
      NonBindableVisitor.prototype.visitComment = function(ast, context) {
        return null;
      };
      NonBindableVisitor.prototype.visitAttr = function(ast, context) {
        return new template_ast_1.AttrAst(ast.name, ast.value, ast.sourceSpan);
      };
      NonBindableVisitor.prototype.visitText = function(ast, parent) {
        var ngContentIndex = parent.findNgContentIndex(TEXT_CSS_SELECTOR);
        return new template_ast_1.TextAst(ast.value, ngContentIndex, ast.sourceSpan);
      };
      NonBindableVisitor.prototype.visitExpansion = function(ast, context) {
        return ast;
      };
      NonBindableVisitor.prototype.visitExpansionCase = function(ast, context) {
        return ast;
      };
      return NonBindableVisitor;
    }());
    var BoundElementOrDirectiveProperty = (function() {
      function BoundElementOrDirectiveProperty(name, expression, isLiteral, sourceSpan) {
        this.name = name;
        this.expression = expression;
        this.isLiteral = isLiteral;
        this.sourceSpan = sourceSpan;
      }
      return BoundElementOrDirectiveProperty;
    }());
    var ElementOrDirectiveRef = (function() {
      function ElementOrDirectiveRef(name, value, sourceSpan) {
        this.name = name;
        this.value = value;
        this.sourceSpan = sourceSpan;
      }
      return ElementOrDirectiveRef;
    }());
    function splitClasses(classAttrValue) {
      return lang_1.StringWrapper.split(classAttrValue.trim(), /\s+/g);
    }
    exports.splitClasses = splitClasses;
    var ElementContext = (function() {
      function ElementContext(isTemplateElement, _ngContentIndexMatcher, _wildcardNgContentIndex, providerContext) {
        this.isTemplateElement = isTemplateElement;
        this._ngContentIndexMatcher = _ngContentIndexMatcher;
        this._wildcardNgContentIndex = _wildcardNgContentIndex;
        this.providerContext = providerContext;
      }
      ElementContext.create = function(isTemplateElement, directives, providerContext) {
        var matcher = new selector_1.SelectorMatcher();
        var wildcardNgContentIndex = null;
        var component = directives.find(function(directive) {
          return directive.directive.isComponent;
        });
        if (lang_1.isPresent(component)) {
          var ngContentSelectors = component.directive.template.ngContentSelectors;
          for (var i = 0; i < ngContentSelectors.length; i++) {
            var selector = ngContentSelectors[i];
            if (lang_1.StringWrapper.equals(selector, '*')) {
              wildcardNgContentIndex = i;
            } else {
              matcher.addSelectables(selector_1.CssSelector.parse(ngContentSelectors[i]), i);
            }
          }
        }
        return new ElementContext(isTemplateElement, matcher, wildcardNgContentIndex, providerContext);
      };
      ElementContext.prototype.findNgContentIndex = function(selector) {
        var ngContentIndices = [];
        this._ngContentIndexMatcher.match(selector, function(selector, ngContentIndex) {
          ngContentIndices.push(ngContentIndex);
        });
        collection_1.ListWrapper.sort(ngContentIndices);
        if (lang_1.isPresent(this._wildcardNgContentIndex)) {
          ngContentIndices.push(this._wildcardNgContentIndex);
        }
        return ngContentIndices.length > 0 ? ngContentIndices[0] : null;
      };
      return ElementContext;
    }());
    function createElementCssSelector(elementName, matchableAttrs) {
      var cssSelector = new selector_1.CssSelector();
      var elNameNoNs = html_tags_1.splitNsName(elementName)[1];
      cssSelector.setElement(elNameNoNs);
      for (var i = 0; i < matchableAttrs.length; i++) {
        var attrName = matchableAttrs[i][0];
        var attrNameNoNs = html_tags_1.splitNsName(attrName)[1];
        var attrValue = matchableAttrs[i][1];
        cssSelector.addAttribute(attrNameNoNs, attrValue);
        if (attrName.toLowerCase() == CLASS_ATTR) {
          var classes = splitClasses(attrValue);
          classes.forEach(function(className) {
            return cssSelector.addClassName(className);
          });
        }
      }
      return cssSelector;
    }
    var EMPTY_ELEMENT_CONTEXT = new ElementContext(true, new selector_1.SelectorMatcher(), null, null);
    var NON_BINDABLE_VISITOR = new NonBindableVisitor();
    var PipeCollector = (function(_super) {
      __extends(PipeCollector, _super);
      function PipeCollector() {
        _super.apply(this, arguments);
        this.pipes = new Set();
      }
      PipeCollector.prototype.visitPipe = function(ast, context) {
        this.pipes.add(ast.name);
        ast.exp.visit(this);
        this.visitAll(ast.args, context);
        return null;
      };
      return PipeCollector;
    }(ast_1.RecursiveAstVisitor));
    exports.PipeCollector = PipeCollector;
    function removeDuplicates(items) {
      var res = [];
      items.forEach(function(item) {
        var hasMatch = res.filter(function(r) {
          return r.type.name == item.type.name && r.type.moduleUrl == item.type.moduleUrl && r.type.runtime == item.type.runtime;
        }).length > 0;
        if (!hasMatch) {
          res.push(item);
        }
      });
      return res;
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("23", ["13", "d", "f", "24"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var o = $__require('f');
  var abstract_emitter_1 = $__require('24');
  var AbstractJsEmitterVisitor = (function(_super) {
    __extends(AbstractJsEmitterVisitor, _super);
    function AbstractJsEmitterVisitor() {
      _super.call(this, false);
    }
    AbstractJsEmitterVisitor.prototype.visitDeclareClassStmt = function(stmt, ctx) {
      var _this = this;
      ctx.pushClass(stmt);
      this._visitClassConstructor(stmt, ctx);
      if (lang_1.isPresent(stmt.parent)) {
        ctx.print(stmt.name + ".prototype = Object.create(");
        stmt.parent.visitExpression(this, ctx);
        ctx.println(".prototype);");
      }
      stmt.getters.forEach(function(getter) {
        return _this._visitClassGetter(stmt, getter, ctx);
      });
      stmt.methods.forEach(function(method) {
        return _this._visitClassMethod(stmt, method, ctx);
      });
      ctx.popClass();
      return null;
    };
    AbstractJsEmitterVisitor.prototype._visitClassConstructor = function(stmt, ctx) {
      ctx.print("function " + stmt.name + "(");
      if (lang_1.isPresent(stmt.constructorMethod)) {
        this._visitParams(stmt.constructorMethod.params, ctx);
      }
      ctx.println(") {");
      ctx.incIndent();
      if (lang_1.isPresent(stmt.constructorMethod)) {
        if (stmt.constructorMethod.body.length > 0) {
          ctx.println("var self = this;");
          this.visitAllStatements(stmt.constructorMethod.body, ctx);
        }
      }
      ctx.decIndent();
      ctx.println("}");
    };
    AbstractJsEmitterVisitor.prototype._visitClassGetter = function(stmt, getter, ctx) {
      ctx.println("Object.defineProperty(" + stmt.name + ".prototype, '" + getter.name + "', { get: function() {");
      ctx.incIndent();
      if (getter.body.length > 0) {
        ctx.println("var self = this;");
        this.visitAllStatements(getter.body, ctx);
      }
      ctx.decIndent();
      ctx.println("}});");
    };
    AbstractJsEmitterVisitor.prototype._visitClassMethod = function(stmt, method, ctx) {
      ctx.print(stmt.name + ".prototype." + method.name + " = function(");
      this._visitParams(method.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      if (method.body.length > 0) {
        ctx.println("var self = this;");
        this.visitAllStatements(method.body, ctx);
      }
      ctx.decIndent();
      ctx.println("};");
    };
    AbstractJsEmitterVisitor.prototype.visitReadVarExpr = function(ast, ctx) {
      if (ast.builtin === o.BuiltinVar.This) {
        ctx.print('self');
      } else if (ast.builtin === o.BuiltinVar.Super) {
        throw new exceptions_1.BaseException("'super' needs to be handled at a parent ast node, not at the variable level!");
      } else {
        _super.prototype.visitReadVarExpr.call(this, ast, ctx);
      }
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitDeclareVarStmt = function(stmt, ctx) {
      ctx.print("var " + stmt.name + " = ");
      stmt.value.visitExpression(this, ctx);
      ctx.println(";");
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitCastExpr = function(ast, ctx) {
      ast.value.visitExpression(this, ctx);
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitInvokeFunctionExpr = function(expr, ctx) {
      var fnExpr = expr.fn;
      if (fnExpr instanceof o.ReadVarExpr && fnExpr.builtin === o.BuiltinVar.Super) {
        ctx.currentClass.parent.visitExpression(this, ctx);
        ctx.print(".call(this");
        if (expr.args.length > 0) {
          ctx.print(", ");
          this.visitAllExpressions(expr.args, ctx, ',');
        }
        ctx.print(")");
      } else {
        _super.prototype.visitInvokeFunctionExpr.call(this, expr, ctx);
      }
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitFunctionExpr = function(ast, ctx) {
      ctx.print("function(");
      this._visitParams(ast.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(ast.statements, ctx);
      ctx.decIndent();
      ctx.print("}");
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitDeclareFunctionStmt = function(stmt, ctx) {
      ctx.print("function " + stmt.name + "(");
      this._visitParams(stmt.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(stmt.statements, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    AbstractJsEmitterVisitor.prototype.visitTryCatchStmt = function(stmt, ctx) {
      ctx.println("try {");
      ctx.incIndent();
      this.visitAllStatements(stmt.bodyStmts, ctx);
      ctx.decIndent();
      ctx.println("} catch (" + abstract_emitter_1.CATCH_ERROR_VAR.name + ") {");
      ctx.incIndent();
      var catchStmts = [abstract_emitter_1.CATCH_STACK_VAR.set(abstract_emitter_1.CATCH_ERROR_VAR.prop('stack')).toDeclStmt(null, [o.StmtModifier.Final])].concat(stmt.catchStmts);
      this.visitAllStatements(catchStmts, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    AbstractJsEmitterVisitor.prototype._visitParams = function(params, ctx) {
      this.visitAllObjects(function(param) {
        return ctx.print(param.name);
      }, params, ctx, ',');
    };
    AbstractJsEmitterVisitor.prototype.getBuiltinMethodName = function(method) {
      var name;
      switch (method) {
        case o.BuiltinMethod.ConcatArray:
          name = 'concat';
          break;
        case o.BuiltinMethod.SubscribeObservable:
          name = 'subscribe';
          break;
        case o.BuiltinMethod.bind:
          name = 'bind';
          break;
        default:
          throw new exceptions_1.BaseException("Unknown builtin method: " + method);
      }
      return name;
    };
    return AbstractJsEmitterVisitor;
  }(abstract_emitter_1.AbstractEmitterVisitor));
  exports.AbstractJsEmitterVisitor = AbstractJsEmitterVisitor;
  return module.exports;
});

$__System.registerDynamic("25", ["13", "24", "23", "10"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  var abstract_emitter_1 = $__require('24');
  var abstract_js_emitter_1 = $__require('23');
  var util_1 = $__require('10');
  function jitStatements(sourceUrl, statements, resultVar) {
    var converter = new JitEmitterVisitor();
    var ctx = abstract_emitter_1.EmitterVisitorContext.createRoot([resultVar]);
    converter.visitAllStatements(statements, ctx);
    return lang_1.evalExpression(sourceUrl, resultVar, ctx.toSource(), converter.getArgs());
  }
  exports.jitStatements = jitStatements;
  var JitEmitterVisitor = (function(_super) {
    __extends(JitEmitterVisitor, _super);
    function JitEmitterVisitor() {
      _super.apply(this, arguments);
      this._evalArgNames = [];
      this._evalArgValues = [];
    }
    JitEmitterVisitor.prototype.getArgs = function() {
      var result = {};
      for (var i = 0; i < this._evalArgNames.length; i++) {
        result[this._evalArgNames[i]] = this._evalArgValues[i];
      }
      return result;
    };
    JitEmitterVisitor.prototype.visitExternalExpr = function(ast, ctx) {
      var value = ast.value.runtime;
      var id = this._evalArgValues.indexOf(value);
      if (id === -1) {
        id = this._evalArgValues.length;
        this._evalArgValues.push(value);
        var name = lang_1.isPresent(ast.value.name) ? util_1.sanitizeIdentifier(ast.value.name) : 'val';
        this._evalArgNames.push(util_1.sanitizeIdentifier("jit_" + name + id));
      }
      ctx.print(this._evalArgNames[id]);
      return null;
    };
    return JitEmitterVisitor;
  }(abstract_js_emitter_1.AbstractJsEmitterVisitor));
  return module.exports;
});

$__System.registerDynamic("26", ["13", "d", "f", "24"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var o = $__require('f');
  var abstract_emitter_1 = $__require('24');
  var _debugModuleUrl = 'asset://debug/lib';
  function debugOutputAstAsDart(ast) {
    var converter = new _DartEmitterVisitor(_debugModuleUrl);
    var ctx = abstract_emitter_1.EmitterVisitorContext.createRoot([]);
    var asts;
    if (lang_1.isArray(ast)) {
      asts = ast;
    } else {
      asts = [ast];
    }
    asts.forEach(function(ast) {
      if (ast instanceof o.Statement) {
        ast.visitStatement(converter, ctx);
      } else if (ast instanceof o.Expression) {
        ast.visitExpression(converter, ctx);
      } else if (ast instanceof o.Type) {
        ast.visitType(converter, ctx);
      } else {
        throw new exceptions_1.BaseException("Don't know how to print debug info for " + ast);
      }
    });
    return ctx.toSource();
  }
  exports.debugOutputAstAsDart = debugOutputAstAsDart;
  var DartEmitter = (function() {
    function DartEmitter(_importGenerator) {
      this._importGenerator = _importGenerator;
    }
    DartEmitter.prototype.emitStatements = function(moduleUrl, stmts, exportedVars) {
      var _this = this;
      var srcParts = [];
      var converter = new _DartEmitterVisitor(moduleUrl);
      var ctx = abstract_emitter_1.EmitterVisitorContext.createRoot(exportedVars);
      converter.visitAllStatements(stmts, ctx);
      converter.importsWithPrefixes.forEach(function(prefix, importedModuleUrl) {
        srcParts.push("import '" + _this._importGenerator.getImportPath(moduleUrl, importedModuleUrl) + "' as " + prefix + ";");
      });
      srcParts.push(ctx.toSource());
      return srcParts.join('\n');
    };
    return DartEmitter;
  }());
  exports.DartEmitter = DartEmitter;
  var _DartEmitterVisitor = (function(_super) {
    __extends(_DartEmitterVisitor, _super);
    function _DartEmitterVisitor(_moduleUrl) {
      _super.call(this, true);
      this._moduleUrl = _moduleUrl;
      this.importsWithPrefixes = new Map();
    }
    _DartEmitterVisitor.prototype.visitExternalExpr = function(ast, ctx) {
      this._visitIdentifier(ast.value, ast.typeParams, ctx);
      return null;
    };
    _DartEmitterVisitor.prototype.visitDeclareVarStmt = function(stmt, ctx) {
      if (stmt.hasModifier(o.StmtModifier.Final)) {
        if (isConstType(stmt.type)) {
          ctx.print("const ");
        } else {
          ctx.print("final ");
        }
      } else if (lang_1.isBlank(stmt.type)) {
        ctx.print("var ");
      }
      if (lang_1.isPresent(stmt.type)) {
        stmt.type.visitType(this, ctx);
        ctx.print(" ");
      }
      ctx.print(stmt.name + " = ");
      stmt.value.visitExpression(this, ctx);
      ctx.println(";");
      return null;
    };
    _DartEmitterVisitor.prototype.visitCastExpr = function(ast, ctx) {
      ctx.print("(");
      ast.value.visitExpression(this, ctx);
      ctx.print(" as ");
      ast.type.visitType(this, ctx);
      ctx.print(")");
      return null;
    };
    _DartEmitterVisitor.prototype.visitDeclareClassStmt = function(stmt, ctx) {
      var _this = this;
      ctx.pushClass(stmt);
      ctx.print("class " + stmt.name);
      if (lang_1.isPresent(stmt.parent)) {
        ctx.print(" extends ");
        stmt.parent.visitExpression(this, ctx);
      }
      ctx.println(" {");
      ctx.incIndent();
      stmt.fields.forEach(function(field) {
        return _this._visitClassField(field, ctx);
      });
      if (lang_1.isPresent(stmt.constructorMethod)) {
        this._visitClassConstructor(stmt, ctx);
      }
      stmt.getters.forEach(function(getter) {
        return _this._visitClassGetter(getter, ctx);
      });
      stmt.methods.forEach(function(method) {
        return _this._visitClassMethod(method, ctx);
      });
      ctx.decIndent();
      ctx.println("}");
      ctx.popClass();
      return null;
    };
    _DartEmitterVisitor.prototype._visitClassField = function(field, ctx) {
      if (field.hasModifier(o.StmtModifier.Final)) {
        ctx.print("final ");
      } else if (lang_1.isBlank(field.type)) {
        ctx.print("var ");
      }
      if (lang_1.isPresent(field.type)) {
        field.type.visitType(this, ctx);
        ctx.print(" ");
      }
      ctx.println(field.name + ";");
    };
    _DartEmitterVisitor.prototype._visitClassGetter = function(getter, ctx) {
      if (lang_1.isPresent(getter.type)) {
        getter.type.visitType(this, ctx);
        ctx.print(" ");
      }
      ctx.println("get " + getter.name + " {");
      ctx.incIndent();
      this.visitAllStatements(getter.body, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _DartEmitterVisitor.prototype._visitClassConstructor = function(stmt, ctx) {
      ctx.print(stmt.name + "(");
      this._visitParams(stmt.constructorMethod.params, ctx);
      ctx.print(")");
      var ctorStmts = stmt.constructorMethod.body;
      var superCtorExpr = ctorStmts.length > 0 ? getSuperConstructorCallExpr(ctorStmts[0]) : null;
      if (lang_1.isPresent(superCtorExpr)) {
        ctx.print(": ");
        superCtorExpr.visitExpression(this, ctx);
        ctorStmts = ctorStmts.slice(1);
      }
      ctx.println(" {");
      ctx.incIndent();
      this.visitAllStatements(ctorStmts, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _DartEmitterVisitor.prototype._visitClassMethod = function(method, ctx) {
      if (lang_1.isPresent(method.type)) {
        method.type.visitType(this, ctx);
      } else {
        ctx.print("void");
      }
      ctx.print(" " + method.name + "(");
      this._visitParams(method.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(method.body, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _DartEmitterVisitor.prototype.visitFunctionExpr = function(ast, ctx) {
      ctx.print("(");
      this._visitParams(ast.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(ast.statements, ctx);
      ctx.decIndent();
      ctx.print("}");
      return null;
    };
    _DartEmitterVisitor.prototype.visitDeclareFunctionStmt = function(stmt, ctx) {
      if (lang_1.isPresent(stmt.type)) {
        stmt.type.visitType(this, ctx);
      } else {
        ctx.print("void");
      }
      ctx.print(" " + stmt.name + "(");
      this._visitParams(stmt.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(stmt.statements, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    _DartEmitterVisitor.prototype.getBuiltinMethodName = function(method) {
      var name;
      switch (method) {
        case o.BuiltinMethod.ConcatArray:
          name = '.addAll';
          break;
        case o.BuiltinMethod.SubscribeObservable:
          name = 'listen';
          break;
        case o.BuiltinMethod.bind:
          name = null;
          break;
        default:
          throw new exceptions_1.BaseException("Unknown builtin method: " + method);
      }
      return name;
    };
    _DartEmitterVisitor.prototype.visitTryCatchStmt = function(stmt, ctx) {
      ctx.println("try {");
      ctx.incIndent();
      this.visitAllStatements(stmt.bodyStmts, ctx);
      ctx.decIndent();
      ctx.println("} catch (" + abstract_emitter_1.CATCH_ERROR_VAR.name + ", " + abstract_emitter_1.CATCH_STACK_VAR.name + ") {");
      ctx.incIndent();
      this.visitAllStatements(stmt.catchStmts, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    _DartEmitterVisitor.prototype.visitBinaryOperatorExpr = function(ast, ctx) {
      switch (ast.operator) {
        case o.BinaryOperator.Identical:
          ctx.print("identical(");
          ast.lhs.visitExpression(this, ctx);
          ctx.print(", ");
          ast.rhs.visitExpression(this, ctx);
          ctx.print(")");
          break;
        case o.BinaryOperator.NotIdentical:
          ctx.print("!identical(");
          ast.lhs.visitExpression(this, ctx);
          ctx.print(", ");
          ast.rhs.visitExpression(this, ctx);
          ctx.print(")");
          break;
        default:
          _super.prototype.visitBinaryOperatorExpr.call(this, ast, ctx);
      }
      return null;
    };
    _DartEmitterVisitor.prototype.visitLiteralArrayExpr = function(ast, ctx) {
      if (isConstType(ast.type)) {
        ctx.print("const ");
      }
      return _super.prototype.visitLiteralArrayExpr.call(this, ast, ctx);
    };
    _DartEmitterVisitor.prototype.visitLiteralMapExpr = function(ast, ctx) {
      if (isConstType(ast.type)) {
        ctx.print("const ");
      }
      if (lang_1.isPresent(ast.valueType)) {
        ctx.print("<String, ");
        ast.valueType.visitType(this, ctx);
        ctx.print(">");
      }
      return _super.prototype.visitLiteralMapExpr.call(this, ast, ctx);
    };
    _DartEmitterVisitor.prototype.visitInstantiateExpr = function(ast, ctx) {
      ctx.print(isConstType(ast.type) ? "const" : "new");
      ctx.print(' ');
      ast.classExpr.visitExpression(this, ctx);
      ctx.print("(");
      this.visitAllExpressions(ast.args, ctx, ",");
      ctx.print(")");
      return null;
    };
    _DartEmitterVisitor.prototype.visitBuiltintType = function(type, ctx) {
      var typeStr;
      switch (type.name) {
        case o.BuiltinTypeName.Bool:
          typeStr = 'bool';
          break;
        case o.BuiltinTypeName.Dynamic:
          typeStr = 'dynamic';
          break;
        case o.BuiltinTypeName.Function:
          typeStr = 'Function';
          break;
        case o.BuiltinTypeName.Number:
          typeStr = 'num';
          break;
        case o.BuiltinTypeName.Int:
          typeStr = 'int';
          break;
        case o.BuiltinTypeName.String:
          typeStr = 'String';
          break;
        default:
          throw new exceptions_1.BaseException("Unsupported builtin type " + type.name);
      }
      ctx.print(typeStr);
      return null;
    };
    _DartEmitterVisitor.prototype.visitExternalType = function(ast, ctx) {
      this._visitIdentifier(ast.value, ast.typeParams, ctx);
      return null;
    };
    _DartEmitterVisitor.prototype.visitArrayType = function(type, ctx) {
      ctx.print("List<");
      if (lang_1.isPresent(type.of)) {
        type.of.visitType(this, ctx);
      } else {
        ctx.print("dynamic");
      }
      ctx.print(">");
      return null;
    };
    _DartEmitterVisitor.prototype.visitMapType = function(type, ctx) {
      ctx.print("Map<String, ");
      if (lang_1.isPresent(type.valueType)) {
        type.valueType.visitType(this, ctx);
      } else {
        ctx.print("dynamic");
      }
      ctx.print(">");
      return null;
    };
    _DartEmitterVisitor.prototype._visitParams = function(params, ctx) {
      var _this = this;
      this.visitAllObjects(function(param) {
        if (lang_1.isPresent(param.type)) {
          param.type.visitType(_this, ctx);
          ctx.print(' ');
        }
        ctx.print(param.name);
      }, params, ctx, ',');
    };
    _DartEmitterVisitor.prototype._visitIdentifier = function(value, typeParams, ctx) {
      var _this = this;
      if (lang_1.isBlank(value.name)) {
        throw new exceptions_1.BaseException("Internal error: unknown identifier " + value);
      }
      if (lang_1.isPresent(value.moduleUrl) && value.moduleUrl != this._moduleUrl) {
        var prefix = this.importsWithPrefixes.get(value.moduleUrl);
        if (lang_1.isBlank(prefix)) {
          prefix = "import" + this.importsWithPrefixes.size;
          this.importsWithPrefixes.set(value.moduleUrl, prefix);
        }
        ctx.print(prefix + ".");
      }
      ctx.print(value.name);
      if (lang_1.isPresent(typeParams) && typeParams.length > 0) {
        ctx.print("<");
        this.visitAllObjects(function(type) {
          return type.visitType(_this, ctx);
        }, typeParams, ctx, ',');
        ctx.print(">");
      }
    };
    return _DartEmitterVisitor;
  }(abstract_emitter_1.AbstractEmitterVisitor));
  function getSuperConstructorCallExpr(stmt) {
    if (stmt instanceof o.ExpressionStatement) {
      var expr = stmt.expr;
      if (expr instanceof o.InvokeFunctionExpr) {
        var fn = expr.fn;
        if (fn instanceof o.ReadVarExpr) {
          if (fn.builtin === o.BuiltinVar.Super) {
            return expr;
          }
        }
      }
    }
    return null;
  }
  function isConstType(type) {
    return lang_1.isPresent(type) && type.hasModifier(o.TypeModifier.Const);
  }
  return module.exports;
});

$__System.registerDynamic("24", ["13", "d", "f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var o = $__require('f');
  var _SINGLE_QUOTE_ESCAPE_STRING_RE = /'|\\|\n|\r|\$/g;
  exports.CATCH_ERROR_VAR = o.variable('error');
  exports.CATCH_STACK_VAR = o.variable('stack');
  var OutputEmitter = (function() {
    function OutputEmitter() {}
    return OutputEmitter;
  }());
  exports.OutputEmitter = OutputEmitter;
  var _EmittedLine = (function() {
    function _EmittedLine(indent) {
      this.indent = indent;
      this.parts = [];
    }
    return _EmittedLine;
  }());
  var EmitterVisitorContext = (function() {
    function EmitterVisitorContext(_exportedVars, _indent) {
      this._exportedVars = _exportedVars;
      this._indent = _indent;
      this._classes = [];
      this._lines = [new _EmittedLine(_indent)];
    }
    EmitterVisitorContext.createRoot = function(exportedVars) {
      return new EmitterVisitorContext(exportedVars, 0);
    };
    Object.defineProperty(EmitterVisitorContext.prototype, "_currentLine", {
      get: function() {
        return this._lines[this._lines.length - 1];
      },
      enumerable: true,
      configurable: true
    });
    EmitterVisitorContext.prototype.isExportedVar = function(varName) {
      return this._exportedVars.indexOf(varName) !== -1;
    };
    EmitterVisitorContext.prototype.println = function(lastPart) {
      if (lastPart === void 0) {
        lastPart = '';
      }
      this.print(lastPart, true);
    };
    EmitterVisitorContext.prototype.lineIsEmpty = function() {
      return this._currentLine.parts.length === 0;
    };
    EmitterVisitorContext.prototype.print = function(part, newLine) {
      if (newLine === void 0) {
        newLine = false;
      }
      if (part.length > 0) {
        this._currentLine.parts.push(part);
      }
      if (newLine) {
        this._lines.push(new _EmittedLine(this._indent));
      }
    };
    EmitterVisitorContext.prototype.removeEmptyLastLine = function() {
      if (this.lineIsEmpty()) {
        this._lines.pop();
      }
    };
    EmitterVisitorContext.prototype.incIndent = function() {
      this._indent++;
      this._currentLine.indent = this._indent;
    };
    EmitterVisitorContext.prototype.decIndent = function() {
      this._indent--;
      this._currentLine.indent = this._indent;
    };
    EmitterVisitorContext.prototype.pushClass = function(clazz) {
      this._classes.push(clazz);
    };
    EmitterVisitorContext.prototype.popClass = function() {
      return this._classes.pop();
    };
    Object.defineProperty(EmitterVisitorContext.prototype, "currentClass", {
      get: function() {
        return this._classes.length > 0 ? this._classes[this._classes.length - 1] : null;
      },
      enumerable: true,
      configurable: true
    });
    EmitterVisitorContext.prototype.toSource = function() {
      var lines = this._lines;
      if (lines[lines.length - 1].parts.length === 0) {
        lines = lines.slice(0, lines.length - 1);
      }
      return lines.map(function(line) {
        if (line.parts.length > 0) {
          return _createIndent(line.indent) + line.parts.join('');
        } else {
          return '';
        }
      }).join('\n');
    };
    return EmitterVisitorContext;
  }());
  exports.EmitterVisitorContext = EmitterVisitorContext;
  var AbstractEmitterVisitor = (function() {
    function AbstractEmitterVisitor(_escapeDollarInStrings) {
      this._escapeDollarInStrings = _escapeDollarInStrings;
    }
    AbstractEmitterVisitor.prototype.visitExpressionStmt = function(stmt, ctx) {
      stmt.expr.visitExpression(this, ctx);
      ctx.println(';');
      return null;
    };
    AbstractEmitterVisitor.prototype.visitReturnStmt = function(stmt, ctx) {
      ctx.print("return ");
      stmt.value.visitExpression(this, ctx);
      ctx.println(';');
      return null;
    };
    AbstractEmitterVisitor.prototype.visitIfStmt = function(stmt, ctx) {
      ctx.print("if (");
      stmt.condition.visitExpression(this, ctx);
      ctx.print(") {");
      var hasElseCase = lang_1.isPresent(stmt.falseCase) && stmt.falseCase.length > 0;
      if (stmt.trueCase.length <= 1 && !hasElseCase) {
        ctx.print(" ");
        this.visitAllStatements(stmt.trueCase, ctx);
        ctx.removeEmptyLastLine();
        ctx.print(" ");
      } else {
        ctx.println();
        ctx.incIndent();
        this.visitAllStatements(stmt.trueCase, ctx);
        ctx.decIndent();
        if (hasElseCase) {
          ctx.println("} else {");
          ctx.incIndent();
          this.visitAllStatements(stmt.falseCase, ctx);
          ctx.decIndent();
        }
      }
      ctx.println("}");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitThrowStmt = function(stmt, ctx) {
      ctx.print("throw ");
      stmt.error.visitExpression(this, ctx);
      ctx.println(";");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitCommentStmt = function(stmt, ctx) {
      var lines = stmt.comment.split('\n');
      lines.forEach(function(line) {
        ctx.println("// " + line);
      });
      return null;
    };
    AbstractEmitterVisitor.prototype.visitWriteVarExpr = function(expr, ctx) {
      var lineWasEmpty = ctx.lineIsEmpty();
      if (!lineWasEmpty) {
        ctx.print('(');
      }
      ctx.print(expr.name + " = ");
      expr.value.visitExpression(this, ctx);
      if (!lineWasEmpty) {
        ctx.print(')');
      }
      return null;
    };
    AbstractEmitterVisitor.prototype.visitWriteKeyExpr = function(expr, ctx) {
      var lineWasEmpty = ctx.lineIsEmpty();
      if (!lineWasEmpty) {
        ctx.print('(');
      }
      expr.receiver.visitExpression(this, ctx);
      ctx.print("[");
      expr.index.visitExpression(this, ctx);
      ctx.print("] = ");
      expr.value.visitExpression(this, ctx);
      if (!lineWasEmpty) {
        ctx.print(')');
      }
      return null;
    };
    AbstractEmitterVisitor.prototype.visitWritePropExpr = function(expr, ctx) {
      var lineWasEmpty = ctx.lineIsEmpty();
      if (!lineWasEmpty) {
        ctx.print('(');
      }
      expr.receiver.visitExpression(this, ctx);
      ctx.print("." + expr.name + " = ");
      expr.value.visitExpression(this, ctx);
      if (!lineWasEmpty) {
        ctx.print(')');
      }
      return null;
    };
    AbstractEmitterVisitor.prototype.visitInvokeMethodExpr = function(expr, ctx) {
      expr.receiver.visitExpression(this, ctx);
      var name = expr.name;
      if (lang_1.isPresent(expr.builtin)) {
        name = this.getBuiltinMethodName(expr.builtin);
        if (lang_1.isBlank(name)) {
          return null;
        }
      }
      ctx.print("." + name + "(");
      this.visitAllExpressions(expr.args, ctx, ",");
      ctx.print(")");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitInvokeFunctionExpr = function(expr, ctx) {
      expr.fn.visitExpression(this, ctx);
      ctx.print("(");
      this.visitAllExpressions(expr.args, ctx, ',');
      ctx.print(")");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitReadVarExpr = function(ast, ctx) {
      var varName = ast.name;
      if (lang_1.isPresent(ast.builtin)) {
        switch (ast.builtin) {
          case o.BuiltinVar.Super:
            varName = 'super';
            break;
          case o.BuiltinVar.This:
            varName = 'this';
            break;
          case o.BuiltinVar.CatchError:
            varName = exports.CATCH_ERROR_VAR.name;
            break;
          case o.BuiltinVar.CatchStack:
            varName = exports.CATCH_STACK_VAR.name;
            break;
          default:
            throw new exceptions_1.BaseException("Unknown builtin variable " + ast.builtin);
        }
      }
      ctx.print(varName);
      return null;
    };
    AbstractEmitterVisitor.prototype.visitInstantiateExpr = function(ast, ctx) {
      ctx.print("new ");
      ast.classExpr.visitExpression(this, ctx);
      ctx.print("(");
      this.visitAllExpressions(ast.args, ctx, ',');
      ctx.print(")");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitLiteralExpr = function(ast, ctx) {
      var value = ast.value;
      if (lang_1.isString(value)) {
        ctx.print(escapeSingleQuoteString(value, this._escapeDollarInStrings));
      } else if (lang_1.isBlank(value)) {
        ctx.print('null');
      } else {
        ctx.print("" + value);
      }
      return null;
    };
    AbstractEmitterVisitor.prototype.visitConditionalExpr = function(ast, ctx) {
      ctx.print("(");
      ast.condition.visitExpression(this, ctx);
      ctx.print('? ');
      ast.trueCase.visitExpression(this, ctx);
      ctx.print(': ');
      ast.falseCase.visitExpression(this, ctx);
      ctx.print(")");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitNotExpr = function(ast, ctx) {
      ctx.print('!');
      ast.condition.visitExpression(this, ctx);
      return null;
    };
    AbstractEmitterVisitor.prototype.visitBinaryOperatorExpr = function(ast, ctx) {
      var opStr;
      switch (ast.operator) {
        case o.BinaryOperator.Equals:
          opStr = '==';
          break;
        case o.BinaryOperator.Identical:
          opStr = '===';
          break;
        case o.BinaryOperator.NotEquals:
          opStr = '!=';
          break;
        case o.BinaryOperator.NotIdentical:
          opStr = '!==';
          break;
        case o.BinaryOperator.And:
          opStr = '&&';
          break;
        case o.BinaryOperator.Or:
          opStr = '||';
          break;
        case o.BinaryOperator.Plus:
          opStr = '+';
          break;
        case o.BinaryOperator.Minus:
          opStr = '-';
          break;
        case o.BinaryOperator.Divide:
          opStr = '/';
          break;
        case o.BinaryOperator.Multiply:
          opStr = '*';
          break;
        case o.BinaryOperator.Modulo:
          opStr = '%';
          break;
        case o.BinaryOperator.Lower:
          opStr = '<';
          break;
        case o.BinaryOperator.LowerEquals:
          opStr = '<=';
          break;
        case o.BinaryOperator.Bigger:
          opStr = '>';
          break;
        case o.BinaryOperator.BiggerEquals:
          opStr = '>=';
          break;
        default:
          throw new exceptions_1.BaseException("Unknown operator " + ast.operator);
      }
      ctx.print("(");
      ast.lhs.visitExpression(this, ctx);
      ctx.print(" " + opStr + " ");
      ast.rhs.visitExpression(this, ctx);
      ctx.print(")");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitReadPropExpr = function(ast, ctx) {
      ast.receiver.visitExpression(this, ctx);
      ctx.print(".");
      ctx.print(ast.name);
      return null;
    };
    AbstractEmitterVisitor.prototype.visitReadKeyExpr = function(ast, ctx) {
      ast.receiver.visitExpression(this, ctx);
      ctx.print("[");
      ast.index.visitExpression(this, ctx);
      ctx.print("]");
      return null;
    };
    AbstractEmitterVisitor.prototype.visitLiteralArrayExpr = function(ast, ctx) {
      var useNewLine = ast.entries.length > 1;
      ctx.print("[", useNewLine);
      ctx.incIndent();
      this.visitAllExpressions(ast.entries, ctx, ',', useNewLine);
      ctx.decIndent();
      ctx.print("]", useNewLine);
      return null;
    };
    AbstractEmitterVisitor.prototype.visitLiteralMapExpr = function(ast, ctx) {
      var _this = this;
      var useNewLine = ast.entries.length > 1;
      ctx.print("{", useNewLine);
      ctx.incIndent();
      this.visitAllObjects(function(entry) {
        ctx.print(escapeSingleQuoteString(entry[0], _this._escapeDollarInStrings) + ": ");
        entry[1].visitExpression(_this, ctx);
      }, ast.entries, ctx, ',', useNewLine);
      ctx.decIndent();
      ctx.print("}", useNewLine);
      return null;
    };
    AbstractEmitterVisitor.prototype.visitAllExpressions = function(expressions, ctx, separator, newLine) {
      var _this = this;
      if (newLine === void 0) {
        newLine = false;
      }
      this.visitAllObjects(function(expr) {
        return expr.visitExpression(_this, ctx);
      }, expressions, ctx, separator, newLine);
    };
    AbstractEmitterVisitor.prototype.visitAllObjects = function(handler, expressions, ctx, separator, newLine) {
      if (newLine === void 0) {
        newLine = false;
      }
      for (var i = 0; i < expressions.length; i++) {
        if (i > 0) {
          ctx.print(separator, newLine);
        }
        handler(expressions[i]);
      }
      if (newLine) {
        ctx.println();
      }
    };
    AbstractEmitterVisitor.prototype.visitAllStatements = function(statements, ctx) {
      var _this = this;
      statements.forEach(function(stmt) {
        return stmt.visitStatement(_this, ctx);
      });
    };
    return AbstractEmitterVisitor;
  }());
  exports.AbstractEmitterVisitor = AbstractEmitterVisitor;
  function escapeSingleQuoteString(input, escapeDollar) {
    if (lang_1.isBlank(input)) {
      return null;
    }
    var body = lang_1.StringWrapper.replaceAllMapped(input, _SINGLE_QUOTE_ESCAPE_STRING_RE, function(match) {
      if (match[0] == '$') {
        return escapeDollar ? '\\$' : '$';
      } else if (match[0] == '\n') {
        return '\\n';
      } else if (match[0] == '\r') {
        return '\\r';
      } else {
        return "\\" + match[0];
      }
    });
    return "'" + body + "'";
  }
  exports.escapeSingleQuoteString = escapeSingleQuoteString;
  function _createIndent(count) {
    var res = '';
    for (var i = 0; i < count; i++) {
      res += '  ';
    }
    return res;
  }
  return module.exports;
});

$__System.registerDynamic("27", ["f", "13", "d", "24"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var o = $__require('f');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var abstract_emitter_1 = $__require('24');
  var _debugModuleUrl = 'asset://debug/lib';
  function debugOutputAstAsTypeScript(ast) {
    var converter = new _TsEmitterVisitor(_debugModuleUrl);
    var ctx = abstract_emitter_1.EmitterVisitorContext.createRoot([]);
    var asts;
    if (lang_1.isArray(ast)) {
      asts = ast;
    } else {
      asts = [ast];
    }
    asts.forEach(function(ast) {
      if (ast instanceof o.Statement) {
        ast.visitStatement(converter, ctx);
      } else if (ast instanceof o.Expression) {
        ast.visitExpression(converter, ctx);
      } else if (ast instanceof o.Type) {
        ast.visitType(converter, ctx);
      } else {
        throw new exceptions_1.BaseException("Don't know how to print debug info for " + ast);
      }
    });
    return ctx.toSource();
  }
  exports.debugOutputAstAsTypeScript = debugOutputAstAsTypeScript;
  var TypeScriptEmitter = (function() {
    function TypeScriptEmitter(_importGenerator) {
      this._importGenerator = _importGenerator;
    }
    TypeScriptEmitter.prototype.emitStatements = function(moduleUrl, stmts, exportedVars) {
      var _this = this;
      var converter = new _TsEmitterVisitor(moduleUrl);
      var ctx = abstract_emitter_1.EmitterVisitorContext.createRoot(exportedVars);
      converter.visitAllStatements(stmts, ctx);
      var srcParts = [];
      converter.importsWithPrefixes.forEach(function(prefix, importedModuleUrl) {
        srcParts.push("imp" + ("ort * as " + prefix + " from '" + _this._importGenerator.getImportPath(moduleUrl, importedModuleUrl) + "';"));
      });
      srcParts.push(ctx.toSource());
      return srcParts.join('\n');
    };
    return TypeScriptEmitter;
  }());
  exports.TypeScriptEmitter = TypeScriptEmitter;
  var _TsEmitterVisitor = (function(_super) {
    __extends(_TsEmitterVisitor, _super);
    function _TsEmitterVisitor(_moduleUrl) {
      _super.call(this, false);
      this._moduleUrl = _moduleUrl;
      this.importsWithPrefixes = new Map();
    }
    _TsEmitterVisitor.prototype.visitExternalExpr = function(ast, ctx) {
      this._visitIdentifier(ast.value, ast.typeParams, ctx);
      return null;
    };
    _TsEmitterVisitor.prototype.visitDeclareVarStmt = function(stmt, ctx) {
      if (ctx.isExportedVar(stmt.name)) {
        ctx.print("export ");
      }
      if (stmt.hasModifier(o.StmtModifier.Final)) {
        ctx.print("const");
      } else {
        ctx.print("var");
      }
      ctx.print(" " + stmt.name);
      if (lang_1.isPresent(stmt.type)) {
        ctx.print(":");
        stmt.type.visitType(this, ctx);
      }
      ctx.print(" = ");
      stmt.value.visitExpression(this, ctx);
      ctx.println(";");
      return null;
    };
    _TsEmitterVisitor.prototype.visitCastExpr = function(ast, ctx) {
      ctx.print("(<");
      ast.type.visitType(this, ctx);
      ctx.print(">");
      ast.value.visitExpression(this, ctx);
      ctx.print(")");
      return null;
    };
    _TsEmitterVisitor.prototype.visitDeclareClassStmt = function(stmt, ctx) {
      var _this = this;
      ctx.pushClass(stmt);
      if (ctx.isExportedVar(stmt.name)) {
        ctx.print("export ");
      }
      ctx.print("class " + stmt.name);
      if (lang_1.isPresent(stmt.parent)) {
        ctx.print(" extends ");
        stmt.parent.visitExpression(this, ctx);
      }
      ctx.println(" {");
      ctx.incIndent();
      stmt.fields.forEach(function(field) {
        return _this._visitClassField(field, ctx);
      });
      if (lang_1.isPresent(stmt.constructorMethod)) {
        this._visitClassConstructor(stmt, ctx);
      }
      stmt.getters.forEach(function(getter) {
        return _this._visitClassGetter(getter, ctx);
      });
      stmt.methods.forEach(function(method) {
        return _this._visitClassMethod(method, ctx);
      });
      ctx.decIndent();
      ctx.println("}");
      ctx.popClass();
      return null;
    };
    _TsEmitterVisitor.prototype._visitClassField = function(field, ctx) {
      if (field.hasModifier(o.StmtModifier.Private)) {
        ctx.print("private ");
      }
      ctx.print(field.name);
      if (lang_1.isPresent(field.type)) {
        ctx.print(":");
        field.type.visitType(this, ctx);
      } else {
        ctx.print(": any");
      }
      ctx.println(";");
    };
    _TsEmitterVisitor.prototype._visitClassGetter = function(getter, ctx) {
      if (getter.hasModifier(o.StmtModifier.Private)) {
        ctx.print("private ");
      }
      ctx.print("get " + getter.name + "()");
      if (lang_1.isPresent(getter.type)) {
        ctx.print(":");
        getter.type.visitType(this, ctx);
      }
      ctx.println(" {");
      ctx.incIndent();
      this.visitAllStatements(getter.body, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _TsEmitterVisitor.prototype._visitClassConstructor = function(stmt, ctx) {
      ctx.print("constructor(");
      this._visitParams(stmt.constructorMethod.params, ctx);
      ctx.println(") {");
      ctx.incIndent();
      this.visitAllStatements(stmt.constructorMethod.body, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _TsEmitterVisitor.prototype._visitClassMethod = function(method, ctx) {
      if (method.hasModifier(o.StmtModifier.Private)) {
        ctx.print("private ");
      }
      ctx.print(method.name + "(");
      this._visitParams(method.params, ctx);
      ctx.print("):");
      if (lang_1.isPresent(method.type)) {
        method.type.visitType(this, ctx);
      } else {
        ctx.print("void");
      }
      ctx.println(" {");
      ctx.incIndent();
      this.visitAllStatements(method.body, ctx);
      ctx.decIndent();
      ctx.println("}");
    };
    _TsEmitterVisitor.prototype.visitFunctionExpr = function(ast, ctx) {
      ctx.print("(");
      this._visitParams(ast.params, ctx);
      ctx.print("):");
      if (lang_1.isPresent(ast.type)) {
        ast.type.visitType(this, ctx);
      } else {
        ctx.print("void");
      }
      ctx.println(" => {");
      ctx.incIndent();
      this.visitAllStatements(ast.statements, ctx);
      ctx.decIndent();
      ctx.print("}");
      return null;
    };
    _TsEmitterVisitor.prototype.visitDeclareFunctionStmt = function(stmt, ctx) {
      if (ctx.isExportedVar(stmt.name)) {
        ctx.print("export ");
      }
      ctx.print("function " + stmt.name + "(");
      this._visitParams(stmt.params, ctx);
      ctx.print("):");
      if (lang_1.isPresent(stmt.type)) {
        stmt.type.visitType(this, ctx);
      } else {
        ctx.print("void");
      }
      ctx.println(" {");
      ctx.incIndent();
      this.visitAllStatements(stmt.statements, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    _TsEmitterVisitor.prototype.visitTryCatchStmt = function(stmt, ctx) {
      ctx.println("try {");
      ctx.incIndent();
      this.visitAllStatements(stmt.bodyStmts, ctx);
      ctx.decIndent();
      ctx.println("} catch (" + abstract_emitter_1.CATCH_ERROR_VAR.name + ") {");
      ctx.incIndent();
      var catchStmts = [abstract_emitter_1.CATCH_STACK_VAR.set(abstract_emitter_1.CATCH_ERROR_VAR.prop('stack')).toDeclStmt(null, [o.StmtModifier.Final])].concat(stmt.catchStmts);
      this.visitAllStatements(catchStmts, ctx);
      ctx.decIndent();
      ctx.println("}");
      return null;
    };
    _TsEmitterVisitor.prototype.visitBuiltintType = function(type, ctx) {
      var typeStr;
      switch (type.name) {
        case o.BuiltinTypeName.Bool:
          typeStr = 'boolean';
          break;
        case o.BuiltinTypeName.Dynamic:
          typeStr = 'any';
          break;
        case o.BuiltinTypeName.Function:
          typeStr = 'Function';
          break;
        case o.BuiltinTypeName.Number:
          typeStr = 'number';
          break;
        case o.BuiltinTypeName.Int:
          typeStr = 'number';
          break;
        case o.BuiltinTypeName.String:
          typeStr = 'string';
          break;
        default:
          throw new exceptions_1.BaseException("Unsupported builtin type " + type.name);
      }
      ctx.print(typeStr);
      return null;
    };
    _TsEmitterVisitor.prototype.visitExternalType = function(ast, ctx) {
      this._visitIdentifier(ast.value, ast.typeParams, ctx);
      return null;
    };
    _TsEmitterVisitor.prototype.visitArrayType = function(type, ctx) {
      if (lang_1.isPresent(type.of)) {
        type.of.visitType(this, ctx);
      } else {
        ctx.print("any");
      }
      ctx.print("[]");
      return null;
    };
    _TsEmitterVisitor.prototype.visitMapType = function(type, ctx) {
      ctx.print("{[key: string]:");
      if (lang_1.isPresent(type.valueType)) {
        type.valueType.visitType(this, ctx);
      } else {
        ctx.print("any");
      }
      ctx.print("}");
      return null;
    };
    _TsEmitterVisitor.prototype.getBuiltinMethodName = function(method) {
      var name;
      switch (method) {
        case o.BuiltinMethod.ConcatArray:
          name = 'concat';
          break;
        case o.BuiltinMethod.SubscribeObservable:
          name = 'subscribe';
          break;
        case o.BuiltinMethod.bind:
          name = 'bind';
          break;
        default:
          throw new exceptions_1.BaseException("Unknown builtin method: " + method);
      }
      return name;
    };
    _TsEmitterVisitor.prototype._visitParams = function(params, ctx) {
      var _this = this;
      this.visitAllObjects(function(param) {
        ctx.print(param.name);
        if (lang_1.isPresent(param.type)) {
          ctx.print(":");
          param.type.visitType(_this, ctx);
        }
      }, params, ctx, ',');
    };
    _TsEmitterVisitor.prototype._visitIdentifier = function(value, typeParams, ctx) {
      var _this = this;
      if (lang_1.isBlank(value.name)) {
        throw new exceptions_1.BaseException("Internal error: unknown identifier " + value);
      }
      if (lang_1.isPresent(value.moduleUrl) && value.moduleUrl != this._moduleUrl) {
        var prefix = this.importsWithPrefixes.get(value.moduleUrl);
        if (lang_1.isBlank(prefix)) {
          prefix = "import" + this.importsWithPrefixes.size;
          this.importsWithPrefixes.set(value.moduleUrl, prefix);
        }
        ctx.print(prefix + ".");
      }
      ctx.print(value.name);
      if (lang_1.isPresent(typeParams) && typeParams.length > 0) {
        ctx.print("<");
        this.visitAllObjects(function(type) {
          return type.visitType(_this, ctx);
        }, typeParams, ctx, ',');
        ctx.print(">");
      }
    };
    return _TsEmitterVisitor;
  }(abstract_emitter_1.AbstractEmitterVisitor));
  return module.exports;
});

$__System.registerDynamic("28", ["11", "13", "29", "d", "e", "f", "26", "27"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var async_1 = $__require('29');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var dart_emitter_1 = $__require('26');
  var ts_emitter_1 = $__require('27');
  function interpretStatements(statements, resultVar, instanceFactory) {
    var stmtsWithReturn = statements.concat([new o.ReturnStatement(o.variable(resultVar))]);
    var ctx = new _ExecutionContext(null, null, null, null, new Map(), new Map(), new Map(), new Map(), instanceFactory);
    var visitor = new StatementInterpreter();
    var result = visitor.visitAllStatements(stmtsWithReturn, ctx);
    return lang_1.isPresent(result) ? result.value : null;
  }
  exports.interpretStatements = interpretStatements;
  var DynamicInstance = (function() {
    function DynamicInstance() {}
    Object.defineProperty(DynamicInstance.prototype, "props", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DynamicInstance.prototype, "getters", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DynamicInstance.prototype, "methods", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DynamicInstance.prototype, "clazz", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return DynamicInstance;
  }());
  exports.DynamicInstance = DynamicInstance;
  function isDynamicInstance(instance) {
    if (lang_1.IS_DART) {
      return instance instanceof DynamicInstance;
    } else {
      return lang_1.isPresent(instance) && lang_1.isPresent(instance.props) && lang_1.isPresent(instance.getters) && lang_1.isPresent(instance.methods);
    }
  }
  function _executeFunctionStatements(varNames, varValues, statements, ctx, visitor) {
    var childCtx = ctx.createChildWihtLocalVars();
    for (var i = 0; i < varNames.length; i++) {
      childCtx.vars.set(varNames[i], varValues[i]);
    }
    var result = visitor.visitAllStatements(statements, childCtx);
    return lang_1.isPresent(result) ? result.value : null;
  }
  var _ExecutionContext = (function() {
    function _ExecutionContext(parent, superClass, superInstance, className, vars, props, getters, methods, instanceFactory) {
      this.parent = parent;
      this.superClass = superClass;
      this.superInstance = superInstance;
      this.className = className;
      this.vars = vars;
      this.props = props;
      this.getters = getters;
      this.methods = methods;
      this.instanceFactory = instanceFactory;
    }
    _ExecutionContext.prototype.createChildWihtLocalVars = function() {
      return new _ExecutionContext(this, this.superClass, this.superInstance, this.className, new Map(), this.props, this.getters, this.methods, this.instanceFactory);
    };
    return _ExecutionContext;
  }());
  var ReturnValue = (function() {
    function ReturnValue(value) {
      this.value = value;
    }
    return ReturnValue;
  }());
  var _DynamicClass = (function() {
    function _DynamicClass(_classStmt, _ctx, _visitor) {
      this._classStmt = _classStmt;
      this._ctx = _ctx;
      this._visitor = _visitor;
    }
    _DynamicClass.prototype.instantiate = function(args) {
      var _this = this;
      var props = new Map();
      var getters = new Map();
      var methods = new Map();
      var superClass = this._classStmt.parent.visitExpression(this._visitor, this._ctx);
      var instanceCtx = new _ExecutionContext(this._ctx, superClass, null, this._classStmt.name, this._ctx.vars, props, getters, methods, this._ctx.instanceFactory);
      this._classStmt.fields.forEach(function(field) {
        props.set(field.name, null);
      });
      this._classStmt.getters.forEach(function(getter) {
        getters.set(getter.name, function() {
          return _executeFunctionStatements([], [], getter.body, instanceCtx, _this._visitor);
        });
      });
      this._classStmt.methods.forEach(function(method) {
        var paramNames = method.params.map(function(param) {
          return param.name;
        });
        methods.set(method.name, _declareFn(paramNames, method.body, instanceCtx, _this._visitor));
      });
      var ctorParamNames = this._classStmt.constructorMethod.params.map(function(param) {
        return param.name;
      });
      _executeFunctionStatements(ctorParamNames, args, this._classStmt.constructorMethod.body, instanceCtx, this._visitor);
      return instanceCtx.superInstance;
    };
    _DynamicClass.prototype.debugAst = function() {
      return this._visitor.debugAst(this._classStmt);
    };
    return _DynamicClass;
  }());
  var StatementInterpreter = (function() {
    function StatementInterpreter() {}
    StatementInterpreter.prototype.debugAst = function(ast) {
      return lang_1.IS_DART ? dart_emitter_1.debugOutputAstAsDart(ast) : ts_emitter_1.debugOutputAstAsTypeScript(ast);
    };
    StatementInterpreter.prototype.visitDeclareVarStmt = function(stmt, ctx) {
      ctx.vars.set(stmt.name, stmt.value.visitExpression(this, ctx));
      return null;
    };
    StatementInterpreter.prototype.visitWriteVarExpr = function(expr, ctx) {
      var value = expr.value.visitExpression(this, ctx);
      var currCtx = ctx;
      while (currCtx != null) {
        if (currCtx.vars.has(expr.name)) {
          currCtx.vars.set(expr.name, value);
          return value;
        }
        currCtx = currCtx.parent;
      }
      throw new exceptions_1.BaseException("Not declared variable " + expr.name);
    };
    StatementInterpreter.prototype.visitReadVarExpr = function(ast, ctx) {
      var varName = ast.name;
      if (lang_1.isPresent(ast.builtin)) {
        switch (ast.builtin) {
          case o.BuiltinVar.Super:
          case o.BuiltinVar.This:
            return ctx.superInstance;
          case o.BuiltinVar.CatchError:
            varName = CATCH_ERROR_VAR;
            break;
          case o.BuiltinVar.CatchStack:
            varName = CATCH_STACK_VAR;
            break;
          default:
            throw new exceptions_1.BaseException("Unknown builtin variable " + ast.builtin);
        }
      }
      var currCtx = ctx;
      while (currCtx != null) {
        if (currCtx.vars.has(varName)) {
          return currCtx.vars.get(varName);
        }
        currCtx = currCtx.parent;
      }
      throw new exceptions_1.BaseException("Not declared variable " + varName);
    };
    StatementInterpreter.prototype.visitWriteKeyExpr = function(expr, ctx) {
      var receiver = expr.receiver.visitExpression(this, ctx);
      var index = expr.index.visitExpression(this, ctx);
      var value = expr.value.visitExpression(this, ctx);
      receiver[index] = value;
      return value;
    };
    StatementInterpreter.prototype.visitWritePropExpr = function(expr, ctx) {
      var receiver = expr.receiver.visitExpression(this, ctx);
      var value = expr.value.visitExpression(this, ctx);
      if (isDynamicInstance(receiver)) {
        var di = receiver;
        if (di.props.has(expr.name)) {
          di.props.set(expr.name, value);
        } else {
          core_1.reflector.setter(expr.name)(receiver, value);
        }
      } else {
        core_1.reflector.setter(expr.name)(receiver, value);
      }
      return value;
    };
    StatementInterpreter.prototype.visitInvokeMethodExpr = function(expr, ctx) {
      var receiver = expr.receiver.visitExpression(this, ctx);
      var args = this.visitAllExpressions(expr.args, ctx);
      var result;
      if (lang_1.isPresent(expr.builtin)) {
        switch (expr.builtin) {
          case o.BuiltinMethod.ConcatArray:
            result = collection_1.ListWrapper.concat(receiver, args[0]);
            break;
          case o.BuiltinMethod.SubscribeObservable:
            result = async_1.ObservableWrapper.subscribe(receiver, args[0]);
            break;
          case o.BuiltinMethod.bind:
            if (lang_1.IS_DART) {
              result = receiver;
            } else {
              result = receiver.bind(args[0]);
            }
            break;
          default:
            throw new exceptions_1.BaseException("Unknown builtin method " + expr.builtin);
        }
      } else if (isDynamicInstance(receiver)) {
        var di = receiver;
        if (di.methods.has(expr.name)) {
          result = lang_1.FunctionWrapper.apply(di.methods.get(expr.name), args);
        } else {
          result = core_1.reflector.method(expr.name)(receiver, args);
        }
      } else {
        result = core_1.reflector.method(expr.name)(receiver, args);
      }
      return result;
    };
    StatementInterpreter.prototype.visitInvokeFunctionExpr = function(stmt, ctx) {
      var args = this.visitAllExpressions(stmt.args, ctx);
      var fnExpr = stmt.fn;
      if (fnExpr instanceof o.ReadVarExpr && fnExpr.builtin === o.BuiltinVar.Super) {
        ctx.superInstance = ctx.instanceFactory.createInstance(ctx.superClass, ctx.className, args, ctx.props, ctx.getters, ctx.methods);
        ctx.parent.superInstance = ctx.superInstance;
        return null;
      } else {
        var fn = stmt.fn.visitExpression(this, ctx);
        return lang_1.FunctionWrapper.apply(fn, args);
      }
    };
    StatementInterpreter.prototype.visitReturnStmt = function(stmt, ctx) {
      return new ReturnValue(stmt.value.visitExpression(this, ctx));
    };
    StatementInterpreter.prototype.visitDeclareClassStmt = function(stmt, ctx) {
      var clazz = new _DynamicClass(stmt, ctx, this);
      ctx.vars.set(stmt.name, clazz);
      return null;
    };
    StatementInterpreter.prototype.visitExpressionStmt = function(stmt, ctx) {
      return stmt.expr.visitExpression(this, ctx);
    };
    StatementInterpreter.prototype.visitIfStmt = function(stmt, ctx) {
      var condition = stmt.condition.visitExpression(this, ctx);
      if (condition) {
        return this.visitAllStatements(stmt.trueCase, ctx);
      } else if (lang_1.isPresent(stmt.falseCase)) {
        return this.visitAllStatements(stmt.falseCase, ctx);
      }
      return null;
    };
    StatementInterpreter.prototype.visitTryCatchStmt = function(stmt, ctx) {
      try {
        return this.visitAllStatements(stmt.bodyStmts, ctx);
      } catch (e) {
        var childCtx = ctx.createChildWihtLocalVars();
        childCtx.vars.set(CATCH_ERROR_VAR, e);
        childCtx.vars.set(CATCH_STACK_VAR, e.stack);
        return this.visitAllStatements(stmt.catchStmts, childCtx);
      }
    };
    StatementInterpreter.prototype.visitThrowStmt = function(stmt, ctx) {
      throw stmt.error.visitExpression(this, ctx);
    };
    StatementInterpreter.prototype.visitCommentStmt = function(stmt, context) {
      return null;
    };
    StatementInterpreter.prototype.visitInstantiateExpr = function(ast, ctx) {
      var args = this.visitAllExpressions(ast.args, ctx);
      var clazz = ast.classExpr.visitExpression(this, ctx);
      if (clazz instanceof _DynamicClass) {
        return clazz.instantiate(args);
      } else {
        return lang_1.FunctionWrapper.apply(core_1.reflector.factory(clazz), args);
      }
    };
    StatementInterpreter.prototype.visitLiteralExpr = function(ast, ctx) {
      return ast.value;
    };
    StatementInterpreter.prototype.visitExternalExpr = function(ast, ctx) {
      return ast.value.runtime;
    };
    StatementInterpreter.prototype.visitConditionalExpr = function(ast, ctx) {
      if (ast.condition.visitExpression(this, ctx)) {
        return ast.trueCase.visitExpression(this, ctx);
      } else if (lang_1.isPresent(ast.falseCase)) {
        return ast.falseCase.visitExpression(this, ctx);
      }
      return null;
    };
    StatementInterpreter.prototype.visitNotExpr = function(ast, ctx) {
      return !ast.condition.visitExpression(this, ctx);
    };
    StatementInterpreter.prototype.visitCastExpr = function(ast, ctx) {
      return ast.value.visitExpression(this, ctx);
    };
    StatementInterpreter.prototype.visitFunctionExpr = function(ast, ctx) {
      var paramNames = ast.params.map(function(param) {
        return param.name;
      });
      return _declareFn(paramNames, ast.statements, ctx, this);
    };
    StatementInterpreter.prototype.visitDeclareFunctionStmt = function(stmt, ctx) {
      var paramNames = stmt.params.map(function(param) {
        return param.name;
      });
      ctx.vars.set(stmt.name, _declareFn(paramNames, stmt.statements, ctx, this));
      return null;
    };
    StatementInterpreter.prototype.visitBinaryOperatorExpr = function(ast, ctx) {
      var _this = this;
      var lhs = function() {
        return ast.lhs.visitExpression(_this, ctx);
      };
      var rhs = function() {
        return ast.rhs.visitExpression(_this, ctx);
      };
      switch (ast.operator) {
        case o.BinaryOperator.Equals:
          return lhs() == rhs();
        case o.BinaryOperator.Identical:
          return lhs() === rhs();
        case o.BinaryOperator.NotEquals:
          return lhs() != rhs();
        case o.BinaryOperator.NotIdentical:
          return lhs() !== rhs();
        case o.BinaryOperator.And:
          return lhs() && rhs();
        case o.BinaryOperator.Or:
          return lhs() || rhs();
        case o.BinaryOperator.Plus:
          return lhs() + rhs();
        case o.BinaryOperator.Minus:
          return lhs() - rhs();
        case o.BinaryOperator.Divide:
          return lhs() / rhs();
        case o.BinaryOperator.Multiply:
          return lhs() * rhs();
        case o.BinaryOperator.Modulo:
          return lhs() % rhs();
        case o.BinaryOperator.Lower:
          return lhs() < rhs();
        case o.BinaryOperator.LowerEquals:
          return lhs() <= rhs();
        case o.BinaryOperator.Bigger:
          return lhs() > rhs();
        case o.BinaryOperator.BiggerEquals:
          return lhs() >= rhs();
        default:
          throw new exceptions_1.BaseException("Unknown operator " + ast.operator);
      }
    };
    StatementInterpreter.prototype.visitReadPropExpr = function(ast, ctx) {
      var result;
      var receiver = ast.receiver.visitExpression(this, ctx);
      if (isDynamicInstance(receiver)) {
        var di = receiver;
        if (di.props.has(ast.name)) {
          result = di.props.get(ast.name);
        } else if (di.getters.has(ast.name)) {
          result = di.getters.get(ast.name)();
        } else if (di.methods.has(ast.name)) {
          result = di.methods.get(ast.name);
        } else {
          result = core_1.reflector.getter(ast.name)(receiver);
        }
      } else {
        result = core_1.reflector.getter(ast.name)(receiver);
      }
      return result;
    };
    StatementInterpreter.prototype.visitReadKeyExpr = function(ast, ctx) {
      var receiver = ast.receiver.visitExpression(this, ctx);
      var prop = ast.index.visitExpression(this, ctx);
      return receiver[prop];
    };
    StatementInterpreter.prototype.visitLiteralArrayExpr = function(ast, ctx) {
      return this.visitAllExpressions(ast.entries, ctx);
    };
    StatementInterpreter.prototype.visitLiteralMapExpr = function(ast, ctx) {
      var _this = this;
      var result = {};
      ast.entries.forEach(function(entry) {
        return result[entry[0]] = entry[1].visitExpression(_this, ctx);
      });
      return result;
    };
    StatementInterpreter.prototype.visitAllExpressions = function(expressions, ctx) {
      var _this = this;
      return expressions.map(function(expr) {
        return expr.visitExpression(_this, ctx);
      });
    };
    StatementInterpreter.prototype.visitAllStatements = function(statements, ctx) {
      for (var i = 0; i < statements.length; i++) {
        var stmt = statements[i];
        var val = stmt.visitStatement(this, ctx);
        if (val instanceof ReturnValue) {
          return val;
        }
      }
      return null;
    };
    return StatementInterpreter;
  }());
  function _declareFn(varNames, statements, ctx, visitor) {
    switch (varNames.length) {
      case 0:
        return function() {
          return _executeFunctionStatements(varNames, [], statements, ctx, visitor);
        };
      case 1:
        return function(d0) {
          return _executeFunctionStatements(varNames, [d0], statements, ctx, visitor);
        };
      case 2:
        return function(d0, d1) {
          return _executeFunctionStatements(varNames, [d0, d1], statements, ctx, visitor);
        };
      case 3:
        return function(d0, d1, d2) {
          return _executeFunctionStatements(varNames, [d0, d1, d2], statements, ctx, visitor);
        };
      case 4:
        return function(d0, d1, d2, d3) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3], statements, ctx, visitor);
        };
      case 5:
        return function(d0, d1, d2, d3, d4) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4], statements, ctx, visitor);
        };
      case 6:
        return function(d0, d1, d2, d3, d4, d5) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4, d5], statements, ctx, visitor);
        };
      case 7:
        return function(d0, d1, d2, d3, d4, d5, d6) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4, d5, d6], statements, ctx, visitor);
        };
      case 8:
        return function(d0, d1, d2, d3, d4, d5, d6, d7) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4, d5, d6, d7], statements, ctx, visitor);
        };
      case 9:
        return function(d0, d1, d2, d3, d4, d5, d6, d7, d8) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4, d5, d6, d7, d8], statements, ctx, visitor);
        };
      case 10:
        return function(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9) {
          return _executeFunctionStatements(varNames, [d0, d1, d2, d3, d4, d5, d6, d7, d8, d9], statements, ctx, visitor);
        };
      default:
        throw new exceptions_1.BaseException('Declaring functions with more than 10 arguments is not supported right now');
    }
  }
  var CATCH_ERROR_VAR = 'error';
  var CATCH_STACK_VAR = 'stack';
  return module.exports;
});

$__System.registerDynamic("2a", ["18", "13", "d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var InterpretiveAppViewInstanceFactory = (function() {
    function InterpretiveAppViewInstanceFactory() {}
    InterpretiveAppViewInstanceFactory.prototype.createInstance = function(superClass, clazz, args, props, getters, methods) {
      if (superClass === core_private_1.AppView) {
        args = args.concat([null]);
        return new _InterpretiveAppView(args, props, getters, methods);
      } else if (superClass === core_private_1.DebugAppView) {
        return new _InterpretiveAppView(args, props, getters, methods);
      }
      throw new exceptions_1.BaseException("Can't instantiate class " + superClass + " in interpretative mode");
    };
    return InterpretiveAppViewInstanceFactory;
  }());
  exports.InterpretiveAppViewInstanceFactory = InterpretiveAppViewInstanceFactory;
  var _InterpretiveAppView = (function(_super) {
    __extends(_InterpretiveAppView, _super);
    function _InterpretiveAppView(args, props, getters, methods) {
      _super.call(this, args[0], args[1], args[2], args[3], args[4], args[5], args[6], args[7]);
      this.props = props;
      this.getters = getters;
      this.methods = methods;
    }
    _InterpretiveAppView.prototype.createInternal = function(rootSelector) {
      var m = this.methods.get('createInternal');
      if (lang_1.isPresent(m)) {
        return m(rootSelector);
      } else {
        return _super.prototype.createInternal.call(this, rootSelector);
      }
    };
    _InterpretiveAppView.prototype.injectorGetInternal = function(token, nodeIndex, notFoundResult) {
      var m = this.methods.get('injectorGetInternal');
      if (lang_1.isPresent(m)) {
        return m(token, nodeIndex, notFoundResult);
      } else {
        return _super.prototype.injectorGet.call(this, token, nodeIndex, notFoundResult);
      }
    };
    _InterpretiveAppView.prototype.destroyInternal = function() {
      var m = this.methods.get('destroyInternal');
      if (lang_1.isPresent(m)) {
        return m();
      } else {
        return _super.prototype.destroyInternal.call(this);
      }
    };
    _InterpretiveAppView.prototype.dirtyParentQueriesInternal = function() {
      var m = this.methods.get('dirtyParentQueriesInternal');
      if (lang_1.isPresent(m)) {
        return m();
      } else {
        return _super.prototype.dirtyParentQueriesInternal.call(this);
      }
    };
    _InterpretiveAppView.prototype.detectChangesInternal = function(throwOnChange) {
      var m = this.methods.get('detectChangesInternal');
      if (lang_1.isPresent(m)) {
        return m(throwOnChange);
      } else {
        return _super.prototype.detectChangesInternal.call(this, throwOnChange);
      }
    };
    return _InterpretiveAppView;
  }(core_private_1.DebugAppView));
  return module.exports;
});

$__System.registerDynamic("2b", ["11", "13", "d", "e", "29", "c", "2c", "2d", "17", "2e", "2f", "30", "f", "25", "28", "2a", "31"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var async_1 = $__require('29');
  var compile_metadata_1 = $__require('c');
  var style_compiler_1 = $__require('2c');
  var view_compiler_1 = $__require('2d');
  var template_parser_1 = $__require('17');
  var directive_normalizer_1 = $__require('2e');
  var metadata_resolver_1 = $__require('2f');
  var config_1 = $__require('30');
  var ir = $__require('f');
  var output_jit_1 = $__require('25');
  var output_interpreter_1 = $__require('28');
  var interpretive_view_1 = $__require('2a');
  var xhr_1 = $__require('31');
  var RuntimeCompiler = (function() {
    function RuntimeCompiler(_metadataResolver, _templateNormalizer, _templateParser, _styleCompiler, _viewCompiler, _xhr, _genConfig) {
      this._metadataResolver = _metadataResolver;
      this._templateNormalizer = _templateNormalizer;
      this._templateParser = _templateParser;
      this._styleCompiler = _styleCompiler;
      this._viewCompiler = _viewCompiler;
      this._xhr = _xhr;
      this._genConfig = _genConfig;
      this._styleCache = new Map();
      this._hostCacheKeys = new Map();
      this._compiledTemplateCache = new Map();
      this._compiledTemplateDone = new Map();
    }
    RuntimeCompiler.prototype.resolveComponent = function(componentType) {
      var compMeta = this._metadataResolver.getDirectiveMetadata(componentType);
      var hostCacheKey = this._hostCacheKeys.get(componentType);
      if (lang_1.isBlank(hostCacheKey)) {
        hostCacheKey = new Object();
        this._hostCacheKeys.set(componentType, hostCacheKey);
        assertComponent(compMeta);
        var hostMeta = compile_metadata_1.createHostComponentMeta(compMeta.type, compMeta.selector);
        this._loadAndCompileComponent(hostCacheKey, hostMeta, [compMeta], [], []);
      }
      return this._compiledTemplateDone.get(hostCacheKey).then(function(compiledTemplate) {
        return new core_1.ComponentFactory(compMeta.selector, compiledTemplate.viewFactory, componentType);
      });
    };
    RuntimeCompiler.prototype.clearCache = function() {
      this._styleCache.clear();
      this._compiledTemplateCache.clear();
      this._compiledTemplateDone.clear();
      this._hostCacheKeys.clear();
    };
    RuntimeCompiler.prototype._loadAndCompileComponent = function(cacheKey, compMeta, viewDirectives, pipes, compilingComponentsPath) {
      var _this = this;
      var compiledTemplate = this._compiledTemplateCache.get(cacheKey);
      var done = this._compiledTemplateDone.get(cacheKey);
      if (lang_1.isBlank(compiledTemplate)) {
        compiledTemplate = new CompiledTemplate();
        this._compiledTemplateCache.set(cacheKey, compiledTemplate);
        done = async_1.PromiseWrapper.all([this._compileComponentStyles(compMeta)].concat(viewDirectives.map(function(dirMeta) {
          return _this._templateNormalizer.normalizeDirective(dirMeta);
        }))).then(function(stylesAndNormalizedViewDirMetas) {
          var normalizedViewDirMetas = stylesAndNormalizedViewDirMetas.slice(1);
          var styles = stylesAndNormalizedViewDirMetas[0];
          var parsedTemplate = _this._templateParser.parse(compMeta, compMeta.template.template, normalizedViewDirMetas, pipes, compMeta.type.name);
          var childPromises = [];
          compiledTemplate.init(_this._compileComponent(compMeta, parsedTemplate, styles, pipes, compilingComponentsPath, childPromises));
          return async_1.PromiseWrapper.all(childPromises).then(function(_) {
            return compiledTemplate;
          });
        });
        this._compiledTemplateDone.set(cacheKey, done);
      }
      return compiledTemplate;
    };
    RuntimeCompiler.prototype._compileComponent = function(compMeta, parsedTemplate, styles, pipes, compilingComponentsPath, childPromises) {
      var _this = this;
      var compileResult = this._viewCompiler.compileComponent(compMeta, parsedTemplate, new ir.ExternalExpr(new compile_metadata_1.CompileIdentifierMetadata({runtime: styles})), pipes);
      compileResult.dependencies.forEach(function(dep) {
        var childCompilingComponentsPath = collection_1.ListWrapper.clone(compilingComponentsPath);
        var childCacheKey = dep.comp.type.runtime;
        var childViewDirectives = _this._metadataResolver.getViewDirectivesMetadata(dep.comp.type.runtime);
        var childViewPipes = _this._metadataResolver.getViewPipesMetadata(dep.comp.type.runtime);
        var childIsRecursive = collection_1.ListWrapper.contains(childCompilingComponentsPath, childCacheKey);
        childCompilingComponentsPath.push(childCacheKey);
        var childComp = _this._loadAndCompileComponent(dep.comp.type.runtime, dep.comp, childViewDirectives, childViewPipes, childCompilingComponentsPath);
        dep.factoryPlaceholder.runtime = childComp.proxyViewFactory;
        dep.factoryPlaceholder.name = "viewFactory_" + dep.comp.type.name;
        if (!childIsRecursive) {
          childPromises.push(_this._compiledTemplateDone.get(childCacheKey));
        }
      });
      var factory;
      if (lang_1.IS_DART || !this._genConfig.useJit) {
        factory = output_interpreter_1.interpretStatements(compileResult.statements, compileResult.viewFactoryVar, new interpretive_view_1.InterpretiveAppViewInstanceFactory());
      } else {
        factory = output_jit_1.jitStatements(compMeta.type.name + ".template.js", compileResult.statements, compileResult.viewFactoryVar);
      }
      return factory;
    };
    RuntimeCompiler.prototype._compileComponentStyles = function(compMeta) {
      var compileResult = this._styleCompiler.compileComponent(compMeta);
      return this._resolveStylesCompileResult(compMeta.type.name, compileResult);
    };
    RuntimeCompiler.prototype._resolveStylesCompileResult = function(sourceUrl, result) {
      var _this = this;
      var promises = result.dependencies.map(function(dep) {
        return _this._loadStylesheetDep(dep);
      });
      return async_1.PromiseWrapper.all(promises).then(function(cssTexts) {
        var nestedCompileResultPromises = [];
        for (var i = 0; i < result.dependencies.length; i++) {
          var dep = result.dependencies[i];
          var cssText = cssTexts[i];
          var nestedCompileResult = _this._styleCompiler.compileStylesheet(dep.moduleUrl, cssText, dep.isShimmed);
          nestedCompileResultPromises.push(_this._resolveStylesCompileResult(dep.moduleUrl, nestedCompileResult));
        }
        return async_1.PromiseWrapper.all(nestedCompileResultPromises);
      }).then(function(nestedStylesArr) {
        for (var i = 0; i < result.dependencies.length; i++) {
          var dep = result.dependencies[i];
          dep.valuePlaceholder.runtime = nestedStylesArr[i];
          dep.valuePlaceholder.name = "importedStyles" + i;
        }
        if (lang_1.IS_DART || !_this._genConfig.useJit) {
          return output_interpreter_1.interpretStatements(result.statements, result.stylesVar, new interpretive_view_1.InterpretiveAppViewInstanceFactory());
        } else {
          return output_jit_1.jitStatements(sourceUrl + ".css.js", result.statements, result.stylesVar);
        }
      });
    };
    RuntimeCompiler.prototype._loadStylesheetDep = function(dep) {
      var cacheKey = "" + dep.moduleUrl + (dep.isShimmed ? '.shim' : '');
      var cssTextPromise = this._styleCache.get(cacheKey);
      if (lang_1.isBlank(cssTextPromise)) {
        cssTextPromise = this._xhr.get(dep.moduleUrl);
        this._styleCache.set(cacheKey, cssTextPromise);
      }
      return cssTextPromise;
    };
    RuntimeCompiler.decorators = [{type: core_1.Injectable}];
    RuntimeCompiler.ctorParameters = [{type: metadata_resolver_1.CompileMetadataResolver}, {type: directive_normalizer_1.DirectiveNormalizer}, {type: template_parser_1.TemplateParser}, {type: style_compiler_1.StyleCompiler}, {type: view_compiler_1.ViewCompiler}, {type: xhr_1.XHR}, {type: config_1.CompilerConfig}];
    return RuntimeCompiler;
  }());
  exports.RuntimeCompiler = RuntimeCompiler;
  var CompiledTemplate = (function() {
    function CompiledTemplate() {
      var _this = this;
      this.viewFactory = null;
      this.proxyViewFactory = function(viewUtils, childInjector, contextEl) {
        return _this.viewFactory(viewUtils, childInjector, contextEl);
      };
    }
    CompiledTemplate.prototype.init = function(viewFactory) {
      this.viewFactory = viewFactory;
    };
    return CompiledTemplate;
  }());
  function assertComponent(meta) {
    if (!meta.isComponent) {
      throw new exceptions_1.BaseException("Could not compile '" + meta.type.name + "' because it is not a component.");
    }
  }
  return module.exports;
});

$__System.registerDynamic("32", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var PromiseCompleter = (function() {
    function PromiseCompleter() {
      var _this = this;
      this.promise = new Promise(function(res, rej) {
        _this.resolve = res;
        _this.reject = rej;
      });
    }
    return PromiseCompleter;
  }());
  exports.PromiseCompleter = PromiseCompleter;
  var PromiseWrapper = (function() {
    function PromiseWrapper() {}
    PromiseWrapper.resolve = function(obj) {
      return Promise.resolve(obj);
    };
    PromiseWrapper.reject = function(obj, _) {
      return Promise.reject(obj);
    };
    PromiseWrapper.catchError = function(promise, onError) {
      return promise.catch(onError);
    };
    PromiseWrapper.all = function(promises) {
      if (promises.length == 0)
        return Promise.resolve([]);
      return Promise.all(promises);
    };
    PromiseWrapper.then = function(promise, success, rejection) {
      return promise.then(success, rejection);
    };
    PromiseWrapper.wrap = function(computation) {
      return new Promise(function(res, rej) {
        try {
          res(computation());
        } catch (e) {
          rej(e);
        }
      });
    };
    PromiseWrapper.scheduleMicrotask = function(computation) {
      PromiseWrapper.then(PromiseWrapper.resolve(null), computation, function(_) {});
    };
    PromiseWrapper.isPromise = function(obj) {
      return obj instanceof Promise;
    };
    PromiseWrapper.completer = function() {
      return new PromiseCompleter();
    };
    return PromiseWrapper;
  }());
  exports.PromiseWrapper = PromiseWrapper;
  return module.exports;
});

$__System.registerDynamic("29", ["13", "32", "33", "34", "35", "36"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  var promise_1 = $__require('32');
  exports.PromiseWrapper = promise_1.PromiseWrapper;
  exports.PromiseCompleter = promise_1.PromiseCompleter;
  var Subject_1 = $__require('33');
  var PromiseObservable_1 = $__require('34');
  var toPromise_1 = $__require('35');
  var Observable_1 = $__require('36');
  exports.Observable = Observable_1.Observable;
  var Subject_2 = $__require('33');
  exports.Subject = Subject_2.Subject;
  var TimerWrapper = (function() {
    function TimerWrapper() {}
    TimerWrapper.setTimeout = function(fn, millis) {
      return lang_1.global.setTimeout(fn, millis);
    };
    TimerWrapper.clearTimeout = function(id) {
      lang_1.global.clearTimeout(id);
    };
    TimerWrapper.setInterval = function(fn, millis) {
      return lang_1.global.setInterval(fn, millis);
    };
    TimerWrapper.clearInterval = function(id) {
      lang_1.global.clearInterval(id);
    };
    return TimerWrapper;
  }());
  exports.TimerWrapper = TimerWrapper;
  var ObservableWrapper = (function() {
    function ObservableWrapper() {}
    ObservableWrapper.subscribe = function(emitter, onNext, onError, onComplete) {
      if (onComplete === void 0) {
        onComplete = function() {};
      }
      onError = (typeof onError === "function") && onError || lang_1.noop;
      onComplete = (typeof onComplete === "function") && onComplete || lang_1.noop;
      return emitter.subscribe({
        next: onNext,
        error: onError,
        complete: onComplete
      });
    };
    ObservableWrapper.isObservable = function(obs) {
      return !!obs.subscribe;
    };
    ObservableWrapper.hasSubscribers = function(obs) {
      return obs.observers.length > 0;
    };
    ObservableWrapper.dispose = function(subscription) {
      subscription.unsubscribe();
    };
    ObservableWrapper.callNext = function(emitter, value) {
      emitter.next(value);
    };
    ObservableWrapper.callEmit = function(emitter, value) {
      emitter.emit(value);
    };
    ObservableWrapper.callError = function(emitter, error) {
      emitter.error(error);
    };
    ObservableWrapper.callComplete = function(emitter) {
      emitter.complete();
    };
    ObservableWrapper.fromPromise = function(promise) {
      return PromiseObservable_1.PromiseObservable.create(promise);
    };
    ObservableWrapper.toPromise = function(obj) {
      return toPromise_1.toPromise.call(obj);
    };
    return ObservableWrapper;
  }());
  exports.ObservableWrapper = ObservableWrapper;
  var EventEmitter = (function(_super) {
    __extends(EventEmitter, _super);
    function EventEmitter(isAsync) {
      if (isAsync === void 0) {
        isAsync = true;
      }
      _super.call(this);
      this._isAsync = isAsync;
    }
    EventEmitter.prototype.emit = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.next = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.subscribe = function(generatorOrNext, error, complete) {
      var schedulerFn;
      var errorFn = function(err) {
        return null;
      };
      var completeFn = function() {
        return null;
      };
      if (generatorOrNext && typeof generatorOrNext === 'object') {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext.next(value);
          });
        } : function(value) {
          generatorOrNext.next(value);
        };
        if (generatorOrNext.error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return generatorOrNext.error(err);
            });
          } : function(err) {
            generatorOrNext.error(err);
          };
        }
        if (generatorOrNext.complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return generatorOrNext.complete();
            });
          } : function() {
            generatorOrNext.complete();
          };
        }
      } else {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext(value);
          });
        } : function(value) {
          generatorOrNext(value);
        };
        if (error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return error(err);
            });
          } : function(err) {
            error(err);
          };
        }
        if (complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return complete();
            });
          } : function() {
            complete();
          };
        }
      }
      return _super.prototype.subscribe.call(this, schedulerFn, errorFn, completeFn);
    };
    return EventEmitter;
  }(Subject_1.Subject));
  exports.EventEmitter = EventEmitter;
  return module.exports;
});

$__System.registerDynamic("31", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var XHR = (function() {
    function XHR() {}
    XHR.prototype.get = function(url) {
      return null;
    };
    return XHR;
  }());
  exports.XHR = XHR;
  return module.exports;
});

$__System.registerDynamic("21", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var HtmlTextAst = (function() {
    function HtmlTextAst(value, sourceSpan) {
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    HtmlTextAst.prototype.visit = function(visitor, context) {
      return visitor.visitText(this, context);
    };
    return HtmlTextAst;
  }());
  exports.HtmlTextAst = HtmlTextAst;
  var HtmlExpansionAst = (function() {
    function HtmlExpansionAst(switchValue, type, cases, sourceSpan, switchValueSourceSpan) {
      this.switchValue = switchValue;
      this.type = type;
      this.cases = cases;
      this.sourceSpan = sourceSpan;
      this.switchValueSourceSpan = switchValueSourceSpan;
    }
    HtmlExpansionAst.prototype.visit = function(visitor, context) {
      return visitor.visitExpansion(this, context);
    };
    return HtmlExpansionAst;
  }());
  exports.HtmlExpansionAst = HtmlExpansionAst;
  var HtmlExpansionCaseAst = (function() {
    function HtmlExpansionCaseAst(value, expression, sourceSpan, valueSourceSpan, expSourceSpan) {
      this.value = value;
      this.expression = expression;
      this.sourceSpan = sourceSpan;
      this.valueSourceSpan = valueSourceSpan;
      this.expSourceSpan = expSourceSpan;
    }
    HtmlExpansionCaseAst.prototype.visit = function(visitor, context) {
      return visitor.visitExpansionCase(this, context);
    };
    return HtmlExpansionCaseAst;
  }());
  exports.HtmlExpansionCaseAst = HtmlExpansionCaseAst;
  var HtmlAttrAst = (function() {
    function HtmlAttrAst(name, value, sourceSpan) {
      this.name = name;
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    HtmlAttrAst.prototype.visit = function(visitor, context) {
      return visitor.visitAttr(this, context);
    };
    return HtmlAttrAst;
  }());
  exports.HtmlAttrAst = HtmlAttrAst;
  var HtmlElementAst = (function() {
    function HtmlElementAst(name, attrs, children, sourceSpan, startSourceSpan, endSourceSpan) {
      this.name = name;
      this.attrs = attrs;
      this.children = children;
      this.sourceSpan = sourceSpan;
      this.startSourceSpan = startSourceSpan;
      this.endSourceSpan = endSourceSpan;
    }
    HtmlElementAst.prototype.visit = function(visitor, context) {
      return visitor.visitElement(this, context);
    };
    return HtmlElementAst;
  }());
  exports.HtmlElementAst = HtmlElementAst;
  var HtmlCommentAst = (function() {
    function HtmlCommentAst(value, sourceSpan) {
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    HtmlCommentAst.prototype.visit = function(visitor, context) {
      return visitor.visitComment(this, context);
    };
    return HtmlCommentAst;
  }());
  exports.HtmlCommentAst = HtmlCommentAst;
  function htmlVisitAll(visitor, asts, context) {
    if (context === void 0) {
      context = null;
    }
    var result = [];
    asts.forEach(function(ast) {
      var astResult = ast.visit(visitor, context);
      if (lang_1.isPresent(astResult)) {
        result.push(astResult);
      }
    });
    return result;
  }
  exports.htmlVisitAll = htmlVisitAll;
  return module.exports;
});

$__System.registerDynamic("37", ["13", "e", "16", "1c", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var __extends = (this && this.__extends) || function(d, b) {
      for (var p in b)
        if (b.hasOwnProperty(p))
          d[p] = b[p];
      function __() {
        this.constructor = d;
      }
      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
    var lang_1 = $__require('13');
    var collection_1 = $__require('e');
    var parse_util_1 = $__require('16');
    var html_tags_1 = $__require('1c');
    (function(HtmlTokenType) {
      HtmlTokenType[HtmlTokenType["TAG_OPEN_START"] = 0] = "TAG_OPEN_START";
      HtmlTokenType[HtmlTokenType["TAG_OPEN_END"] = 1] = "TAG_OPEN_END";
      HtmlTokenType[HtmlTokenType["TAG_OPEN_END_VOID"] = 2] = "TAG_OPEN_END_VOID";
      HtmlTokenType[HtmlTokenType["TAG_CLOSE"] = 3] = "TAG_CLOSE";
      HtmlTokenType[HtmlTokenType["TEXT"] = 4] = "TEXT";
      HtmlTokenType[HtmlTokenType["ESCAPABLE_RAW_TEXT"] = 5] = "ESCAPABLE_RAW_TEXT";
      HtmlTokenType[HtmlTokenType["RAW_TEXT"] = 6] = "RAW_TEXT";
      HtmlTokenType[HtmlTokenType["COMMENT_START"] = 7] = "COMMENT_START";
      HtmlTokenType[HtmlTokenType["COMMENT_END"] = 8] = "COMMENT_END";
      HtmlTokenType[HtmlTokenType["CDATA_START"] = 9] = "CDATA_START";
      HtmlTokenType[HtmlTokenType["CDATA_END"] = 10] = "CDATA_END";
      HtmlTokenType[HtmlTokenType["ATTR_NAME"] = 11] = "ATTR_NAME";
      HtmlTokenType[HtmlTokenType["ATTR_VALUE"] = 12] = "ATTR_VALUE";
      HtmlTokenType[HtmlTokenType["DOC_TYPE"] = 13] = "DOC_TYPE";
      HtmlTokenType[HtmlTokenType["EXPANSION_FORM_START"] = 14] = "EXPANSION_FORM_START";
      HtmlTokenType[HtmlTokenType["EXPANSION_CASE_VALUE"] = 15] = "EXPANSION_CASE_VALUE";
      HtmlTokenType[HtmlTokenType["EXPANSION_CASE_EXP_START"] = 16] = "EXPANSION_CASE_EXP_START";
      HtmlTokenType[HtmlTokenType["EXPANSION_CASE_EXP_END"] = 17] = "EXPANSION_CASE_EXP_END";
      HtmlTokenType[HtmlTokenType["EXPANSION_FORM_END"] = 18] = "EXPANSION_FORM_END";
      HtmlTokenType[HtmlTokenType["EOF"] = 19] = "EOF";
    })(exports.HtmlTokenType || (exports.HtmlTokenType = {}));
    var HtmlTokenType = exports.HtmlTokenType;
    var HtmlToken = (function() {
      function HtmlToken(type, parts, sourceSpan) {
        this.type = type;
        this.parts = parts;
        this.sourceSpan = sourceSpan;
      }
      return HtmlToken;
    }());
    exports.HtmlToken = HtmlToken;
    var HtmlTokenError = (function(_super) {
      __extends(HtmlTokenError, _super);
      function HtmlTokenError(errorMsg, tokenType, span) {
        _super.call(this, span, errorMsg);
        this.tokenType = tokenType;
      }
      return HtmlTokenError;
    }(parse_util_1.ParseError));
    exports.HtmlTokenError = HtmlTokenError;
    var HtmlTokenizeResult = (function() {
      function HtmlTokenizeResult(tokens, errors) {
        this.tokens = tokens;
        this.errors = errors;
      }
      return HtmlTokenizeResult;
    }());
    exports.HtmlTokenizeResult = HtmlTokenizeResult;
    function tokenizeHtml(sourceContent, sourceUrl, tokenizeExpansionForms) {
      if (tokenizeExpansionForms === void 0) {
        tokenizeExpansionForms = false;
      }
      return new _HtmlTokenizer(new parse_util_1.ParseSourceFile(sourceContent, sourceUrl), tokenizeExpansionForms).tokenize();
    }
    exports.tokenizeHtml = tokenizeHtml;
    var $EOF = 0;
    var $TAB = 9;
    var $LF = 10;
    var $FF = 12;
    var $CR = 13;
    var $SPACE = 32;
    var $BANG = 33;
    var $DQ = 34;
    var $HASH = 35;
    var $$ = 36;
    var $AMPERSAND = 38;
    var $SQ = 39;
    var $MINUS = 45;
    var $SLASH = 47;
    var $0 = 48;
    var $SEMICOLON = 59;
    var $9 = 57;
    var $COLON = 58;
    var $LT = 60;
    var $EQ = 61;
    var $GT = 62;
    var $QUESTION = 63;
    var $LBRACKET = 91;
    var $RBRACKET = 93;
    var $LBRACE = 123;
    var $RBRACE = 125;
    var $COMMA = 44;
    var $A = 65;
    var $F = 70;
    var $X = 88;
    var $Z = 90;
    var $a = 97;
    var $f = 102;
    var $z = 122;
    var $x = 120;
    var $NBSP = 160;
    var CR_OR_CRLF_REGEXP = /\r\n?/g;
    function unexpectedCharacterErrorMsg(charCode) {
      var char = charCode === $EOF ? 'EOF' : lang_1.StringWrapper.fromCharCode(charCode);
      return "Unexpected character \"" + char + "\"";
    }
    function unknownEntityErrorMsg(entitySrc) {
      return "Unknown entity \"" + entitySrc + "\" - use the \"&#<decimal>;\" or  \"&#x<hex>;\" syntax";
    }
    var ControlFlowError = (function() {
      function ControlFlowError(error) {
        this.error = error;
      }
      return ControlFlowError;
    }());
    var _HtmlTokenizer = (function() {
      function _HtmlTokenizer(file, tokenizeExpansionForms) {
        this.file = file;
        this.tokenizeExpansionForms = tokenizeExpansionForms;
        this.peek = -1;
        this.nextPeek = -1;
        this.index = -1;
        this.line = 0;
        this.column = -1;
        this.expansionCaseStack = [];
        this.tokens = [];
        this.errors = [];
        this.input = file.content;
        this.length = file.content.length;
        this._advance();
      }
      _HtmlTokenizer.prototype._processCarriageReturns = function(content) {
        return lang_1.StringWrapper.replaceAll(content, CR_OR_CRLF_REGEXP, '\n');
      };
      _HtmlTokenizer.prototype.tokenize = function() {
        while (this.peek !== $EOF) {
          var start = this._getLocation();
          try {
            if (this._attemptCharCode($LT)) {
              if (this._attemptCharCode($BANG)) {
                if (this._attemptCharCode($LBRACKET)) {
                  this._consumeCdata(start);
                } else if (this._attemptCharCode($MINUS)) {
                  this._consumeComment(start);
                } else {
                  this._consumeDocType(start);
                }
              } else if (this._attemptCharCode($SLASH)) {
                this._consumeTagClose(start);
              } else {
                this._consumeTagOpen(start);
              }
            } else if (isSpecialFormStart(this.peek, this.nextPeek) && this.tokenizeExpansionForms) {
              this._consumeExpansionFormStart();
            } else if (this.peek === $EQ && this.tokenizeExpansionForms) {
              this._consumeExpansionCaseStart();
            } else if (this.peek === $RBRACE && this.isInExpansionCase() && this.tokenizeExpansionForms) {
              this._consumeExpansionCaseEnd();
            } else if (this.peek === $RBRACE && this.isInExpansionForm() && this.tokenizeExpansionForms) {
              this._consumeExpansionFormEnd();
            } else {
              this._consumeText();
            }
          } catch (e) {
            if (e instanceof ControlFlowError) {
              this.errors.push(e.error);
            } else {
              throw e;
            }
          }
        }
        this._beginToken(HtmlTokenType.EOF);
        this._endToken([]);
        return new HtmlTokenizeResult(mergeTextTokens(this.tokens), this.errors);
      };
      _HtmlTokenizer.prototype._getLocation = function() {
        return new parse_util_1.ParseLocation(this.file, this.index, this.line, this.column);
      };
      _HtmlTokenizer.prototype._getSpan = function(start, end) {
        if (lang_1.isBlank(start)) {
          start = this._getLocation();
        }
        if (lang_1.isBlank(end)) {
          end = this._getLocation();
        }
        return new parse_util_1.ParseSourceSpan(start, end);
      };
      _HtmlTokenizer.prototype._beginToken = function(type, start) {
        if (start === void 0) {
          start = null;
        }
        if (lang_1.isBlank(start)) {
          start = this._getLocation();
        }
        this.currentTokenStart = start;
        this.currentTokenType = type;
      };
      _HtmlTokenizer.prototype._endToken = function(parts, end) {
        if (end === void 0) {
          end = null;
        }
        if (lang_1.isBlank(end)) {
          end = this._getLocation();
        }
        var token = new HtmlToken(this.currentTokenType, parts, new parse_util_1.ParseSourceSpan(this.currentTokenStart, end));
        this.tokens.push(token);
        this.currentTokenStart = null;
        this.currentTokenType = null;
        return token;
      };
      _HtmlTokenizer.prototype._createError = function(msg, span) {
        var error = new HtmlTokenError(msg, this.currentTokenType, span);
        this.currentTokenStart = null;
        this.currentTokenType = null;
        return new ControlFlowError(error);
      };
      _HtmlTokenizer.prototype._advance = function() {
        if (this.index >= this.length) {
          throw this._createError(unexpectedCharacterErrorMsg($EOF), this._getSpan());
        }
        if (this.peek === $LF) {
          this.line++;
          this.column = 0;
        } else if (this.peek !== $LF && this.peek !== $CR) {
          this.column++;
        }
        this.index++;
        this.peek = this.index >= this.length ? $EOF : lang_1.StringWrapper.charCodeAt(this.input, this.index);
        this.nextPeek = this.index + 1 >= this.length ? $EOF : lang_1.StringWrapper.charCodeAt(this.input, this.index + 1);
      };
      _HtmlTokenizer.prototype._attemptCharCode = function(charCode) {
        if (this.peek === charCode) {
          this._advance();
          return true;
        }
        return false;
      };
      _HtmlTokenizer.prototype._attemptCharCodeCaseInsensitive = function(charCode) {
        if (compareCharCodeCaseInsensitive(this.peek, charCode)) {
          this._advance();
          return true;
        }
        return false;
      };
      _HtmlTokenizer.prototype._requireCharCode = function(charCode) {
        var location = this._getLocation();
        if (!this._attemptCharCode(charCode)) {
          throw this._createError(unexpectedCharacterErrorMsg(this.peek), this._getSpan(location, location));
        }
      };
      _HtmlTokenizer.prototype._attemptStr = function(chars) {
        for (var i = 0; i < chars.length; i++) {
          if (!this._attemptCharCode(lang_1.StringWrapper.charCodeAt(chars, i))) {
            return false;
          }
        }
        return true;
      };
      _HtmlTokenizer.prototype._attemptStrCaseInsensitive = function(chars) {
        for (var i = 0; i < chars.length; i++) {
          if (!this._attemptCharCodeCaseInsensitive(lang_1.StringWrapper.charCodeAt(chars, i))) {
            return false;
          }
        }
        return true;
      };
      _HtmlTokenizer.prototype._requireStr = function(chars) {
        var location = this._getLocation();
        if (!this._attemptStr(chars)) {
          throw this._createError(unexpectedCharacterErrorMsg(this.peek), this._getSpan(location));
        }
      };
      _HtmlTokenizer.prototype._attemptCharCodeUntilFn = function(predicate) {
        while (!predicate(this.peek)) {
          this._advance();
        }
      };
      _HtmlTokenizer.prototype._requireCharCodeUntilFn = function(predicate, len) {
        var start = this._getLocation();
        this._attemptCharCodeUntilFn(predicate);
        if (this.index - start.offset < len) {
          throw this._createError(unexpectedCharacterErrorMsg(this.peek), this._getSpan(start, start));
        }
      };
      _HtmlTokenizer.prototype._attemptUntilChar = function(char) {
        while (this.peek !== char) {
          this._advance();
        }
      };
      _HtmlTokenizer.prototype._readChar = function(decodeEntities) {
        if (decodeEntities && this.peek === $AMPERSAND) {
          return this._decodeEntity();
        } else {
          var index = this.index;
          this._advance();
          return this.input[index];
        }
      };
      _HtmlTokenizer.prototype._decodeEntity = function() {
        var start = this._getLocation();
        this._advance();
        if (this._attemptCharCode($HASH)) {
          var isHex = this._attemptCharCode($x) || this._attemptCharCode($X);
          var numberStart = this._getLocation().offset;
          this._attemptCharCodeUntilFn(isDigitEntityEnd);
          if (this.peek != $SEMICOLON) {
            throw this._createError(unexpectedCharacterErrorMsg(this.peek), this._getSpan());
          }
          this._advance();
          var strNum = this.input.substring(numberStart, this.index - 1);
          try {
            var charCode = lang_1.NumberWrapper.parseInt(strNum, isHex ? 16 : 10);
            return lang_1.StringWrapper.fromCharCode(charCode);
          } catch (e) {
            var entity = this.input.substring(start.offset + 1, this.index - 1);
            throw this._createError(unknownEntityErrorMsg(entity), this._getSpan(start));
          }
        } else {
          var startPosition = this._savePosition();
          this._attemptCharCodeUntilFn(isNamedEntityEnd);
          if (this.peek != $SEMICOLON) {
            this._restorePosition(startPosition);
            return '&';
          }
          this._advance();
          var name_1 = this.input.substring(start.offset + 1, this.index - 1);
          var char = html_tags_1.NAMED_ENTITIES[name_1];
          if (lang_1.isBlank(char)) {
            throw this._createError(unknownEntityErrorMsg(name_1), this._getSpan(start));
          }
          return char;
        }
      };
      _HtmlTokenizer.prototype._consumeRawText = function(decodeEntities, firstCharOfEnd, attemptEndRest) {
        var tagCloseStart;
        var textStart = this._getLocation();
        this._beginToken(decodeEntities ? HtmlTokenType.ESCAPABLE_RAW_TEXT : HtmlTokenType.RAW_TEXT, textStart);
        var parts = [];
        while (true) {
          tagCloseStart = this._getLocation();
          if (this._attemptCharCode(firstCharOfEnd) && attemptEndRest()) {
            break;
          }
          if (this.index > tagCloseStart.offset) {
            parts.push(this.input.substring(tagCloseStart.offset, this.index));
          }
          while (this.peek !== firstCharOfEnd) {
            parts.push(this._readChar(decodeEntities));
          }
        }
        return this._endToken([this._processCarriageReturns(parts.join(''))], tagCloseStart);
      };
      _HtmlTokenizer.prototype._consumeComment = function(start) {
        var _this = this;
        this._beginToken(HtmlTokenType.COMMENT_START, start);
        this._requireCharCode($MINUS);
        this._endToken([]);
        var textToken = this._consumeRawText(false, $MINUS, function() {
          return _this._attemptStr('->');
        });
        this._beginToken(HtmlTokenType.COMMENT_END, textToken.sourceSpan.end);
        this._endToken([]);
      };
      _HtmlTokenizer.prototype._consumeCdata = function(start) {
        var _this = this;
        this._beginToken(HtmlTokenType.CDATA_START, start);
        this._requireStr('CDATA[');
        this._endToken([]);
        var textToken = this._consumeRawText(false, $RBRACKET, function() {
          return _this._attemptStr(']>');
        });
        this._beginToken(HtmlTokenType.CDATA_END, textToken.sourceSpan.end);
        this._endToken([]);
      };
      _HtmlTokenizer.prototype._consumeDocType = function(start) {
        this._beginToken(HtmlTokenType.DOC_TYPE, start);
        this._attemptUntilChar($GT);
        this._advance();
        this._endToken([this.input.substring(start.offset + 2, this.index - 1)]);
      };
      _HtmlTokenizer.prototype._consumePrefixAndName = function() {
        var nameOrPrefixStart = this.index;
        var prefix = null;
        while (this.peek !== $COLON && !isPrefixEnd(this.peek)) {
          this._advance();
        }
        var nameStart;
        if (this.peek === $COLON) {
          this._advance();
          prefix = this.input.substring(nameOrPrefixStart, this.index - 1);
          nameStart = this.index;
        } else {
          nameStart = nameOrPrefixStart;
        }
        this._requireCharCodeUntilFn(isNameEnd, this.index === nameStart ? 1 : 0);
        var name = this.input.substring(nameStart, this.index);
        return [prefix, name];
      };
      _HtmlTokenizer.prototype._consumeTagOpen = function(start) {
        var savedPos = this._savePosition();
        var lowercaseTagName;
        try {
          if (!isAsciiLetter(this.peek)) {
            throw this._createError(unexpectedCharacterErrorMsg(this.peek), this._getSpan());
          }
          var nameStart = this.index;
          this._consumeTagOpenStart(start);
          lowercaseTagName = this.input.substring(nameStart, this.index).toLowerCase();
          this._attemptCharCodeUntilFn(isNotWhitespace);
          while (this.peek !== $SLASH && this.peek !== $GT) {
            this._consumeAttributeName();
            this._attemptCharCodeUntilFn(isNotWhitespace);
            if (this._attemptCharCode($EQ)) {
              this._attemptCharCodeUntilFn(isNotWhitespace);
              this._consumeAttributeValue();
            }
            this._attemptCharCodeUntilFn(isNotWhitespace);
          }
          this._consumeTagOpenEnd();
        } catch (e) {
          if (e instanceof ControlFlowError) {
            this._restorePosition(savedPos);
            this._beginToken(HtmlTokenType.TEXT, start);
            this._endToken(['<']);
            return;
          }
          throw e;
        }
        var contentTokenType = html_tags_1.getHtmlTagDefinition(lowercaseTagName).contentType;
        if (contentTokenType === html_tags_1.HtmlTagContentType.RAW_TEXT) {
          this._consumeRawTextWithTagClose(lowercaseTagName, false);
        } else if (contentTokenType === html_tags_1.HtmlTagContentType.ESCAPABLE_RAW_TEXT) {
          this._consumeRawTextWithTagClose(lowercaseTagName, true);
        }
      };
      _HtmlTokenizer.prototype._consumeRawTextWithTagClose = function(lowercaseTagName, decodeEntities) {
        var _this = this;
        var textToken = this._consumeRawText(decodeEntities, $LT, function() {
          if (!_this._attemptCharCode($SLASH))
            return false;
          _this._attemptCharCodeUntilFn(isNotWhitespace);
          if (!_this._attemptStrCaseInsensitive(lowercaseTagName))
            return false;
          _this._attemptCharCodeUntilFn(isNotWhitespace);
          if (!_this._attemptCharCode($GT))
            return false;
          return true;
        });
        this._beginToken(HtmlTokenType.TAG_CLOSE, textToken.sourceSpan.end);
        this._endToken([null, lowercaseTagName]);
      };
      _HtmlTokenizer.prototype._consumeTagOpenStart = function(start) {
        this._beginToken(HtmlTokenType.TAG_OPEN_START, start);
        var parts = this._consumePrefixAndName();
        this._endToken(parts);
      };
      _HtmlTokenizer.prototype._consumeAttributeName = function() {
        this._beginToken(HtmlTokenType.ATTR_NAME);
        var prefixAndName = this._consumePrefixAndName();
        this._endToken(prefixAndName);
      };
      _HtmlTokenizer.prototype._consumeAttributeValue = function() {
        this._beginToken(HtmlTokenType.ATTR_VALUE);
        var value;
        if (this.peek === $SQ || this.peek === $DQ) {
          var quoteChar = this.peek;
          this._advance();
          var parts = [];
          while (this.peek !== quoteChar) {
            parts.push(this._readChar(true));
          }
          value = parts.join('');
          this._advance();
        } else {
          var valueStart = this.index;
          this._requireCharCodeUntilFn(isNameEnd, 1);
          value = this.input.substring(valueStart, this.index);
        }
        this._endToken([this._processCarriageReturns(value)]);
      };
      _HtmlTokenizer.prototype._consumeTagOpenEnd = function() {
        var tokenType = this._attemptCharCode($SLASH) ? HtmlTokenType.TAG_OPEN_END_VOID : HtmlTokenType.TAG_OPEN_END;
        this._beginToken(tokenType);
        this._requireCharCode($GT);
        this._endToken([]);
      };
      _HtmlTokenizer.prototype._consumeTagClose = function(start) {
        this._beginToken(HtmlTokenType.TAG_CLOSE, start);
        this._attemptCharCodeUntilFn(isNotWhitespace);
        var prefixAndName;
        prefixAndName = this._consumePrefixAndName();
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this._requireCharCode($GT);
        this._endToken(prefixAndName);
      };
      _HtmlTokenizer.prototype._consumeExpansionFormStart = function() {
        this._beginToken(HtmlTokenType.EXPANSION_FORM_START, this._getLocation());
        this._requireCharCode($LBRACE);
        this._endToken([]);
        this._beginToken(HtmlTokenType.RAW_TEXT, this._getLocation());
        var condition = this._readUntil($COMMA);
        this._endToken([condition], this._getLocation());
        this._requireCharCode($COMMA);
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this._beginToken(HtmlTokenType.RAW_TEXT, this._getLocation());
        var type = this._readUntil($COMMA);
        this._endToken([type], this._getLocation());
        this._requireCharCode($COMMA);
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this.expansionCaseStack.push(HtmlTokenType.EXPANSION_FORM_START);
      };
      _HtmlTokenizer.prototype._consumeExpansionCaseStart = function() {
        this._requireCharCode($EQ);
        this._beginToken(HtmlTokenType.EXPANSION_CASE_VALUE, this._getLocation());
        var value = this._readUntil($LBRACE).trim();
        this._endToken([value], this._getLocation());
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this._beginToken(HtmlTokenType.EXPANSION_CASE_EXP_START, this._getLocation());
        this._requireCharCode($LBRACE);
        this._endToken([], this._getLocation());
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this.expansionCaseStack.push(HtmlTokenType.EXPANSION_CASE_EXP_START);
      };
      _HtmlTokenizer.prototype._consumeExpansionCaseEnd = function() {
        this._beginToken(HtmlTokenType.EXPANSION_CASE_EXP_END, this._getLocation());
        this._requireCharCode($RBRACE);
        this._endToken([], this._getLocation());
        this._attemptCharCodeUntilFn(isNotWhitespace);
        this.expansionCaseStack.pop();
      };
      _HtmlTokenizer.prototype._consumeExpansionFormEnd = function() {
        this._beginToken(HtmlTokenType.EXPANSION_FORM_END, this._getLocation());
        this._requireCharCode($RBRACE);
        this._endToken([]);
        this.expansionCaseStack.pop();
      };
      _HtmlTokenizer.prototype._consumeText = function() {
        var start = this._getLocation();
        this._beginToken(HtmlTokenType.TEXT, start);
        var parts = [];
        var interpolation = false;
        if (this.peek === $LBRACE && this.nextPeek === $LBRACE) {
          parts.push(this._readChar(true));
          parts.push(this._readChar(true));
          interpolation = true;
        } else {
          parts.push(this._readChar(true));
        }
        while (!this.isTextEnd(interpolation)) {
          if (this.peek === $LBRACE && this.nextPeek === $LBRACE) {
            parts.push(this._readChar(true));
            parts.push(this._readChar(true));
            interpolation = true;
          } else if (this.peek === $RBRACE && this.nextPeek === $RBRACE && interpolation) {
            parts.push(this._readChar(true));
            parts.push(this._readChar(true));
            interpolation = false;
          } else {
            parts.push(this._readChar(true));
          }
        }
        this._endToken([this._processCarriageReturns(parts.join(''))]);
      };
      _HtmlTokenizer.prototype.isTextEnd = function(interpolation) {
        if (this.peek === $LT || this.peek === $EOF)
          return true;
        if (this.tokenizeExpansionForms) {
          if (isSpecialFormStart(this.peek, this.nextPeek))
            return true;
          if (this.peek === $RBRACE && !interpolation && (this.isInExpansionCase() || this.isInExpansionForm()))
            return true;
        }
        return false;
      };
      _HtmlTokenizer.prototype._savePosition = function() {
        return [this.peek, this.index, this.column, this.line, this.tokens.length];
      };
      _HtmlTokenizer.prototype._readUntil = function(char) {
        var start = this.index;
        this._attemptUntilChar(char);
        return this.input.substring(start, this.index);
      };
      _HtmlTokenizer.prototype._restorePosition = function(position) {
        this.peek = position[0];
        this.index = position[1];
        this.column = position[2];
        this.line = position[3];
        var nbTokens = position[4];
        if (nbTokens < this.tokens.length) {
          this.tokens = collection_1.ListWrapper.slice(this.tokens, 0, nbTokens);
        }
      };
      _HtmlTokenizer.prototype.isInExpansionCase = function() {
        return this.expansionCaseStack.length > 0 && this.expansionCaseStack[this.expansionCaseStack.length - 1] === HtmlTokenType.EXPANSION_CASE_EXP_START;
      };
      _HtmlTokenizer.prototype.isInExpansionForm = function() {
        return this.expansionCaseStack.length > 0 && this.expansionCaseStack[this.expansionCaseStack.length - 1] === HtmlTokenType.EXPANSION_FORM_START;
      };
      return _HtmlTokenizer;
    }());
    function isNotWhitespace(code) {
      return !isWhitespace(code) || code === $EOF;
    }
    function isWhitespace(code) {
      return (code >= $TAB && code <= $SPACE) || (code === $NBSP);
    }
    function isNameEnd(code) {
      return isWhitespace(code) || code === $GT || code === $SLASH || code === $SQ || code === $DQ || code === $EQ;
    }
    function isPrefixEnd(code) {
      return (code < $a || $z < code) && (code < $A || $Z < code) && (code < $0 || code > $9);
    }
    function isDigitEntityEnd(code) {
      return code == $SEMICOLON || code == $EOF || !isAsciiHexDigit(code);
    }
    function isNamedEntityEnd(code) {
      return code == $SEMICOLON || code == $EOF || !isAsciiLetter(code);
    }
    function isSpecialFormStart(peek, nextPeek) {
      return peek === $LBRACE && nextPeek != $LBRACE;
    }
    function isAsciiLetter(code) {
      return code >= $a && code <= $z || code >= $A && code <= $Z;
    }
    function isAsciiHexDigit(code) {
      return code >= $a && code <= $f || code >= $A && code <= $F || code >= $0 && code <= $9;
    }
    function compareCharCodeCaseInsensitive(code1, code2) {
      return toUpperCaseCharCode(code1) == toUpperCaseCharCode(code2);
    }
    function toUpperCaseCharCode(code) {
      return code >= $a && code <= $z ? code - $a + $A : code;
    }
    function mergeTextTokens(srcTokens) {
      var dstTokens = [];
      var lastDstToken;
      for (var i = 0; i < srcTokens.length; i++) {
        var token = srcTokens[i];
        if (lang_1.isPresent(lastDstToken) && lastDstToken.type == HtmlTokenType.TEXT && token.type == HtmlTokenType.TEXT) {
          lastDstToken.parts[0] += token.parts[0];
          lastDstToken.sourceSpan.end = token.sourceSpan.end;
        } else {
          lastDstToken = token;
          dstTokens.push(lastDstToken);
        }
      }
      return dstTokens;
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("16", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ParseLocation = (function() {
    function ParseLocation(file, offset, line, col) {
      this.file = file;
      this.offset = offset;
      this.line = line;
      this.col = col;
    }
    ParseLocation.prototype.toString = function() {
      return this.file.url + "@" + this.line + ":" + this.col;
    };
    return ParseLocation;
  }());
  exports.ParseLocation = ParseLocation;
  var ParseSourceFile = (function() {
    function ParseSourceFile(content, url) {
      this.content = content;
      this.url = url;
    }
    return ParseSourceFile;
  }());
  exports.ParseSourceFile = ParseSourceFile;
  var ParseSourceSpan = (function() {
    function ParseSourceSpan(start, end) {
      this.start = start;
      this.end = end;
    }
    ParseSourceSpan.prototype.toString = function() {
      return this.start.file.content.substring(this.start.offset, this.end.offset);
    };
    return ParseSourceSpan;
  }());
  exports.ParseSourceSpan = ParseSourceSpan;
  (function(ParseErrorLevel) {
    ParseErrorLevel[ParseErrorLevel["WARNING"] = 0] = "WARNING";
    ParseErrorLevel[ParseErrorLevel["FATAL"] = 1] = "FATAL";
  })(exports.ParseErrorLevel || (exports.ParseErrorLevel = {}));
  var ParseErrorLevel = exports.ParseErrorLevel;
  var ParseError = (function() {
    function ParseError(span, msg, level) {
      if (level === void 0) {
        level = ParseErrorLevel.FATAL;
      }
      this.span = span;
      this.msg = msg;
      this.level = level;
    }
    ParseError.prototype.toString = function() {
      var source = this.span.start.file.content;
      var ctxStart = this.span.start.offset;
      if (ctxStart > source.length - 1) {
        ctxStart = source.length - 1;
      }
      var ctxEnd = ctxStart;
      var ctxLen = 0;
      var ctxLines = 0;
      while (ctxLen < 100 && ctxStart > 0) {
        ctxStart--;
        ctxLen++;
        if (source[ctxStart] == "\n") {
          if (++ctxLines == 3) {
            break;
          }
        }
      }
      ctxLen = 0;
      ctxLines = 0;
      while (ctxLen < 100 && ctxEnd < source.length - 1) {
        ctxEnd++;
        ctxLen++;
        if (source[ctxEnd] == "\n") {
          if (++ctxLines == 3) {
            break;
          }
        }
      }
      var context = source.substring(ctxStart, this.span.start.offset) + '[ERROR ->]' + source.substring(this.span.start.offset, ctxEnd + 1);
      return this.msg + " (\"" + context + "\"): " + this.span.start;
    };
    return ParseError;
  }());
  exports.ParseError = ParseError;
  return module.exports;
});

$__System.registerDynamic("1b", ["11", "13", "e", "21", "37", "16", "1c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var html_ast_1 = $__require('21');
  var html_lexer_1 = $__require('37');
  var parse_util_1 = $__require('16');
  var html_tags_1 = $__require('1c');
  var HtmlTreeError = (function(_super) {
    __extends(HtmlTreeError, _super);
    function HtmlTreeError(elementName, span, msg) {
      _super.call(this, span, msg);
      this.elementName = elementName;
    }
    HtmlTreeError.create = function(elementName, span, msg) {
      return new HtmlTreeError(elementName, span, msg);
    };
    return HtmlTreeError;
  }(parse_util_1.ParseError));
  exports.HtmlTreeError = HtmlTreeError;
  var HtmlParseTreeResult = (function() {
    function HtmlParseTreeResult(rootNodes, errors) {
      this.rootNodes = rootNodes;
      this.errors = errors;
    }
    return HtmlParseTreeResult;
  }());
  exports.HtmlParseTreeResult = HtmlParseTreeResult;
  var HtmlParser = (function() {
    function HtmlParser() {}
    HtmlParser.prototype.parse = function(sourceContent, sourceUrl, parseExpansionForms) {
      if (parseExpansionForms === void 0) {
        parseExpansionForms = false;
      }
      var tokensAndErrors = html_lexer_1.tokenizeHtml(sourceContent, sourceUrl, parseExpansionForms);
      var treeAndErrors = new TreeBuilder(tokensAndErrors.tokens).build();
      return new HtmlParseTreeResult(treeAndErrors.rootNodes, tokensAndErrors.errors.concat(treeAndErrors.errors));
    };
    HtmlParser.decorators = [{type: core_1.Injectable}];
    return HtmlParser;
  }());
  exports.HtmlParser = HtmlParser;
  var TreeBuilder = (function() {
    function TreeBuilder(tokens) {
      this.tokens = tokens;
      this.index = -1;
      this.rootNodes = [];
      this.errors = [];
      this.elementStack = [];
      this._advance();
    }
    TreeBuilder.prototype.build = function() {
      while (this.peek.type !== html_lexer_1.HtmlTokenType.EOF) {
        if (this.peek.type === html_lexer_1.HtmlTokenType.TAG_OPEN_START) {
          this._consumeStartTag(this._advance());
        } else if (this.peek.type === html_lexer_1.HtmlTokenType.TAG_CLOSE) {
          this._consumeEndTag(this._advance());
        } else if (this.peek.type === html_lexer_1.HtmlTokenType.CDATA_START) {
          this._closeVoidElement();
          this._consumeCdata(this._advance());
        } else if (this.peek.type === html_lexer_1.HtmlTokenType.COMMENT_START) {
          this._closeVoidElement();
          this._consumeComment(this._advance());
        } else if (this.peek.type === html_lexer_1.HtmlTokenType.TEXT || this.peek.type === html_lexer_1.HtmlTokenType.RAW_TEXT || this.peek.type === html_lexer_1.HtmlTokenType.ESCAPABLE_RAW_TEXT) {
          this._closeVoidElement();
          this._consumeText(this._advance());
        } else if (this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_FORM_START) {
          this._consumeExpansion(this._advance());
        } else {
          this._advance();
        }
      }
      return new HtmlParseTreeResult(this.rootNodes, this.errors);
    };
    TreeBuilder.prototype._advance = function() {
      var prev = this.peek;
      if (this.index < this.tokens.length - 1) {
        this.index++;
      }
      this.peek = this.tokens[this.index];
      return prev;
    };
    TreeBuilder.prototype._advanceIf = function(type) {
      if (this.peek.type === type) {
        return this._advance();
      }
      return null;
    };
    TreeBuilder.prototype._consumeCdata = function(startToken) {
      this._consumeText(this._advance());
      this._advanceIf(html_lexer_1.HtmlTokenType.CDATA_END);
    };
    TreeBuilder.prototype._consumeComment = function(token) {
      var text = this._advanceIf(html_lexer_1.HtmlTokenType.RAW_TEXT);
      this._advanceIf(html_lexer_1.HtmlTokenType.COMMENT_END);
      var value = lang_1.isPresent(text) ? text.parts[0].trim() : null;
      this._addToParent(new html_ast_1.HtmlCommentAst(value, token.sourceSpan));
    };
    TreeBuilder.prototype._consumeExpansion = function(token) {
      var switchValue = this._advance();
      var type = this._advance();
      var cases = [];
      while (this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_CASE_VALUE) {
        var expCase = this._parseExpansionCase();
        if (lang_1.isBlank(expCase))
          return;
        cases.push(expCase);
      }
      if (this.peek.type !== html_lexer_1.HtmlTokenType.EXPANSION_FORM_END) {
        this.errors.push(HtmlTreeError.create(null, this.peek.sourceSpan, "Invalid expansion form. Missing '}'."));
        return;
      }
      this._advance();
      var mainSourceSpan = new parse_util_1.ParseSourceSpan(token.sourceSpan.start, this.peek.sourceSpan.end);
      this._addToParent(new html_ast_1.HtmlExpansionAst(switchValue.parts[0], type.parts[0], cases, mainSourceSpan, switchValue.sourceSpan));
    };
    TreeBuilder.prototype._parseExpansionCase = function() {
      var value = this._advance();
      if (this.peek.type !== html_lexer_1.HtmlTokenType.EXPANSION_CASE_EXP_START) {
        this.errors.push(HtmlTreeError.create(null, this.peek.sourceSpan, "Invalid expansion form. Missing '{'.,"));
        return null;
      }
      var start = this._advance();
      var exp = this._collectExpansionExpTokens(start);
      if (lang_1.isBlank(exp))
        return null;
      var end = this._advance();
      exp.push(new html_lexer_1.HtmlToken(html_lexer_1.HtmlTokenType.EOF, [], end.sourceSpan));
      var parsedExp = new TreeBuilder(exp).build();
      if (parsedExp.errors.length > 0) {
        this.errors = this.errors.concat(parsedExp.errors);
        return null;
      }
      var sourceSpan = new parse_util_1.ParseSourceSpan(value.sourceSpan.start, end.sourceSpan.end);
      var expSourceSpan = new parse_util_1.ParseSourceSpan(start.sourceSpan.start, end.sourceSpan.end);
      return new html_ast_1.HtmlExpansionCaseAst(value.parts[0], parsedExp.rootNodes, sourceSpan, value.sourceSpan, expSourceSpan);
    };
    TreeBuilder.prototype._collectExpansionExpTokens = function(start) {
      var exp = [];
      var expansionFormStack = [html_lexer_1.HtmlTokenType.EXPANSION_CASE_EXP_START];
      while (true) {
        if (this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_FORM_START || this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_CASE_EXP_START) {
          expansionFormStack.push(this.peek.type);
        }
        if (this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_CASE_EXP_END) {
          if (lastOnStack(expansionFormStack, html_lexer_1.HtmlTokenType.EXPANSION_CASE_EXP_START)) {
            expansionFormStack.pop();
            if (expansionFormStack.length == 0)
              return exp;
          } else {
            this.errors.push(HtmlTreeError.create(null, start.sourceSpan, "Invalid expansion form. Missing '}'."));
            return null;
          }
        }
        if (this.peek.type === html_lexer_1.HtmlTokenType.EXPANSION_FORM_END) {
          if (lastOnStack(expansionFormStack, html_lexer_1.HtmlTokenType.EXPANSION_FORM_START)) {
            expansionFormStack.pop();
          } else {
            this.errors.push(HtmlTreeError.create(null, start.sourceSpan, "Invalid expansion form. Missing '}'."));
            return null;
          }
        }
        if (this.peek.type === html_lexer_1.HtmlTokenType.EOF) {
          this.errors.push(HtmlTreeError.create(null, start.sourceSpan, "Invalid expansion form. Missing '}'."));
          return null;
        }
        exp.push(this._advance());
      }
    };
    TreeBuilder.prototype._consumeText = function(token) {
      var text = token.parts[0];
      if (text.length > 0 && text[0] == '\n') {
        var parent_1 = this._getParentElement();
        if (lang_1.isPresent(parent_1) && parent_1.children.length == 0 && html_tags_1.getHtmlTagDefinition(parent_1.name).ignoreFirstLf) {
          text = text.substring(1);
        }
      }
      if (text.length > 0) {
        this._addToParent(new html_ast_1.HtmlTextAst(text, token.sourceSpan));
      }
    };
    TreeBuilder.prototype._closeVoidElement = function() {
      if (this.elementStack.length > 0) {
        var el = collection_1.ListWrapper.last(this.elementStack);
        if (html_tags_1.getHtmlTagDefinition(el.name).isVoid) {
          this.elementStack.pop();
        }
      }
    };
    TreeBuilder.prototype._consumeStartTag = function(startTagToken) {
      var prefix = startTagToken.parts[0];
      var name = startTagToken.parts[1];
      var attrs = [];
      while (this.peek.type === html_lexer_1.HtmlTokenType.ATTR_NAME) {
        attrs.push(this._consumeAttr(this._advance()));
      }
      var fullName = getElementFullName(prefix, name, this._getParentElement());
      var selfClosing = false;
      if (this.peek.type === html_lexer_1.HtmlTokenType.TAG_OPEN_END_VOID) {
        this._advance();
        selfClosing = true;
        if (html_tags_1.getNsPrefix(fullName) == null && !html_tags_1.getHtmlTagDefinition(fullName).isVoid) {
          this.errors.push(HtmlTreeError.create(fullName, startTagToken.sourceSpan, "Only void and foreign elements can be self closed \"" + startTagToken.parts[1] + "\""));
        }
      } else if (this.peek.type === html_lexer_1.HtmlTokenType.TAG_OPEN_END) {
        this._advance();
        selfClosing = false;
      }
      var end = this.peek.sourceSpan.start;
      var span = new parse_util_1.ParseSourceSpan(startTagToken.sourceSpan.start, end);
      var el = new html_ast_1.HtmlElementAst(fullName, attrs, [], span, span, null);
      this._pushElement(el);
      if (selfClosing) {
        this._popElement(fullName);
        el.endSourceSpan = span;
      }
    };
    TreeBuilder.prototype._pushElement = function(el) {
      if (this.elementStack.length > 0) {
        var parentEl = collection_1.ListWrapper.last(this.elementStack);
        if (html_tags_1.getHtmlTagDefinition(parentEl.name).isClosedByChild(el.name)) {
          this.elementStack.pop();
        }
      }
      var tagDef = html_tags_1.getHtmlTagDefinition(el.name);
      var parentEl = this._getParentElement();
      if (tagDef.requireExtraParent(lang_1.isPresent(parentEl) ? parentEl.name : null)) {
        var newParent = new html_ast_1.HtmlElementAst(tagDef.parentToAdd, [], [el], el.sourceSpan, el.startSourceSpan, el.endSourceSpan);
        this._addToParent(newParent);
        this.elementStack.push(newParent);
        this.elementStack.push(el);
      } else {
        this._addToParent(el);
        this.elementStack.push(el);
      }
    };
    TreeBuilder.prototype._consumeEndTag = function(endTagToken) {
      var fullName = getElementFullName(endTagToken.parts[0], endTagToken.parts[1], this._getParentElement());
      this._getParentElement().endSourceSpan = endTagToken.sourceSpan;
      if (html_tags_1.getHtmlTagDefinition(fullName).isVoid) {
        this.errors.push(HtmlTreeError.create(fullName, endTagToken.sourceSpan, "Void elements do not have end tags \"" + endTagToken.parts[1] + "\""));
      } else if (!this._popElement(fullName)) {
        this.errors.push(HtmlTreeError.create(fullName, endTagToken.sourceSpan, "Unexpected closing tag \"" + endTagToken.parts[1] + "\""));
      }
    };
    TreeBuilder.prototype._popElement = function(fullName) {
      for (var stackIndex = this.elementStack.length - 1; stackIndex >= 0; stackIndex--) {
        var el = this.elementStack[stackIndex];
        if (el.name == fullName) {
          collection_1.ListWrapper.splice(this.elementStack, stackIndex, this.elementStack.length - stackIndex);
          return true;
        }
        if (!html_tags_1.getHtmlTagDefinition(el.name).closedByParent) {
          return false;
        }
      }
      return false;
    };
    TreeBuilder.prototype._consumeAttr = function(attrName) {
      var fullName = html_tags_1.mergeNsAndName(attrName.parts[0], attrName.parts[1]);
      var end = attrName.sourceSpan.end;
      var value = '';
      if (this.peek.type === html_lexer_1.HtmlTokenType.ATTR_VALUE) {
        var valueToken = this._advance();
        value = valueToken.parts[0];
        end = valueToken.sourceSpan.end;
      }
      return new html_ast_1.HtmlAttrAst(fullName, value, new parse_util_1.ParseSourceSpan(attrName.sourceSpan.start, end));
    };
    TreeBuilder.prototype._getParentElement = function() {
      return this.elementStack.length > 0 ? collection_1.ListWrapper.last(this.elementStack) : null;
    };
    TreeBuilder.prototype._addToParent = function(node) {
      var parent = this._getParentElement();
      if (lang_1.isPresent(parent)) {
        parent.children.push(node);
      } else {
        this.rootNodes.push(node);
      }
    };
    return TreeBuilder;
  }());
  function getElementFullName(prefix, localName, parentElement) {
    if (lang_1.isBlank(prefix)) {
      prefix = html_tags_1.getHtmlTagDefinition(localName).implicitNamespacePrefix;
      if (lang_1.isBlank(prefix) && lang_1.isPresent(parentElement)) {
        prefix = html_tags_1.getNsPrefix(parentElement.name);
      }
    }
    return html_tags_1.mergeNsAndName(prefix, localName);
  }
  function lastOnStack(stack, element) {
    return stack.length > 0 && stack[stack.length - 1] === element;
  }
  return module.exports;
});

$__System.registerDynamic("1c", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  exports.NAMED_ENTITIES = {
    'Aacute': '\u00C1',
    'aacute': '\u00E1',
    'Acirc': '\u00C2',
    'acirc': '\u00E2',
    'acute': '\u00B4',
    'AElig': '\u00C6',
    'aelig': '\u00E6',
    'Agrave': '\u00C0',
    'agrave': '\u00E0',
    'alefsym': '\u2135',
    'Alpha': '\u0391',
    'alpha': '\u03B1',
    'amp': '&',
    'and': '\u2227',
    'ang': '\u2220',
    'apos': '\u0027',
    'Aring': '\u00C5',
    'aring': '\u00E5',
    'asymp': '\u2248',
    'Atilde': '\u00C3',
    'atilde': '\u00E3',
    'Auml': '\u00C4',
    'auml': '\u00E4',
    'bdquo': '\u201E',
    'Beta': '\u0392',
    'beta': '\u03B2',
    'brvbar': '\u00A6',
    'bull': '\u2022',
    'cap': '\u2229',
    'Ccedil': '\u00C7',
    'ccedil': '\u00E7',
    'cedil': '\u00B8',
    'cent': '\u00A2',
    'Chi': '\u03A7',
    'chi': '\u03C7',
    'circ': '\u02C6',
    'clubs': '\u2663',
    'cong': '\u2245',
    'copy': '\u00A9',
    'crarr': '\u21B5',
    'cup': '\u222A',
    'curren': '\u00A4',
    'dagger': '\u2020',
    'Dagger': '\u2021',
    'darr': '\u2193',
    'dArr': '\u21D3',
    'deg': '\u00B0',
    'Delta': '\u0394',
    'delta': '\u03B4',
    'diams': '\u2666',
    'divide': '\u00F7',
    'Eacute': '\u00C9',
    'eacute': '\u00E9',
    'Ecirc': '\u00CA',
    'ecirc': '\u00EA',
    'Egrave': '\u00C8',
    'egrave': '\u00E8',
    'empty': '\u2205',
    'emsp': '\u2003',
    'ensp': '\u2002',
    'Epsilon': '\u0395',
    'epsilon': '\u03B5',
    'equiv': '\u2261',
    'Eta': '\u0397',
    'eta': '\u03B7',
    'ETH': '\u00D0',
    'eth': '\u00F0',
    'Euml': '\u00CB',
    'euml': '\u00EB',
    'euro': '\u20AC',
    'exist': '\u2203',
    'fnof': '\u0192',
    'forall': '\u2200',
    'frac12': '\u00BD',
    'frac14': '\u00BC',
    'frac34': '\u00BE',
    'frasl': '\u2044',
    'Gamma': '\u0393',
    'gamma': '\u03B3',
    'ge': '\u2265',
    'gt': '>',
    'harr': '\u2194',
    'hArr': '\u21D4',
    'hearts': '\u2665',
    'hellip': '\u2026',
    'Iacute': '\u00CD',
    'iacute': '\u00ED',
    'Icirc': '\u00CE',
    'icirc': '\u00EE',
    'iexcl': '\u00A1',
    'Igrave': '\u00CC',
    'igrave': '\u00EC',
    'image': '\u2111',
    'infin': '\u221E',
    'int': '\u222B',
    'Iota': '\u0399',
    'iota': '\u03B9',
    'iquest': '\u00BF',
    'isin': '\u2208',
    'Iuml': '\u00CF',
    'iuml': '\u00EF',
    'Kappa': '\u039A',
    'kappa': '\u03BA',
    'Lambda': '\u039B',
    'lambda': '\u03BB',
    'lang': '\u27E8',
    'laquo': '\u00AB',
    'larr': '\u2190',
    'lArr': '\u21D0',
    'lceil': '\u2308',
    'ldquo': '\u201C',
    'le': '\u2264',
    'lfloor': '\u230A',
    'lowast': '\u2217',
    'loz': '\u25CA',
    'lrm': '\u200E',
    'lsaquo': '\u2039',
    'lsquo': '\u2018',
    'lt': '<',
    'macr': '\u00AF',
    'mdash': '\u2014',
    'micro': '\u00B5',
    'middot': '\u00B7',
    'minus': '\u2212',
    'Mu': '\u039C',
    'mu': '\u03BC',
    'nabla': '\u2207',
    'nbsp': '\u00A0',
    'ndash': '\u2013',
    'ne': '\u2260',
    'ni': '\u220B',
    'not': '\u00AC',
    'notin': '\u2209',
    'nsub': '\u2284',
    'Ntilde': '\u00D1',
    'ntilde': '\u00F1',
    'Nu': '\u039D',
    'nu': '\u03BD',
    'Oacute': '\u00D3',
    'oacute': '\u00F3',
    'Ocirc': '\u00D4',
    'ocirc': '\u00F4',
    'OElig': '\u0152',
    'oelig': '\u0153',
    'Ograve': '\u00D2',
    'ograve': '\u00F2',
    'oline': '\u203E',
    'Omega': '\u03A9',
    'omega': '\u03C9',
    'Omicron': '\u039F',
    'omicron': '\u03BF',
    'oplus': '\u2295',
    'or': '\u2228',
    'ordf': '\u00AA',
    'ordm': '\u00BA',
    'Oslash': '\u00D8',
    'oslash': '\u00F8',
    'Otilde': '\u00D5',
    'otilde': '\u00F5',
    'otimes': '\u2297',
    'Ouml': '\u00D6',
    'ouml': '\u00F6',
    'para': '\u00B6',
    'permil': '\u2030',
    'perp': '\u22A5',
    'Phi': '\u03A6',
    'phi': '\u03C6',
    'Pi': '\u03A0',
    'pi': '\u03C0',
    'piv': '\u03D6',
    'plusmn': '\u00B1',
    'pound': '\u00A3',
    'prime': '\u2032',
    'Prime': '\u2033',
    'prod': '\u220F',
    'prop': '\u221D',
    'Psi': '\u03A8',
    'psi': '\u03C8',
    'quot': '\u0022',
    'radic': '\u221A',
    'rang': '\u27E9',
    'raquo': '\u00BB',
    'rarr': '\u2192',
    'rArr': '\u21D2',
    'rceil': '\u2309',
    'rdquo': '\u201D',
    'real': '\u211C',
    'reg': '\u00AE',
    'rfloor': '\u230B',
    'Rho': '\u03A1',
    'rho': '\u03C1',
    'rlm': '\u200F',
    'rsaquo': '\u203A',
    'rsquo': '\u2019',
    'sbquo': '\u201A',
    'Scaron': '\u0160',
    'scaron': '\u0161',
    'sdot': '\u22C5',
    'sect': '\u00A7',
    'shy': '\u00AD',
    'Sigma': '\u03A3',
    'sigma': '\u03C3',
    'sigmaf': '\u03C2',
    'sim': '\u223C',
    'spades': '\u2660',
    'sub': '\u2282',
    'sube': '\u2286',
    'sum': '\u2211',
    'sup': '\u2283',
    'sup1': '\u00B9',
    'sup2': '\u00B2',
    'sup3': '\u00B3',
    'supe': '\u2287',
    'szlig': '\u00DF',
    'Tau': '\u03A4',
    'tau': '\u03C4',
    'there4': '\u2234',
    'Theta': '\u0398',
    'theta': '\u03B8',
    'thetasym': '\u03D1',
    'thinsp': '\u2009',
    'THORN': '\u00DE',
    'thorn': '\u00FE',
    'tilde': '\u02DC',
    'times': '\u00D7',
    'trade': '\u2122',
    'Uacute': '\u00DA',
    'uacute': '\u00FA',
    'uarr': '\u2191',
    'uArr': '\u21D1',
    'Ucirc': '\u00DB',
    'ucirc': '\u00FB',
    'Ugrave': '\u00D9',
    'ugrave': '\u00F9',
    'uml': '\u00A8',
    'upsih': '\u03D2',
    'Upsilon': '\u03A5',
    'upsilon': '\u03C5',
    'Uuml': '\u00DC',
    'uuml': '\u00FC',
    'weierp': '\u2118',
    'Xi': '\u039E',
    'xi': '\u03BE',
    'Yacute': '\u00DD',
    'yacute': '\u00FD',
    'yen': '\u00A5',
    'yuml': '\u00FF',
    'Yuml': '\u0178',
    'Zeta': '\u0396',
    'zeta': '\u03B6',
    'zwj': '\u200D',
    'zwnj': '\u200C'
  };
  (function(HtmlTagContentType) {
    HtmlTagContentType[HtmlTagContentType["RAW_TEXT"] = 0] = "RAW_TEXT";
    HtmlTagContentType[HtmlTagContentType["ESCAPABLE_RAW_TEXT"] = 1] = "ESCAPABLE_RAW_TEXT";
    HtmlTagContentType[HtmlTagContentType["PARSABLE_DATA"] = 2] = "PARSABLE_DATA";
  })(exports.HtmlTagContentType || (exports.HtmlTagContentType = {}));
  var HtmlTagContentType = exports.HtmlTagContentType;
  var HtmlTagDefinition = (function() {
    function HtmlTagDefinition(_a) {
      var _this = this;
      var _b = _a === void 0 ? {} : _a,
          closedByChildren = _b.closedByChildren,
          requiredParents = _b.requiredParents,
          implicitNamespacePrefix = _b.implicitNamespacePrefix,
          contentType = _b.contentType,
          closedByParent = _b.closedByParent,
          isVoid = _b.isVoid,
          ignoreFirstLf = _b.ignoreFirstLf;
      this.closedByChildren = {};
      this.closedByParent = false;
      if (lang_1.isPresent(closedByChildren) && closedByChildren.length > 0) {
        closedByChildren.forEach(function(tagName) {
          return _this.closedByChildren[tagName] = true;
        });
      }
      this.isVoid = lang_1.normalizeBool(isVoid);
      this.closedByParent = lang_1.normalizeBool(closedByParent) || this.isVoid;
      if (lang_1.isPresent(requiredParents) && requiredParents.length > 0) {
        this.requiredParents = {};
        this.parentToAdd = requiredParents[0];
        requiredParents.forEach(function(tagName) {
          return _this.requiredParents[tagName] = true;
        });
      }
      this.implicitNamespacePrefix = implicitNamespacePrefix;
      this.contentType = lang_1.isPresent(contentType) ? contentType : HtmlTagContentType.PARSABLE_DATA;
      this.ignoreFirstLf = lang_1.normalizeBool(ignoreFirstLf);
    }
    HtmlTagDefinition.prototype.requireExtraParent = function(currentParent) {
      if (lang_1.isBlank(this.requiredParents)) {
        return false;
      }
      if (lang_1.isBlank(currentParent)) {
        return true;
      }
      var lcParent = currentParent.toLowerCase();
      return this.requiredParents[lcParent] != true && lcParent != 'template';
    };
    HtmlTagDefinition.prototype.isClosedByChild = function(name) {
      return this.isVoid || lang_1.normalizeBool(this.closedByChildren[name.toLowerCase()]);
    };
    return HtmlTagDefinition;
  }());
  exports.HtmlTagDefinition = HtmlTagDefinition;
  var TAG_DEFINITIONS = {
    'base': new HtmlTagDefinition({isVoid: true}),
    'meta': new HtmlTagDefinition({isVoid: true}),
    'area': new HtmlTagDefinition({isVoid: true}),
    'embed': new HtmlTagDefinition({isVoid: true}),
    'link': new HtmlTagDefinition({isVoid: true}),
    'img': new HtmlTagDefinition({isVoid: true}),
    'input': new HtmlTagDefinition({isVoid: true}),
    'param': new HtmlTagDefinition({isVoid: true}),
    'hr': new HtmlTagDefinition({isVoid: true}),
    'br': new HtmlTagDefinition({isVoid: true}),
    'source': new HtmlTagDefinition({isVoid: true}),
    'track': new HtmlTagDefinition({isVoid: true}),
    'wbr': new HtmlTagDefinition({isVoid: true}),
    'p': new HtmlTagDefinition({
      closedByChildren: ['address', 'article', 'aside', 'blockquote', 'div', 'dl', 'fieldset', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'header', 'hgroup', 'hr', 'main', 'nav', 'ol', 'p', 'pre', 'section', 'table', 'ul'],
      closedByParent: true
    }),
    'thead': new HtmlTagDefinition({closedByChildren: ['tbody', 'tfoot']}),
    'tbody': new HtmlTagDefinition({
      closedByChildren: ['tbody', 'tfoot'],
      closedByParent: true
    }),
    'tfoot': new HtmlTagDefinition({
      closedByChildren: ['tbody'],
      closedByParent: true
    }),
    'tr': new HtmlTagDefinition({
      closedByChildren: ['tr'],
      requiredParents: ['tbody', 'tfoot', 'thead'],
      closedByParent: true
    }),
    'td': new HtmlTagDefinition({
      closedByChildren: ['td', 'th'],
      closedByParent: true
    }),
    'th': new HtmlTagDefinition({
      closedByChildren: ['td', 'th'],
      closedByParent: true
    }),
    'col': new HtmlTagDefinition({
      requiredParents: ['colgroup'],
      isVoid: true
    }),
    'svg': new HtmlTagDefinition({implicitNamespacePrefix: 'svg'}),
    'math': new HtmlTagDefinition({implicitNamespacePrefix: 'math'}),
    'li': new HtmlTagDefinition({
      closedByChildren: ['li'],
      closedByParent: true
    }),
    'dt': new HtmlTagDefinition({closedByChildren: ['dt', 'dd']}),
    'dd': new HtmlTagDefinition({
      closedByChildren: ['dt', 'dd'],
      closedByParent: true
    }),
    'rb': new HtmlTagDefinition({
      closedByChildren: ['rb', 'rt', 'rtc', 'rp'],
      closedByParent: true
    }),
    'rt': new HtmlTagDefinition({
      closedByChildren: ['rb', 'rt', 'rtc', 'rp'],
      closedByParent: true
    }),
    'rtc': new HtmlTagDefinition({
      closedByChildren: ['rb', 'rtc', 'rp'],
      closedByParent: true
    }),
    'rp': new HtmlTagDefinition({
      closedByChildren: ['rb', 'rt', 'rtc', 'rp'],
      closedByParent: true
    }),
    'optgroup': new HtmlTagDefinition({
      closedByChildren: ['optgroup'],
      closedByParent: true
    }),
    'option': new HtmlTagDefinition({
      closedByChildren: ['option', 'optgroup'],
      closedByParent: true
    }),
    'pre': new HtmlTagDefinition({ignoreFirstLf: true}),
    'listing': new HtmlTagDefinition({ignoreFirstLf: true}),
    'style': new HtmlTagDefinition({contentType: HtmlTagContentType.RAW_TEXT}),
    'script': new HtmlTagDefinition({contentType: HtmlTagContentType.RAW_TEXT}),
    'title': new HtmlTagDefinition({contentType: HtmlTagContentType.ESCAPABLE_RAW_TEXT}),
    'textarea': new HtmlTagDefinition({
      contentType: HtmlTagContentType.ESCAPABLE_RAW_TEXT,
      ignoreFirstLf: true
    })
  };
  var DEFAULT_TAG_DEFINITION = new HtmlTagDefinition();
  function getHtmlTagDefinition(tagName) {
    var result = TAG_DEFINITIONS[tagName.toLowerCase()];
    return lang_1.isPresent(result) ? result : DEFAULT_TAG_DEFINITION;
  }
  exports.getHtmlTagDefinition = getHtmlTagDefinition;
  var NS_PREFIX_RE = /^@([^:]+):(.+)/g;
  function splitNsName(elementName) {
    if (elementName[0] != '@') {
      return [null, elementName];
    }
    var match = lang_1.RegExpWrapper.firstMatch(NS_PREFIX_RE, elementName);
    return [match[1], match[2]];
  }
  exports.splitNsName = splitNsName;
  function getNsPrefix(elementName) {
    return splitNsName(elementName)[0];
  }
  exports.getNsPrefix = getNsPrefix;
  function mergeNsAndName(prefix, localName) {
    return lang_1.isPresent(prefix) ? "@" + prefix + ":" + localName : localName;
  }
  exports.mergeNsAndName = mergeNsAndName;
  return module.exports;
});

$__System.registerDynamic("1f", ["13", "1c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var html_tags_1 = $__require('1c');
  var NG_CONTENT_SELECT_ATTR = 'select';
  var NG_CONTENT_ELEMENT = 'ng-content';
  var LINK_ELEMENT = 'link';
  var LINK_STYLE_REL_ATTR = 'rel';
  var LINK_STYLE_HREF_ATTR = 'href';
  var LINK_STYLE_REL_VALUE = 'stylesheet';
  var STYLE_ELEMENT = 'style';
  var SCRIPT_ELEMENT = 'script';
  var NG_NON_BINDABLE_ATTR = 'ngNonBindable';
  var NG_PROJECT_AS = 'ngProjectAs';
  function preparseElement(ast) {
    var selectAttr = null;
    var hrefAttr = null;
    var relAttr = null;
    var nonBindable = false;
    var projectAs = null;
    ast.attrs.forEach(function(attr) {
      var lcAttrName = attr.name.toLowerCase();
      if (lcAttrName == NG_CONTENT_SELECT_ATTR) {
        selectAttr = attr.value;
      } else if (lcAttrName == LINK_STYLE_HREF_ATTR) {
        hrefAttr = attr.value;
      } else if (lcAttrName == LINK_STYLE_REL_ATTR) {
        relAttr = attr.value;
      } else if (attr.name == NG_NON_BINDABLE_ATTR) {
        nonBindable = true;
      } else if (attr.name == NG_PROJECT_AS) {
        if (attr.value.length > 0) {
          projectAs = attr.value;
        }
      }
    });
    selectAttr = normalizeNgContentSelect(selectAttr);
    var nodeName = ast.name.toLowerCase();
    var type = PreparsedElementType.OTHER;
    if (html_tags_1.splitNsName(nodeName)[1] == NG_CONTENT_ELEMENT) {
      type = PreparsedElementType.NG_CONTENT;
    } else if (nodeName == STYLE_ELEMENT) {
      type = PreparsedElementType.STYLE;
    } else if (nodeName == SCRIPT_ELEMENT) {
      type = PreparsedElementType.SCRIPT;
    } else if (nodeName == LINK_ELEMENT && relAttr == LINK_STYLE_REL_VALUE) {
      type = PreparsedElementType.STYLESHEET;
    }
    return new PreparsedElement(type, selectAttr, hrefAttr, nonBindable, projectAs);
  }
  exports.preparseElement = preparseElement;
  (function(PreparsedElementType) {
    PreparsedElementType[PreparsedElementType["NG_CONTENT"] = 0] = "NG_CONTENT";
    PreparsedElementType[PreparsedElementType["STYLE"] = 1] = "STYLE";
    PreparsedElementType[PreparsedElementType["STYLESHEET"] = 2] = "STYLESHEET";
    PreparsedElementType[PreparsedElementType["SCRIPT"] = 3] = "SCRIPT";
    PreparsedElementType[PreparsedElementType["OTHER"] = 4] = "OTHER";
  })(exports.PreparsedElementType || (exports.PreparsedElementType = {}));
  var PreparsedElementType = exports.PreparsedElementType;
  var PreparsedElement = (function() {
    function PreparsedElement(type, selectAttr, hrefAttr, nonBindable, projectAs) {
      this.type = type;
      this.selectAttr = selectAttr;
      this.hrefAttr = hrefAttr;
      this.nonBindable = nonBindable;
      this.projectAs = projectAs;
    }
    return PreparsedElement;
  }());
  exports.PreparsedElement = PreparsedElement;
  function normalizeNgContentSelect(selectAttr) {
    if (lang_1.isBlank(selectAttr) || selectAttr.length === 0) {
      return '*';
    }
    return selectAttr;
  }
  return module.exports;
});

$__System.registerDynamic("2e", ["11", "13", "d", "29", "c", "31", "38", "20", "21", "1b", "1f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var async_1 = $__require('29');
  var compile_metadata_1 = $__require('c');
  var xhr_1 = $__require('31');
  var url_resolver_1 = $__require('38');
  var style_url_resolver_1 = $__require('20');
  var html_ast_1 = $__require('21');
  var html_parser_1 = $__require('1b');
  var template_preparser_1 = $__require('1f');
  var DirectiveNormalizer = (function() {
    function DirectiveNormalizer(_xhr, _urlResolver, _htmlParser) {
      this._xhr = _xhr;
      this._urlResolver = _urlResolver;
      this._htmlParser = _htmlParser;
    }
    DirectiveNormalizer.prototype.normalizeDirective = function(directive) {
      if (!directive.isComponent) {
        return async_1.PromiseWrapper.resolve(directive);
      }
      return this.normalizeTemplate(directive.type, directive.template).then(function(normalizedTemplate) {
        return new compile_metadata_1.CompileDirectiveMetadata({
          type: directive.type,
          isComponent: directive.isComponent,
          selector: directive.selector,
          exportAs: directive.exportAs,
          changeDetection: directive.changeDetection,
          inputs: directive.inputs,
          outputs: directive.outputs,
          hostListeners: directive.hostListeners,
          hostProperties: directive.hostProperties,
          hostAttributes: directive.hostAttributes,
          lifecycleHooks: directive.lifecycleHooks,
          providers: directive.providers,
          viewProviders: directive.viewProviders,
          queries: directive.queries,
          viewQueries: directive.viewQueries,
          template: normalizedTemplate
        });
      });
    };
    DirectiveNormalizer.prototype.normalizeTemplate = function(directiveType, template) {
      var _this = this;
      if (lang_1.isPresent(template.template)) {
        return async_1.PromiseWrapper.resolve(this.normalizeLoadedTemplate(directiveType, template, template.template, directiveType.moduleUrl));
      } else if (lang_1.isPresent(template.templateUrl)) {
        var sourceAbsUrl = this._urlResolver.resolve(directiveType.moduleUrl, template.templateUrl);
        return this._xhr.get(sourceAbsUrl).then(function(templateContent) {
          return _this.normalizeLoadedTemplate(directiveType, template, templateContent, sourceAbsUrl);
        });
      } else {
        throw new exceptions_1.BaseException("No template specified for component " + directiveType.name);
      }
    };
    DirectiveNormalizer.prototype.normalizeLoadedTemplate = function(directiveType, templateMeta, template, templateAbsUrl) {
      var _this = this;
      var rootNodesAndErrors = this._htmlParser.parse(template, directiveType.name);
      if (rootNodesAndErrors.errors.length > 0) {
        var errorString = rootNodesAndErrors.errors.join('\n');
        throw new exceptions_1.BaseException("Template parse errors:\n" + errorString);
      }
      var visitor = new TemplatePreparseVisitor();
      html_ast_1.htmlVisitAll(visitor, rootNodesAndErrors.rootNodes);
      var allStyles = templateMeta.styles.concat(visitor.styles);
      var allStyleAbsUrls = visitor.styleUrls.filter(style_url_resolver_1.isStyleUrlResolvable).map(function(url) {
        return _this._urlResolver.resolve(templateAbsUrl, url);
      }).concat(templateMeta.styleUrls.filter(style_url_resolver_1.isStyleUrlResolvable).map(function(url) {
        return _this._urlResolver.resolve(directiveType.moduleUrl, url);
      }));
      var allResolvedStyles = allStyles.map(function(style) {
        var styleWithImports = style_url_resolver_1.extractStyleUrls(_this._urlResolver, templateAbsUrl, style);
        styleWithImports.styleUrls.forEach(function(styleUrl) {
          return allStyleAbsUrls.push(styleUrl);
        });
        return styleWithImports.style;
      });
      var encapsulation = templateMeta.encapsulation;
      if (encapsulation === core_1.ViewEncapsulation.Emulated && allResolvedStyles.length === 0 && allStyleAbsUrls.length === 0) {
        encapsulation = core_1.ViewEncapsulation.None;
      }
      return new compile_metadata_1.CompileTemplateMetadata({
        encapsulation: encapsulation,
        template: template,
        templateUrl: templateAbsUrl,
        styles: allResolvedStyles,
        styleUrls: allStyleAbsUrls,
        ngContentSelectors: visitor.ngContentSelectors
      });
    };
    DirectiveNormalizer.decorators = [{type: core_1.Injectable}];
    DirectiveNormalizer.ctorParameters = [{type: xhr_1.XHR}, {type: url_resolver_1.UrlResolver}, {type: html_parser_1.HtmlParser}];
    return DirectiveNormalizer;
  }());
  exports.DirectiveNormalizer = DirectiveNormalizer;
  var TemplatePreparseVisitor = (function() {
    function TemplatePreparseVisitor() {
      this.ngContentSelectors = [];
      this.styles = [];
      this.styleUrls = [];
      this.ngNonBindableStackCount = 0;
    }
    TemplatePreparseVisitor.prototype.visitElement = function(ast, context) {
      var preparsedElement = template_preparser_1.preparseElement(ast);
      switch (preparsedElement.type) {
        case template_preparser_1.PreparsedElementType.NG_CONTENT:
          if (this.ngNonBindableStackCount === 0) {
            this.ngContentSelectors.push(preparsedElement.selectAttr);
          }
          break;
        case template_preparser_1.PreparsedElementType.STYLE:
          var textContent = '';
          ast.children.forEach(function(child) {
            if (child instanceof html_ast_1.HtmlTextAst) {
              textContent += child.value;
            }
          });
          this.styles.push(textContent);
          break;
        case template_preparser_1.PreparsedElementType.STYLESHEET:
          this.styleUrls.push(preparsedElement.hrefAttr);
          break;
        default:
          break;
      }
      if (preparsedElement.nonBindable) {
        this.ngNonBindableStackCount++;
      }
      html_ast_1.htmlVisitAll(this, ast.children);
      if (preparsedElement.nonBindable) {
        this.ngNonBindableStackCount--;
      }
      return null;
    };
    TemplatePreparseVisitor.prototype.visitComment = function(ast, context) {
      return null;
    };
    TemplatePreparseVisitor.prototype.visitAttr = function(ast, context) {
      return null;
    };
    TemplatePreparseVisitor.prototype.visitText = function(ast, context) {
      return null;
    };
    TemplatePreparseVisitor.prototype.visitExpansion = function(ast, context) {
      return null;
    };
    TemplatePreparseVisitor.prototype.visitExpansionCase = function(ast, context) {
      return null;
    };
    return TemplatePreparseVisitor;
  }());
  return module.exports;
});

$__System.registerDynamic("39", ["11", "18", "13", "d", "e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  function _isDirectiveMetadata(type) {
    return type instanceof core_1.DirectiveMetadata;
  }
  var DirectiveResolver = (function() {
    function DirectiveResolver(_reflector) {
      if (lang_1.isPresent(_reflector)) {
        this._reflector = _reflector;
      } else {
        this._reflector = core_1.reflector;
      }
    }
    DirectiveResolver.prototype.resolve = function(type) {
      var typeMetadata = this._reflector.annotations(core_1.resolveForwardRef(type));
      if (lang_1.isPresent(typeMetadata)) {
        var metadata = typeMetadata.find(_isDirectiveMetadata);
        if (lang_1.isPresent(metadata)) {
          var propertyMetadata = this._reflector.propMetadata(type);
          return this._mergeWithPropertyMetadata(metadata, propertyMetadata, type);
        }
      }
      throw new exceptions_1.BaseException("No Directive annotation found on " + lang_1.stringify(type));
    };
    DirectiveResolver.prototype._mergeWithPropertyMetadata = function(dm, propertyMetadata, directiveType) {
      var inputs = [];
      var outputs = [];
      var host = {};
      var queries = {};
      collection_1.StringMapWrapper.forEach(propertyMetadata, function(metadata, propName) {
        metadata.forEach(function(a) {
          if (a instanceof core_1.InputMetadata) {
            if (lang_1.isPresent(a.bindingPropertyName)) {
              inputs.push(propName + ": " + a.bindingPropertyName);
            } else {
              inputs.push(propName);
            }
          }
          if (a instanceof core_1.OutputMetadata) {
            if (lang_1.isPresent(a.bindingPropertyName)) {
              outputs.push(propName + ": " + a.bindingPropertyName);
            } else {
              outputs.push(propName);
            }
          }
          if (a instanceof core_1.HostBindingMetadata) {
            if (lang_1.isPresent(a.hostPropertyName)) {
              host[("[" + a.hostPropertyName + "]")] = propName;
            } else {
              host[("[" + propName + "]")] = propName;
            }
          }
          if (a instanceof core_1.HostListenerMetadata) {
            var args = lang_1.isPresent(a.args) ? a.args.join(', ') : '';
            host[("(" + a.eventName + ")")] = propName + "(" + args + ")";
          }
          if (a instanceof core_1.ContentChildrenMetadata) {
            queries[propName] = a;
          }
          if (a instanceof core_1.ViewChildrenMetadata) {
            queries[propName] = a;
          }
          if (a instanceof core_1.ContentChildMetadata) {
            queries[propName] = a;
          }
          if (a instanceof core_1.ViewChildMetadata) {
            queries[propName] = a;
          }
        });
      });
      return this._merge(dm, inputs, outputs, host, queries, directiveType);
    };
    DirectiveResolver.prototype._merge = function(dm, inputs, outputs, host, queries, directiveType) {
      var mergedInputs = lang_1.isPresent(dm.inputs) ? collection_1.ListWrapper.concat(dm.inputs, inputs) : inputs;
      var mergedOutputs;
      if (lang_1.isPresent(dm.outputs)) {
        dm.outputs.forEach(function(propName) {
          if (collection_1.ListWrapper.contains(outputs, propName)) {
            throw new exceptions_1.BaseException("Output event '" + propName + "' defined multiple times in '" + lang_1.stringify(directiveType) + "'");
          }
        });
        mergedOutputs = collection_1.ListWrapper.concat(dm.outputs, outputs);
      } else {
        mergedOutputs = outputs;
      }
      var mergedHost = lang_1.isPresent(dm.host) ? collection_1.StringMapWrapper.merge(dm.host, host) : host;
      var mergedQueries = lang_1.isPresent(dm.queries) ? collection_1.StringMapWrapper.merge(dm.queries, queries) : queries;
      if (dm instanceof core_1.ComponentMetadata) {
        return new core_1.ComponentMetadata({
          selector: dm.selector,
          inputs: mergedInputs,
          outputs: mergedOutputs,
          host: mergedHost,
          exportAs: dm.exportAs,
          moduleId: dm.moduleId,
          queries: mergedQueries,
          changeDetection: dm.changeDetection,
          providers: dm.providers,
          viewProviders: dm.viewProviders
        });
      } else {
        return new core_1.DirectiveMetadata({
          selector: dm.selector,
          inputs: mergedInputs,
          outputs: mergedOutputs,
          host: mergedHost,
          exportAs: dm.exportAs,
          queries: mergedQueries,
          providers: dm.providers
        });
      }
    };
    DirectiveResolver.decorators = [{type: core_1.Injectable}];
    DirectiveResolver.ctorParameters = [{type: core_private_1.ReflectorReader}];
    return DirectiveResolver;
  }());
  exports.DirectiveResolver = DirectiveResolver;
  exports.CODEGEN_DIRECTIVE_RESOLVER = new DirectiveResolver(core_1.reflector);
  return module.exports;
});

$__System.registerDynamic("3a", ["11", "18", "13", "d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  function _isPipeMetadata(type) {
    return type instanceof core_1.PipeMetadata;
  }
  var PipeResolver = (function() {
    function PipeResolver(_reflector) {
      if (lang_1.isPresent(_reflector)) {
        this._reflector = _reflector;
      } else {
        this._reflector = core_1.reflector;
      }
    }
    PipeResolver.prototype.resolve = function(type) {
      var metas = this._reflector.annotations(core_1.resolveForwardRef(type));
      if (lang_1.isPresent(metas)) {
        var annotation = metas.find(_isPipeMetadata);
        if (lang_1.isPresent(annotation)) {
          return annotation;
        }
      }
      throw new exceptions_1.BaseException("No Pipe decorator found on " + lang_1.stringify(type));
    };
    PipeResolver.decorators = [{type: core_1.Injectable}];
    PipeResolver.ctorParameters = [{type: core_private_1.ReflectorReader}];
    return PipeResolver;
  }());
  exports.PipeResolver = PipeResolver;
  exports.CODEGEN_PIPE_RESOLVER = new PipeResolver(core_1.reflector);
  return module.exports;
});

$__System.registerDynamic("3b", ["11", "18", "13", "d", "e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var ViewResolver = (function() {
    function ViewResolver(_reflector) {
      this._cache = new collection_1.Map();
      if (lang_1.isPresent(_reflector)) {
        this._reflector = _reflector;
      } else {
        this._reflector = core_1.reflector;
      }
    }
    ViewResolver.prototype.resolve = function(component) {
      var view = this._cache.get(component);
      if (lang_1.isBlank(view)) {
        view = this._resolve(component);
        this._cache.set(component, view);
      }
      return view;
    };
    ViewResolver.prototype._resolve = function(component) {
      var compMeta;
      var viewMeta;
      this._reflector.annotations(component).forEach(function(m) {
        if (m instanceof core_1.ViewMetadata) {
          viewMeta = m;
        }
        if (m instanceof core_1.ComponentMetadata) {
          compMeta = m;
        }
      });
      if (lang_1.isPresent(compMeta)) {
        if (lang_1.isBlank(compMeta.template) && lang_1.isBlank(compMeta.templateUrl) && lang_1.isBlank(viewMeta)) {
          throw new exceptions_1.BaseException("Component '" + lang_1.stringify(component) + "' must have either 'template' or 'templateUrl' set.");
        } else if (lang_1.isPresent(compMeta.template) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("template", component);
        } else if (lang_1.isPresent(compMeta.templateUrl) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("templateUrl", component);
        } else if (lang_1.isPresent(compMeta.directives) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("directives", component);
        } else if (lang_1.isPresent(compMeta.pipes) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("pipes", component);
        } else if (lang_1.isPresent(compMeta.encapsulation) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("encapsulation", component);
        } else if (lang_1.isPresent(compMeta.styles) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("styles", component);
        } else if (lang_1.isPresent(compMeta.styleUrls) && lang_1.isPresent(viewMeta)) {
          this._throwMixingViewAndComponent("styleUrls", component);
        } else if (lang_1.isPresent(viewMeta)) {
          return viewMeta;
        } else {
          return new core_1.ViewMetadata({
            templateUrl: compMeta.templateUrl,
            template: compMeta.template,
            directives: compMeta.directives,
            pipes: compMeta.pipes,
            encapsulation: compMeta.encapsulation,
            styles: compMeta.styles,
            styleUrls: compMeta.styleUrls
          });
        }
      } else {
        if (lang_1.isBlank(viewMeta)) {
          throw new exceptions_1.BaseException("Could not compile '" + lang_1.stringify(component) + "' because it is not a component.");
        } else {
          return viewMeta;
        }
      }
      return null;
    };
    ViewResolver.prototype._throwMixingViewAndComponent = function(propertyName, component) {
      throw new exceptions_1.BaseException("Component '" + lang_1.stringify(component) + "' cannot have both '" + propertyName + "' and '@View' set at the same time\"");
    };
    ViewResolver.decorators = [{type: core_1.Injectable}];
    ViewResolver.ctorParameters = [{type: core_private_1.ReflectorReader}];
    return ViewResolver;
  }());
  exports.ViewResolver = ViewResolver;
  return module.exports;
});

$__System.registerDynamic("3c", ["18", "13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  function hasLifecycleHook(lcInterface, token) {
    if (!(token instanceof lang_1.Type))
      return false;
    var proto = token.prototype;
    switch (lcInterface) {
      case core_private_1.LifecycleHooks.AfterContentInit:
        return !!proto.ngAfterContentInit;
      case core_private_1.LifecycleHooks.AfterContentChecked:
        return !!proto.ngAfterContentChecked;
      case core_private_1.LifecycleHooks.AfterViewInit:
        return !!proto.ngAfterViewInit;
      case core_private_1.LifecycleHooks.AfterViewChecked:
        return !!proto.ngAfterViewChecked;
      case core_private_1.LifecycleHooks.OnChanges:
        return !!proto.ngOnChanges;
      case core_private_1.LifecycleHooks.DoCheck:
        return !!proto.ngDoCheck;
      case core_private_1.LifecycleHooks.OnDestroy:
        return !!proto.ngOnDestroy;
      case core_private_1.LifecycleHooks.OnInit:
        return !!proto.ngOnInit;
      default:
        return false;
    }
  }
  exports.hasLifecycleHook = hasLifecycleHook;
  return module.exports;
});

$__System.registerDynamic("3d", ["13", "d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  function assertArrayOfStrings(identifier, value) {
    if (!lang_1.assertionsEnabled() || lang_1.isBlank(value)) {
      return;
    }
    if (!lang_1.isArray(value)) {
      throw new exceptions_1.BaseException("Expected '" + identifier + "' to be an array of strings.");
    }
    for (var i = 0; i < value.length; i += 1) {
      if (!lang_1.isString(value[i])) {
        throw new exceptions_1.BaseException("Expected '" + identifier + "' to be an array of strings.");
      }
    }
  }
  exports.assertArrayOfStrings = assertArrayOfStrings;
  return module.exports;
});

$__System.registerDynamic("2f", ["11", "18", "13", "e", "d", "c", "39", "3a", "3b", "3c", "10", "3d", "38"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var exceptions_1 = $__require('d');
  var cpl = $__require('c');
  var directive_resolver_1 = $__require('39');
  var pipe_resolver_1 = $__require('3a');
  var view_resolver_1 = $__require('3b');
  var directive_lifecycle_reflector_1 = $__require('3c');
  var util_1 = $__require('10');
  var assertions_1 = $__require('3d');
  var url_resolver_1 = $__require('38');
  var core_private_2 = $__require('18');
  var CompileMetadataResolver = (function() {
    function CompileMetadataResolver(_directiveResolver, _pipeResolver, _viewResolver, _platformDirectives, _platformPipes, _reflector) {
      this._directiveResolver = _directiveResolver;
      this._pipeResolver = _pipeResolver;
      this._viewResolver = _viewResolver;
      this._platformDirectives = _platformDirectives;
      this._platformPipes = _platformPipes;
      this._directiveCache = new Map();
      this._pipeCache = new Map();
      this._anonymousTypes = new Map();
      this._anonymousTypeIndex = 0;
      if (lang_1.isPresent(_reflector)) {
        this._reflector = _reflector;
      } else {
        this._reflector = core_1.reflector;
      }
    }
    CompileMetadataResolver.prototype.sanitizeTokenName = function(token) {
      var identifier = lang_1.stringify(token);
      if (identifier.indexOf('(') >= 0) {
        var found = this._anonymousTypes.get(token);
        if (lang_1.isBlank(found)) {
          this._anonymousTypes.set(token, this._anonymousTypeIndex++);
          found = this._anonymousTypes.get(token);
        }
        identifier = "anonymous_token_" + found + "_";
      }
      return util_1.sanitizeIdentifier(identifier);
    };
    CompileMetadataResolver.prototype.getDirectiveMetadata = function(directiveType) {
      var meta = this._directiveCache.get(directiveType);
      if (lang_1.isBlank(meta)) {
        var dirMeta = this._directiveResolver.resolve(directiveType);
        var templateMeta = null;
        var changeDetectionStrategy = null;
        var viewProviders = [];
        var moduleUrl = staticTypeModuleUrl(directiveType);
        if (dirMeta instanceof core_1.ComponentMetadata) {
          assertions_1.assertArrayOfStrings('styles', dirMeta.styles);
          var cmpMeta = dirMeta;
          var viewMeta = this._viewResolver.resolve(directiveType);
          assertions_1.assertArrayOfStrings('styles', viewMeta.styles);
          templateMeta = new cpl.CompileTemplateMetadata({
            encapsulation: viewMeta.encapsulation,
            template: viewMeta.template,
            templateUrl: viewMeta.templateUrl,
            styles: viewMeta.styles,
            styleUrls: viewMeta.styleUrls
          });
          changeDetectionStrategy = cmpMeta.changeDetection;
          if (lang_1.isPresent(dirMeta.viewProviders)) {
            viewProviders = this.getProvidersMetadata(dirMeta.viewProviders);
          }
          moduleUrl = componentModuleUrl(this._reflector, directiveType, cmpMeta);
        }
        var providers = [];
        if (lang_1.isPresent(dirMeta.providers)) {
          providers = this.getProvidersMetadata(dirMeta.providers);
        }
        var queries = [];
        var viewQueries = [];
        if (lang_1.isPresent(dirMeta.queries)) {
          queries = this.getQueriesMetadata(dirMeta.queries, false);
          viewQueries = this.getQueriesMetadata(dirMeta.queries, true);
        }
        meta = cpl.CompileDirectiveMetadata.create({
          selector: dirMeta.selector,
          exportAs: dirMeta.exportAs,
          isComponent: lang_1.isPresent(templateMeta),
          type: this.getTypeMetadata(directiveType, moduleUrl),
          template: templateMeta,
          changeDetection: changeDetectionStrategy,
          inputs: dirMeta.inputs,
          outputs: dirMeta.outputs,
          host: dirMeta.host,
          lifecycleHooks: core_private_1.LIFECYCLE_HOOKS_VALUES.filter(function(hook) {
            return directive_lifecycle_reflector_1.hasLifecycleHook(hook, directiveType);
          }),
          providers: providers,
          viewProviders: viewProviders,
          queries: queries,
          viewQueries: viewQueries
        });
        this._directiveCache.set(directiveType, meta);
      }
      return meta;
    };
    CompileMetadataResolver.prototype.maybeGetDirectiveMetadata = function(someType) {
      try {
        return this.getDirectiveMetadata(someType);
      } catch (e) {
        if (e.message.indexOf('No Directive annotation') !== -1) {
          return null;
        }
        throw e;
      }
    };
    CompileMetadataResolver.prototype.getTypeMetadata = function(type, moduleUrl) {
      return new cpl.CompileTypeMetadata({
        name: this.sanitizeTokenName(type),
        moduleUrl: moduleUrl,
        runtime: type,
        diDeps: this.getDependenciesMetadata(type, null)
      });
    };
    CompileMetadataResolver.prototype.getFactoryMetadata = function(factory, moduleUrl) {
      return new cpl.CompileFactoryMetadata({
        name: this.sanitizeTokenName(factory),
        moduleUrl: moduleUrl,
        runtime: factory,
        diDeps: this.getDependenciesMetadata(factory, null)
      });
    };
    CompileMetadataResolver.prototype.getPipeMetadata = function(pipeType) {
      var meta = this._pipeCache.get(pipeType);
      if (lang_1.isBlank(meta)) {
        var pipeMeta = this._pipeResolver.resolve(pipeType);
        meta = new cpl.CompilePipeMetadata({
          type: this.getTypeMetadata(pipeType, staticTypeModuleUrl(pipeType)),
          name: pipeMeta.name,
          pure: pipeMeta.pure,
          lifecycleHooks: core_private_1.LIFECYCLE_HOOKS_VALUES.filter(function(hook) {
            return directive_lifecycle_reflector_1.hasLifecycleHook(hook, pipeType);
          })
        });
        this._pipeCache.set(pipeType, meta);
      }
      return meta;
    };
    CompileMetadataResolver.prototype.getViewDirectivesMetadata = function(component) {
      var _this = this;
      var view = this._viewResolver.resolve(component);
      var directives = flattenDirectives(view, this._platformDirectives);
      for (var i = 0; i < directives.length; i++) {
        if (!isValidType(directives[i])) {
          throw new exceptions_1.BaseException("Unexpected directive value '" + lang_1.stringify(directives[i]) + "' on the View of component '" + lang_1.stringify(component) + "'");
        }
      }
      return directives.map(function(type) {
        return _this.getDirectiveMetadata(type);
      });
    };
    CompileMetadataResolver.prototype.getViewPipesMetadata = function(component) {
      var _this = this;
      var view = this._viewResolver.resolve(component);
      var pipes = flattenPipes(view, this._platformPipes);
      for (var i = 0; i < pipes.length; i++) {
        if (!isValidType(pipes[i])) {
          throw new exceptions_1.BaseException("Unexpected piped value '" + lang_1.stringify(pipes[i]) + "' on the View of component '" + lang_1.stringify(component) + "'");
        }
      }
      return pipes.map(function(type) {
        return _this.getPipeMetadata(type);
      });
    };
    CompileMetadataResolver.prototype.getDependenciesMetadata = function(typeOrFunc, dependencies) {
      var _this = this;
      var params = lang_1.isPresent(dependencies) ? dependencies : this._reflector.parameters(typeOrFunc);
      if (lang_1.isBlank(params)) {
        params = [];
      }
      return params.map(function(param) {
        if (lang_1.isBlank(param)) {
          return null;
        }
        var isAttribute = false;
        var isHost = false;
        var isSelf = false;
        var isSkipSelf = false;
        var isOptional = false;
        var query = null;
        var viewQuery = null;
        var token = null;
        if (lang_1.isArray(param)) {
          param.forEach(function(paramEntry) {
            if (paramEntry instanceof core_1.HostMetadata) {
              isHost = true;
            } else if (paramEntry instanceof core_1.SelfMetadata) {
              isSelf = true;
            } else if (paramEntry instanceof core_1.SkipSelfMetadata) {
              isSkipSelf = true;
            } else if (paramEntry instanceof core_1.OptionalMetadata) {
              isOptional = true;
            } else if (paramEntry instanceof core_1.AttributeMetadata) {
              isAttribute = true;
              token = paramEntry.attributeName;
            } else if (paramEntry instanceof core_1.QueryMetadata) {
              if (paramEntry.isViewQuery) {
                viewQuery = paramEntry;
              } else {
                query = paramEntry;
              }
            } else if (paramEntry instanceof core_1.InjectMetadata) {
              token = paramEntry.token;
            } else if (isValidType(paramEntry) && lang_1.isBlank(token)) {
              token = paramEntry;
            }
          });
        } else {
          token = param;
        }
        if (lang_1.isBlank(token)) {
          return null;
        }
        return new cpl.CompileDiDependencyMetadata({
          isAttribute: isAttribute,
          isHost: isHost,
          isSelf: isSelf,
          isSkipSelf: isSkipSelf,
          isOptional: isOptional,
          query: lang_1.isPresent(query) ? _this.getQueryMetadata(query, null) : null,
          viewQuery: lang_1.isPresent(viewQuery) ? _this.getQueryMetadata(viewQuery, null) : null,
          token: _this.getTokenMetadata(token)
        });
      });
    };
    CompileMetadataResolver.prototype.getTokenMetadata = function(token) {
      token = core_1.resolveForwardRef(token);
      var compileToken;
      if (lang_1.isString(token)) {
        compileToken = new cpl.CompileTokenMetadata({value: token});
      } else {
        compileToken = new cpl.CompileTokenMetadata({identifier: new cpl.CompileIdentifierMetadata({
            runtime: token,
            name: this.sanitizeTokenName(token),
            moduleUrl: staticTypeModuleUrl(token)
          })});
      }
      return compileToken;
    };
    CompileMetadataResolver.prototype.getProvidersMetadata = function(providers) {
      var _this = this;
      return providers.map(function(provider) {
        provider = core_1.resolveForwardRef(provider);
        if (lang_1.isArray(provider)) {
          return _this.getProvidersMetadata(provider);
        } else if (provider instanceof core_1.Provider) {
          return _this.getProviderMetadata(provider);
        } else if (core_private_2.isProviderLiteral(provider)) {
          return _this.getProviderMetadata(core_private_2.createProvider(provider));
        } else {
          return _this.getTypeMetadata(provider, staticTypeModuleUrl(provider));
        }
      });
    };
    CompileMetadataResolver.prototype.getProviderMetadata = function(provider) {
      var compileDeps;
      if (lang_1.isPresent(provider.useClass)) {
        compileDeps = this.getDependenciesMetadata(provider.useClass, provider.dependencies);
      } else if (lang_1.isPresent(provider.useFactory)) {
        compileDeps = this.getDependenciesMetadata(provider.useFactory, provider.dependencies);
      }
      return new cpl.CompileProviderMetadata({
        token: this.getTokenMetadata(provider.token),
        useClass: lang_1.isPresent(provider.useClass) ? this.getTypeMetadata(provider.useClass, staticTypeModuleUrl(provider.useClass)) : null,
        useValue: convertToCompileValue(provider.useValue),
        useFactory: lang_1.isPresent(provider.useFactory) ? this.getFactoryMetadata(provider.useFactory, staticTypeModuleUrl(provider.useFactory)) : null,
        useExisting: lang_1.isPresent(provider.useExisting) ? this.getTokenMetadata(provider.useExisting) : null,
        deps: compileDeps,
        multi: provider.multi
      });
    };
    CompileMetadataResolver.prototype.getQueriesMetadata = function(queries, isViewQuery) {
      var _this = this;
      var compileQueries = [];
      collection_1.StringMapWrapper.forEach(queries, function(query, propertyName) {
        if (query.isViewQuery === isViewQuery) {
          compileQueries.push(_this.getQueryMetadata(query, propertyName));
        }
      });
      return compileQueries;
    };
    CompileMetadataResolver.prototype.getQueryMetadata = function(q, propertyName) {
      var _this = this;
      var selectors;
      if (q.isVarBindingQuery) {
        selectors = q.varBindings.map(function(varName) {
          return _this.getTokenMetadata(varName);
        });
      } else {
        selectors = [this.getTokenMetadata(q.selector)];
      }
      return new cpl.CompileQueryMetadata({
        selectors: selectors,
        first: q.first,
        descendants: q.descendants,
        propertyName: propertyName,
        read: lang_1.isPresent(q.read) ? this.getTokenMetadata(q.read) : null
      });
    };
    CompileMetadataResolver.decorators = [{type: core_1.Injectable}];
    CompileMetadataResolver.ctorParameters = [{type: directive_resolver_1.DirectiveResolver}, {type: pipe_resolver_1.PipeResolver}, {type: view_resolver_1.ViewResolver}, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {
        type: core_1.Inject,
        args: [core_1.PLATFORM_DIRECTIVES]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {
        type: core_1.Inject,
        args: [core_1.PLATFORM_PIPES]
      }]
    }, {type: core_private_1.ReflectorReader}];
    return CompileMetadataResolver;
  }());
  exports.CompileMetadataResolver = CompileMetadataResolver;
  function flattenDirectives(view, platformDirectives) {
    var directives = [];
    if (lang_1.isPresent(platformDirectives)) {
      flattenArray(platformDirectives, directives);
    }
    if (lang_1.isPresent(view.directives)) {
      flattenArray(view.directives, directives);
    }
    return directives;
  }
  function flattenPipes(view, platformPipes) {
    var pipes = [];
    if (lang_1.isPresent(platformPipes)) {
      flattenArray(platformPipes, pipes);
    }
    if (lang_1.isPresent(view.pipes)) {
      flattenArray(view.pipes, pipes);
    }
    return pipes;
  }
  function flattenArray(tree, out) {
    for (var i = 0; i < tree.length; i++) {
      var item = core_1.resolveForwardRef(tree[i]);
      if (lang_1.isArray(item)) {
        flattenArray(item, out);
      } else {
        out.push(item);
      }
    }
  }
  function isStaticType(value) {
    return lang_1.isStringMap(value) && lang_1.isPresent(value['name']) && lang_1.isPresent(value['filePath']);
  }
  function isValidType(value) {
    return isStaticType(value) || (value instanceof lang_1.Type);
  }
  function staticTypeModuleUrl(value) {
    return isStaticType(value) ? value['filePath'] : null;
  }
  function componentModuleUrl(reflector, type, cmpMetadata) {
    if (isStaticType(type)) {
      return staticTypeModuleUrl(type);
    }
    if (lang_1.isPresent(cmpMetadata.moduleId)) {
      var moduleId = cmpMetadata.moduleId;
      var scheme = url_resolver_1.getUrlScheme(moduleId);
      return lang_1.isPresent(scheme) && scheme.length > 0 ? moduleId : "package:" + moduleId + util_1.MODULE_SUFFIX;
    }
    return reflector.importUri(type);
  }
  function convertToCompileValue(value) {
    return util_1.visitValue(value, new _CompileValueConverter(), null);
  }
  var _CompileValueConverter = (function(_super) {
    __extends(_CompileValueConverter, _super);
    function _CompileValueConverter() {
      _super.apply(this, arguments);
    }
    _CompileValueConverter.prototype.visitOther = function(value, context) {
      if (isStaticType(value)) {
        return new cpl.CompileIdentifierMetadata({
          name: value['name'],
          moduleUrl: staticTypeModuleUrl(value)
        });
      } else {
        return new cpl.CompileIdentifierMetadata({runtime: value});
      }
    };
    return _CompileValueConverter;
  }(util_1.ValueTransformer));
  return module.exports;
});

$__System.registerDynamic("3e", ["e", "13", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var collection_1 = $__require('e');
    var lang_1 = $__require('13');
    var ShadowCss = (function() {
      function ShadowCss() {
        this.strictStyling = true;
      }
      ShadowCss.prototype.shimCssText = function(cssText, selector, hostSelector) {
        if (hostSelector === void 0) {
          hostSelector = '';
        }
        cssText = stripComments(cssText);
        cssText = this._insertDirectives(cssText);
        return this._scopeCssText(cssText, selector, hostSelector);
      };
      ShadowCss.prototype._insertDirectives = function(cssText) {
        cssText = this._insertPolyfillDirectivesInCssText(cssText);
        return this._insertPolyfillRulesInCssText(cssText);
      };
      ShadowCss.prototype._insertPolyfillDirectivesInCssText = function(cssText) {
        return lang_1.StringWrapper.replaceAllMapped(cssText, _cssContentNextSelectorRe, function(m) {
          return m[1] + '{';
        });
      };
      ShadowCss.prototype._insertPolyfillRulesInCssText = function(cssText) {
        return lang_1.StringWrapper.replaceAllMapped(cssText, _cssContentRuleRe, function(m) {
          var rule = m[0];
          rule = lang_1.StringWrapper.replace(rule, m[1], '');
          rule = lang_1.StringWrapper.replace(rule, m[2], '');
          return m[3] + rule;
        });
      };
      ShadowCss.prototype._scopeCssText = function(cssText, scopeSelector, hostSelector) {
        var unscoped = this._extractUnscopedRulesFromCssText(cssText);
        cssText = this._insertPolyfillHostInCssText(cssText);
        cssText = this._convertColonHost(cssText);
        cssText = this._convertColonHostContext(cssText);
        cssText = this._convertShadowDOMSelectors(cssText);
        if (lang_1.isPresent(scopeSelector)) {
          cssText = this._scopeSelectors(cssText, scopeSelector, hostSelector);
        }
        cssText = cssText + '\n' + unscoped;
        return cssText.trim();
      };
      ShadowCss.prototype._extractUnscopedRulesFromCssText = function(cssText) {
        var r = '',
            m;
        var matcher = lang_1.RegExpWrapper.matcher(_cssContentUnscopedRuleRe, cssText);
        while (lang_1.isPresent(m = lang_1.RegExpMatcherWrapper.next(matcher))) {
          var rule = m[0];
          rule = lang_1.StringWrapper.replace(rule, m[2], '');
          rule = lang_1.StringWrapper.replace(rule, m[1], m[3]);
          r += rule + '\n\n';
        }
        return r;
      };
      ShadowCss.prototype._convertColonHost = function(cssText) {
        return this._convertColonRule(cssText, _cssColonHostRe, this._colonHostPartReplacer);
      };
      ShadowCss.prototype._convertColonHostContext = function(cssText) {
        return this._convertColonRule(cssText, _cssColonHostContextRe, this._colonHostContextPartReplacer);
      };
      ShadowCss.prototype._convertColonRule = function(cssText, regExp, partReplacer) {
        return lang_1.StringWrapper.replaceAllMapped(cssText, regExp, function(m) {
          if (lang_1.isPresent(m[2])) {
            var parts = m[2].split(','),
                r = [];
            for (var i = 0; i < parts.length; i++) {
              var p = parts[i];
              if (lang_1.isBlank(p))
                break;
              p = p.trim();
              r.push(partReplacer(_polyfillHostNoCombinator, p, m[3]));
            }
            return r.join(',');
          } else {
            return _polyfillHostNoCombinator + m[3];
          }
        });
      };
      ShadowCss.prototype._colonHostContextPartReplacer = function(host, part, suffix) {
        if (lang_1.StringWrapper.contains(part, _polyfillHost)) {
          return this._colonHostPartReplacer(host, part, suffix);
        } else {
          return host + part + suffix + ', ' + part + ' ' + host + suffix;
        }
      };
      ShadowCss.prototype._colonHostPartReplacer = function(host, part, suffix) {
        return host + lang_1.StringWrapper.replace(part, _polyfillHost, '') + suffix;
      };
      ShadowCss.prototype._convertShadowDOMSelectors = function(cssText) {
        for (var i = 0; i < _shadowDOMSelectorsRe.length; i++) {
          cssText = lang_1.StringWrapper.replaceAll(cssText, _shadowDOMSelectorsRe[i], ' ');
        }
        return cssText;
      };
      ShadowCss.prototype._scopeSelectors = function(cssText, scopeSelector, hostSelector) {
        var _this = this;
        return processRules(cssText, function(rule) {
          var selector = rule.selector;
          var content = rule.content;
          if (rule.selector[0] != '@' || rule.selector.startsWith('@page')) {
            selector = _this._scopeSelector(rule.selector, scopeSelector, hostSelector, _this.strictStyling);
          } else if (rule.selector.startsWith('@media')) {
            content = _this._scopeSelectors(rule.content, scopeSelector, hostSelector);
          }
          return new CssRule(selector, content);
        });
      };
      ShadowCss.prototype._scopeSelector = function(selector, scopeSelector, hostSelector, strict) {
        var r = [],
            parts = selector.split(',');
        for (var i = 0; i < parts.length; i++) {
          var p = parts[i].trim();
          var deepParts = lang_1.StringWrapper.split(p, _shadowDeepSelectors);
          var shallowPart = deepParts[0];
          if (this._selectorNeedsScoping(shallowPart, scopeSelector)) {
            deepParts[0] = strict && !lang_1.StringWrapper.contains(shallowPart, _polyfillHostNoCombinator) ? this._applyStrictSelectorScope(shallowPart, scopeSelector) : this._applySelectorScope(shallowPart, scopeSelector, hostSelector);
          }
          r.push(deepParts.join(' '));
        }
        return r.join(', ');
      };
      ShadowCss.prototype._selectorNeedsScoping = function(selector, scopeSelector) {
        var re = this._makeScopeMatcher(scopeSelector);
        return !lang_1.isPresent(lang_1.RegExpWrapper.firstMatch(re, selector));
      };
      ShadowCss.prototype._makeScopeMatcher = function(scopeSelector) {
        var lre = /\[/g;
        var rre = /\]/g;
        scopeSelector = lang_1.StringWrapper.replaceAll(scopeSelector, lre, '\\[');
        scopeSelector = lang_1.StringWrapper.replaceAll(scopeSelector, rre, '\\]');
        return lang_1.RegExpWrapper.create('^(' + scopeSelector + ')' + _selectorReSuffix, 'm');
      };
      ShadowCss.prototype._applySelectorScope = function(selector, scopeSelector, hostSelector) {
        return this._applySimpleSelectorScope(selector, scopeSelector, hostSelector);
      };
      ShadowCss.prototype._applySimpleSelectorScope = function(selector, scopeSelector, hostSelector) {
        if (lang_1.isPresent(lang_1.RegExpWrapper.firstMatch(_polyfillHostRe, selector))) {
          var replaceBy = this.strictStyling ? "[" + hostSelector + "]" : scopeSelector;
          selector = lang_1.StringWrapper.replace(selector, _polyfillHostNoCombinator, replaceBy);
          return lang_1.StringWrapper.replaceAll(selector, _polyfillHostRe, replaceBy + ' ');
        } else {
          return scopeSelector + ' ' + selector;
        }
      };
      ShadowCss.prototype._applyStrictSelectorScope = function(selector, scopeSelector) {
        var isRe = /\[is=([^\]]*)\]/g;
        scopeSelector = lang_1.StringWrapper.replaceAllMapped(scopeSelector, isRe, function(m) {
          return m[1];
        });
        var splits = [' ', '>', '+', '~'],
            scoped = selector,
            attrName = '[' + scopeSelector + ']';
        for (var i = 0; i < splits.length; i++) {
          var sep = splits[i];
          var parts = scoped.split(sep);
          scoped = parts.map(function(p) {
            var t = lang_1.StringWrapper.replaceAll(p.trim(), _polyfillHostRe, '');
            if (t.length > 0 && !collection_1.ListWrapper.contains(splits, t) && !lang_1.StringWrapper.contains(t, attrName)) {
              var re = /([^:]*)(:*)(.*)/g;
              var m = lang_1.RegExpWrapper.firstMatch(re, t);
              if (lang_1.isPresent(m)) {
                p = m[1] + attrName + m[2] + m[3];
              }
            }
            return p;
          }).join(sep);
        }
        return scoped;
      };
      ShadowCss.prototype._insertPolyfillHostInCssText = function(selector) {
        selector = lang_1.StringWrapper.replaceAll(selector, _colonHostContextRe, _polyfillHostContext);
        selector = lang_1.StringWrapper.replaceAll(selector, _colonHostRe, _polyfillHost);
        return selector;
      };
      return ShadowCss;
    }());
    exports.ShadowCss = ShadowCss;
    var _cssContentNextSelectorRe = /polyfill-next-selector[^}]*content:[\s]*?['"](.*?)['"][;\s]*}([^{]*?){/gim;
    var _cssContentRuleRe = /(polyfill-rule)[^}]*(content:[\s]*['"](.*?)['"])[;\s]*[^}]*}/gim;
    var _cssContentUnscopedRuleRe = /(polyfill-unscoped-rule)[^}]*(content:[\s]*['"](.*?)['"])[;\s]*[^}]*}/gim;
    var _polyfillHost = '-shadowcsshost';
    var _polyfillHostContext = '-shadowcsscontext';
    var _parenSuffix = ')(?:\\((' + '(?:\\([^)(]*\\)|[^)(]*)+?' + ')\\))?([^,{]*)';
    var _cssColonHostRe = lang_1.RegExpWrapper.create('(' + _polyfillHost + _parenSuffix, 'im');
    var _cssColonHostContextRe = lang_1.RegExpWrapper.create('(' + _polyfillHostContext + _parenSuffix, 'im');
    var _polyfillHostNoCombinator = _polyfillHost + '-no-combinator';
    var _shadowDOMSelectorsRe = [/::shadow/g, /::content/g, /\/shadow-deep\//g, /\/shadow\//g];
    var _shadowDeepSelectors = /(?:>>>)|(?:\/deep\/)/g;
    var _selectorReSuffix = '([>\\s~+\[.,{:][\\s\\S]*)?$';
    var _polyfillHostRe = lang_1.RegExpWrapper.create(_polyfillHost, 'im');
    var _colonHostRe = /:host/gim;
    var _colonHostContextRe = /:host-context/gim;
    var _commentRe = /\/\*[\s\S]*?\*\//g;
    function stripComments(input) {
      return lang_1.StringWrapper.replaceAllMapped(input, _commentRe, function(_) {
        return '';
      });
    }
    var _ruleRe = /(\s*)([^;\{\}]+?)(\s*)((?:{%BLOCK%}?\s*;?)|(?:\s*;))/g;
    var _curlyRe = /([{}])/g;
    var OPEN_CURLY = '{';
    var CLOSE_CURLY = '}';
    var BLOCK_PLACEHOLDER = '%BLOCK%';
    var CssRule = (function() {
      function CssRule(selector, content) {
        this.selector = selector;
        this.content = content;
      }
      return CssRule;
    }());
    exports.CssRule = CssRule;
    function processRules(input, ruleCallback) {
      var inputWithEscapedBlocks = escapeBlocks(input);
      var nextBlockIndex = 0;
      return lang_1.StringWrapper.replaceAllMapped(inputWithEscapedBlocks.escapedString, _ruleRe, function(m) {
        var selector = m[2];
        var content = '';
        var suffix = m[4];
        var contentPrefix = '';
        if (lang_1.isPresent(m[4]) && m[4].startsWith('{' + BLOCK_PLACEHOLDER)) {
          content = inputWithEscapedBlocks.blocks[nextBlockIndex++];
          suffix = m[4].substring(BLOCK_PLACEHOLDER.length + 1);
          contentPrefix = '{';
        }
        var rule = ruleCallback(new CssRule(selector, content));
        return "" + m[1] + rule.selector + m[3] + contentPrefix + rule.content + suffix;
      });
    }
    exports.processRules = processRules;
    var StringWithEscapedBlocks = (function() {
      function StringWithEscapedBlocks(escapedString, blocks) {
        this.escapedString = escapedString;
        this.blocks = blocks;
      }
      return StringWithEscapedBlocks;
    }());
    function escapeBlocks(input) {
      var inputParts = lang_1.StringWrapper.split(input, _curlyRe);
      var resultParts = [];
      var escapedBlocks = [];
      var bracketCount = 0;
      var currentBlockParts = [];
      for (var partIndex = 0; partIndex < inputParts.length; partIndex++) {
        var part = inputParts[partIndex];
        if (part == CLOSE_CURLY) {
          bracketCount--;
        }
        if (bracketCount > 0) {
          currentBlockParts.push(part);
        } else {
          if (currentBlockParts.length > 0) {
            escapedBlocks.push(currentBlockParts.join(''));
            resultParts.push(BLOCK_PLACEHOLDER);
            currentBlockParts = [];
          }
          resultParts.push(part);
        }
        if (part == OPEN_CURLY) {
          bracketCount++;
        }
      }
      if (currentBlockParts.length > 0) {
        escapedBlocks.push(currentBlockParts.join(''));
        resultParts.push(BLOCK_PLACEHOLDER);
      }
      return new StringWithEscapedBlocks(resultParts.join(''), escapedBlocks);
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("20", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var StyleWithImports = (function() {
    function StyleWithImports(style, styleUrls) {
      this.style = style;
      this.styleUrls = styleUrls;
    }
    return StyleWithImports;
  }());
  exports.StyleWithImports = StyleWithImports;
  function isStyleUrlResolvable(url) {
    if (lang_1.isBlank(url) || url.length === 0 || url[0] == '/')
      return false;
    var schemeMatch = lang_1.RegExpWrapper.firstMatch(_urlWithSchemaRe, url);
    return lang_1.isBlank(schemeMatch) || schemeMatch[1] == 'package' || schemeMatch[1] == 'asset';
  }
  exports.isStyleUrlResolvable = isStyleUrlResolvable;
  function extractStyleUrls(resolver, baseUrl, cssText) {
    var foundUrls = [];
    var modifiedCssText = lang_1.StringWrapper.replaceAllMapped(cssText, _cssImportRe, function(m) {
      var url = lang_1.isPresent(m[1]) ? m[1] : m[2];
      if (!isStyleUrlResolvable(url)) {
        return m[0];
      }
      foundUrls.push(resolver.resolve(baseUrl, url));
      return '';
    });
    return new StyleWithImports(modifiedCssText, foundUrls);
  }
  exports.extractStyleUrls = extractStyleUrls;
  var _cssImportRe = /@import\s+(?:url\()?\s*(?:(?:['"]([^'"]*))|([^;\)\s]*))[^;]*;?/g;
  var _urlWithSchemaRe = /^([a-zA-Z\-\+\.]+):/g;
  return module.exports;
});

$__System.registerDynamic("2c", ["11", "c", "f", "3e", "38", "20", "13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var compile_metadata_1 = $__require('c');
  var o = $__require('f');
  var shadow_css_1 = $__require('3e');
  var url_resolver_1 = $__require('38');
  var style_url_resolver_1 = $__require('20');
  var lang_1 = $__require('13');
  var COMPONENT_VARIABLE = '%COMP%';
  var HOST_ATTR = "_nghost-" + COMPONENT_VARIABLE;
  var CONTENT_ATTR = "_ngcontent-" + COMPONENT_VARIABLE;
  var StylesCompileDependency = (function() {
    function StylesCompileDependency(moduleUrl, isShimmed, valuePlaceholder) {
      this.moduleUrl = moduleUrl;
      this.isShimmed = isShimmed;
      this.valuePlaceholder = valuePlaceholder;
    }
    return StylesCompileDependency;
  }());
  exports.StylesCompileDependency = StylesCompileDependency;
  var StylesCompileResult = (function() {
    function StylesCompileResult(statements, stylesVar, dependencies) {
      this.statements = statements;
      this.stylesVar = stylesVar;
      this.dependencies = dependencies;
    }
    return StylesCompileResult;
  }());
  exports.StylesCompileResult = StylesCompileResult;
  var StyleCompiler = (function() {
    function StyleCompiler(_urlResolver) {
      this._urlResolver = _urlResolver;
      this._shadowCss = new shadow_css_1.ShadowCss();
    }
    StyleCompiler.prototype.compileComponent = function(comp) {
      var shim = comp.template.encapsulation === core_1.ViewEncapsulation.Emulated;
      return this._compileStyles(getStylesVarName(comp), comp.template.styles, comp.template.styleUrls, shim);
    };
    StyleCompiler.prototype.compileStylesheet = function(stylesheetUrl, cssText, isShimmed) {
      var styleWithImports = style_url_resolver_1.extractStyleUrls(this._urlResolver, stylesheetUrl, cssText);
      return this._compileStyles(getStylesVarName(null), [styleWithImports.style], styleWithImports.styleUrls, isShimmed);
    };
    StyleCompiler.prototype._compileStyles = function(stylesVar, plainStyles, absUrls, shim) {
      var _this = this;
      var styleExpressions = plainStyles.map(function(plainStyle) {
        return o.literal(_this._shimIfNeeded(plainStyle, shim));
      });
      var dependencies = [];
      for (var i = 0; i < absUrls.length; i++) {
        var identifier = new compile_metadata_1.CompileIdentifierMetadata({name: getStylesVarName(null)});
        dependencies.push(new StylesCompileDependency(absUrls[i], shim, identifier));
        styleExpressions.push(new o.ExternalExpr(identifier));
      }
      var stmt = o.variable(stylesVar).set(o.literalArr(styleExpressions, new o.ArrayType(o.DYNAMIC_TYPE, [o.TypeModifier.Const]))).toDeclStmt(null, [o.StmtModifier.Final]);
      return new StylesCompileResult([stmt], stylesVar, dependencies);
    };
    StyleCompiler.prototype._shimIfNeeded = function(style, shim) {
      return shim ? this._shadowCss.shimCssText(style, CONTENT_ATTR, HOST_ATTR) : style;
    };
    StyleCompiler.decorators = [{type: core_1.Injectable}];
    StyleCompiler.ctorParameters = [{type: url_resolver_1.UrlResolver}];
    return StyleCompiler;
  }());
  exports.StyleCompiler = StyleCompiler;
  function getStylesVarName(component) {
    var result = "styles";
    if (lang_1.isPresent(component)) {
      result += "_" + component.type.name;
    }
    return result;
  }
  return module.exports;
});

$__System.registerDynamic("3f", ["13", "d", "f", "15", "40"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var util_1 = $__require('40');
  var _PurePipeProxy = (function() {
    function _PurePipeProxy(view, instance, argCount) {
      this.view = view;
      this.instance = instance;
      this.argCount = argCount;
    }
    return _PurePipeProxy;
  }());
  var CompilePipe = (function() {
    function CompilePipe(view, meta) {
      this.view = view;
      this.meta = meta;
      this._purePipeProxies = [];
      this.instance = o.THIS_EXPR.prop("_pipe_" + meta.name + "_" + view.pipeCount++);
    }
    CompilePipe.call = function(view, name, args) {
      var compView = view.componentView;
      var meta = _findPipeMeta(compView, name);
      var pipe;
      if (meta.pure) {
        pipe = compView.purePipes.get(name);
        if (lang_1.isBlank(pipe)) {
          pipe = new CompilePipe(compView, meta);
          compView.purePipes.set(name, pipe);
          compView.pipes.push(pipe);
        }
      } else {
        pipe = new CompilePipe(view, meta);
        view.pipes.push(pipe);
      }
      return pipe._call(view, args);
    };
    Object.defineProperty(CompilePipe.prototype, "pure", {
      get: function() {
        return this.meta.pure;
      },
      enumerable: true,
      configurable: true
    });
    CompilePipe.prototype.create = function() {
      var _this = this;
      var deps = this.meta.type.diDeps.map(function(diDep) {
        if (diDep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.ChangeDetectorRef))) {
          return util_1.getPropertyInView(o.THIS_EXPR.prop('ref'), _this.view, _this.view.componentView);
        }
        return util_1.injectFromViewParentInjector(diDep.token, false);
      });
      this.view.fields.push(new o.ClassField(this.instance.name, o.importType(this.meta.type)));
      this.view.createMethod.resetDebugInfo(null, null);
      this.view.createMethod.addStmt(o.THIS_EXPR.prop(this.instance.name).set(o.importExpr(this.meta.type).instantiate(deps)).toStmt());
      this._purePipeProxies.forEach(function(purePipeProxy) {
        var pipeInstanceSeenFromPureProxy = util_1.getPropertyInView(_this.instance, purePipeProxy.view, _this.view);
        util_1.createPureProxy(pipeInstanceSeenFromPureProxy.prop('transform').callMethod(o.BuiltinMethod.bind, [pipeInstanceSeenFromPureProxy]), purePipeProxy.argCount, purePipeProxy.instance, purePipeProxy.view);
      });
    };
    CompilePipe.prototype._call = function(callingView, args) {
      if (this.meta.pure) {
        var purePipeProxy = new _PurePipeProxy(callingView, o.THIS_EXPR.prop(this.instance.name + "_" + this._purePipeProxies.length), args.length);
        this._purePipeProxies.push(purePipeProxy);
        return o.importExpr(identifiers_1.Identifiers.castByValue).callFn([purePipeProxy.instance, util_1.getPropertyInView(this.instance.prop('transform'), callingView, this.view)]).callFn(args);
      } else {
        return util_1.getPropertyInView(this.instance, callingView, this.view).callMethod('transform', args);
      }
    };
    return CompilePipe;
  }());
  exports.CompilePipe = CompilePipe;
  function _findPipeMeta(view, name) {
    var pipeMeta = null;
    for (var i = view.pipeMetas.length - 1; i >= 0; i--) {
      var localPipeMeta = view.pipeMetas[i];
      if (localPipeMeta.name == name) {
        pipeMeta = localPipeMeta;
        break;
      }
    }
    if (lang_1.isBlank(pipeMeta)) {
      throw new exceptions_1.BaseException("Illegal state: Could not find pipe " + name + " although the parser should have detected this error!");
    }
    return pipeMeta;
  }
  return module.exports;
});

$__System.registerDynamic("41", ["18", "13", "e", "f", "42", "43", "44", "3f", "c", "40", "15"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var constants_1 = $__require('42');
  var compile_query_1 = $__require('43');
  var compile_method_1 = $__require('44');
  var compile_pipe_1 = $__require('3f');
  var compile_metadata_1 = $__require('c');
  var util_1 = $__require('40');
  var identifiers_1 = $__require('15');
  var CompileView = (function() {
    function CompileView(component, genConfig, pipeMetas, styles, viewIndex, declarationElement, templateVariableBindings) {
      var _this = this;
      this.component = component;
      this.genConfig = genConfig;
      this.pipeMetas = pipeMetas;
      this.styles = styles;
      this.viewIndex = viewIndex;
      this.declarationElement = declarationElement;
      this.templateVariableBindings = templateVariableBindings;
      this.nodes = [];
      this.rootNodesOrAppElements = [];
      this.bindings = [];
      this.classStatements = [];
      this.eventHandlerMethods = [];
      this.fields = [];
      this.getters = [];
      this.disposables = [];
      this.subscriptions = [];
      this.purePipes = new Map();
      this.pipes = [];
      this.locals = new Map();
      this.literalArrayCount = 0;
      this.literalMapCount = 0;
      this.pipeCount = 0;
      this.createMethod = new compile_method_1.CompileMethod(this);
      this.injectorGetMethod = new compile_method_1.CompileMethod(this);
      this.updateContentQueriesMethod = new compile_method_1.CompileMethod(this);
      this.dirtyParentQueriesMethod = new compile_method_1.CompileMethod(this);
      this.updateViewQueriesMethod = new compile_method_1.CompileMethod(this);
      this.detectChangesInInputsMethod = new compile_method_1.CompileMethod(this);
      this.detectChangesRenderPropertiesMethod = new compile_method_1.CompileMethod(this);
      this.afterContentLifecycleCallbacksMethod = new compile_method_1.CompileMethod(this);
      this.afterViewLifecycleCallbacksMethod = new compile_method_1.CompileMethod(this);
      this.destroyMethod = new compile_method_1.CompileMethod(this);
      this.viewType = getViewType(component, viewIndex);
      this.className = "_View_" + component.type.name + viewIndex;
      this.classType = o.importType(new compile_metadata_1.CompileIdentifierMetadata({name: this.className}));
      this.viewFactory = o.variable(util_1.getViewFactoryName(component, viewIndex));
      if (this.viewType === core_private_1.ViewType.COMPONENT || this.viewType === core_private_1.ViewType.HOST) {
        this.componentView = this;
      } else {
        this.componentView = this.declarationElement.view.componentView;
      }
      this.componentContext = util_1.getPropertyInView(o.THIS_EXPR.prop('context'), this, this.componentView);
      var viewQueries = new compile_metadata_1.CompileTokenMap();
      if (this.viewType === core_private_1.ViewType.COMPONENT) {
        var directiveInstance = o.THIS_EXPR.prop('context');
        collection_1.ListWrapper.forEachWithIndex(this.component.viewQueries, function(queryMeta, queryIndex) {
          var propName = "_viewQuery_" + queryMeta.selectors[0].name + "_" + queryIndex;
          var queryList = compile_query_1.createQueryList(queryMeta, directiveInstance, propName, _this);
          var query = new compile_query_1.CompileQuery(queryMeta, queryList, directiveInstance, _this);
          compile_query_1.addQueryToTokenMap(viewQueries, query);
        });
        var constructorViewQueryCount = 0;
        this.component.type.diDeps.forEach(function(dep) {
          if (lang_1.isPresent(dep.viewQuery)) {
            var queryList = o.THIS_EXPR.prop('declarationAppElement').prop('componentConstructorViewQueries').key(o.literal(constructorViewQueryCount++));
            var query = new compile_query_1.CompileQuery(dep.viewQuery, queryList, null, _this);
            compile_query_1.addQueryToTokenMap(viewQueries, query);
          }
        });
      }
      this.viewQueries = viewQueries;
      templateVariableBindings.forEach(function(entry) {
        _this.locals.set(entry[1], o.THIS_EXPR.prop('context').prop(entry[0]));
      });
      if (!this.declarationElement.isNull()) {
        this.declarationElement.setEmbeddedView(this);
      }
    }
    CompileView.prototype.callPipe = function(name, input, args) {
      return compile_pipe_1.CompilePipe.call(this, name, [input].concat(args));
    };
    CompileView.prototype.getLocal = function(name) {
      if (name == constants_1.EventHandlerVars.event.name) {
        return constants_1.EventHandlerVars.event;
      }
      var currView = this;
      var result = currView.locals.get(name);
      while (lang_1.isBlank(result) && lang_1.isPresent(currView.declarationElement.view)) {
        currView = currView.declarationElement.view;
        result = currView.locals.get(name);
      }
      if (lang_1.isPresent(result)) {
        return util_1.getPropertyInView(result, this, currView);
      } else {
        return null;
      }
    };
    CompileView.prototype.createLiteralArray = function(values) {
      if (values.length === 0) {
        return o.importExpr(identifiers_1.Identifiers.EMPTY_ARRAY);
      }
      var proxyExpr = o.THIS_EXPR.prop("_arr_" + this.literalArrayCount++);
      var proxyParams = [];
      var proxyReturnEntries = [];
      for (var i = 0; i < values.length; i++) {
        var paramName = "p" + i;
        proxyParams.push(new o.FnParam(paramName));
        proxyReturnEntries.push(o.variable(paramName));
      }
      util_1.createPureProxy(o.fn(proxyParams, [new o.ReturnStatement(o.literalArr(proxyReturnEntries))]), values.length, proxyExpr, this);
      return proxyExpr.callFn(values);
    };
    CompileView.prototype.createLiteralMap = function(entries) {
      if (entries.length === 0) {
        return o.importExpr(identifiers_1.Identifiers.EMPTY_MAP);
      }
      var proxyExpr = o.THIS_EXPR.prop("_map_" + this.literalMapCount++);
      var proxyParams = [];
      var proxyReturnEntries = [];
      var values = [];
      for (var i = 0; i < entries.length; i++) {
        var paramName = "p" + i;
        proxyParams.push(new o.FnParam(paramName));
        proxyReturnEntries.push([entries[i][0], o.variable(paramName)]);
        values.push(entries[i][1]);
      }
      util_1.createPureProxy(o.fn(proxyParams, [new o.ReturnStatement(o.literalMap(proxyReturnEntries))]), entries.length, proxyExpr, this);
      return proxyExpr.callFn(values);
    };
    CompileView.prototype.afterNodes = function() {
      var _this = this;
      this.pipes.forEach(function(pipe) {
        return pipe.create();
      });
      this.viewQueries.values().forEach(function(queries) {
        return queries.forEach(function(query) {
          return query.afterChildren(_this.updateViewQueriesMethod);
        });
      });
    };
    return CompileView;
  }());
  exports.CompileView = CompileView;
  function getViewType(component, embeddedTemplateIndex) {
    if (embeddedTemplateIndex > 0) {
      return core_private_1.ViewType.EMBEDDED;
    } else if (component.type.isHost) {
      return core_private_1.ViewType.HOST;
    } else {
      return core_private_1.ViewType.COMPONENT;
    }
  }
  return module.exports;
});

$__System.registerDynamic("43", ["13", "e", "f", "15", "40"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var util_1 = $__require('40');
  var ViewQueryValues = (function() {
    function ViewQueryValues(view, values) {
      this.view = view;
      this.values = values;
    }
    return ViewQueryValues;
  }());
  var CompileQuery = (function() {
    function CompileQuery(meta, queryList, ownerDirectiveExpression, view) {
      this.meta = meta;
      this.queryList = queryList;
      this.ownerDirectiveExpression = ownerDirectiveExpression;
      this.view = view;
      this._values = new ViewQueryValues(view, []);
    }
    CompileQuery.prototype.addValue = function(value, view) {
      var currentView = view;
      var elPath = [];
      while (lang_1.isPresent(currentView) && currentView !== this.view) {
        var parentEl = currentView.declarationElement;
        elPath.unshift(parentEl);
        currentView = parentEl.view;
      }
      var queryListForDirtyExpr = util_1.getPropertyInView(this.queryList, view, this.view);
      var viewValues = this._values;
      elPath.forEach(function(el) {
        var last = viewValues.values.length > 0 ? viewValues.values[viewValues.values.length - 1] : null;
        if (last instanceof ViewQueryValues && last.view === el.embeddedView) {
          viewValues = last;
        } else {
          var newViewValues = new ViewQueryValues(el.embeddedView, []);
          viewValues.values.push(newViewValues);
          viewValues = newViewValues;
        }
      });
      viewValues.values.push(value);
      if (elPath.length > 0) {
        view.dirtyParentQueriesMethod.addStmt(queryListForDirtyExpr.callMethod('setDirty', []).toStmt());
      }
    };
    CompileQuery.prototype.afterChildren = function(targetMethod) {
      var values = createQueryValues(this._values);
      var updateStmts = [this.queryList.callMethod('reset', [o.literalArr(values)]).toStmt()];
      if (lang_1.isPresent(this.ownerDirectiveExpression)) {
        var valueExpr = this.meta.first ? this.queryList.prop('first') : this.queryList;
        updateStmts.push(this.ownerDirectiveExpression.prop(this.meta.propertyName).set(valueExpr).toStmt());
      }
      if (!this.meta.first) {
        updateStmts.push(this.queryList.callMethod('notifyOnChanges', []).toStmt());
      }
      targetMethod.addStmt(new o.IfStmt(this.queryList.prop('dirty'), updateStmts));
    };
    return CompileQuery;
  }());
  exports.CompileQuery = CompileQuery;
  function createQueryValues(viewValues) {
    return collection_1.ListWrapper.flatten(viewValues.values.map(function(entry) {
      if (entry instanceof ViewQueryValues) {
        return mapNestedViews(entry.view.declarationElement.appElement, entry.view, createQueryValues(entry));
      } else {
        return entry;
      }
    }));
  }
  function mapNestedViews(declarationAppElement, view, expressions) {
    var adjustedExpressions = expressions.map(function(expr) {
      return o.replaceVarInExpression(o.THIS_EXPR.name, o.variable('nestedView'), expr);
    });
    return declarationAppElement.callMethod('mapNestedViews', [o.variable(view.className), o.fn([new o.FnParam('nestedView', view.classType)], [new o.ReturnStatement(o.literalArr(adjustedExpressions))])]);
  }
  function createQueryList(query, directiveInstance, propertyName, compileView) {
    compileView.fields.push(new o.ClassField(propertyName, o.importType(identifiers_1.Identifiers.QueryList)));
    var expr = o.THIS_EXPR.prop(propertyName);
    compileView.createMethod.addStmt(o.THIS_EXPR.prop(propertyName).set(o.importExpr(identifiers_1.Identifiers.QueryList).instantiate([])).toStmt());
    return expr;
  }
  exports.createQueryList = createQueryList;
  function addQueryToTokenMap(map, query) {
    query.meta.selectors.forEach(function(selector) {
      var entry = map.get(selector);
      if (lang_1.isBlank(entry)) {
        entry = [];
        map.add(selector, entry);
      }
      entry.push(query);
    });
  }
  exports.addQueryToTokenMap = addQueryToTokenMap;
  return module.exports;
});

$__System.registerDynamic("45", ["11", "13", "e", "f", "15", "42", "14", "c", "40", "43", "44", "10"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var constants_1 = $__require('42');
  var template_ast_1 = $__require('14');
  var compile_metadata_1 = $__require('c');
  var util_1 = $__require('40');
  var compile_query_1 = $__require('43');
  var compile_method_1 = $__require('44');
  var util_2 = $__require('10');
  var CompileNode = (function() {
    function CompileNode(parent, view, nodeIndex, renderNode, sourceAst) {
      this.parent = parent;
      this.view = view;
      this.nodeIndex = nodeIndex;
      this.renderNode = renderNode;
      this.sourceAst = sourceAst;
    }
    CompileNode.prototype.isNull = function() {
      return lang_1.isBlank(this.renderNode);
    };
    CompileNode.prototype.isRootElement = function() {
      return this.view != this.parent.view;
    };
    return CompileNode;
  }());
  exports.CompileNode = CompileNode;
  var CompileElement = (function(_super) {
    __extends(CompileElement, _super);
    function CompileElement(parent, view, nodeIndex, renderNode, sourceAst, component, _directives, _resolvedProvidersArray, hasViewContainer, hasEmbeddedView, references) {
      var _this = this;
      _super.call(this, parent, view, nodeIndex, renderNode, sourceAst);
      this.component = component;
      this._directives = _directives;
      this._resolvedProvidersArray = _resolvedProvidersArray;
      this.hasViewContainer = hasViewContainer;
      this.hasEmbeddedView = hasEmbeddedView;
      this._compViewExpr = null;
      this._instances = new compile_metadata_1.CompileTokenMap();
      this._queryCount = 0;
      this._queries = new compile_metadata_1.CompileTokenMap();
      this._componentConstructorViewQueryLists = [];
      this.contentNodesByNgContentIndex = null;
      this.referenceTokens = {};
      references.forEach(function(ref) {
        return _this.referenceTokens[ref.name] = ref.value;
      });
      this.elementRef = o.importExpr(identifiers_1.Identifiers.ElementRef).instantiate([this.renderNode]);
      this._instances.add(identifiers_1.identifierToken(identifiers_1.Identifiers.ElementRef), this.elementRef);
      this.injector = o.THIS_EXPR.callMethod('injector', [o.literal(this.nodeIndex)]);
      this._instances.add(identifiers_1.identifierToken(identifiers_1.Identifiers.Injector), this.injector);
      this._instances.add(identifiers_1.identifierToken(identifiers_1.Identifiers.Renderer), o.THIS_EXPR.prop('renderer'));
      if (this.hasViewContainer || this.hasEmbeddedView || lang_1.isPresent(this.component)) {
        this._createAppElement();
      }
    }
    CompileElement.createNull = function() {
      return new CompileElement(null, null, null, null, null, null, [], [], false, false, []);
    };
    CompileElement.prototype._createAppElement = function() {
      var fieldName = "_appEl_" + this.nodeIndex;
      var parentNodeIndex = this.isRootElement() ? null : this.parent.nodeIndex;
      this.view.fields.push(new o.ClassField(fieldName, o.importType(identifiers_1.Identifiers.AppElement), [o.StmtModifier.Private]));
      var statement = o.THIS_EXPR.prop(fieldName).set(o.importExpr(identifiers_1.Identifiers.AppElement).instantiate([o.literal(this.nodeIndex), o.literal(parentNodeIndex), o.THIS_EXPR, this.renderNode])).toStmt();
      this.view.createMethod.addStmt(statement);
      this.appElement = o.THIS_EXPR.prop(fieldName);
      this._instances.add(identifiers_1.identifierToken(identifiers_1.Identifiers.AppElement), this.appElement);
    };
    CompileElement.prototype.setComponentView = function(compViewExpr) {
      this._compViewExpr = compViewExpr;
      this.contentNodesByNgContentIndex = collection_1.ListWrapper.createFixedSize(this.component.template.ngContentSelectors.length);
      for (var i = 0; i < this.contentNodesByNgContentIndex.length; i++) {
        this.contentNodesByNgContentIndex[i] = [];
      }
    };
    CompileElement.prototype.setEmbeddedView = function(embeddedView) {
      this.embeddedView = embeddedView;
      if (lang_1.isPresent(embeddedView)) {
        var createTemplateRefExpr = o.importExpr(identifiers_1.Identifiers.TemplateRef_).instantiate([this.appElement, this.embeddedView.viewFactory]);
        var provider = new compile_metadata_1.CompileProviderMetadata({
          token: identifiers_1.identifierToken(identifiers_1.Identifiers.TemplateRef),
          useValue: createTemplateRefExpr
        });
        this._resolvedProvidersArray.unshift(new template_ast_1.ProviderAst(provider.token, false, true, [provider], template_ast_1.ProviderAstType.Builtin, this.sourceAst.sourceSpan));
      }
    };
    CompileElement.prototype.beforeChildren = function() {
      var _this = this;
      if (this.hasViewContainer) {
        this._instances.add(identifiers_1.identifierToken(identifiers_1.Identifiers.ViewContainerRef), this.appElement.prop('vcRef'));
      }
      this._resolvedProviders = new compile_metadata_1.CompileTokenMap();
      this._resolvedProvidersArray.forEach(function(provider) {
        return _this._resolvedProviders.add(provider.token, provider);
      });
      this._resolvedProviders.values().forEach(function(resolvedProvider) {
        var providerValueExpressions = resolvedProvider.providers.map(function(provider) {
          if (lang_1.isPresent(provider.useExisting)) {
            return _this._getDependency(resolvedProvider.providerType, new compile_metadata_1.CompileDiDependencyMetadata({token: provider.useExisting}));
          } else if (lang_1.isPresent(provider.useFactory)) {
            var deps = lang_1.isPresent(provider.deps) ? provider.deps : provider.useFactory.diDeps;
            var depsExpr = deps.map(function(dep) {
              return _this._getDependency(resolvedProvider.providerType, dep);
            });
            return o.importExpr(provider.useFactory).callFn(depsExpr);
          } else if (lang_1.isPresent(provider.useClass)) {
            var deps = lang_1.isPresent(provider.deps) ? provider.deps : provider.useClass.diDeps;
            var depsExpr = deps.map(function(dep) {
              return _this._getDependency(resolvedProvider.providerType, dep);
            });
            return o.importExpr(provider.useClass).instantiate(depsExpr, o.importType(provider.useClass));
          } else {
            return _convertValueToOutputAst(provider.useValue);
          }
        });
        var propName = "_" + resolvedProvider.token.name + "_" + _this.nodeIndex + "_" + _this._instances.size;
        var instance = createProviderProperty(propName, resolvedProvider, providerValueExpressions, resolvedProvider.multiProvider, resolvedProvider.eager, _this);
        _this._instances.add(resolvedProvider.token, instance);
      });
      this.directiveInstances = this._directives.map(function(directive) {
        return _this._instances.get(identifiers_1.identifierToken(directive.type));
      });
      for (var i = 0; i < this.directiveInstances.length; i++) {
        var directiveInstance = this.directiveInstances[i];
        var directive = this._directives[i];
        directive.queries.forEach(function(queryMeta) {
          _this._addQuery(queryMeta, directiveInstance);
        });
      }
      var queriesWithReads = [];
      this._resolvedProviders.values().forEach(function(resolvedProvider) {
        var queriesForProvider = _this._getQueriesFor(resolvedProvider.token);
        collection_1.ListWrapper.addAll(queriesWithReads, queriesForProvider.map(function(query) {
          return new _QueryWithRead(query, resolvedProvider.token);
        }));
      });
      collection_1.StringMapWrapper.forEach(this.referenceTokens, function(_, varName) {
        var token = _this.referenceTokens[varName];
        var varValue;
        if (lang_1.isPresent(token)) {
          varValue = _this._instances.get(token);
        } else {
          varValue = _this.renderNode;
        }
        _this.view.locals.set(varName, varValue);
        var varToken = new compile_metadata_1.CompileTokenMetadata({value: varName});
        collection_1.ListWrapper.addAll(queriesWithReads, _this._getQueriesFor(varToken).map(function(query) {
          return new _QueryWithRead(query, varToken);
        }));
      });
      queriesWithReads.forEach(function(queryWithRead) {
        var value;
        if (lang_1.isPresent(queryWithRead.read.identifier)) {
          value = _this._instances.get(queryWithRead.read);
        } else {
          var token = _this.referenceTokens[queryWithRead.read.value];
          if (lang_1.isPresent(token)) {
            value = _this._instances.get(token);
          } else {
            value = _this.elementRef;
          }
        }
        if (lang_1.isPresent(value)) {
          queryWithRead.query.addValue(value, _this.view);
        }
      });
      if (lang_1.isPresent(this.component)) {
        var componentConstructorViewQueryList = lang_1.isPresent(this.component) ? o.literalArr(this._componentConstructorViewQueryLists) : o.NULL_EXPR;
        var compExpr = lang_1.isPresent(this.getComponent()) ? this.getComponent() : o.NULL_EXPR;
        this.view.createMethod.addStmt(this.appElement.callMethod('initComponent', [compExpr, componentConstructorViewQueryList, this._compViewExpr]).toStmt());
      }
    };
    CompileElement.prototype.afterChildren = function(childNodeCount) {
      var _this = this;
      this._resolvedProviders.values().forEach(function(resolvedProvider) {
        var providerExpr = _this._instances.get(resolvedProvider.token);
        var providerChildNodeCount = resolvedProvider.providerType === template_ast_1.ProviderAstType.PrivateService ? 0 : childNodeCount;
        _this.view.injectorGetMethod.addStmt(createInjectInternalCondition(_this.nodeIndex, providerChildNodeCount, resolvedProvider, providerExpr));
      });
      this._queries.values().forEach(function(queries) {
        return queries.forEach(function(query) {
          return query.afterChildren(_this.view.updateContentQueriesMethod);
        });
      });
    };
    CompileElement.prototype.addContentNode = function(ngContentIndex, nodeExpr) {
      this.contentNodesByNgContentIndex[ngContentIndex].push(nodeExpr);
    };
    CompileElement.prototype.getComponent = function() {
      return lang_1.isPresent(this.component) ? this._instances.get(identifiers_1.identifierToken(this.component.type)) : null;
    };
    CompileElement.prototype.getProviderTokens = function() {
      return this._resolvedProviders.values().map(function(resolvedProvider) {
        return util_1.createDiTokenExpression(resolvedProvider.token);
      });
    };
    CompileElement.prototype._getQueriesFor = function(token) {
      var result = [];
      var currentEl = this;
      var distance = 0;
      var queries;
      while (!currentEl.isNull()) {
        queries = currentEl._queries.get(token);
        if (lang_1.isPresent(queries)) {
          collection_1.ListWrapper.addAll(result, queries.filter(function(query) {
            return query.meta.descendants || distance <= 1;
          }));
        }
        if (currentEl._directives.length > 0) {
          distance++;
        }
        currentEl = currentEl.parent;
      }
      queries = this.view.componentView.viewQueries.get(token);
      if (lang_1.isPresent(queries)) {
        collection_1.ListWrapper.addAll(result, queries);
      }
      return result;
    };
    CompileElement.prototype._addQuery = function(queryMeta, directiveInstance) {
      var propName = "_query_" + queryMeta.selectors[0].name + "_" + this.nodeIndex + "_" + this._queryCount++;
      var queryList = compile_query_1.createQueryList(queryMeta, directiveInstance, propName, this.view);
      var query = new compile_query_1.CompileQuery(queryMeta, queryList, directiveInstance, this.view);
      compile_query_1.addQueryToTokenMap(this._queries, query);
      return query;
    };
    CompileElement.prototype._getLocalDependency = function(requestingProviderType, dep) {
      var result = null;
      if (lang_1.isBlank(result) && lang_1.isPresent(dep.query)) {
        result = this._addQuery(dep.query, null).queryList;
      }
      if (lang_1.isBlank(result) && lang_1.isPresent(dep.viewQuery)) {
        result = compile_query_1.createQueryList(dep.viewQuery, null, "_viewQuery_" + dep.viewQuery.selectors[0].name + "_" + this.nodeIndex + "_" + this._componentConstructorViewQueryLists.length, this.view);
        this._componentConstructorViewQueryLists.push(result);
      }
      if (lang_1.isPresent(dep.token)) {
        if (lang_1.isBlank(result)) {
          if (dep.token.equalsTo(identifiers_1.identifierToken(identifiers_1.Identifiers.ChangeDetectorRef))) {
            if (requestingProviderType === template_ast_1.ProviderAstType.Component) {
              return this._compViewExpr.prop('ref');
            } else {
              return util_1.getPropertyInView(o.THIS_EXPR.prop('ref'), this.view, this.view.componentView);
            }
          }
        }
        if (lang_1.isBlank(result)) {
          result = this._instances.get(dep.token);
        }
      }
      return result;
    };
    CompileElement.prototype._getDependency = function(requestingProviderType, dep) {
      var currElement = this;
      var result = null;
      if (dep.isValue) {
        result = o.literal(dep.value);
      }
      if (lang_1.isBlank(result) && !dep.isSkipSelf) {
        result = this._getLocalDependency(requestingProviderType, dep);
      }
      while (lang_1.isBlank(result) && !currElement.parent.isNull()) {
        currElement = currElement.parent;
        result = currElement._getLocalDependency(template_ast_1.ProviderAstType.PublicService, new compile_metadata_1.CompileDiDependencyMetadata({token: dep.token}));
      }
      if (lang_1.isBlank(result)) {
        result = util_1.injectFromViewParentInjector(dep.token, dep.isOptional);
      }
      if (lang_1.isBlank(result)) {
        result = o.NULL_EXPR;
      }
      return util_1.getPropertyInView(result, this.view, currElement.view);
    };
    return CompileElement;
  }(CompileNode));
  exports.CompileElement = CompileElement;
  function createInjectInternalCondition(nodeIndex, childNodeCount, provider, providerExpr) {
    var indexCondition;
    if (childNodeCount > 0) {
      indexCondition = o.literal(nodeIndex).lowerEquals(constants_1.InjectMethodVars.requestNodeIndex).and(constants_1.InjectMethodVars.requestNodeIndex.lowerEquals(o.literal(nodeIndex + childNodeCount)));
    } else {
      indexCondition = o.literal(nodeIndex).identical(constants_1.InjectMethodVars.requestNodeIndex);
    }
    return new o.IfStmt(constants_1.InjectMethodVars.token.identical(util_1.createDiTokenExpression(provider.token)).and(indexCondition), [new o.ReturnStatement(providerExpr)]);
  }
  function createProviderProperty(propName, provider, providerValueExpressions, isMulti, isEager, compileElement) {
    var view = compileElement.view;
    var resolvedProviderValueExpr;
    var type;
    if (isMulti) {
      resolvedProviderValueExpr = o.literalArr(providerValueExpressions);
      type = new o.ArrayType(o.DYNAMIC_TYPE);
    } else {
      resolvedProviderValueExpr = providerValueExpressions[0];
      type = providerValueExpressions[0].type;
    }
    if (lang_1.isBlank(type)) {
      type = o.DYNAMIC_TYPE;
    }
    if (isEager) {
      view.fields.push(new o.ClassField(propName, type));
      view.createMethod.addStmt(o.THIS_EXPR.prop(propName).set(resolvedProviderValueExpr).toStmt());
    } else {
      var internalField = "_" + propName;
      view.fields.push(new o.ClassField(internalField, type));
      var getter = new compile_method_1.CompileMethod(view);
      getter.resetDebugInfo(compileElement.nodeIndex, compileElement.sourceAst);
      getter.addStmt(new o.IfStmt(o.THIS_EXPR.prop(internalField).isBlank(), [o.THIS_EXPR.prop(internalField).set(resolvedProviderValueExpr).toStmt()]));
      getter.addStmt(new o.ReturnStatement(o.THIS_EXPR.prop(internalField)));
      view.getters.push(new o.ClassGetter(propName, getter.finish(), type));
    }
    return o.THIS_EXPR.prop(propName);
  }
  var _QueryWithRead = (function() {
    function _QueryWithRead(query, match) {
      this.query = query;
      this.read = lang_1.isPresent(query.meta.read) ? query.meta.read : match;
    }
    return _QueryWithRead;
  }());
  function _convertValueToOutputAst(value) {
    return util_2.visitValue(value, new _ValueOutputAstTransformer(), null);
  }
  var _ValueOutputAstTransformer = (function(_super) {
    __extends(_ValueOutputAstTransformer, _super);
    function _ValueOutputAstTransformer() {
      _super.apply(this, arguments);
    }
    _ValueOutputAstTransformer.prototype.visitArray = function(arr, context) {
      var _this = this;
      return o.literalArr(arr.map(function(value) {
        return util_2.visitValue(value, _this, context);
      }));
    };
    _ValueOutputAstTransformer.prototype.visitStringMap = function(map, context) {
      var _this = this;
      var entries = [];
      collection_1.StringMapWrapper.forEach(map, function(value, key) {
        entries.push([key, util_2.visitValue(value, _this, context)]);
      });
      return o.literalMap(entries);
    };
    _ValueOutputAstTransformer.prototype.visitPrimitive = function(value, context) {
      return o.literal(value);
    };
    _ValueOutputAstTransformer.prototype.visitOther = function(value, context) {
      if (value instanceof compile_metadata_1.CompileIdentifierMetadata) {
        return o.importExpr(value);
      } else if (value instanceof o.Expression) {
        return value;
      } else {
        throw new core_1.BaseException("Illegal state: Don't now how to compile value " + value);
      }
    };
    return _ValueOutputAstTransformer;
  }(util_2.ValueTransformer));
  return module.exports;
});

$__System.registerDynamic("40", ["13", "d", "f", "15"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  function getPropertyInView(property, callingView, definedView) {
    if (callingView === definedView) {
      return property;
    } else {
      var viewProp = o.THIS_EXPR;
      var currView = callingView;
      while (currView !== definedView && lang_1.isPresent(currView.declarationElement.view)) {
        currView = currView.declarationElement.view;
        viewProp = viewProp.prop('parent');
      }
      if (currView !== definedView) {
        throw new exceptions_1.BaseException("Internal error: Could not calculate a property in a parent view: " + property);
      }
      if (property instanceof o.ReadPropExpr) {
        var readPropExpr_1 = property;
        if (definedView.fields.some(function(field) {
          return field.name == readPropExpr_1.name;
        }) || definedView.getters.some(function(field) {
          return field.name == readPropExpr_1.name;
        })) {
          viewProp = viewProp.cast(definedView.classType);
        }
      }
      return o.replaceVarInExpression(o.THIS_EXPR.name, viewProp, property);
    }
  }
  exports.getPropertyInView = getPropertyInView;
  function injectFromViewParentInjector(token, optional) {
    var args = [createDiTokenExpression(token)];
    if (optional) {
      args.push(o.NULL_EXPR);
    }
    return o.THIS_EXPR.prop('parentInjector').callMethod('get', args);
  }
  exports.injectFromViewParentInjector = injectFromViewParentInjector;
  function getViewFactoryName(component, embeddedTemplateIndex) {
    return "viewFactory_" + component.type.name + embeddedTemplateIndex;
  }
  exports.getViewFactoryName = getViewFactoryName;
  function createDiTokenExpression(token) {
    if (lang_1.isPresent(token.value)) {
      return o.literal(token.value);
    } else if (token.identifierIsInstance) {
      return o.importExpr(token.identifier).instantiate([], o.importType(token.identifier, [], [o.TypeModifier.Const]));
    } else {
      return o.importExpr(token.identifier);
    }
  }
  exports.createDiTokenExpression = createDiTokenExpression;
  function createFlatArray(expressions) {
    var lastNonArrayExpressions = [];
    var result = o.literalArr([]);
    for (var i = 0; i < expressions.length; i++) {
      var expr = expressions[i];
      if (expr.type instanceof o.ArrayType) {
        if (lastNonArrayExpressions.length > 0) {
          result = result.callMethod(o.BuiltinMethod.ConcatArray, [o.literalArr(lastNonArrayExpressions)]);
          lastNonArrayExpressions = [];
        }
        result = result.callMethod(o.BuiltinMethod.ConcatArray, [expr]);
      } else {
        lastNonArrayExpressions.push(expr);
      }
    }
    if (lastNonArrayExpressions.length > 0) {
      result = result.callMethod(o.BuiltinMethod.ConcatArray, [o.literalArr(lastNonArrayExpressions)]);
    }
    return result;
  }
  exports.createFlatArray = createFlatArray;
  function createPureProxy(fn, argCount, pureProxyProp, view) {
    view.fields.push(new o.ClassField(pureProxyProp.name, null));
    var pureProxyId = argCount < identifiers_1.Identifiers.pureProxies.length ? identifiers_1.Identifiers.pureProxies[argCount] : null;
    if (lang_1.isBlank(pureProxyId)) {
      throw new exceptions_1.BaseException("Unsupported number of argument for pure functions: " + argCount);
    }
    view.createMethod.addStmt(o.THIS_EXPR.prop(pureProxyProp.name).set(o.importExpr(pureProxyId).callFn([fn])).toStmt());
  }
  exports.createPureProxy = createPureProxy;
  return module.exports;
});

$__System.registerDynamic("46", ["11", "18", "13", "e", "f", "15", "42", "41", "45", "14", "40", "c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var constants_1 = $__require('42');
  var compile_view_1 = $__require('41');
  var compile_element_1 = $__require('45');
  var template_ast_1 = $__require('14');
  var util_1 = $__require('40');
  var compile_metadata_1 = $__require('c');
  var IMPLICIT_TEMPLATE_VAR = '\$implicit';
  var CLASS_ATTR = 'class';
  var STYLE_ATTR = 'style';
  var parentRenderNodeVar = o.variable('parentRenderNode');
  var rootSelectorVar = o.variable('rootSelector');
  var ViewCompileDependency = (function() {
    function ViewCompileDependency(comp, factoryPlaceholder) {
      this.comp = comp;
      this.factoryPlaceholder = factoryPlaceholder;
    }
    return ViewCompileDependency;
  }());
  exports.ViewCompileDependency = ViewCompileDependency;
  function buildView(view, template, targetDependencies) {
    var builderVisitor = new ViewBuilderVisitor(view, targetDependencies);
    template_ast_1.templateVisitAll(builderVisitor, template, view.declarationElement.isNull() ? view.declarationElement : view.declarationElement.parent);
    return builderVisitor.nestedViewCount;
  }
  exports.buildView = buildView;
  function finishView(view, targetStatements) {
    view.afterNodes();
    createViewTopLevelStmts(view, targetStatements);
    view.nodes.forEach(function(node) {
      if (node instanceof compile_element_1.CompileElement && node.hasEmbeddedView) {
        finishView(node.embeddedView, targetStatements);
      }
    });
  }
  exports.finishView = finishView;
  var ViewBuilderVisitor = (function() {
    function ViewBuilderVisitor(view, targetDependencies) {
      this.view = view;
      this.targetDependencies = targetDependencies;
      this.nestedViewCount = 0;
    }
    ViewBuilderVisitor.prototype._isRootNode = function(parent) {
      return parent.view !== this.view;
    };
    ViewBuilderVisitor.prototype._addRootNodeAndProject = function(node, ngContentIndex, parent) {
      var vcAppEl = (node instanceof compile_element_1.CompileElement && node.hasViewContainer) ? node.appElement : null;
      if (this._isRootNode(parent)) {
        if (this.view.viewType !== core_private_1.ViewType.COMPONENT) {
          this.view.rootNodesOrAppElements.push(lang_1.isPresent(vcAppEl) ? vcAppEl : node.renderNode);
        }
      } else if (lang_1.isPresent(parent.component) && lang_1.isPresent(ngContentIndex)) {
        parent.addContentNode(ngContentIndex, lang_1.isPresent(vcAppEl) ? vcAppEl : node.renderNode);
      }
    };
    ViewBuilderVisitor.prototype._getParentRenderNode = function(parent) {
      if (this._isRootNode(parent)) {
        if (this.view.viewType === core_private_1.ViewType.COMPONENT) {
          return parentRenderNodeVar;
        } else {
          return o.NULL_EXPR;
        }
      } else {
        return lang_1.isPresent(parent.component) && parent.component.template.encapsulation !== core_1.ViewEncapsulation.Native ? o.NULL_EXPR : parent.renderNode;
      }
    };
    ViewBuilderVisitor.prototype.visitBoundText = function(ast, parent) {
      return this._visitText(ast, '', ast.ngContentIndex, parent);
    };
    ViewBuilderVisitor.prototype.visitText = function(ast, parent) {
      return this._visitText(ast, ast.value, ast.ngContentIndex, parent);
    };
    ViewBuilderVisitor.prototype._visitText = function(ast, value, ngContentIndex, parent) {
      var fieldName = "_text_" + this.view.nodes.length;
      this.view.fields.push(new o.ClassField(fieldName, o.importType(this.view.genConfig.renderTypes.renderText)));
      var renderNode = o.THIS_EXPR.prop(fieldName);
      var compileNode = new compile_element_1.CompileNode(parent, this.view, this.view.nodes.length, renderNode, ast);
      var createRenderNode = o.THIS_EXPR.prop(fieldName).set(constants_1.ViewProperties.renderer.callMethod('createText', [this._getParentRenderNode(parent), o.literal(value), this.view.createMethod.resetDebugInfoExpr(this.view.nodes.length, ast)])).toStmt();
      this.view.nodes.push(compileNode);
      this.view.createMethod.addStmt(createRenderNode);
      this._addRootNodeAndProject(compileNode, ngContentIndex, parent);
      return renderNode;
    };
    ViewBuilderVisitor.prototype.visitNgContent = function(ast, parent) {
      this.view.createMethod.resetDebugInfo(null, ast);
      var parentRenderNode = this._getParentRenderNode(parent);
      var nodesExpression = constants_1.ViewProperties.projectableNodes.key(o.literal(ast.index), new o.ArrayType(o.importType(this.view.genConfig.renderTypes.renderNode)));
      if (parentRenderNode !== o.NULL_EXPR) {
        this.view.createMethod.addStmt(constants_1.ViewProperties.renderer.callMethod('projectNodes', [parentRenderNode, o.importExpr(identifiers_1.Identifiers.flattenNestedViewRenderNodes).callFn([nodesExpression])]).toStmt());
      } else if (this._isRootNode(parent)) {
        if (this.view.viewType !== core_private_1.ViewType.COMPONENT) {
          this.view.rootNodesOrAppElements.push(nodesExpression);
        }
      } else {
        if (lang_1.isPresent(parent.component) && lang_1.isPresent(ast.ngContentIndex)) {
          parent.addContentNode(ast.ngContentIndex, nodesExpression);
        }
      }
      return null;
    };
    ViewBuilderVisitor.prototype.visitElement = function(ast, parent) {
      var nodeIndex = this.view.nodes.length;
      var createRenderNodeExpr;
      var debugContextExpr = this.view.createMethod.resetDebugInfoExpr(nodeIndex, ast);
      if (nodeIndex === 0 && this.view.viewType === core_private_1.ViewType.HOST) {
        createRenderNodeExpr = o.THIS_EXPR.callMethod('selectOrCreateHostElement', [o.literal(ast.name), rootSelectorVar, debugContextExpr]);
      } else {
        createRenderNodeExpr = constants_1.ViewProperties.renderer.callMethod('createElement', [this._getParentRenderNode(parent), o.literal(ast.name), debugContextExpr]);
      }
      var fieldName = "_el_" + nodeIndex;
      this.view.fields.push(new o.ClassField(fieldName, o.importType(this.view.genConfig.renderTypes.renderElement)));
      this.view.createMethod.addStmt(o.THIS_EXPR.prop(fieldName).set(createRenderNodeExpr).toStmt());
      var renderNode = o.THIS_EXPR.prop(fieldName);
      var directives = ast.directives.map(function(directiveAst) {
        return directiveAst.directive;
      });
      var component = directives.find(function(directive) {
        return directive.isComponent;
      });
      var htmlAttrs = _readHtmlAttrs(ast.attrs);
      var attrNameAndValues = _mergeHtmlAndDirectiveAttrs(htmlAttrs, directives);
      for (var i = 0; i < attrNameAndValues.length; i++) {
        var attrName = attrNameAndValues[i][0];
        var attrValue = attrNameAndValues[i][1];
        this.view.createMethod.addStmt(constants_1.ViewProperties.renderer.callMethod('setElementAttribute', [renderNode, o.literal(attrName), o.literal(attrValue)]).toStmt());
      }
      var compileElement = new compile_element_1.CompileElement(parent, this.view, nodeIndex, renderNode, ast, component, directives, ast.providers, ast.hasViewContainer, false, ast.references);
      this.view.nodes.push(compileElement);
      var compViewExpr = null;
      if (lang_1.isPresent(component)) {
        var nestedComponentIdentifier = new compile_metadata_1.CompileIdentifierMetadata({name: util_1.getViewFactoryName(component, 0)});
        this.targetDependencies.push(new ViewCompileDependency(component, nestedComponentIdentifier));
        compViewExpr = o.variable("compView_" + nodeIndex);
        compileElement.setComponentView(compViewExpr);
        this.view.createMethod.addStmt(compViewExpr.set(o.importExpr(nestedComponentIdentifier).callFn([constants_1.ViewProperties.viewUtils, compileElement.injector, compileElement.appElement])).toDeclStmt());
      }
      compileElement.beforeChildren();
      this._addRootNodeAndProject(compileElement, ast.ngContentIndex, parent);
      template_ast_1.templateVisitAll(this, ast.children, compileElement);
      compileElement.afterChildren(this.view.nodes.length - nodeIndex - 1);
      if (lang_1.isPresent(compViewExpr)) {
        var codeGenContentNodes;
        if (this.view.component.type.isHost) {
          codeGenContentNodes = constants_1.ViewProperties.projectableNodes;
        } else {
          codeGenContentNodes = o.literalArr(compileElement.contentNodesByNgContentIndex.map(function(nodes) {
            return util_1.createFlatArray(nodes);
          }));
        }
        this.view.createMethod.addStmt(compViewExpr.callMethod('create', [compileElement.getComponent(), codeGenContentNodes, o.NULL_EXPR]).toStmt());
      }
      return null;
    };
    ViewBuilderVisitor.prototype.visitEmbeddedTemplate = function(ast, parent) {
      var nodeIndex = this.view.nodes.length;
      var fieldName = "_anchor_" + nodeIndex;
      this.view.fields.push(new o.ClassField(fieldName, o.importType(this.view.genConfig.renderTypes.renderComment)));
      this.view.createMethod.addStmt(o.THIS_EXPR.prop(fieldName).set(constants_1.ViewProperties.renderer.callMethod('createTemplateAnchor', [this._getParentRenderNode(parent), this.view.createMethod.resetDebugInfoExpr(nodeIndex, ast)])).toStmt());
      var renderNode = o.THIS_EXPR.prop(fieldName);
      var templateVariableBindings = ast.variables.map(function(varAst) {
        return [varAst.value.length > 0 ? varAst.value : IMPLICIT_TEMPLATE_VAR, varAst.name];
      });
      var directives = ast.directives.map(function(directiveAst) {
        return directiveAst.directive;
      });
      var compileElement = new compile_element_1.CompileElement(parent, this.view, nodeIndex, renderNode, ast, null, directives, ast.providers, ast.hasViewContainer, true, ast.references);
      this.view.nodes.push(compileElement);
      this.nestedViewCount++;
      var embeddedView = new compile_view_1.CompileView(this.view.component, this.view.genConfig, this.view.pipeMetas, o.NULL_EXPR, this.view.viewIndex + this.nestedViewCount, compileElement, templateVariableBindings);
      this.nestedViewCount += buildView(embeddedView, ast.children, this.targetDependencies);
      compileElement.beforeChildren();
      this._addRootNodeAndProject(compileElement, ast.ngContentIndex, parent);
      compileElement.afterChildren(0);
      return null;
    };
    ViewBuilderVisitor.prototype.visitAttr = function(ast, ctx) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitDirective = function(ast, ctx) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitEvent = function(ast, eventTargetAndNames) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitReference = function(ast, ctx) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitVariable = function(ast, ctx) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitDirectiveProperty = function(ast, context) {
      return null;
    };
    ViewBuilderVisitor.prototype.visitElementProperty = function(ast, context) {
      return null;
    };
    return ViewBuilderVisitor;
  }());
  function _mergeHtmlAndDirectiveAttrs(declaredHtmlAttrs, directives) {
    var result = {};
    collection_1.StringMapWrapper.forEach(declaredHtmlAttrs, function(value, key) {
      result[key] = value;
    });
    directives.forEach(function(directiveMeta) {
      collection_1.StringMapWrapper.forEach(directiveMeta.hostAttributes, function(value, name) {
        var prevValue = result[name];
        result[name] = lang_1.isPresent(prevValue) ? mergeAttributeValue(name, prevValue, value) : value;
      });
    });
    return mapToKeyValueArray(result);
  }
  function _readHtmlAttrs(attrs) {
    var htmlAttrs = {};
    attrs.forEach(function(ast) {
      htmlAttrs[ast.name] = ast.value;
    });
    return htmlAttrs;
  }
  function mergeAttributeValue(attrName, attrValue1, attrValue2) {
    if (attrName == CLASS_ATTR || attrName == STYLE_ATTR) {
      return attrValue1 + " " + attrValue2;
    } else {
      return attrValue2;
    }
  }
  function mapToKeyValueArray(data) {
    var entryArray = [];
    collection_1.StringMapWrapper.forEach(data, function(value, name) {
      entryArray.push([name, value]);
    });
    collection_1.ListWrapper.sort(entryArray, function(entry1, entry2) {
      return lang_1.StringWrapper.compare(entry1[0], entry2[0]);
    });
    var keyValueArray = [];
    entryArray.forEach(function(entry) {
      keyValueArray.push([entry[0], entry[1]]);
    });
    return keyValueArray;
  }
  function createViewTopLevelStmts(view, targetStatements) {
    var nodeDebugInfosVar = o.NULL_EXPR;
    if (view.genConfig.genDebugInfo) {
      nodeDebugInfosVar = o.variable("nodeDebugInfos_" + view.component.type.name + view.viewIndex);
      targetStatements.push(nodeDebugInfosVar.set(o.literalArr(view.nodes.map(createStaticNodeDebugInfo), new o.ArrayType(new o.ExternalType(identifiers_1.Identifiers.StaticNodeDebugInfo), [o.TypeModifier.Const]))).toDeclStmt(null, [o.StmtModifier.Final]));
    }
    var renderCompTypeVar = o.variable("renderType_" + view.component.type.name);
    if (view.viewIndex === 0) {
      targetStatements.push(renderCompTypeVar.set(o.NULL_EXPR).toDeclStmt(o.importType(identifiers_1.Identifiers.RenderComponentType)));
    }
    var viewClass = createViewClass(view, renderCompTypeVar, nodeDebugInfosVar);
    targetStatements.push(viewClass);
    targetStatements.push(createViewFactory(view, viewClass, renderCompTypeVar));
  }
  function createStaticNodeDebugInfo(node) {
    var compileElement = node instanceof compile_element_1.CompileElement ? node : null;
    var providerTokens = [];
    var componentToken = o.NULL_EXPR;
    var varTokenEntries = [];
    if (lang_1.isPresent(compileElement)) {
      providerTokens = compileElement.getProviderTokens();
      if (lang_1.isPresent(compileElement.component)) {
        componentToken = util_1.createDiTokenExpression(identifiers_1.identifierToken(compileElement.component.type));
      }
      collection_1.StringMapWrapper.forEach(compileElement.referenceTokens, function(token, varName) {
        varTokenEntries.push([varName, lang_1.isPresent(token) ? util_1.createDiTokenExpression(token) : o.NULL_EXPR]);
      });
    }
    return o.importExpr(identifiers_1.Identifiers.StaticNodeDebugInfo).instantiate([o.literalArr(providerTokens, new o.ArrayType(o.DYNAMIC_TYPE, [o.TypeModifier.Const])), componentToken, o.literalMap(varTokenEntries, new o.MapType(o.DYNAMIC_TYPE, [o.TypeModifier.Const]))], o.importType(identifiers_1.Identifiers.StaticNodeDebugInfo, null, [o.TypeModifier.Const]));
  }
  function createViewClass(view, renderCompTypeVar, nodeDebugInfosVar) {
    var viewConstructorArgs = [new o.FnParam(constants_1.ViewConstructorVars.viewUtils.name, o.importType(identifiers_1.Identifiers.ViewUtils)), new o.FnParam(constants_1.ViewConstructorVars.parentInjector.name, o.importType(identifiers_1.Identifiers.Injector)), new o.FnParam(constants_1.ViewConstructorVars.declarationEl.name, o.importType(identifiers_1.Identifiers.AppElement))];
    var superConstructorArgs = [o.variable(view.className), renderCompTypeVar, constants_1.ViewTypeEnum.fromValue(view.viewType), constants_1.ViewConstructorVars.viewUtils, constants_1.ViewConstructorVars.parentInjector, constants_1.ViewConstructorVars.declarationEl, constants_1.ChangeDetectionStrategyEnum.fromValue(getChangeDetectionMode(view))];
    if (view.genConfig.genDebugInfo) {
      superConstructorArgs.push(nodeDebugInfosVar);
    }
    var viewConstructor = new o.ClassMethod(null, viewConstructorArgs, [o.SUPER_EXPR.callFn(superConstructorArgs).toStmt()]);
    var viewMethods = [new o.ClassMethod('createInternal', [new o.FnParam(rootSelectorVar.name, o.STRING_TYPE)], generateCreateMethod(view), o.importType(identifiers_1.Identifiers.AppElement)), new o.ClassMethod('injectorGetInternal', [new o.FnParam(constants_1.InjectMethodVars.token.name, o.DYNAMIC_TYPE), new o.FnParam(constants_1.InjectMethodVars.requestNodeIndex.name, o.NUMBER_TYPE), new o.FnParam(constants_1.InjectMethodVars.notFoundResult.name, o.DYNAMIC_TYPE)], addReturnValuefNotEmpty(view.injectorGetMethod.finish(), constants_1.InjectMethodVars.notFoundResult), o.DYNAMIC_TYPE), new o.ClassMethod('detectChangesInternal', [new o.FnParam(constants_1.DetectChangesVars.throwOnChange.name, o.BOOL_TYPE)], generateDetectChangesMethod(view)), new o.ClassMethod('dirtyParentQueriesInternal', [], view.dirtyParentQueriesMethod.finish()), new o.ClassMethod('destroyInternal', [], view.destroyMethod.finish())].concat(view.eventHandlerMethods);
    var superClass = view.genConfig.genDebugInfo ? identifiers_1.Identifiers.DebugAppView : identifiers_1.Identifiers.AppView;
    var viewClass = new o.ClassStmt(view.className, o.importExpr(superClass, [getContextType(view)]), view.fields, view.getters, viewConstructor, viewMethods.filter(function(method) {
      return method.body.length > 0;
    }));
    return viewClass;
  }
  function createViewFactory(view, viewClass, renderCompTypeVar) {
    var viewFactoryArgs = [new o.FnParam(constants_1.ViewConstructorVars.viewUtils.name, o.importType(identifiers_1.Identifiers.ViewUtils)), new o.FnParam(constants_1.ViewConstructorVars.parentInjector.name, o.importType(identifiers_1.Identifiers.Injector)), new o.FnParam(constants_1.ViewConstructorVars.declarationEl.name, o.importType(identifiers_1.Identifiers.AppElement))];
    var initRenderCompTypeStmts = [];
    var templateUrlInfo;
    if (view.component.template.templateUrl == view.component.type.moduleUrl) {
      templateUrlInfo = view.component.type.moduleUrl + " class " + view.component.type.name + " - inline template";
    } else {
      templateUrlInfo = view.component.template.templateUrl;
    }
    if (view.viewIndex === 0) {
      initRenderCompTypeStmts = [new o.IfStmt(renderCompTypeVar.identical(o.NULL_EXPR), [renderCompTypeVar.set(constants_1.ViewConstructorVars.viewUtils.callMethod('createRenderComponentType', [o.literal(templateUrlInfo), o.literal(view.component.template.ngContentSelectors.length), constants_1.ViewEncapsulationEnum.fromValue(view.component.template.encapsulation), view.styles])).toStmt()])];
    }
    return o.fn(viewFactoryArgs, initRenderCompTypeStmts.concat([new o.ReturnStatement(o.variable(viewClass.name).instantiate(viewClass.constructorMethod.params.map(function(param) {
      return o.variable(param.name);
    })))]), o.importType(identifiers_1.Identifiers.AppView, [getContextType(view)])).toDeclStmt(view.viewFactory.name, [o.StmtModifier.Final]);
  }
  function generateCreateMethod(view) {
    var parentRenderNodeExpr = o.NULL_EXPR;
    var parentRenderNodeStmts = [];
    if (view.viewType === core_private_1.ViewType.COMPONENT) {
      parentRenderNodeExpr = constants_1.ViewProperties.renderer.callMethod('createViewRoot', [o.THIS_EXPR.prop('declarationAppElement').prop('nativeElement')]);
      parentRenderNodeStmts = [parentRenderNodeVar.set(parentRenderNodeExpr).toDeclStmt(o.importType(view.genConfig.renderTypes.renderNode), [o.StmtModifier.Final])];
    }
    var resultExpr;
    if (view.viewType === core_private_1.ViewType.HOST) {
      resultExpr = view.nodes[0].appElement;
    } else {
      resultExpr = o.NULL_EXPR;
    }
    return parentRenderNodeStmts.concat(view.createMethod.finish()).concat([o.THIS_EXPR.callMethod('init', [util_1.createFlatArray(view.rootNodesOrAppElements), o.literalArr(view.nodes.map(function(node) {
      return node.renderNode;
    })), o.literalArr(view.disposables), o.literalArr(view.subscriptions)]).toStmt(), new o.ReturnStatement(resultExpr)]);
  }
  function generateDetectChangesMethod(view) {
    var stmts = [];
    if (view.detectChangesInInputsMethod.isEmpty() && view.updateContentQueriesMethod.isEmpty() && view.afterContentLifecycleCallbacksMethod.isEmpty() && view.detectChangesRenderPropertiesMethod.isEmpty() && view.updateViewQueriesMethod.isEmpty() && view.afterViewLifecycleCallbacksMethod.isEmpty()) {
      return stmts;
    }
    collection_1.ListWrapper.addAll(stmts, view.detectChangesInInputsMethod.finish());
    stmts.push(o.THIS_EXPR.callMethod('detectContentChildrenChanges', [constants_1.DetectChangesVars.throwOnChange]).toStmt());
    var afterContentStmts = view.updateContentQueriesMethod.finish().concat(view.afterContentLifecycleCallbacksMethod.finish());
    if (afterContentStmts.length > 0) {
      stmts.push(new o.IfStmt(o.not(constants_1.DetectChangesVars.throwOnChange), afterContentStmts));
    }
    collection_1.ListWrapper.addAll(stmts, view.detectChangesRenderPropertiesMethod.finish());
    stmts.push(o.THIS_EXPR.callMethod('detectViewChildrenChanges', [constants_1.DetectChangesVars.throwOnChange]).toStmt());
    var afterViewStmts = view.updateViewQueriesMethod.finish().concat(view.afterViewLifecycleCallbacksMethod.finish());
    if (afterViewStmts.length > 0) {
      stmts.push(new o.IfStmt(o.not(constants_1.DetectChangesVars.throwOnChange), afterViewStmts));
    }
    var varStmts = [];
    var readVars = o.findReadVarNames(stmts);
    if (collection_1.SetWrapper.has(readVars, constants_1.DetectChangesVars.changed.name)) {
      varStmts.push(constants_1.DetectChangesVars.changed.set(o.literal(true)).toDeclStmt(o.BOOL_TYPE));
    }
    if (collection_1.SetWrapper.has(readVars, constants_1.DetectChangesVars.changes.name)) {
      varStmts.push(constants_1.DetectChangesVars.changes.set(o.NULL_EXPR).toDeclStmt(new o.MapType(o.importType(identifiers_1.Identifiers.SimpleChange))));
    }
    if (collection_1.SetWrapper.has(readVars, constants_1.DetectChangesVars.valUnwrapper.name)) {
      varStmts.push(constants_1.DetectChangesVars.valUnwrapper.set(o.importExpr(identifiers_1.Identifiers.ValueUnwrapper).instantiate([])).toDeclStmt(null, [o.StmtModifier.Final]));
    }
    return varStmts.concat(stmts);
  }
  function addReturnValuefNotEmpty(statements, value) {
    if (statements.length > 0) {
      return statements.concat([new o.ReturnStatement(value)]);
    } else {
      return statements;
    }
  }
  function getContextType(view) {
    if (view.viewType === core_private_1.ViewType.COMPONENT) {
      return o.importType(view.component.type);
    }
    return o.DYNAMIC_TYPE;
  }
  function getChangeDetectionMode(view) {
    var mode;
    if (view.viewType === core_private_1.ViewType.COMPONENT) {
      mode = core_private_1.isDefaultChangeDetectionStrategy(view.component.changeDetection) ? core_1.ChangeDetectionStrategy.CheckAlways : core_1.ChangeDetectionStrategy.CheckOnce;
    } else {
      mode = core_1.ChangeDetectionStrategy.CheckAlways;
    }
    return mode;
  }
  return module.exports;
});

$__System.registerDynamic("47", ["18", "13", "f", "15", "42", "14", "10", "48", "49"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_private_1 = $__require('18');
  var core_private_2 = $__require('18');
  var lang_1 = $__require('13');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var constants_1 = $__require('42');
  var template_ast_1 = $__require('14');
  var util_1 = $__require('10');
  var expression_converter_1 = $__require('48');
  var compile_binding_1 = $__require('49');
  function createBindFieldExpr(exprIndex) {
    return o.THIS_EXPR.prop("_expr_" + exprIndex);
  }
  function createCurrValueExpr(exprIndex) {
    return o.variable("currVal_" + exprIndex);
  }
  function bind(view, currValExpr, fieldExpr, parsedExpression, context, actions, method) {
    var checkExpression = expression_converter_1.convertCdExpressionToIr(view, context, parsedExpression, constants_1.DetectChangesVars.valUnwrapper);
    if (lang_1.isBlank(checkExpression.expression)) {
      return;
    }
    view.fields.push(new o.ClassField(fieldExpr.name, null, [o.StmtModifier.Private]));
    view.createMethod.addStmt(o.THIS_EXPR.prop(fieldExpr.name).set(o.importExpr(identifiers_1.Identifiers.uninitialized)).toStmt());
    if (checkExpression.needsValueUnwrapper) {
      var initValueUnwrapperStmt = constants_1.DetectChangesVars.valUnwrapper.callMethod('reset', []).toStmt();
      method.addStmt(initValueUnwrapperStmt);
    }
    method.addStmt(currValExpr.set(checkExpression.expression).toDeclStmt(null, [o.StmtModifier.Final]));
    var condition = o.importExpr(identifiers_1.Identifiers.checkBinding).callFn([constants_1.DetectChangesVars.throwOnChange, fieldExpr, currValExpr]);
    if (checkExpression.needsValueUnwrapper) {
      condition = constants_1.DetectChangesVars.valUnwrapper.prop('hasWrappedValue').or(condition);
    }
    method.addStmt(new o.IfStmt(condition, actions.concat([o.THIS_EXPR.prop(fieldExpr.name).set(currValExpr).toStmt()])));
  }
  function bindRenderText(boundText, compileNode, view) {
    var bindingIndex = view.bindings.length;
    view.bindings.push(new compile_binding_1.CompileBinding(compileNode, boundText));
    var currValExpr = createCurrValueExpr(bindingIndex);
    var valueField = createBindFieldExpr(bindingIndex);
    view.detectChangesRenderPropertiesMethod.resetDebugInfo(compileNode.nodeIndex, boundText);
    bind(view, currValExpr, valueField, boundText.value, view.componentContext, [o.THIS_EXPR.prop('renderer').callMethod('setText', [compileNode.renderNode, currValExpr]).toStmt()], view.detectChangesRenderPropertiesMethod);
  }
  exports.bindRenderText = bindRenderText;
  function bindAndWriteToRenderer(boundProps, context, compileElement) {
    var view = compileElement.view;
    var renderNode = compileElement.renderNode;
    boundProps.forEach(function(boundProp) {
      var bindingIndex = view.bindings.length;
      view.bindings.push(new compile_binding_1.CompileBinding(compileElement, boundProp));
      view.detectChangesRenderPropertiesMethod.resetDebugInfo(compileElement.nodeIndex, boundProp);
      var fieldExpr = createBindFieldExpr(bindingIndex);
      var currValExpr = createCurrValueExpr(bindingIndex);
      var renderMethod;
      var renderValue = sanitizedValue(boundProp, currValExpr);
      var updateStmts = [];
      switch (boundProp.type) {
        case template_ast_1.PropertyBindingType.Property:
          renderMethod = 'setElementProperty';
          if (view.genConfig.logBindingUpdate) {
            updateStmts.push(logBindingUpdateStmt(renderNode, boundProp.name, currValExpr));
          }
          break;
        case template_ast_1.PropertyBindingType.Attribute:
          renderMethod = 'setElementAttribute';
          renderValue = renderValue.isBlank().conditional(o.NULL_EXPR, renderValue.callMethod('toString', []));
          break;
        case template_ast_1.PropertyBindingType.Class:
          renderMethod = 'setElementClass';
          break;
        case template_ast_1.PropertyBindingType.Style:
          renderMethod = 'setElementStyle';
          var strValue = renderValue.callMethod('toString', []);
          if (lang_1.isPresent(boundProp.unit)) {
            strValue = strValue.plus(o.literal(boundProp.unit));
          }
          renderValue = renderValue.isBlank().conditional(o.NULL_EXPR, strValue);
          break;
      }
      updateStmts.push(o.THIS_EXPR.prop('renderer').callMethod(renderMethod, [renderNode, o.literal(boundProp.name), renderValue]).toStmt());
      bind(view, currValExpr, fieldExpr, boundProp.value, context, updateStmts, view.detectChangesRenderPropertiesMethod);
    });
  }
  function sanitizedValue(boundProp, renderValue) {
    var enumValue;
    switch (boundProp.securityContext) {
      case core_private_1.SecurityContext.NONE:
        return renderValue;
      case core_private_1.SecurityContext.HTML:
        enumValue = 'HTML';
        break;
      case core_private_1.SecurityContext.STYLE:
        enumValue = 'STYLE';
        break;
      case core_private_1.SecurityContext.SCRIPT:
        enumValue = 'SCRIPT';
        break;
      case core_private_1.SecurityContext.URL:
        enumValue = 'URL';
        break;
      case core_private_1.SecurityContext.RESOURCE_URL:
        enumValue = 'RESOURCE_URL';
        break;
      default:
        throw new Error("internal error, unexpected SecurityContext " + boundProp.securityContext + ".");
    }
    var ctx = constants_1.ViewProperties.viewUtils.prop('sanitizer');
    var args = [o.importExpr(identifiers_1.Identifiers.SecurityContext).prop(enumValue), renderValue];
    return ctx.callMethod('sanitize', args);
  }
  function bindRenderInputs(boundProps, compileElement) {
    bindAndWriteToRenderer(boundProps, compileElement.view.componentContext, compileElement);
  }
  exports.bindRenderInputs = bindRenderInputs;
  function bindDirectiveHostProps(directiveAst, directiveInstance, compileElement) {
    bindAndWriteToRenderer(directiveAst.hostProperties, directiveInstance, compileElement);
  }
  exports.bindDirectiveHostProps = bindDirectiveHostProps;
  function bindDirectiveInputs(directiveAst, directiveInstance, compileElement) {
    if (directiveAst.inputs.length === 0) {
      return;
    }
    var view = compileElement.view;
    var detectChangesInInputsMethod = view.detectChangesInInputsMethod;
    detectChangesInInputsMethod.resetDebugInfo(compileElement.nodeIndex, compileElement.sourceAst);
    var lifecycleHooks = directiveAst.directive.lifecycleHooks;
    var calcChangesMap = lifecycleHooks.indexOf(core_private_2.LifecycleHooks.OnChanges) !== -1;
    var isOnPushComp = directiveAst.directive.isComponent && !core_private_2.isDefaultChangeDetectionStrategy(directiveAst.directive.changeDetection);
    if (calcChangesMap) {
      detectChangesInInputsMethod.addStmt(constants_1.DetectChangesVars.changes.set(o.NULL_EXPR).toStmt());
    }
    if (isOnPushComp) {
      detectChangesInInputsMethod.addStmt(constants_1.DetectChangesVars.changed.set(o.literal(false)).toStmt());
    }
    directiveAst.inputs.forEach(function(input) {
      var bindingIndex = view.bindings.length;
      view.bindings.push(new compile_binding_1.CompileBinding(compileElement, input));
      detectChangesInInputsMethod.resetDebugInfo(compileElement.nodeIndex, input);
      var fieldExpr = createBindFieldExpr(bindingIndex);
      var currValExpr = createCurrValueExpr(bindingIndex);
      var statements = [directiveInstance.prop(input.directiveName).set(currValExpr).toStmt()];
      if (calcChangesMap) {
        statements.push(new o.IfStmt(constants_1.DetectChangesVars.changes.identical(o.NULL_EXPR), [constants_1.DetectChangesVars.changes.set(o.literalMap([], new o.MapType(o.importType(identifiers_1.Identifiers.SimpleChange)))).toStmt()]));
        statements.push(constants_1.DetectChangesVars.changes.key(o.literal(input.directiveName)).set(o.importExpr(identifiers_1.Identifiers.SimpleChange).instantiate([fieldExpr, currValExpr])).toStmt());
      }
      if (isOnPushComp) {
        statements.push(constants_1.DetectChangesVars.changed.set(o.literal(true)).toStmt());
      }
      if (view.genConfig.logBindingUpdate) {
        statements.push(logBindingUpdateStmt(compileElement.renderNode, input.directiveName, currValExpr));
      }
      bind(view, currValExpr, fieldExpr, input.value, view.componentContext, statements, detectChangesInInputsMethod);
    });
    if (isOnPushComp) {
      detectChangesInInputsMethod.addStmt(new o.IfStmt(constants_1.DetectChangesVars.changed, [compileElement.appElement.prop('componentView').callMethod('markAsCheckOnce', []).toStmt()]));
    }
  }
  exports.bindDirectiveInputs = bindDirectiveInputs;
  function logBindingUpdateStmt(renderNode, propName, value) {
    return o.THIS_EXPR.prop('renderer').callMethod('setBindingDebugInfo', [renderNode, o.literal("ng-reflect-" + util_1.camelCaseToDashCase(propName)), value.isBlank().conditional(o.NULL_EXPR, value.callMethod('toString', []))]).toStmt();
  }
  return module.exports;
});

$__System.registerDynamic("44", ["13", "e", "f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var o = $__require('f');
  var _DebugState = (function() {
    function _DebugState(nodeIndex, sourceAst) {
      this.nodeIndex = nodeIndex;
      this.sourceAst = sourceAst;
    }
    return _DebugState;
  }());
  var NULL_DEBUG_STATE = new _DebugState(null, null);
  var CompileMethod = (function() {
    function CompileMethod(_view) {
      this._view = _view;
      this._newState = NULL_DEBUG_STATE;
      this._currState = NULL_DEBUG_STATE;
      this._bodyStatements = [];
      this._debugEnabled = this._view.genConfig.genDebugInfo;
    }
    CompileMethod.prototype._updateDebugContextIfNeeded = function() {
      if (this._newState.nodeIndex !== this._currState.nodeIndex || this._newState.sourceAst !== this._currState.sourceAst) {
        var expr = this._updateDebugContext(this._newState);
        if (lang_1.isPresent(expr)) {
          this._bodyStatements.push(expr.toStmt());
        }
      }
    };
    CompileMethod.prototype._updateDebugContext = function(newState) {
      this._currState = this._newState = newState;
      if (this._debugEnabled) {
        var sourceLocation = lang_1.isPresent(newState.sourceAst) ? newState.sourceAst.sourceSpan.start : null;
        return o.THIS_EXPR.callMethod('debug', [o.literal(newState.nodeIndex), lang_1.isPresent(sourceLocation) ? o.literal(sourceLocation.line) : o.NULL_EXPR, lang_1.isPresent(sourceLocation) ? o.literal(sourceLocation.col) : o.NULL_EXPR]);
      } else {
        return null;
      }
    };
    CompileMethod.prototype.resetDebugInfoExpr = function(nodeIndex, templateAst) {
      var res = this._updateDebugContext(new _DebugState(nodeIndex, templateAst));
      return lang_1.isPresent(res) ? res : o.NULL_EXPR;
    };
    CompileMethod.prototype.resetDebugInfo = function(nodeIndex, templateAst) {
      this._newState = new _DebugState(nodeIndex, templateAst);
    };
    CompileMethod.prototype.addStmt = function(stmt) {
      this._updateDebugContextIfNeeded();
      this._bodyStatements.push(stmt);
    };
    CompileMethod.prototype.addStmts = function(stmts) {
      this._updateDebugContextIfNeeded();
      collection_1.ListWrapper.addAll(this._bodyStatements, stmts);
    };
    CompileMethod.prototype.finish = function() {
      return this._bodyStatements;
    };
    CompileMethod.prototype.isEmpty = function() {
      return this._bodyStatements.length === 0;
    };
    return CompileMethod;
  }());
  exports.CompileMethod = CompileMethod;
  return module.exports;
});

$__System.registerDynamic("48", ["d", "13", "f", "15"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var exceptions_1 = $__require('d');
  var lang_1 = $__require('13');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  var IMPLICIT_RECEIVER = o.variable('#implicit');
  var ExpressionWithWrappedValueInfo = (function() {
    function ExpressionWithWrappedValueInfo(expression, needsValueUnwrapper) {
      this.expression = expression;
      this.needsValueUnwrapper = needsValueUnwrapper;
    }
    return ExpressionWithWrappedValueInfo;
  }());
  exports.ExpressionWithWrappedValueInfo = ExpressionWithWrappedValueInfo;
  function convertCdExpressionToIr(nameResolver, implicitReceiver, expression, valueUnwrapper) {
    var visitor = new _AstToIrVisitor(nameResolver, implicitReceiver, valueUnwrapper);
    var irAst = expression.visit(visitor, _Mode.Expression);
    return new ExpressionWithWrappedValueInfo(irAst, visitor.needsValueUnwrapper);
  }
  exports.convertCdExpressionToIr = convertCdExpressionToIr;
  function convertCdStatementToIr(nameResolver, implicitReceiver, stmt) {
    var visitor = new _AstToIrVisitor(nameResolver, implicitReceiver, null);
    var statements = [];
    flattenStatements(stmt.visit(visitor, _Mode.Statement), statements);
    return statements;
  }
  exports.convertCdStatementToIr = convertCdStatementToIr;
  var _Mode;
  (function(_Mode) {
    _Mode[_Mode["Statement"] = 0] = "Statement";
    _Mode[_Mode["Expression"] = 1] = "Expression";
  })(_Mode || (_Mode = {}));
  function ensureStatementMode(mode, ast) {
    if (mode !== _Mode.Statement) {
      throw new exceptions_1.BaseException("Expected a statement, but saw " + ast);
    }
  }
  function ensureExpressionMode(mode, ast) {
    if (mode !== _Mode.Expression) {
      throw new exceptions_1.BaseException("Expected an expression, but saw " + ast);
    }
  }
  function convertToStatementIfNeeded(mode, expr) {
    if (mode === _Mode.Statement) {
      return expr.toStmt();
    } else {
      return expr;
    }
  }
  var _AstToIrVisitor = (function() {
    function _AstToIrVisitor(_nameResolver, _implicitReceiver, _valueUnwrapper) {
      this._nameResolver = _nameResolver;
      this._implicitReceiver = _implicitReceiver;
      this._valueUnwrapper = _valueUnwrapper;
      this.needsValueUnwrapper = false;
    }
    _AstToIrVisitor.prototype.visitBinary = function(ast, mode) {
      var op;
      switch (ast.operation) {
        case '+':
          op = o.BinaryOperator.Plus;
          break;
        case '-':
          op = o.BinaryOperator.Minus;
          break;
        case '*':
          op = o.BinaryOperator.Multiply;
          break;
        case '/':
          op = o.BinaryOperator.Divide;
          break;
        case '%':
          op = o.BinaryOperator.Modulo;
          break;
        case '&&':
          op = o.BinaryOperator.And;
          break;
        case '||':
          op = o.BinaryOperator.Or;
          break;
        case '==':
          op = o.BinaryOperator.Equals;
          break;
        case '!=':
          op = o.BinaryOperator.NotEquals;
          break;
        case '===':
          op = o.BinaryOperator.Identical;
          break;
        case '!==':
          op = o.BinaryOperator.NotIdentical;
          break;
        case '<':
          op = o.BinaryOperator.Lower;
          break;
        case '>':
          op = o.BinaryOperator.Bigger;
          break;
        case '<=':
          op = o.BinaryOperator.LowerEquals;
          break;
        case '>=':
          op = o.BinaryOperator.BiggerEquals;
          break;
        default:
          throw new exceptions_1.BaseException("Unsupported operation " + ast.operation);
      }
      return convertToStatementIfNeeded(mode, new o.BinaryOperatorExpr(op, ast.left.visit(this, _Mode.Expression), ast.right.visit(this, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitChain = function(ast, mode) {
      ensureStatementMode(mode, ast);
      return this.visitAll(ast.expressions, mode);
    };
    _AstToIrVisitor.prototype.visitConditional = function(ast, mode) {
      var value = ast.condition.visit(this, _Mode.Expression);
      return convertToStatementIfNeeded(mode, value.conditional(ast.trueExp.visit(this, _Mode.Expression), ast.falseExp.visit(this, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitPipe = function(ast, mode) {
      var input = ast.exp.visit(this, _Mode.Expression);
      var args = this.visitAll(ast.args, _Mode.Expression);
      var value = this._nameResolver.callPipe(ast.name, input, args);
      this.needsValueUnwrapper = true;
      return convertToStatementIfNeeded(mode, this._valueUnwrapper.callMethod('unwrap', [value]));
    };
    _AstToIrVisitor.prototype.visitFunctionCall = function(ast, mode) {
      return convertToStatementIfNeeded(mode, ast.target.visit(this, _Mode.Expression).callFn(this.visitAll(ast.args, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitImplicitReceiver = function(ast, mode) {
      ensureExpressionMode(mode, ast);
      return IMPLICIT_RECEIVER;
    };
    _AstToIrVisitor.prototype.visitInterpolation = function(ast, mode) {
      ensureExpressionMode(mode, ast);
      var args = [o.literal(ast.expressions.length)];
      for (var i = 0; i < ast.strings.length - 1; i++) {
        args.push(o.literal(ast.strings[i]));
        args.push(ast.expressions[i].visit(this, _Mode.Expression));
      }
      args.push(o.literal(ast.strings[ast.strings.length - 1]));
      return o.importExpr(identifiers_1.Identifiers.interpolate).callFn(args);
    };
    _AstToIrVisitor.prototype.visitKeyedRead = function(ast, mode) {
      return convertToStatementIfNeeded(mode, ast.obj.visit(this, _Mode.Expression).key(ast.key.visit(this, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitKeyedWrite = function(ast, mode) {
      var obj = ast.obj.visit(this, _Mode.Expression);
      var key = ast.key.visit(this, _Mode.Expression);
      var value = ast.value.visit(this, _Mode.Expression);
      return convertToStatementIfNeeded(mode, obj.key(key).set(value));
    };
    _AstToIrVisitor.prototype.visitLiteralArray = function(ast, mode) {
      return convertToStatementIfNeeded(mode, this._nameResolver.createLiteralArray(this.visitAll(ast.expressions, mode)));
    };
    _AstToIrVisitor.prototype.visitLiteralMap = function(ast, mode) {
      var parts = [];
      for (var i = 0; i < ast.keys.length; i++) {
        parts.push([ast.keys[i], ast.values[i].visit(this, _Mode.Expression)]);
      }
      return convertToStatementIfNeeded(mode, this._nameResolver.createLiteralMap(parts));
    };
    _AstToIrVisitor.prototype.visitLiteralPrimitive = function(ast, mode) {
      return convertToStatementIfNeeded(mode, o.literal(ast.value));
    };
    _AstToIrVisitor.prototype.visitMethodCall = function(ast, mode) {
      var args = this.visitAll(ast.args, _Mode.Expression);
      var result = null;
      var receiver = ast.receiver.visit(this, _Mode.Expression);
      if (receiver === IMPLICIT_RECEIVER) {
        var varExpr = this._nameResolver.getLocal(ast.name);
        if (lang_1.isPresent(varExpr)) {
          result = varExpr.callFn(args);
        } else {
          receiver = this._implicitReceiver;
        }
      }
      if (lang_1.isBlank(result)) {
        result = receiver.callMethod(ast.name, args);
      }
      return convertToStatementIfNeeded(mode, result);
    };
    _AstToIrVisitor.prototype.visitPrefixNot = function(ast, mode) {
      return convertToStatementIfNeeded(mode, o.not(ast.expression.visit(this, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitPropertyRead = function(ast, mode) {
      var result = null;
      var receiver = ast.receiver.visit(this, _Mode.Expression);
      if (receiver === IMPLICIT_RECEIVER) {
        result = this._nameResolver.getLocal(ast.name);
        if (lang_1.isBlank(result)) {
          receiver = this._implicitReceiver;
        }
      }
      if (lang_1.isBlank(result)) {
        result = receiver.prop(ast.name);
      }
      return convertToStatementIfNeeded(mode, result);
    };
    _AstToIrVisitor.prototype.visitPropertyWrite = function(ast, mode) {
      var receiver = ast.receiver.visit(this, _Mode.Expression);
      if (receiver === IMPLICIT_RECEIVER) {
        var varExpr = this._nameResolver.getLocal(ast.name);
        if (lang_1.isPresent(varExpr)) {
          throw new exceptions_1.BaseException('Cannot assign to a reference or variable!');
        }
        receiver = this._implicitReceiver;
      }
      return convertToStatementIfNeeded(mode, receiver.prop(ast.name).set(ast.value.visit(this, _Mode.Expression)));
    };
    _AstToIrVisitor.prototype.visitSafePropertyRead = function(ast, mode) {
      var receiver = ast.receiver.visit(this, _Mode.Expression);
      return convertToStatementIfNeeded(mode, receiver.isBlank().conditional(o.NULL_EXPR, receiver.prop(ast.name)));
    };
    _AstToIrVisitor.prototype.visitSafeMethodCall = function(ast, mode) {
      var receiver = ast.receiver.visit(this, _Mode.Expression);
      var args = this.visitAll(ast.args, _Mode.Expression);
      return convertToStatementIfNeeded(mode, receiver.isBlank().conditional(o.NULL_EXPR, receiver.callMethod(ast.name, args)));
    };
    _AstToIrVisitor.prototype.visitAll = function(asts, mode) {
      var _this = this;
      return asts.map(function(ast) {
        return ast.visit(_this, mode);
      });
    };
    _AstToIrVisitor.prototype.visitQuote = function(ast, mode) {
      throw new exceptions_1.BaseException('Quotes are not supported for evaluation!');
    };
    return _AstToIrVisitor;
  }());
  function flattenStatements(arg, output) {
    if (lang_1.isArray(arg)) {
      arg.forEach(function(entry) {
        return flattenStatements(entry, output);
      });
    } else {
      output.push(arg);
    }
  }
  return module.exports;
});

$__System.registerDynamic("49", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var CompileBinding = (function() {
    function CompileBinding(node, sourceAst) {
      this.node = node;
      this.sourceAst = sourceAst;
    }
    return CompileBinding;
  }());
  exports.CompileBinding = CompileBinding;
  return module.exports;
});

$__System.registerDynamic("4a", ["13", "e", "42", "f", "44", "48", "49"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var constants_1 = $__require('42');
  var o = $__require('f');
  var compile_method_1 = $__require('44');
  var expression_converter_1 = $__require('48');
  var compile_binding_1 = $__require('49');
  var CompileEventListener = (function() {
    function CompileEventListener(compileElement, eventTarget, eventName, listenerIndex) {
      this.compileElement = compileElement;
      this.eventTarget = eventTarget;
      this.eventName = eventName;
      this._hasComponentHostListener = false;
      this._actionResultExprs = [];
      this._method = new compile_method_1.CompileMethod(compileElement.view);
      this._methodName = "_handle_" + santitizeEventName(eventName) + "_" + compileElement.nodeIndex + "_" + listenerIndex;
      this._eventParam = new o.FnParam(constants_1.EventHandlerVars.event.name, o.importType(this.compileElement.view.genConfig.renderTypes.renderEvent));
    }
    CompileEventListener.getOrCreate = function(compileElement, eventTarget, eventName, targetEventListeners) {
      var listener = targetEventListeners.find(function(listener) {
        return listener.eventTarget == eventTarget && listener.eventName == eventName;
      });
      if (lang_1.isBlank(listener)) {
        listener = new CompileEventListener(compileElement, eventTarget, eventName, targetEventListeners.length);
        targetEventListeners.push(listener);
      }
      return listener;
    };
    CompileEventListener.prototype.addAction = function(hostEvent, directive, directiveInstance) {
      if (lang_1.isPresent(directive) && directive.isComponent) {
        this._hasComponentHostListener = true;
      }
      this._method.resetDebugInfo(this.compileElement.nodeIndex, hostEvent);
      var context = lang_1.isPresent(directiveInstance) ? directiveInstance : this.compileElement.view.componentContext;
      var actionStmts = expression_converter_1.convertCdStatementToIr(this.compileElement.view, context, hostEvent.handler);
      var lastIndex = actionStmts.length - 1;
      if (lastIndex >= 0) {
        var lastStatement = actionStmts[lastIndex];
        var returnExpr = convertStmtIntoExpression(lastStatement);
        var preventDefaultVar = o.variable("pd_" + this._actionResultExprs.length);
        this._actionResultExprs.push(preventDefaultVar);
        if (lang_1.isPresent(returnExpr)) {
          actionStmts[lastIndex] = preventDefaultVar.set(returnExpr.cast(o.DYNAMIC_TYPE).notIdentical(o.literal(false))).toDeclStmt(null, [o.StmtModifier.Final]);
        }
      }
      this._method.addStmts(actionStmts);
    };
    CompileEventListener.prototype.finishMethod = function() {
      var markPathToRootStart = this._hasComponentHostListener ? this.compileElement.appElement.prop('componentView') : o.THIS_EXPR;
      var resultExpr = o.literal(true);
      this._actionResultExprs.forEach(function(expr) {
        resultExpr = resultExpr.and(expr);
      });
      var stmts = [markPathToRootStart.callMethod('markPathToRootAsCheckOnce', []).toStmt()].concat(this._method.finish()).concat([new o.ReturnStatement(resultExpr)]);
      this.compileElement.view.eventHandlerMethods.push(new o.ClassMethod(this._methodName, [this._eventParam], stmts, o.BOOL_TYPE, [o.StmtModifier.Private]));
    };
    CompileEventListener.prototype.listenToRenderer = function() {
      var listenExpr;
      var eventListener = o.THIS_EXPR.callMethod('eventHandler', [o.THIS_EXPR.prop(this._methodName).callMethod(o.BuiltinMethod.bind, [o.THIS_EXPR])]);
      if (lang_1.isPresent(this.eventTarget)) {
        listenExpr = constants_1.ViewProperties.renderer.callMethod('listenGlobal', [o.literal(this.eventTarget), o.literal(this.eventName), eventListener]);
      } else {
        listenExpr = constants_1.ViewProperties.renderer.callMethod('listen', [this.compileElement.renderNode, o.literal(this.eventName), eventListener]);
      }
      var disposable = o.variable("disposable_" + this.compileElement.view.disposables.length);
      this.compileElement.view.disposables.push(disposable);
      this.compileElement.view.createMethod.addStmt(disposable.set(listenExpr).toDeclStmt(o.FUNCTION_TYPE, [o.StmtModifier.Private]));
    };
    CompileEventListener.prototype.listenToDirective = function(directiveInstance, observablePropName) {
      var subscription = o.variable("subscription_" + this.compileElement.view.subscriptions.length);
      this.compileElement.view.subscriptions.push(subscription);
      var eventListener = o.THIS_EXPR.callMethod('eventHandler', [o.THIS_EXPR.prop(this._methodName).callMethod(o.BuiltinMethod.bind, [o.THIS_EXPR])]);
      this.compileElement.view.createMethod.addStmt(subscription.set(directiveInstance.prop(observablePropName).callMethod(o.BuiltinMethod.SubscribeObservable, [eventListener])).toDeclStmt(null, [o.StmtModifier.Final]));
    };
    return CompileEventListener;
  }());
  exports.CompileEventListener = CompileEventListener;
  function collectEventListeners(hostEvents, dirs, compileElement) {
    var eventListeners = [];
    hostEvents.forEach(function(hostEvent) {
      compileElement.view.bindings.push(new compile_binding_1.CompileBinding(compileElement, hostEvent));
      var listener = CompileEventListener.getOrCreate(compileElement, hostEvent.target, hostEvent.name, eventListeners);
      listener.addAction(hostEvent, null, null);
    });
    collection_1.ListWrapper.forEachWithIndex(dirs, function(directiveAst, i) {
      var directiveInstance = compileElement.directiveInstances[i];
      directiveAst.hostEvents.forEach(function(hostEvent) {
        compileElement.view.bindings.push(new compile_binding_1.CompileBinding(compileElement, hostEvent));
        var listener = CompileEventListener.getOrCreate(compileElement, hostEvent.target, hostEvent.name, eventListeners);
        listener.addAction(hostEvent, directiveAst.directive, directiveInstance);
      });
    });
    eventListeners.forEach(function(listener) {
      return listener.finishMethod();
    });
    return eventListeners;
  }
  exports.collectEventListeners = collectEventListeners;
  function bindDirectiveOutputs(directiveAst, directiveInstance, eventListeners) {
    collection_1.StringMapWrapper.forEach(directiveAst.directive.outputs, function(eventName, observablePropName) {
      eventListeners.filter(function(listener) {
        return listener.eventName == eventName;
      }).forEach(function(listener) {
        listener.listenToDirective(directiveInstance, observablePropName);
      });
    });
  }
  exports.bindDirectiveOutputs = bindDirectiveOutputs;
  function bindRenderOutputs(eventListeners) {
    eventListeners.forEach(function(listener) {
      return listener.listenToRenderer();
    });
  }
  exports.bindRenderOutputs = bindRenderOutputs;
  function convertStmtIntoExpression(stmt) {
    if (stmt instanceof o.ExpressionStatement) {
      return stmt.expr;
    } else if (stmt instanceof o.ReturnStatement) {
      return stmt.value;
    }
    return null;
  }
  function santitizeEventName(name) {
    return lang_1.StringWrapper.replaceAll(name, /[^a-zA-Z_]/g, '_');
  }
  return module.exports;
});

$__System.registerDynamic("f", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('13');
  (function(TypeModifier) {
    TypeModifier[TypeModifier["Const"] = 0] = "Const";
  })(exports.TypeModifier || (exports.TypeModifier = {}));
  var TypeModifier = exports.TypeModifier;
  var Type = (function() {
    function Type(modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      this.modifiers = modifiers;
      if (lang_1.isBlank(modifiers)) {
        this.modifiers = [];
      }
    }
    Type.prototype.hasModifier = function(modifier) {
      return this.modifiers.indexOf(modifier) !== -1;
    };
    return Type;
  }());
  exports.Type = Type;
  (function(BuiltinTypeName) {
    BuiltinTypeName[BuiltinTypeName["Dynamic"] = 0] = "Dynamic";
    BuiltinTypeName[BuiltinTypeName["Bool"] = 1] = "Bool";
    BuiltinTypeName[BuiltinTypeName["String"] = 2] = "String";
    BuiltinTypeName[BuiltinTypeName["Int"] = 3] = "Int";
    BuiltinTypeName[BuiltinTypeName["Number"] = 4] = "Number";
    BuiltinTypeName[BuiltinTypeName["Function"] = 5] = "Function";
  })(exports.BuiltinTypeName || (exports.BuiltinTypeName = {}));
  var BuiltinTypeName = exports.BuiltinTypeName;
  var BuiltinType = (function(_super) {
    __extends(BuiltinType, _super);
    function BuiltinType(name, modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.name = name;
    }
    BuiltinType.prototype.visitType = function(visitor, context) {
      return visitor.visitBuiltintType(this, context);
    };
    return BuiltinType;
  }(Type));
  exports.BuiltinType = BuiltinType;
  var ExternalType = (function(_super) {
    __extends(ExternalType, _super);
    function ExternalType(value, typeParams, modifiers) {
      if (typeParams === void 0) {
        typeParams = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.value = value;
      this.typeParams = typeParams;
    }
    ExternalType.prototype.visitType = function(visitor, context) {
      return visitor.visitExternalType(this, context);
    };
    return ExternalType;
  }(Type));
  exports.ExternalType = ExternalType;
  var ArrayType = (function(_super) {
    __extends(ArrayType, _super);
    function ArrayType(of, modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.of = of;
    }
    ArrayType.prototype.visitType = function(visitor, context) {
      return visitor.visitArrayType(this, context);
    };
    return ArrayType;
  }(Type));
  exports.ArrayType = ArrayType;
  var MapType = (function(_super) {
    __extends(MapType, _super);
    function MapType(valueType, modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.valueType = valueType;
    }
    MapType.prototype.visitType = function(visitor, context) {
      return visitor.visitMapType(this, context);
    };
    return MapType;
  }(Type));
  exports.MapType = MapType;
  exports.DYNAMIC_TYPE = new BuiltinType(BuiltinTypeName.Dynamic);
  exports.BOOL_TYPE = new BuiltinType(BuiltinTypeName.Bool);
  exports.INT_TYPE = new BuiltinType(BuiltinTypeName.Int);
  exports.NUMBER_TYPE = new BuiltinType(BuiltinTypeName.Number);
  exports.STRING_TYPE = new BuiltinType(BuiltinTypeName.String);
  exports.FUNCTION_TYPE = new BuiltinType(BuiltinTypeName.Function);
  (function(BinaryOperator) {
    BinaryOperator[BinaryOperator["Equals"] = 0] = "Equals";
    BinaryOperator[BinaryOperator["NotEquals"] = 1] = "NotEquals";
    BinaryOperator[BinaryOperator["Identical"] = 2] = "Identical";
    BinaryOperator[BinaryOperator["NotIdentical"] = 3] = "NotIdentical";
    BinaryOperator[BinaryOperator["Minus"] = 4] = "Minus";
    BinaryOperator[BinaryOperator["Plus"] = 5] = "Plus";
    BinaryOperator[BinaryOperator["Divide"] = 6] = "Divide";
    BinaryOperator[BinaryOperator["Multiply"] = 7] = "Multiply";
    BinaryOperator[BinaryOperator["Modulo"] = 8] = "Modulo";
    BinaryOperator[BinaryOperator["And"] = 9] = "And";
    BinaryOperator[BinaryOperator["Or"] = 10] = "Or";
    BinaryOperator[BinaryOperator["Lower"] = 11] = "Lower";
    BinaryOperator[BinaryOperator["LowerEquals"] = 12] = "LowerEquals";
    BinaryOperator[BinaryOperator["Bigger"] = 13] = "Bigger";
    BinaryOperator[BinaryOperator["BiggerEquals"] = 14] = "BiggerEquals";
  })(exports.BinaryOperator || (exports.BinaryOperator = {}));
  var BinaryOperator = exports.BinaryOperator;
  var Expression = (function() {
    function Expression(type) {
      this.type = type;
    }
    Expression.prototype.prop = function(name) {
      return new ReadPropExpr(this, name);
    };
    Expression.prototype.key = function(index, type) {
      if (type === void 0) {
        type = null;
      }
      return new ReadKeyExpr(this, index, type);
    };
    Expression.prototype.callMethod = function(name, params) {
      return new InvokeMethodExpr(this, name, params);
    };
    Expression.prototype.callFn = function(params) {
      return new InvokeFunctionExpr(this, params);
    };
    Expression.prototype.instantiate = function(params, type) {
      if (type === void 0) {
        type = null;
      }
      return new InstantiateExpr(this, params, type);
    };
    Expression.prototype.conditional = function(trueCase, falseCase) {
      if (falseCase === void 0) {
        falseCase = null;
      }
      return new ConditionalExpr(this, trueCase, falseCase);
    };
    Expression.prototype.equals = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Equals, this, rhs);
    };
    Expression.prototype.notEquals = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.NotEquals, this, rhs);
    };
    Expression.prototype.identical = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Identical, this, rhs);
    };
    Expression.prototype.notIdentical = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.NotIdentical, this, rhs);
    };
    Expression.prototype.minus = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Minus, this, rhs);
    };
    Expression.prototype.plus = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Plus, this, rhs);
    };
    Expression.prototype.divide = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Divide, this, rhs);
    };
    Expression.prototype.multiply = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Multiply, this, rhs);
    };
    Expression.prototype.modulo = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Modulo, this, rhs);
    };
    Expression.prototype.and = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.And, this, rhs);
    };
    Expression.prototype.or = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Or, this, rhs);
    };
    Expression.prototype.lower = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Lower, this, rhs);
    };
    Expression.prototype.lowerEquals = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.LowerEquals, this, rhs);
    };
    Expression.prototype.bigger = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.Bigger, this, rhs);
    };
    Expression.prototype.biggerEquals = function(rhs) {
      return new BinaryOperatorExpr(BinaryOperator.BiggerEquals, this, rhs);
    };
    Expression.prototype.isBlank = function() {
      return this.equals(exports.NULL_EXPR);
    };
    Expression.prototype.cast = function(type) {
      return new CastExpr(this, type);
    };
    Expression.prototype.toStmt = function() {
      return new ExpressionStatement(this);
    };
    return Expression;
  }());
  exports.Expression = Expression;
  (function(BuiltinVar) {
    BuiltinVar[BuiltinVar["This"] = 0] = "This";
    BuiltinVar[BuiltinVar["Super"] = 1] = "Super";
    BuiltinVar[BuiltinVar["CatchError"] = 2] = "CatchError";
    BuiltinVar[BuiltinVar["CatchStack"] = 3] = "CatchStack";
  })(exports.BuiltinVar || (exports.BuiltinVar = {}));
  var BuiltinVar = exports.BuiltinVar;
  var ReadVarExpr = (function(_super) {
    __extends(ReadVarExpr, _super);
    function ReadVarExpr(name, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      if (lang_1.isString(name)) {
        this.name = name;
        this.builtin = null;
      } else {
        this.name = null;
        this.builtin = name;
      }
    }
    ReadVarExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitReadVarExpr(this, context);
    };
    ReadVarExpr.prototype.set = function(value) {
      return new WriteVarExpr(this.name, value);
    };
    return ReadVarExpr;
  }(Expression));
  exports.ReadVarExpr = ReadVarExpr;
  var WriteVarExpr = (function(_super) {
    __extends(WriteVarExpr, _super);
    function WriteVarExpr(name, value, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, lang_1.isPresent(type) ? type : value.type);
      this.name = name;
      this.value = value;
    }
    WriteVarExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitWriteVarExpr(this, context);
    };
    WriteVarExpr.prototype.toDeclStmt = function(type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      return new DeclareVarStmt(this.name, this.value, type, modifiers);
    };
    return WriteVarExpr;
  }(Expression));
  exports.WriteVarExpr = WriteVarExpr;
  var WriteKeyExpr = (function(_super) {
    __extends(WriteKeyExpr, _super);
    function WriteKeyExpr(receiver, index, value, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, lang_1.isPresent(type) ? type : value.type);
      this.receiver = receiver;
      this.index = index;
      this.value = value;
    }
    WriteKeyExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitWriteKeyExpr(this, context);
    };
    return WriteKeyExpr;
  }(Expression));
  exports.WriteKeyExpr = WriteKeyExpr;
  var WritePropExpr = (function(_super) {
    __extends(WritePropExpr, _super);
    function WritePropExpr(receiver, name, value, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, lang_1.isPresent(type) ? type : value.type);
      this.receiver = receiver;
      this.name = name;
      this.value = value;
    }
    WritePropExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitWritePropExpr(this, context);
    };
    return WritePropExpr;
  }(Expression));
  exports.WritePropExpr = WritePropExpr;
  (function(BuiltinMethod) {
    BuiltinMethod[BuiltinMethod["ConcatArray"] = 0] = "ConcatArray";
    BuiltinMethod[BuiltinMethod["SubscribeObservable"] = 1] = "SubscribeObservable";
    BuiltinMethod[BuiltinMethod["bind"] = 2] = "bind";
  })(exports.BuiltinMethod || (exports.BuiltinMethod = {}));
  var BuiltinMethod = exports.BuiltinMethod;
  var InvokeMethodExpr = (function(_super) {
    __extends(InvokeMethodExpr, _super);
    function InvokeMethodExpr(receiver, method, args, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.receiver = receiver;
      this.args = args;
      if (lang_1.isString(method)) {
        this.name = method;
        this.builtin = null;
      } else {
        this.name = null;
        this.builtin = method;
      }
    }
    InvokeMethodExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitInvokeMethodExpr(this, context);
    };
    return InvokeMethodExpr;
  }(Expression));
  exports.InvokeMethodExpr = InvokeMethodExpr;
  var InvokeFunctionExpr = (function(_super) {
    __extends(InvokeFunctionExpr, _super);
    function InvokeFunctionExpr(fn, args, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.fn = fn;
      this.args = args;
    }
    InvokeFunctionExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitInvokeFunctionExpr(this, context);
    };
    return InvokeFunctionExpr;
  }(Expression));
  exports.InvokeFunctionExpr = InvokeFunctionExpr;
  var InstantiateExpr = (function(_super) {
    __extends(InstantiateExpr, _super);
    function InstantiateExpr(classExpr, args, type) {
      _super.call(this, type);
      this.classExpr = classExpr;
      this.args = args;
    }
    InstantiateExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitInstantiateExpr(this, context);
    };
    return InstantiateExpr;
  }(Expression));
  exports.InstantiateExpr = InstantiateExpr;
  var LiteralExpr = (function(_super) {
    __extends(LiteralExpr, _super);
    function LiteralExpr(value, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.value = value;
    }
    LiteralExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitLiteralExpr(this, context);
    };
    return LiteralExpr;
  }(Expression));
  exports.LiteralExpr = LiteralExpr;
  var ExternalExpr = (function(_super) {
    __extends(ExternalExpr, _super);
    function ExternalExpr(value, type, typeParams) {
      if (type === void 0) {
        type = null;
      }
      if (typeParams === void 0) {
        typeParams = null;
      }
      _super.call(this, type);
      this.value = value;
      this.typeParams = typeParams;
    }
    ExternalExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitExternalExpr(this, context);
    };
    return ExternalExpr;
  }(Expression));
  exports.ExternalExpr = ExternalExpr;
  var ConditionalExpr = (function(_super) {
    __extends(ConditionalExpr, _super);
    function ConditionalExpr(condition, trueCase, falseCase, type) {
      if (falseCase === void 0) {
        falseCase = null;
      }
      if (type === void 0) {
        type = null;
      }
      _super.call(this, lang_1.isPresent(type) ? type : trueCase.type);
      this.condition = condition;
      this.falseCase = falseCase;
      this.trueCase = trueCase;
    }
    ConditionalExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitConditionalExpr(this, context);
    };
    return ConditionalExpr;
  }(Expression));
  exports.ConditionalExpr = ConditionalExpr;
  var NotExpr = (function(_super) {
    __extends(NotExpr, _super);
    function NotExpr(condition) {
      _super.call(this, exports.BOOL_TYPE);
      this.condition = condition;
    }
    NotExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitNotExpr(this, context);
    };
    return NotExpr;
  }(Expression));
  exports.NotExpr = NotExpr;
  var CastExpr = (function(_super) {
    __extends(CastExpr, _super);
    function CastExpr(value, type) {
      _super.call(this, type);
      this.value = value;
    }
    CastExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitCastExpr(this, context);
    };
    return CastExpr;
  }(Expression));
  exports.CastExpr = CastExpr;
  var FnParam = (function() {
    function FnParam(name, type) {
      if (type === void 0) {
        type = null;
      }
      this.name = name;
      this.type = type;
    }
    return FnParam;
  }());
  exports.FnParam = FnParam;
  var FunctionExpr = (function(_super) {
    __extends(FunctionExpr, _super);
    function FunctionExpr(params, statements, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.params = params;
      this.statements = statements;
    }
    FunctionExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitFunctionExpr(this, context);
    };
    FunctionExpr.prototype.toDeclStmt = function(name, modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      return new DeclareFunctionStmt(name, this.params, this.statements, this.type, modifiers);
    };
    return FunctionExpr;
  }(Expression));
  exports.FunctionExpr = FunctionExpr;
  var BinaryOperatorExpr = (function(_super) {
    __extends(BinaryOperatorExpr, _super);
    function BinaryOperatorExpr(operator, lhs, rhs, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, lang_1.isPresent(type) ? type : lhs.type);
      this.operator = operator;
      this.rhs = rhs;
      this.lhs = lhs;
    }
    BinaryOperatorExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitBinaryOperatorExpr(this, context);
    };
    return BinaryOperatorExpr;
  }(Expression));
  exports.BinaryOperatorExpr = BinaryOperatorExpr;
  var ReadPropExpr = (function(_super) {
    __extends(ReadPropExpr, _super);
    function ReadPropExpr(receiver, name, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.receiver = receiver;
      this.name = name;
    }
    ReadPropExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitReadPropExpr(this, context);
    };
    ReadPropExpr.prototype.set = function(value) {
      return new WritePropExpr(this.receiver, this.name, value);
    };
    return ReadPropExpr;
  }(Expression));
  exports.ReadPropExpr = ReadPropExpr;
  var ReadKeyExpr = (function(_super) {
    __extends(ReadKeyExpr, _super);
    function ReadKeyExpr(receiver, index, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.receiver = receiver;
      this.index = index;
    }
    ReadKeyExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitReadKeyExpr(this, context);
    };
    ReadKeyExpr.prototype.set = function(value) {
      return new WriteKeyExpr(this.receiver, this.index, value);
    };
    return ReadKeyExpr;
  }(Expression));
  exports.ReadKeyExpr = ReadKeyExpr;
  var LiteralArrayExpr = (function(_super) {
    __extends(LiteralArrayExpr, _super);
    function LiteralArrayExpr(entries, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.entries = entries;
    }
    LiteralArrayExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitLiteralArrayExpr(this, context);
    };
    return LiteralArrayExpr;
  }(Expression));
  exports.LiteralArrayExpr = LiteralArrayExpr;
  var LiteralMapExpr = (function(_super) {
    __extends(LiteralMapExpr, _super);
    function LiteralMapExpr(entries, type) {
      if (type === void 0) {
        type = null;
      }
      _super.call(this, type);
      this.entries = entries;
      this.valueType = null;
      if (lang_1.isPresent(type)) {
        this.valueType = type.valueType;
      }
    }
    LiteralMapExpr.prototype.visitExpression = function(visitor, context) {
      return visitor.visitLiteralMapExpr(this, context);
    };
    return LiteralMapExpr;
  }(Expression));
  exports.LiteralMapExpr = LiteralMapExpr;
  exports.THIS_EXPR = new ReadVarExpr(BuiltinVar.This);
  exports.SUPER_EXPR = new ReadVarExpr(BuiltinVar.Super);
  exports.CATCH_ERROR_VAR = new ReadVarExpr(BuiltinVar.CatchError);
  exports.CATCH_STACK_VAR = new ReadVarExpr(BuiltinVar.CatchStack);
  exports.NULL_EXPR = new LiteralExpr(null, null);
  (function(StmtModifier) {
    StmtModifier[StmtModifier["Final"] = 0] = "Final";
    StmtModifier[StmtModifier["Private"] = 1] = "Private";
  })(exports.StmtModifier || (exports.StmtModifier = {}));
  var StmtModifier = exports.StmtModifier;
  var Statement = (function() {
    function Statement(modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      this.modifiers = modifiers;
      if (lang_1.isBlank(modifiers)) {
        this.modifiers = [];
      }
    }
    Statement.prototype.hasModifier = function(modifier) {
      return this.modifiers.indexOf(modifier) !== -1;
    };
    return Statement;
  }());
  exports.Statement = Statement;
  var DeclareVarStmt = (function(_super) {
    __extends(DeclareVarStmt, _super);
    function DeclareVarStmt(name, value, type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.name = name;
      this.value = value;
      this.type = lang_1.isPresent(type) ? type : value.type;
    }
    DeclareVarStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitDeclareVarStmt(this, context);
    };
    return DeclareVarStmt;
  }(Statement));
  exports.DeclareVarStmt = DeclareVarStmt;
  var DeclareFunctionStmt = (function(_super) {
    __extends(DeclareFunctionStmt, _super);
    function DeclareFunctionStmt(name, params, statements, type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.name = name;
      this.params = params;
      this.statements = statements;
      this.type = type;
    }
    DeclareFunctionStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitDeclareFunctionStmt(this, context);
    };
    return DeclareFunctionStmt;
  }(Statement));
  exports.DeclareFunctionStmt = DeclareFunctionStmt;
  var ExpressionStatement = (function(_super) {
    __extends(ExpressionStatement, _super);
    function ExpressionStatement(expr) {
      _super.call(this);
      this.expr = expr;
    }
    ExpressionStatement.prototype.visitStatement = function(visitor, context) {
      return visitor.visitExpressionStmt(this, context);
    };
    return ExpressionStatement;
  }(Statement));
  exports.ExpressionStatement = ExpressionStatement;
  var ReturnStatement = (function(_super) {
    __extends(ReturnStatement, _super);
    function ReturnStatement(value) {
      _super.call(this);
      this.value = value;
    }
    ReturnStatement.prototype.visitStatement = function(visitor, context) {
      return visitor.visitReturnStmt(this, context);
    };
    return ReturnStatement;
  }(Statement));
  exports.ReturnStatement = ReturnStatement;
  var AbstractClassPart = (function() {
    function AbstractClassPart(type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      this.type = type;
      this.modifiers = modifiers;
      if (lang_1.isBlank(modifiers)) {
        this.modifiers = [];
      }
    }
    AbstractClassPart.prototype.hasModifier = function(modifier) {
      return this.modifiers.indexOf(modifier) !== -1;
    };
    return AbstractClassPart;
  }());
  exports.AbstractClassPart = AbstractClassPart;
  var ClassField = (function(_super) {
    __extends(ClassField, _super);
    function ClassField(name, type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, type, modifiers);
      this.name = name;
    }
    return ClassField;
  }(AbstractClassPart));
  exports.ClassField = ClassField;
  var ClassMethod = (function(_super) {
    __extends(ClassMethod, _super);
    function ClassMethod(name, params, body, type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, type, modifiers);
      this.name = name;
      this.params = params;
      this.body = body;
    }
    return ClassMethod;
  }(AbstractClassPart));
  exports.ClassMethod = ClassMethod;
  var ClassGetter = (function(_super) {
    __extends(ClassGetter, _super);
    function ClassGetter(name, body, type, modifiers) {
      if (type === void 0) {
        type = null;
      }
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, type, modifiers);
      this.name = name;
      this.body = body;
    }
    return ClassGetter;
  }(AbstractClassPart));
  exports.ClassGetter = ClassGetter;
  var ClassStmt = (function(_super) {
    __extends(ClassStmt, _super);
    function ClassStmt(name, parent, fields, getters, constructorMethod, methods, modifiers) {
      if (modifiers === void 0) {
        modifiers = null;
      }
      _super.call(this, modifiers);
      this.name = name;
      this.parent = parent;
      this.fields = fields;
      this.getters = getters;
      this.constructorMethod = constructorMethod;
      this.methods = methods;
    }
    ClassStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitDeclareClassStmt(this, context);
    };
    return ClassStmt;
  }(Statement));
  exports.ClassStmt = ClassStmt;
  var IfStmt = (function(_super) {
    __extends(IfStmt, _super);
    function IfStmt(condition, trueCase, falseCase) {
      if (falseCase === void 0) {
        falseCase = [];
      }
      _super.call(this);
      this.condition = condition;
      this.trueCase = trueCase;
      this.falseCase = falseCase;
    }
    IfStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitIfStmt(this, context);
    };
    return IfStmt;
  }(Statement));
  exports.IfStmt = IfStmt;
  var CommentStmt = (function(_super) {
    __extends(CommentStmt, _super);
    function CommentStmt(comment) {
      _super.call(this);
      this.comment = comment;
    }
    CommentStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitCommentStmt(this, context);
    };
    return CommentStmt;
  }(Statement));
  exports.CommentStmt = CommentStmt;
  var TryCatchStmt = (function(_super) {
    __extends(TryCatchStmt, _super);
    function TryCatchStmt(bodyStmts, catchStmts) {
      _super.call(this);
      this.bodyStmts = bodyStmts;
      this.catchStmts = catchStmts;
    }
    TryCatchStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitTryCatchStmt(this, context);
    };
    return TryCatchStmt;
  }(Statement));
  exports.TryCatchStmt = TryCatchStmt;
  var ThrowStmt = (function(_super) {
    __extends(ThrowStmt, _super);
    function ThrowStmt(error) {
      _super.call(this);
      this.error = error;
    }
    ThrowStmt.prototype.visitStatement = function(visitor, context) {
      return visitor.visitThrowStmt(this, context);
    };
    return ThrowStmt;
  }(Statement));
  exports.ThrowStmt = ThrowStmt;
  var ExpressionTransformer = (function() {
    function ExpressionTransformer() {}
    ExpressionTransformer.prototype.visitReadVarExpr = function(ast, context) {
      return ast;
    };
    ExpressionTransformer.prototype.visitWriteVarExpr = function(expr, context) {
      return new WriteVarExpr(expr.name, expr.value.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitWriteKeyExpr = function(expr, context) {
      return new WriteKeyExpr(expr.receiver.visitExpression(this, context), expr.index.visitExpression(this, context), expr.value.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitWritePropExpr = function(expr, context) {
      return new WritePropExpr(expr.receiver.visitExpression(this, context), expr.name, expr.value.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitInvokeMethodExpr = function(ast, context) {
      var method = lang_1.isPresent(ast.builtin) ? ast.builtin : ast.name;
      return new InvokeMethodExpr(ast.receiver.visitExpression(this, context), method, this.visitAllExpressions(ast.args, context), ast.type);
    };
    ExpressionTransformer.prototype.visitInvokeFunctionExpr = function(ast, context) {
      return new InvokeFunctionExpr(ast.fn.visitExpression(this, context), this.visitAllExpressions(ast.args, context), ast.type);
    };
    ExpressionTransformer.prototype.visitInstantiateExpr = function(ast, context) {
      return new InstantiateExpr(ast.classExpr.visitExpression(this, context), this.visitAllExpressions(ast.args, context), ast.type);
    };
    ExpressionTransformer.prototype.visitLiteralExpr = function(ast, context) {
      return ast;
    };
    ExpressionTransformer.prototype.visitExternalExpr = function(ast, context) {
      return ast;
    };
    ExpressionTransformer.prototype.visitConditionalExpr = function(ast, context) {
      return new ConditionalExpr(ast.condition.visitExpression(this, context), ast.trueCase.visitExpression(this, context), ast.falseCase.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitNotExpr = function(ast, context) {
      return new NotExpr(ast.condition.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitCastExpr = function(ast, context) {
      return new CastExpr(ast.value.visitExpression(this, context), context);
    };
    ExpressionTransformer.prototype.visitFunctionExpr = function(ast, context) {
      return ast;
    };
    ExpressionTransformer.prototype.visitBinaryOperatorExpr = function(ast, context) {
      return new BinaryOperatorExpr(ast.operator, ast.lhs.visitExpression(this, context), ast.rhs.visitExpression(this, context), ast.type);
    };
    ExpressionTransformer.prototype.visitReadPropExpr = function(ast, context) {
      return new ReadPropExpr(ast.receiver.visitExpression(this, context), ast.name, ast.type);
    };
    ExpressionTransformer.prototype.visitReadKeyExpr = function(ast, context) {
      return new ReadKeyExpr(ast.receiver.visitExpression(this, context), ast.index.visitExpression(this, context), ast.type);
    };
    ExpressionTransformer.prototype.visitLiteralArrayExpr = function(ast, context) {
      return new LiteralArrayExpr(this.visitAllExpressions(ast.entries, context));
    };
    ExpressionTransformer.prototype.visitLiteralMapExpr = function(ast, context) {
      var _this = this;
      return new LiteralMapExpr(ast.entries.map(function(entry) {
        return [entry[0], entry[1].visitExpression(_this, context)];
      }));
    };
    ExpressionTransformer.prototype.visitAllExpressions = function(exprs, context) {
      var _this = this;
      return exprs.map(function(expr) {
        return expr.visitExpression(_this, context);
      });
    };
    ExpressionTransformer.prototype.visitDeclareVarStmt = function(stmt, context) {
      return new DeclareVarStmt(stmt.name, stmt.value.visitExpression(this, context), stmt.type, stmt.modifiers);
    };
    ExpressionTransformer.prototype.visitDeclareFunctionStmt = function(stmt, context) {
      return stmt;
    };
    ExpressionTransformer.prototype.visitExpressionStmt = function(stmt, context) {
      return new ExpressionStatement(stmt.expr.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitReturnStmt = function(stmt, context) {
      return new ReturnStatement(stmt.value.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitDeclareClassStmt = function(stmt, context) {
      return stmt;
    };
    ExpressionTransformer.prototype.visitIfStmt = function(stmt, context) {
      return new IfStmt(stmt.condition.visitExpression(this, context), this.visitAllStatements(stmt.trueCase, context), this.visitAllStatements(stmt.falseCase, context));
    };
    ExpressionTransformer.prototype.visitTryCatchStmt = function(stmt, context) {
      return new TryCatchStmt(this.visitAllStatements(stmt.bodyStmts, context), this.visitAllStatements(stmt.catchStmts, context));
    };
    ExpressionTransformer.prototype.visitThrowStmt = function(stmt, context) {
      return new ThrowStmt(stmt.error.visitExpression(this, context));
    };
    ExpressionTransformer.prototype.visitCommentStmt = function(stmt, context) {
      return stmt;
    };
    ExpressionTransformer.prototype.visitAllStatements = function(stmts, context) {
      var _this = this;
      return stmts.map(function(stmt) {
        return stmt.visitStatement(_this, context);
      });
    };
    return ExpressionTransformer;
  }());
  exports.ExpressionTransformer = ExpressionTransformer;
  var RecursiveExpressionVisitor = (function() {
    function RecursiveExpressionVisitor() {}
    RecursiveExpressionVisitor.prototype.visitReadVarExpr = function(ast, context) {
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitWriteVarExpr = function(expr, context) {
      expr.value.visitExpression(this, context);
      return expr;
    };
    RecursiveExpressionVisitor.prototype.visitWriteKeyExpr = function(expr, context) {
      expr.receiver.visitExpression(this, context);
      expr.index.visitExpression(this, context);
      expr.value.visitExpression(this, context);
      return expr;
    };
    RecursiveExpressionVisitor.prototype.visitWritePropExpr = function(expr, context) {
      expr.receiver.visitExpression(this, context);
      expr.value.visitExpression(this, context);
      return expr;
    };
    RecursiveExpressionVisitor.prototype.visitInvokeMethodExpr = function(ast, context) {
      ast.receiver.visitExpression(this, context);
      this.visitAllExpressions(ast.args, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitInvokeFunctionExpr = function(ast, context) {
      ast.fn.visitExpression(this, context);
      this.visitAllExpressions(ast.args, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitInstantiateExpr = function(ast, context) {
      ast.classExpr.visitExpression(this, context);
      this.visitAllExpressions(ast.args, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitLiteralExpr = function(ast, context) {
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitExternalExpr = function(ast, context) {
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitConditionalExpr = function(ast, context) {
      ast.condition.visitExpression(this, context);
      ast.trueCase.visitExpression(this, context);
      ast.falseCase.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitNotExpr = function(ast, context) {
      ast.condition.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitCastExpr = function(ast, context) {
      ast.value.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitFunctionExpr = function(ast, context) {
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitBinaryOperatorExpr = function(ast, context) {
      ast.lhs.visitExpression(this, context);
      ast.rhs.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitReadPropExpr = function(ast, context) {
      ast.receiver.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitReadKeyExpr = function(ast, context) {
      ast.receiver.visitExpression(this, context);
      ast.index.visitExpression(this, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitLiteralArrayExpr = function(ast, context) {
      this.visitAllExpressions(ast.entries, context);
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitLiteralMapExpr = function(ast, context) {
      var _this = this;
      ast.entries.forEach(function(entry) {
        return entry[1].visitExpression(_this, context);
      });
      return ast;
    };
    RecursiveExpressionVisitor.prototype.visitAllExpressions = function(exprs, context) {
      var _this = this;
      exprs.forEach(function(expr) {
        return expr.visitExpression(_this, context);
      });
    };
    RecursiveExpressionVisitor.prototype.visitDeclareVarStmt = function(stmt, context) {
      stmt.value.visitExpression(this, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitDeclareFunctionStmt = function(stmt, context) {
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitExpressionStmt = function(stmt, context) {
      stmt.expr.visitExpression(this, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitReturnStmt = function(stmt, context) {
      stmt.value.visitExpression(this, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitDeclareClassStmt = function(stmt, context) {
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitIfStmt = function(stmt, context) {
      stmt.condition.visitExpression(this, context);
      this.visitAllStatements(stmt.trueCase, context);
      this.visitAllStatements(stmt.falseCase, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitTryCatchStmt = function(stmt, context) {
      this.visitAllStatements(stmt.bodyStmts, context);
      this.visitAllStatements(stmt.catchStmts, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitThrowStmt = function(stmt, context) {
      stmt.error.visitExpression(this, context);
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitCommentStmt = function(stmt, context) {
      return stmt;
    };
    RecursiveExpressionVisitor.prototype.visitAllStatements = function(stmts, context) {
      var _this = this;
      stmts.forEach(function(stmt) {
        return stmt.visitStatement(_this, context);
      });
    };
    return RecursiveExpressionVisitor;
  }());
  exports.RecursiveExpressionVisitor = RecursiveExpressionVisitor;
  function replaceVarInExpression(varName, newValue, expression) {
    var transformer = new _ReplaceVariableTransformer(varName, newValue);
    return expression.visitExpression(transformer, null);
  }
  exports.replaceVarInExpression = replaceVarInExpression;
  var _ReplaceVariableTransformer = (function(_super) {
    __extends(_ReplaceVariableTransformer, _super);
    function _ReplaceVariableTransformer(_varName, _newValue) {
      _super.call(this);
      this._varName = _varName;
      this._newValue = _newValue;
    }
    _ReplaceVariableTransformer.prototype.visitReadVarExpr = function(ast, context) {
      return ast.name == this._varName ? this._newValue : ast;
    };
    return _ReplaceVariableTransformer;
  }(ExpressionTransformer));
  function findReadVarNames(stmts) {
    var finder = new _VariableFinder();
    finder.visitAllStatements(stmts, null);
    return finder.varNames;
  }
  exports.findReadVarNames = findReadVarNames;
  var _VariableFinder = (function(_super) {
    __extends(_VariableFinder, _super);
    function _VariableFinder() {
      _super.apply(this, arguments);
      this.varNames = new Set();
    }
    _VariableFinder.prototype.visitReadVarExpr = function(ast, context) {
      this.varNames.add(ast.name);
      return null;
    };
    return _VariableFinder;
  }(RecursiveExpressionVisitor));
  function variable(name, type) {
    if (type === void 0) {
      type = null;
    }
    return new ReadVarExpr(name, type);
  }
  exports.variable = variable;
  function importExpr(id, typeParams) {
    if (typeParams === void 0) {
      typeParams = null;
    }
    return new ExternalExpr(id, null, typeParams);
  }
  exports.importExpr = importExpr;
  function importType(id, typeParams, typeModifiers) {
    if (typeParams === void 0) {
      typeParams = null;
    }
    if (typeModifiers === void 0) {
      typeModifiers = null;
    }
    return lang_1.isPresent(id) ? new ExternalType(id, typeParams, typeModifiers) : null;
  }
  exports.importType = importType;
  function literal(value, type) {
    if (type === void 0) {
      type = null;
    }
    return new LiteralExpr(value, type);
  }
  exports.literal = literal;
  function literalArr(values, type) {
    if (type === void 0) {
      type = null;
    }
    return new LiteralArrayExpr(values, type);
  }
  exports.literalArr = literalArr;
  function literalMap(values, type) {
    if (type === void 0) {
      type = null;
    }
    return new LiteralMapExpr(values, type);
  }
  exports.literalMap = literalMap;
  function not(expr) {
    return new NotExpr(expr);
  }
  exports.not = not;
  function fn(params, body, type) {
    if (type === void 0) {
      type = null;
    }
    return new FunctionExpr(params, body, type);
  }
  exports.fn = fn;
  return module.exports;
});

$__System.registerDynamic("42", ["11", "18", "13", "c", "f", "15"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var compile_metadata_1 = $__require('c');
  var o = $__require('f');
  var identifiers_1 = $__require('15');
  function _enumExpression(classIdentifier, value) {
    if (lang_1.isBlank(value))
      return o.NULL_EXPR;
    var name = lang_1.resolveEnumToken(classIdentifier.runtime, value);
    return o.importExpr(new compile_metadata_1.CompileIdentifierMetadata({
      name: classIdentifier.name + "." + name,
      moduleUrl: classIdentifier.moduleUrl,
      runtime: value
    }));
  }
  var ViewTypeEnum = (function() {
    function ViewTypeEnum() {}
    ViewTypeEnum.fromValue = function(value) {
      return _enumExpression(identifiers_1.Identifiers.ViewType, value);
    };
    ViewTypeEnum.HOST = ViewTypeEnum.fromValue(core_private_1.ViewType.HOST);
    ViewTypeEnum.COMPONENT = ViewTypeEnum.fromValue(core_private_1.ViewType.COMPONENT);
    ViewTypeEnum.EMBEDDED = ViewTypeEnum.fromValue(core_private_1.ViewType.EMBEDDED);
    return ViewTypeEnum;
  }());
  exports.ViewTypeEnum = ViewTypeEnum;
  var ViewEncapsulationEnum = (function() {
    function ViewEncapsulationEnum() {}
    ViewEncapsulationEnum.fromValue = function(value) {
      return _enumExpression(identifiers_1.Identifiers.ViewEncapsulation, value);
    };
    ViewEncapsulationEnum.Emulated = ViewEncapsulationEnum.fromValue(core_1.ViewEncapsulation.Emulated);
    ViewEncapsulationEnum.Native = ViewEncapsulationEnum.fromValue(core_1.ViewEncapsulation.Native);
    ViewEncapsulationEnum.None = ViewEncapsulationEnum.fromValue(core_1.ViewEncapsulation.None);
    return ViewEncapsulationEnum;
  }());
  exports.ViewEncapsulationEnum = ViewEncapsulationEnum;
  var ChangeDetectorStateEnum = (function() {
    function ChangeDetectorStateEnum() {}
    ChangeDetectorStateEnum.fromValue = function(value) {
      return _enumExpression(identifiers_1.Identifiers.ChangeDetectorState, value);
    };
    ChangeDetectorStateEnum.NeverChecked = ChangeDetectorStateEnum.fromValue(core_private_1.ChangeDetectorState.NeverChecked);
    ChangeDetectorStateEnum.CheckedBefore = ChangeDetectorStateEnum.fromValue(core_private_1.ChangeDetectorState.CheckedBefore);
    ChangeDetectorStateEnum.Errored = ChangeDetectorStateEnum.fromValue(core_private_1.ChangeDetectorState.Errored);
    return ChangeDetectorStateEnum;
  }());
  exports.ChangeDetectorStateEnum = ChangeDetectorStateEnum;
  var ChangeDetectionStrategyEnum = (function() {
    function ChangeDetectionStrategyEnum() {}
    ChangeDetectionStrategyEnum.fromValue = function(value) {
      return _enumExpression(identifiers_1.Identifiers.ChangeDetectionStrategy, value);
    };
    ChangeDetectionStrategyEnum.CheckOnce = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.CheckOnce);
    ChangeDetectionStrategyEnum.Checked = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.Checked);
    ChangeDetectionStrategyEnum.CheckAlways = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.CheckAlways);
    ChangeDetectionStrategyEnum.Detached = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.Detached);
    ChangeDetectionStrategyEnum.OnPush = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.OnPush);
    ChangeDetectionStrategyEnum.Default = ChangeDetectionStrategyEnum.fromValue(core_1.ChangeDetectionStrategy.Default);
    return ChangeDetectionStrategyEnum;
  }());
  exports.ChangeDetectionStrategyEnum = ChangeDetectionStrategyEnum;
  var ViewConstructorVars = (function() {
    function ViewConstructorVars() {}
    ViewConstructorVars.viewUtils = o.variable('viewUtils');
    ViewConstructorVars.parentInjector = o.variable('parentInjector');
    ViewConstructorVars.declarationEl = o.variable('declarationEl');
    return ViewConstructorVars;
  }());
  exports.ViewConstructorVars = ViewConstructorVars;
  var ViewProperties = (function() {
    function ViewProperties() {}
    ViewProperties.renderer = o.THIS_EXPR.prop('renderer');
    ViewProperties.projectableNodes = o.THIS_EXPR.prop('projectableNodes');
    ViewProperties.viewUtils = o.THIS_EXPR.prop('viewUtils');
    return ViewProperties;
  }());
  exports.ViewProperties = ViewProperties;
  var EventHandlerVars = (function() {
    function EventHandlerVars() {}
    EventHandlerVars.event = o.variable('$event');
    return EventHandlerVars;
  }());
  exports.EventHandlerVars = EventHandlerVars;
  var InjectMethodVars = (function() {
    function InjectMethodVars() {}
    InjectMethodVars.token = o.variable('token');
    InjectMethodVars.requestNodeIndex = o.variable('requestNodeIndex');
    InjectMethodVars.notFoundResult = o.variable('notFoundResult');
    return InjectMethodVars;
  }());
  exports.InjectMethodVars = InjectMethodVars;
  var DetectChangesVars = (function() {
    function DetectChangesVars() {}
    DetectChangesVars.throwOnChange = o.variable("throwOnChange");
    DetectChangesVars.changes = o.variable("changes");
    DetectChangesVars.changed = o.variable("changed");
    DetectChangesVars.valUnwrapper = o.variable("valUnwrapper");
    return DetectChangesVars;
  }());
  exports.DetectChangesVars = DetectChangesVars;
  return module.exports;
});

$__System.registerDynamic("4b", ["18", "f", "42"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_private_1 = $__require('18');
  var o = $__require('f');
  var constants_1 = $__require('42');
  var STATE_IS_NEVER_CHECKED = o.THIS_EXPR.prop('cdState').identical(constants_1.ChangeDetectorStateEnum.NeverChecked);
  var NOT_THROW_ON_CHANGES = o.not(constants_1.DetectChangesVars.throwOnChange);
  function bindDirectiveDetectChangesLifecycleCallbacks(directiveAst, directiveInstance, compileElement) {
    var view = compileElement.view;
    var detectChangesInInputsMethod = view.detectChangesInInputsMethod;
    var lifecycleHooks = directiveAst.directive.lifecycleHooks;
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.OnChanges) !== -1 && directiveAst.inputs.length > 0) {
      detectChangesInInputsMethod.addStmt(new o.IfStmt(constants_1.DetectChangesVars.changes.notIdentical(o.NULL_EXPR), [directiveInstance.callMethod('ngOnChanges', [constants_1.DetectChangesVars.changes]).toStmt()]));
    }
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.OnInit) !== -1) {
      detectChangesInInputsMethod.addStmt(new o.IfStmt(STATE_IS_NEVER_CHECKED.and(NOT_THROW_ON_CHANGES), [directiveInstance.callMethod('ngOnInit', []).toStmt()]));
    }
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.DoCheck) !== -1) {
      detectChangesInInputsMethod.addStmt(new o.IfStmt(NOT_THROW_ON_CHANGES, [directiveInstance.callMethod('ngDoCheck', []).toStmt()]));
    }
  }
  exports.bindDirectiveDetectChangesLifecycleCallbacks = bindDirectiveDetectChangesLifecycleCallbacks;
  function bindDirectiveAfterContentLifecycleCallbacks(directiveMeta, directiveInstance, compileElement) {
    var view = compileElement.view;
    var lifecycleHooks = directiveMeta.lifecycleHooks;
    var afterContentLifecycleCallbacksMethod = view.afterContentLifecycleCallbacksMethod;
    afterContentLifecycleCallbacksMethod.resetDebugInfo(compileElement.nodeIndex, compileElement.sourceAst);
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.AfterContentInit) !== -1) {
      afterContentLifecycleCallbacksMethod.addStmt(new o.IfStmt(STATE_IS_NEVER_CHECKED, [directiveInstance.callMethod('ngAfterContentInit', []).toStmt()]));
    }
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.AfterContentChecked) !== -1) {
      afterContentLifecycleCallbacksMethod.addStmt(directiveInstance.callMethod('ngAfterContentChecked', []).toStmt());
    }
  }
  exports.bindDirectiveAfterContentLifecycleCallbacks = bindDirectiveAfterContentLifecycleCallbacks;
  function bindDirectiveAfterViewLifecycleCallbacks(directiveMeta, directiveInstance, compileElement) {
    var view = compileElement.view;
    var lifecycleHooks = directiveMeta.lifecycleHooks;
    var afterViewLifecycleCallbacksMethod = view.afterViewLifecycleCallbacksMethod;
    afterViewLifecycleCallbacksMethod.resetDebugInfo(compileElement.nodeIndex, compileElement.sourceAst);
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.AfterViewInit) !== -1) {
      afterViewLifecycleCallbacksMethod.addStmt(new o.IfStmt(STATE_IS_NEVER_CHECKED, [directiveInstance.callMethod('ngAfterViewInit', []).toStmt()]));
    }
    if (lifecycleHooks.indexOf(core_private_1.LifecycleHooks.AfterViewChecked) !== -1) {
      afterViewLifecycleCallbacksMethod.addStmt(directiveInstance.callMethod('ngAfterViewChecked', []).toStmt());
    }
  }
  exports.bindDirectiveAfterViewLifecycleCallbacks = bindDirectiveAfterViewLifecycleCallbacks;
  function bindDirectiveDestroyLifecycleCallbacks(directiveMeta, directiveInstance, compileElement) {
    var onDestroyMethod = compileElement.view.destroyMethod;
    onDestroyMethod.resetDebugInfo(compileElement.nodeIndex, compileElement.sourceAst);
    if (directiveMeta.lifecycleHooks.indexOf(core_private_1.LifecycleHooks.OnDestroy) !== -1) {
      onDestroyMethod.addStmt(directiveInstance.callMethod('ngOnDestroy', []).toStmt());
    }
  }
  exports.bindDirectiveDestroyLifecycleCallbacks = bindDirectiveDestroyLifecycleCallbacks;
  function bindPipeDestroyLifecycleCallbacks(pipeMeta, pipeInstance, view) {
    var onDestroyMethod = view.destroyMethod;
    if (pipeMeta.lifecycleHooks.indexOf(core_private_1.LifecycleHooks.OnDestroy) !== -1) {
      onDestroyMethod.addStmt(pipeInstance.callMethod('ngOnDestroy', []).toStmt());
    }
  }
  exports.bindPipeDestroyLifecycleCallbacks = bindPipeDestroyLifecycleCallbacks;
  return module.exports;
});

$__System.registerDynamic("4c", ["e", "14", "47", "4a", "4b"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('e');
  var template_ast_1 = $__require('14');
  var property_binder_1 = $__require('47');
  var event_binder_1 = $__require('4a');
  var lifecycle_binder_1 = $__require('4b');
  function bindView(view, parsedTemplate) {
    var visitor = new ViewBinderVisitor(view);
    template_ast_1.templateVisitAll(visitor, parsedTemplate);
    view.pipes.forEach(function(pipe) {
      lifecycle_binder_1.bindPipeDestroyLifecycleCallbacks(pipe.meta, pipe.instance, pipe.view);
    });
  }
  exports.bindView = bindView;
  var ViewBinderVisitor = (function() {
    function ViewBinderVisitor(view) {
      this.view = view;
      this._nodeIndex = 0;
    }
    ViewBinderVisitor.prototype.visitBoundText = function(ast, parent) {
      var node = this.view.nodes[this._nodeIndex++];
      property_binder_1.bindRenderText(ast, node, this.view);
      return null;
    };
    ViewBinderVisitor.prototype.visitText = function(ast, parent) {
      this._nodeIndex++;
      return null;
    };
    ViewBinderVisitor.prototype.visitNgContent = function(ast, parent) {
      return null;
    };
    ViewBinderVisitor.prototype.visitElement = function(ast, parent) {
      var compileElement = this.view.nodes[this._nodeIndex++];
      var eventListeners = event_binder_1.collectEventListeners(ast.outputs, ast.directives, compileElement);
      property_binder_1.bindRenderInputs(ast.inputs, compileElement);
      event_binder_1.bindRenderOutputs(eventListeners);
      collection_1.ListWrapper.forEachWithIndex(ast.directives, function(directiveAst, index) {
        var directiveInstance = compileElement.directiveInstances[index];
        property_binder_1.bindDirectiveInputs(directiveAst, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveDetectChangesLifecycleCallbacks(directiveAst, directiveInstance, compileElement);
        property_binder_1.bindDirectiveHostProps(directiveAst, directiveInstance, compileElement);
        event_binder_1.bindDirectiveOutputs(directiveAst, directiveInstance, eventListeners);
      });
      template_ast_1.templateVisitAll(this, ast.children, compileElement);
      collection_1.ListWrapper.forEachWithIndex(ast.directives, function(directiveAst, index) {
        var directiveInstance = compileElement.directiveInstances[index];
        lifecycle_binder_1.bindDirectiveAfterContentLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveAfterViewLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveDestroyLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
      });
      return null;
    };
    ViewBinderVisitor.prototype.visitEmbeddedTemplate = function(ast, parent) {
      var compileElement = this.view.nodes[this._nodeIndex++];
      var eventListeners = event_binder_1.collectEventListeners(ast.outputs, ast.directives, compileElement);
      collection_1.ListWrapper.forEachWithIndex(ast.directives, function(directiveAst, index) {
        var directiveInstance = compileElement.directiveInstances[index];
        property_binder_1.bindDirectiveInputs(directiveAst, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveDetectChangesLifecycleCallbacks(directiveAst, directiveInstance, compileElement);
        event_binder_1.bindDirectiveOutputs(directiveAst, directiveInstance, eventListeners);
        lifecycle_binder_1.bindDirectiveAfterContentLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveAfterViewLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
        lifecycle_binder_1.bindDirectiveDestroyLifecycleCallbacks(directiveAst.directive, directiveInstance, compileElement);
      });
      bindView(compileElement.embeddedView, ast.children);
      return null;
    };
    ViewBinderVisitor.prototype.visitAttr = function(ast, ctx) {
      return null;
    };
    ViewBinderVisitor.prototype.visitDirective = function(ast, ctx) {
      return null;
    };
    ViewBinderVisitor.prototype.visitEvent = function(ast, eventTargetAndNames) {
      return null;
    };
    ViewBinderVisitor.prototype.visitReference = function(ast, ctx) {
      return null;
    };
    ViewBinderVisitor.prototype.visitVariable = function(ast, ctx) {
      return null;
    };
    ViewBinderVisitor.prototype.visitDirectiveProperty = function(ast, context) {
      return null;
    };
    ViewBinderVisitor.prototype.visitElementProperty = function(ast, context) {
      return null;
    };
    return ViewBinderVisitor;
  }());
  return module.exports;
});

$__System.registerDynamic("38", ["11", "13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var _ASSET_SCHEME = 'asset:';
  function createUrlResolverWithoutPackagePrefix() {
    return new UrlResolver();
  }
  exports.createUrlResolverWithoutPackagePrefix = createUrlResolverWithoutPackagePrefix;
  function createOfflineCompileUrlResolver() {
    return new UrlResolver(_ASSET_SCHEME);
  }
  exports.createOfflineCompileUrlResolver = createOfflineCompileUrlResolver;
  exports.DEFAULT_PACKAGE_URL_PROVIDER = {
    provide: core_1.PACKAGE_ROOT_URL,
    useValue: "/"
  };
  var UrlResolver = (function() {
    function UrlResolver(_packagePrefix) {
      if (_packagePrefix === void 0) {
        _packagePrefix = null;
      }
      this._packagePrefix = _packagePrefix;
    }
    UrlResolver.prototype.resolve = function(baseUrl, url) {
      var resolvedUrl = url;
      if (lang_1.isPresent(baseUrl) && baseUrl.length > 0) {
        resolvedUrl = _resolveUrl(baseUrl, resolvedUrl);
      }
      var resolvedParts = _split(resolvedUrl);
      var prefix = this._packagePrefix;
      if (lang_1.isPresent(prefix) && lang_1.isPresent(resolvedParts) && resolvedParts[_ComponentIndex.Scheme] == "package") {
        var path = resolvedParts[_ComponentIndex.Path];
        if (this._packagePrefix === _ASSET_SCHEME) {
          var pathSegements = path.split(/\//);
          resolvedUrl = "asset:" + pathSegements[0] + "/lib/" + pathSegements.slice(1).join('/');
        } else {
          prefix = lang_1.StringWrapper.stripRight(prefix, '/');
          path = lang_1.StringWrapper.stripLeft(path, '/');
          return prefix + "/" + path;
        }
      }
      return resolvedUrl;
    };
    UrlResolver.decorators = [{type: core_1.Injectable}];
    UrlResolver.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Inject,
        args: [core_1.PACKAGE_ROOT_URL]
      }]
    }];
    return UrlResolver;
  }());
  exports.UrlResolver = UrlResolver;
  function getUrlScheme(url) {
    var match = _split(url);
    return (match && match[_ComponentIndex.Scheme]) || "";
  }
  exports.getUrlScheme = getUrlScheme;
  function _buildFromEncodedParts(opt_scheme, opt_userInfo, opt_domain, opt_port, opt_path, opt_queryData, opt_fragment) {
    var out = [];
    if (lang_1.isPresent(opt_scheme)) {
      out.push(opt_scheme + ':');
    }
    if (lang_1.isPresent(opt_domain)) {
      out.push('//');
      if (lang_1.isPresent(opt_userInfo)) {
        out.push(opt_userInfo + '@');
      }
      out.push(opt_domain);
      if (lang_1.isPresent(opt_port)) {
        out.push(':' + opt_port);
      }
    }
    if (lang_1.isPresent(opt_path)) {
      out.push(opt_path);
    }
    if (lang_1.isPresent(opt_queryData)) {
      out.push('?' + opt_queryData);
    }
    if (lang_1.isPresent(opt_fragment)) {
      out.push('#' + opt_fragment);
    }
    return out.join('');
  }
  var _splitRe = lang_1.RegExpWrapper.create('^' + '(?:' + '([^:/?#.]+)' + ':)?' + '(?://' + '(?:([^/?#]*)@)?' + '([\\w\\d\\-\\u0100-\\uffff.%]*)' + '(?::([0-9]+))?' + ')?' + '([^?#]+)?' + '(?:\\?([^#]*))?' + '(?:#(.*))?' + '$');
  var _ComponentIndex;
  (function(_ComponentIndex) {
    _ComponentIndex[_ComponentIndex["Scheme"] = 1] = "Scheme";
    _ComponentIndex[_ComponentIndex["UserInfo"] = 2] = "UserInfo";
    _ComponentIndex[_ComponentIndex["Domain"] = 3] = "Domain";
    _ComponentIndex[_ComponentIndex["Port"] = 4] = "Port";
    _ComponentIndex[_ComponentIndex["Path"] = 5] = "Path";
    _ComponentIndex[_ComponentIndex["QueryData"] = 6] = "QueryData";
    _ComponentIndex[_ComponentIndex["Fragment"] = 7] = "Fragment";
  })(_ComponentIndex || (_ComponentIndex = {}));
  function _split(uri) {
    return lang_1.RegExpWrapper.firstMatch(_splitRe, uri);
  }
  function _removeDotSegments(path) {
    if (path == '/')
      return '/';
    var leadingSlash = path[0] == '/' ? '/' : '';
    var trailingSlash = path[path.length - 1] === '/' ? '/' : '';
    var segments = path.split('/');
    var out = [];
    var up = 0;
    for (var pos = 0; pos < segments.length; pos++) {
      var segment = segments[pos];
      switch (segment) {
        case '':
        case '.':
          break;
        case '..':
          if (out.length > 0) {
            out.pop();
          } else {
            up++;
          }
          break;
        default:
          out.push(segment);
      }
    }
    if (leadingSlash == '') {
      while (up-- > 0) {
        out.unshift('..');
      }
      if (out.length === 0)
        out.push('.');
    }
    return leadingSlash + out.join('/') + trailingSlash;
  }
  function _joinAndCanonicalizePath(parts) {
    var path = parts[_ComponentIndex.Path];
    path = lang_1.isBlank(path) ? '' : _removeDotSegments(path);
    parts[_ComponentIndex.Path] = path;
    return _buildFromEncodedParts(parts[_ComponentIndex.Scheme], parts[_ComponentIndex.UserInfo], parts[_ComponentIndex.Domain], parts[_ComponentIndex.Port], path, parts[_ComponentIndex.QueryData], parts[_ComponentIndex.Fragment]);
  }
  function _resolveUrl(base, url) {
    var parts = _split(encodeURI(url));
    var baseParts = _split(base);
    if (lang_1.isPresent(parts[_ComponentIndex.Scheme])) {
      return _joinAndCanonicalizePath(parts);
    } else {
      parts[_ComponentIndex.Scheme] = baseParts[_ComponentIndex.Scheme];
    }
    for (var i = _ComponentIndex.Scheme; i <= _ComponentIndex.Port; i++) {
      if (lang_1.isBlank(parts[i])) {
        parts[i] = baseParts[i];
      }
    }
    if (parts[_ComponentIndex.Path][0] == '/') {
      return _joinAndCanonicalizePath(parts);
    }
    var path = baseParts[_ComponentIndex.Path];
    if (lang_1.isBlank(path))
      path = '/';
    var index = path.lastIndexOf('/');
    path = path.substring(0, index + 1) + parts[_ComponentIndex.Path];
    parts[_ComponentIndex.Path] = path;
    return _joinAndCanonicalizePath(parts);
  }
  return module.exports;
});

$__System.registerDynamic("c", ["11", "18", "13", "d", "e", "1d", "10", "38"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var selector_1 = $__require('1d');
  var util_1 = $__require('10');
  var url_resolver_1 = $__require('38');
  var HOST_REG_EXP = /^(?:(?:\[([^\]]+)\])|(?:\(([^\)]+)\)))$/g;
  var CompileMetadataWithIdentifier = (function() {
    function CompileMetadataWithIdentifier() {}
    Object.defineProperty(CompileMetadataWithIdentifier.prototype, "identifier", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return CompileMetadataWithIdentifier;
  }());
  exports.CompileMetadataWithIdentifier = CompileMetadataWithIdentifier;
  var CompileMetadataWithType = (function(_super) {
    __extends(CompileMetadataWithType, _super);
    function CompileMetadataWithType() {
      _super.apply(this, arguments);
    }
    Object.defineProperty(CompileMetadataWithType.prototype, "type", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(CompileMetadataWithType.prototype, "identifier", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return CompileMetadataWithType;
  }(CompileMetadataWithIdentifier));
  exports.CompileMetadataWithType = CompileMetadataWithType;
  function metadataFromJson(data) {
    return _COMPILE_METADATA_FROM_JSON[data['class']](data);
  }
  exports.metadataFromJson = metadataFromJson;
  var CompileIdentifierMetadata = (function() {
    function CompileIdentifierMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          runtime = _b.runtime,
          name = _b.name,
          moduleUrl = _b.moduleUrl,
          prefix = _b.prefix,
          value = _b.value;
      this.runtime = runtime;
      this.name = name;
      this.prefix = prefix;
      this.moduleUrl = moduleUrl;
      this.value = value;
    }
    CompileIdentifierMetadata.fromJson = function(data) {
      var value = lang_1.isArray(data['value']) ? _arrayFromJson(data['value'], metadataFromJson) : _objFromJson(data['value'], metadataFromJson);
      return new CompileIdentifierMetadata({
        name: data['name'],
        prefix: data['prefix'],
        moduleUrl: data['moduleUrl'],
        value: value
      });
    };
    CompileIdentifierMetadata.prototype.toJson = function() {
      var value = lang_1.isArray(this.value) ? _arrayToJson(this.value) : _objToJson(this.value);
      return {
        'class': 'Identifier',
        'name': this.name,
        'moduleUrl': this.moduleUrl,
        'prefix': this.prefix,
        'value': value
      };
    };
    Object.defineProperty(CompileIdentifierMetadata.prototype, "identifier", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    return CompileIdentifierMetadata;
  }());
  exports.CompileIdentifierMetadata = CompileIdentifierMetadata;
  var CompileDiDependencyMetadata = (function() {
    function CompileDiDependencyMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          isAttribute = _b.isAttribute,
          isSelf = _b.isSelf,
          isHost = _b.isHost,
          isSkipSelf = _b.isSkipSelf,
          isOptional = _b.isOptional,
          isValue = _b.isValue,
          query = _b.query,
          viewQuery = _b.viewQuery,
          token = _b.token,
          value = _b.value;
      this.isAttribute = lang_1.normalizeBool(isAttribute);
      this.isSelf = lang_1.normalizeBool(isSelf);
      this.isHost = lang_1.normalizeBool(isHost);
      this.isSkipSelf = lang_1.normalizeBool(isSkipSelf);
      this.isOptional = lang_1.normalizeBool(isOptional);
      this.isValue = lang_1.normalizeBool(isValue);
      this.query = query;
      this.viewQuery = viewQuery;
      this.token = token;
      this.value = value;
    }
    CompileDiDependencyMetadata.fromJson = function(data) {
      return new CompileDiDependencyMetadata({
        token: _objFromJson(data['token'], CompileTokenMetadata.fromJson),
        query: _objFromJson(data['query'], CompileQueryMetadata.fromJson),
        viewQuery: _objFromJson(data['viewQuery'], CompileQueryMetadata.fromJson),
        value: data['value'],
        isAttribute: data['isAttribute'],
        isSelf: data['isSelf'],
        isHost: data['isHost'],
        isSkipSelf: data['isSkipSelf'],
        isOptional: data['isOptional'],
        isValue: data['isValue']
      });
    };
    CompileDiDependencyMetadata.prototype.toJson = function() {
      return {
        'token': _objToJson(this.token),
        'query': _objToJson(this.query),
        'viewQuery': _objToJson(this.viewQuery),
        'value': this.value,
        'isAttribute': this.isAttribute,
        'isSelf': this.isSelf,
        'isHost': this.isHost,
        'isSkipSelf': this.isSkipSelf,
        'isOptional': this.isOptional,
        'isValue': this.isValue
      };
    };
    return CompileDiDependencyMetadata;
  }());
  exports.CompileDiDependencyMetadata = CompileDiDependencyMetadata;
  var CompileProviderMetadata = (function() {
    function CompileProviderMetadata(_a) {
      var token = _a.token,
          useClass = _a.useClass,
          useValue = _a.useValue,
          useExisting = _a.useExisting,
          useFactory = _a.useFactory,
          deps = _a.deps,
          multi = _a.multi;
      this.token = token;
      this.useClass = useClass;
      this.useValue = useValue;
      this.useExisting = useExisting;
      this.useFactory = useFactory;
      this.deps = lang_1.normalizeBlank(deps);
      this.multi = lang_1.normalizeBool(multi);
    }
    CompileProviderMetadata.fromJson = function(data) {
      return new CompileProviderMetadata({
        token: _objFromJson(data['token'], CompileTokenMetadata.fromJson),
        useClass: _objFromJson(data['useClass'], CompileTypeMetadata.fromJson),
        useExisting: _objFromJson(data['useExisting'], CompileTokenMetadata.fromJson),
        useValue: _objFromJson(data['useValue'], CompileIdentifierMetadata.fromJson),
        useFactory: _objFromJson(data['useFactory'], CompileFactoryMetadata.fromJson),
        multi: data['multi'],
        deps: _arrayFromJson(data['deps'], CompileDiDependencyMetadata.fromJson)
      });
    };
    CompileProviderMetadata.prototype.toJson = function() {
      return {
        'class': 'Provider',
        'token': _objToJson(this.token),
        'useClass': _objToJson(this.useClass),
        'useExisting': _objToJson(this.useExisting),
        'useValue': _objToJson(this.useValue),
        'useFactory': _objToJson(this.useFactory),
        'multi': this.multi,
        'deps': _arrayToJson(this.deps)
      };
    };
    return CompileProviderMetadata;
  }());
  exports.CompileProviderMetadata = CompileProviderMetadata;
  var CompileFactoryMetadata = (function() {
    function CompileFactoryMetadata(_a) {
      var runtime = _a.runtime,
          name = _a.name,
          moduleUrl = _a.moduleUrl,
          prefix = _a.prefix,
          diDeps = _a.diDeps,
          value = _a.value;
      this.runtime = runtime;
      this.name = name;
      this.prefix = prefix;
      this.moduleUrl = moduleUrl;
      this.diDeps = _normalizeArray(diDeps);
      this.value = value;
    }
    Object.defineProperty(CompileFactoryMetadata.prototype, "identifier", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    CompileFactoryMetadata.fromJson = function(data) {
      return new CompileFactoryMetadata({
        name: data['name'],
        prefix: data['prefix'],
        moduleUrl: data['moduleUrl'],
        value: data['value'],
        diDeps: _arrayFromJson(data['diDeps'], CompileDiDependencyMetadata.fromJson)
      });
    };
    CompileFactoryMetadata.prototype.toJson = function() {
      return {
        'class': 'Factory',
        'name': this.name,
        'prefix': this.prefix,
        'moduleUrl': this.moduleUrl,
        'value': this.value,
        'diDeps': _arrayToJson(this.diDeps)
      };
    };
    return CompileFactoryMetadata;
  }());
  exports.CompileFactoryMetadata = CompileFactoryMetadata;
  var CompileTokenMetadata = (function() {
    function CompileTokenMetadata(_a) {
      var value = _a.value,
          identifier = _a.identifier,
          identifierIsInstance = _a.identifierIsInstance;
      this.value = value;
      this.identifier = identifier;
      this.identifierIsInstance = lang_1.normalizeBool(identifierIsInstance);
    }
    CompileTokenMetadata.fromJson = function(data) {
      return new CompileTokenMetadata({
        value: data['value'],
        identifier: _objFromJson(data['identifier'], CompileIdentifierMetadata.fromJson),
        identifierIsInstance: data['identifierIsInstance']
      });
    };
    CompileTokenMetadata.prototype.toJson = function() {
      return {
        'value': this.value,
        'identifier': _objToJson(this.identifier),
        'identifierIsInstance': this.identifierIsInstance
      };
    };
    Object.defineProperty(CompileTokenMetadata.prototype, "runtimeCacheKey", {
      get: function() {
        if (lang_1.isPresent(this.identifier)) {
          return this.identifier.runtime;
        } else {
          return this.value;
        }
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(CompileTokenMetadata.prototype, "assetCacheKey", {
      get: function() {
        if (lang_1.isPresent(this.identifier)) {
          return lang_1.isPresent(this.identifier.moduleUrl) && lang_1.isPresent(url_resolver_1.getUrlScheme(this.identifier.moduleUrl)) ? this.identifier.name + "|" + this.identifier.moduleUrl + "|" + this.identifierIsInstance : null;
        } else {
          return this.value;
        }
      },
      enumerable: true,
      configurable: true
    });
    CompileTokenMetadata.prototype.equalsTo = function(token2) {
      var rk = this.runtimeCacheKey;
      var ak = this.assetCacheKey;
      return (lang_1.isPresent(rk) && rk == token2.runtimeCacheKey) || (lang_1.isPresent(ak) && ak == token2.assetCacheKey);
    };
    Object.defineProperty(CompileTokenMetadata.prototype, "name", {
      get: function() {
        return lang_1.isPresent(this.value) ? util_1.sanitizeIdentifier(this.value) : this.identifier.name;
      },
      enumerable: true,
      configurable: true
    });
    return CompileTokenMetadata;
  }());
  exports.CompileTokenMetadata = CompileTokenMetadata;
  var CompileTokenMap = (function() {
    function CompileTokenMap() {
      this._valueMap = new Map();
      this._values = [];
    }
    CompileTokenMap.prototype.add = function(token, value) {
      var existing = this.get(token);
      if (lang_1.isPresent(existing)) {
        throw new exceptions_1.BaseException("Can only add to a TokenMap! Token: " + token.name);
      }
      this._values.push(value);
      var rk = token.runtimeCacheKey;
      if (lang_1.isPresent(rk)) {
        this._valueMap.set(rk, value);
      }
      var ak = token.assetCacheKey;
      if (lang_1.isPresent(ak)) {
        this._valueMap.set(ak, value);
      }
    };
    CompileTokenMap.prototype.get = function(token) {
      var rk = token.runtimeCacheKey;
      var ak = token.assetCacheKey;
      var result;
      if (lang_1.isPresent(rk)) {
        result = this._valueMap.get(rk);
      }
      if (lang_1.isBlank(result) && lang_1.isPresent(ak)) {
        result = this._valueMap.get(ak);
      }
      return result;
    };
    CompileTokenMap.prototype.values = function() {
      return this._values;
    };
    Object.defineProperty(CompileTokenMap.prototype, "size", {
      get: function() {
        return this._values.length;
      },
      enumerable: true,
      configurable: true
    });
    return CompileTokenMap;
  }());
  exports.CompileTokenMap = CompileTokenMap;
  var CompileTypeMetadata = (function() {
    function CompileTypeMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          runtime = _b.runtime,
          name = _b.name,
          moduleUrl = _b.moduleUrl,
          prefix = _b.prefix,
          isHost = _b.isHost,
          value = _b.value,
          diDeps = _b.diDeps;
      this.runtime = runtime;
      this.name = name;
      this.moduleUrl = moduleUrl;
      this.prefix = prefix;
      this.isHost = lang_1.normalizeBool(isHost);
      this.value = value;
      this.diDeps = _normalizeArray(diDeps);
    }
    CompileTypeMetadata.fromJson = function(data) {
      return new CompileTypeMetadata({
        name: data['name'],
        moduleUrl: data['moduleUrl'],
        prefix: data['prefix'],
        isHost: data['isHost'],
        value: data['value'],
        diDeps: _arrayFromJson(data['diDeps'], CompileDiDependencyMetadata.fromJson)
      });
    };
    Object.defineProperty(CompileTypeMetadata.prototype, "identifier", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(CompileTypeMetadata.prototype, "type", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    CompileTypeMetadata.prototype.toJson = function() {
      return {
        'class': 'Type',
        'name': this.name,
        'moduleUrl': this.moduleUrl,
        'prefix': this.prefix,
        'isHost': this.isHost,
        'value': this.value,
        'diDeps': _arrayToJson(this.diDeps)
      };
    };
    return CompileTypeMetadata;
  }());
  exports.CompileTypeMetadata = CompileTypeMetadata;
  var CompileQueryMetadata = (function() {
    function CompileQueryMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          selectors = _b.selectors,
          descendants = _b.descendants,
          first = _b.first,
          propertyName = _b.propertyName,
          read = _b.read;
      this.selectors = selectors;
      this.descendants = lang_1.normalizeBool(descendants);
      this.first = lang_1.normalizeBool(first);
      this.propertyName = propertyName;
      this.read = read;
    }
    CompileQueryMetadata.fromJson = function(data) {
      return new CompileQueryMetadata({
        selectors: _arrayFromJson(data['selectors'], CompileTokenMetadata.fromJson),
        descendants: data['descendants'],
        first: data['first'],
        propertyName: data['propertyName'],
        read: _objFromJson(data['read'], CompileTokenMetadata.fromJson)
      });
    };
    CompileQueryMetadata.prototype.toJson = function() {
      return {
        'selectors': _arrayToJson(this.selectors),
        'descendants': this.descendants,
        'first': this.first,
        'propertyName': this.propertyName,
        'read': _objToJson(this.read)
      };
    };
    return CompileQueryMetadata;
  }());
  exports.CompileQueryMetadata = CompileQueryMetadata;
  var CompileTemplateMetadata = (function() {
    function CompileTemplateMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          encapsulation = _b.encapsulation,
          template = _b.template,
          templateUrl = _b.templateUrl,
          styles = _b.styles,
          styleUrls = _b.styleUrls,
          ngContentSelectors = _b.ngContentSelectors;
      this.encapsulation = lang_1.isPresent(encapsulation) ? encapsulation : core_1.ViewEncapsulation.Emulated;
      this.template = template;
      this.templateUrl = templateUrl;
      this.styles = lang_1.isPresent(styles) ? styles : [];
      this.styleUrls = lang_1.isPresent(styleUrls) ? styleUrls : [];
      this.ngContentSelectors = lang_1.isPresent(ngContentSelectors) ? ngContentSelectors : [];
    }
    CompileTemplateMetadata.fromJson = function(data) {
      return new CompileTemplateMetadata({
        encapsulation: lang_1.isPresent(data['encapsulation']) ? core_private_1.VIEW_ENCAPSULATION_VALUES[data['encapsulation']] : data['encapsulation'],
        template: data['template'],
        templateUrl: data['templateUrl'],
        styles: data['styles'],
        styleUrls: data['styleUrls'],
        ngContentSelectors: data['ngContentSelectors']
      });
    };
    CompileTemplateMetadata.prototype.toJson = function() {
      return {
        'encapsulation': lang_1.isPresent(this.encapsulation) ? lang_1.serializeEnum(this.encapsulation) : this.encapsulation,
        'template': this.template,
        'templateUrl': this.templateUrl,
        'styles': this.styles,
        'styleUrls': this.styleUrls,
        'ngContentSelectors': this.ngContentSelectors
      };
    };
    return CompileTemplateMetadata;
  }());
  exports.CompileTemplateMetadata = CompileTemplateMetadata;
  var CompileDirectiveMetadata = (function() {
    function CompileDirectiveMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          type = _b.type,
          isComponent = _b.isComponent,
          selector = _b.selector,
          exportAs = _b.exportAs,
          changeDetection = _b.changeDetection,
          inputs = _b.inputs,
          outputs = _b.outputs,
          hostListeners = _b.hostListeners,
          hostProperties = _b.hostProperties,
          hostAttributes = _b.hostAttributes,
          lifecycleHooks = _b.lifecycleHooks,
          providers = _b.providers,
          viewProviders = _b.viewProviders,
          queries = _b.queries,
          viewQueries = _b.viewQueries,
          template = _b.template;
      this.type = type;
      this.isComponent = isComponent;
      this.selector = selector;
      this.exportAs = exportAs;
      this.changeDetection = changeDetection;
      this.inputs = inputs;
      this.outputs = outputs;
      this.hostListeners = hostListeners;
      this.hostProperties = hostProperties;
      this.hostAttributes = hostAttributes;
      this.lifecycleHooks = _normalizeArray(lifecycleHooks);
      this.providers = _normalizeArray(providers);
      this.viewProviders = _normalizeArray(viewProviders);
      this.queries = _normalizeArray(queries);
      this.viewQueries = _normalizeArray(viewQueries);
      this.template = template;
    }
    CompileDirectiveMetadata.create = function(_a) {
      var _b = _a === void 0 ? {} : _a,
          type = _b.type,
          isComponent = _b.isComponent,
          selector = _b.selector,
          exportAs = _b.exportAs,
          changeDetection = _b.changeDetection,
          inputs = _b.inputs,
          outputs = _b.outputs,
          host = _b.host,
          lifecycleHooks = _b.lifecycleHooks,
          providers = _b.providers,
          viewProviders = _b.viewProviders,
          queries = _b.queries,
          viewQueries = _b.viewQueries,
          template = _b.template;
      var hostListeners = {};
      var hostProperties = {};
      var hostAttributes = {};
      if (lang_1.isPresent(host)) {
        collection_1.StringMapWrapper.forEach(host, function(value, key) {
          var matches = lang_1.RegExpWrapper.firstMatch(HOST_REG_EXP, key);
          if (lang_1.isBlank(matches)) {
            hostAttributes[key] = value;
          } else if (lang_1.isPresent(matches[1])) {
            hostProperties[matches[1]] = value;
          } else if (lang_1.isPresent(matches[2])) {
            hostListeners[matches[2]] = value;
          }
        });
      }
      var inputsMap = {};
      if (lang_1.isPresent(inputs)) {
        inputs.forEach(function(bindConfig) {
          var parts = util_1.splitAtColon(bindConfig, [bindConfig, bindConfig]);
          inputsMap[parts[0]] = parts[1];
        });
      }
      var outputsMap = {};
      if (lang_1.isPresent(outputs)) {
        outputs.forEach(function(bindConfig) {
          var parts = util_1.splitAtColon(bindConfig, [bindConfig, bindConfig]);
          outputsMap[parts[0]] = parts[1];
        });
      }
      return new CompileDirectiveMetadata({
        type: type,
        isComponent: lang_1.normalizeBool(isComponent),
        selector: selector,
        exportAs: exportAs,
        changeDetection: changeDetection,
        inputs: inputsMap,
        outputs: outputsMap,
        hostListeners: hostListeners,
        hostProperties: hostProperties,
        hostAttributes: hostAttributes,
        lifecycleHooks: lang_1.isPresent(lifecycleHooks) ? lifecycleHooks : [],
        providers: providers,
        viewProviders: viewProviders,
        queries: queries,
        viewQueries: viewQueries,
        template: template
      });
    };
    Object.defineProperty(CompileDirectiveMetadata.prototype, "identifier", {
      get: function() {
        return this.type;
      },
      enumerable: true,
      configurable: true
    });
    CompileDirectiveMetadata.fromJson = function(data) {
      return new CompileDirectiveMetadata({
        isComponent: data['isComponent'],
        selector: data['selector'],
        exportAs: data['exportAs'],
        type: lang_1.isPresent(data['type']) ? CompileTypeMetadata.fromJson(data['type']) : data['type'],
        changeDetection: lang_1.isPresent(data['changeDetection']) ? core_private_1.CHANGE_DETECTION_STRATEGY_VALUES[data['changeDetection']] : data['changeDetection'],
        inputs: data['inputs'],
        outputs: data['outputs'],
        hostListeners: data['hostListeners'],
        hostProperties: data['hostProperties'],
        hostAttributes: data['hostAttributes'],
        lifecycleHooks: data['lifecycleHooks'].map(function(hookValue) {
          return core_private_1.LIFECYCLE_HOOKS_VALUES[hookValue];
        }),
        template: lang_1.isPresent(data['template']) ? CompileTemplateMetadata.fromJson(data['template']) : data['template'],
        providers: _arrayFromJson(data['providers'], metadataFromJson),
        viewProviders: _arrayFromJson(data['viewProviders'], metadataFromJson),
        queries: _arrayFromJson(data['queries'], CompileQueryMetadata.fromJson),
        viewQueries: _arrayFromJson(data['viewQueries'], CompileQueryMetadata.fromJson)
      });
    };
    CompileDirectiveMetadata.prototype.toJson = function() {
      return {
        'class': 'Directive',
        'isComponent': this.isComponent,
        'selector': this.selector,
        'exportAs': this.exportAs,
        'type': lang_1.isPresent(this.type) ? this.type.toJson() : this.type,
        'changeDetection': lang_1.isPresent(this.changeDetection) ? lang_1.serializeEnum(this.changeDetection) : this.changeDetection,
        'inputs': this.inputs,
        'outputs': this.outputs,
        'hostListeners': this.hostListeners,
        'hostProperties': this.hostProperties,
        'hostAttributes': this.hostAttributes,
        'lifecycleHooks': this.lifecycleHooks.map(function(hook) {
          return lang_1.serializeEnum(hook);
        }),
        'template': lang_1.isPresent(this.template) ? this.template.toJson() : this.template,
        'providers': _arrayToJson(this.providers),
        'viewProviders': _arrayToJson(this.viewProviders),
        'queries': _arrayToJson(this.queries),
        'viewQueries': _arrayToJson(this.viewQueries)
      };
    };
    return CompileDirectiveMetadata;
  }());
  exports.CompileDirectiveMetadata = CompileDirectiveMetadata;
  function createHostComponentMeta(componentType, componentSelector) {
    var template = selector_1.CssSelector.parse(componentSelector)[0].getMatchingElementTemplate();
    return CompileDirectiveMetadata.create({
      type: new CompileTypeMetadata({
        runtime: Object,
        name: componentType.name + "_Host",
        moduleUrl: componentType.moduleUrl,
        isHost: true
      }),
      template: new CompileTemplateMetadata({
        template: template,
        templateUrl: '',
        styles: [],
        styleUrls: [],
        ngContentSelectors: []
      }),
      changeDetection: core_1.ChangeDetectionStrategy.Default,
      inputs: [],
      outputs: [],
      host: {},
      lifecycleHooks: [],
      isComponent: true,
      selector: '*',
      providers: [],
      viewProviders: [],
      queries: [],
      viewQueries: []
    });
  }
  exports.createHostComponentMeta = createHostComponentMeta;
  var CompilePipeMetadata = (function() {
    function CompilePipeMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          type = _b.type,
          name = _b.name,
          pure = _b.pure,
          lifecycleHooks = _b.lifecycleHooks;
      this.type = type;
      this.name = name;
      this.pure = lang_1.normalizeBool(pure);
      this.lifecycleHooks = _normalizeArray(lifecycleHooks);
    }
    Object.defineProperty(CompilePipeMetadata.prototype, "identifier", {
      get: function() {
        return this.type;
      },
      enumerable: true,
      configurable: true
    });
    CompilePipeMetadata.fromJson = function(data) {
      return new CompilePipeMetadata({
        type: lang_1.isPresent(data['type']) ? CompileTypeMetadata.fromJson(data['type']) : data['type'],
        name: data['name'],
        pure: data['pure']
      });
    };
    CompilePipeMetadata.prototype.toJson = function() {
      return {
        'class': 'Pipe',
        'type': lang_1.isPresent(this.type) ? this.type.toJson() : null,
        'name': this.name,
        'pure': this.pure
      };
    };
    return CompilePipeMetadata;
  }());
  exports.CompilePipeMetadata = CompilePipeMetadata;
  var _COMPILE_METADATA_FROM_JSON = {
    'Directive': CompileDirectiveMetadata.fromJson,
    'Pipe': CompilePipeMetadata.fromJson,
    'Type': CompileTypeMetadata.fromJson,
    'Provider': CompileProviderMetadata.fromJson,
    'Identifier': CompileIdentifierMetadata.fromJson,
    'Factory': CompileFactoryMetadata.fromJson
  };
  function _arrayFromJson(obj, fn) {
    return lang_1.isBlank(obj) ? null : obj.map(function(o) {
      return _objFromJson(o, fn);
    });
  }
  function _arrayToJson(obj) {
    return lang_1.isBlank(obj) ? null : obj.map(_objToJson);
  }
  function _objFromJson(obj, fn) {
    if (lang_1.isArray(obj))
      return _arrayFromJson(obj, fn);
    if (lang_1.isString(obj) || lang_1.isBlank(obj) || lang_1.isBoolean(obj) || lang_1.isNumber(obj))
      return obj;
    return fn(obj);
  }
  function _objToJson(obj) {
    if (lang_1.isArray(obj))
      return _arrayToJson(obj);
    if (lang_1.isString(obj) || lang_1.isBlank(obj) || lang_1.isBoolean(obj) || lang_1.isNumber(obj))
      return obj;
    return obj.toJson();
  }
  function _normalizeArray(obj) {
    return lang_1.isPresent(obj) ? obj : [];
  }
  return module.exports;
});

$__System.registerDynamic("10", ["13", "e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  exports.MODULE_SUFFIX = lang_1.IS_DART ? '.dart' : '';
  var CAMEL_CASE_REGEXP = /([A-Z])/g;
  var DASH_CASE_REGEXP = /-([a-z])/g;
  function camelCaseToDashCase(input) {
    return lang_1.StringWrapper.replaceAllMapped(input, CAMEL_CASE_REGEXP, function(m) {
      return '-' + m[1].toLowerCase();
    });
  }
  exports.camelCaseToDashCase = camelCaseToDashCase;
  function dashCaseToCamelCase(input) {
    return lang_1.StringWrapper.replaceAllMapped(input, DASH_CASE_REGEXP, function(m) {
      return m[1].toUpperCase();
    });
  }
  exports.dashCaseToCamelCase = dashCaseToCamelCase;
  function splitAtColon(input, defaultValues) {
    var parts = lang_1.StringWrapper.split(input.trim(), /\s*:\s*/g);
    if (parts.length > 1) {
      return parts;
    } else {
      return defaultValues;
    }
  }
  exports.splitAtColon = splitAtColon;
  function sanitizeIdentifier(name) {
    return lang_1.StringWrapper.replaceAll(name, /\W/g, '_');
  }
  exports.sanitizeIdentifier = sanitizeIdentifier;
  function visitValue(value, visitor, context) {
    if (lang_1.isArray(value)) {
      return visitor.visitArray(value, context);
    } else if (lang_1.isStrictStringMap(value)) {
      return visitor.visitStringMap(value, context);
    } else if (lang_1.isBlank(value) || lang_1.isPrimitive(value)) {
      return visitor.visitPrimitive(value, context);
    } else {
      return visitor.visitOther(value, context);
    }
  }
  exports.visitValue = visitValue;
  var ValueTransformer = (function() {
    function ValueTransformer() {}
    ValueTransformer.prototype.visitArray = function(arr, context) {
      var _this = this;
      return arr.map(function(value) {
        return visitValue(value, _this, context);
      });
    };
    ValueTransformer.prototype.visitStringMap = function(map, context) {
      var _this = this;
      var result = {};
      collection_1.StringMapWrapper.forEach(map, function(value, key) {
        result[key] = visitValue(value, _this, context);
      });
      return result;
    };
    ValueTransformer.prototype.visitPrimitive = function(value, context) {
      return value;
    };
    ValueTransformer.prototype.visitOther = function(value, context) {
      return value;
    };
    return ValueTransformer;
  }());
  exports.ValueTransformer = ValueTransformer;
  function assetUrl(pkg, path, type) {
    if (path === void 0) {
      path = null;
    }
    if (type === void 0) {
      type = 'src';
    }
    if (lang_1.IS_DART) {
      if (path == null) {
        return "asset:angular2/" + pkg + "/" + pkg + ".dart";
      } else {
        return "asset:angular2/lib/" + pkg + "/src/" + path + ".dart";
      }
    } else {
      if (path == null) {
        return "asset:@angular/lib/" + pkg + "/index";
      } else {
        return "asset:@angular/lib/" + pkg + "/src/" + path;
      }
    }
  }
  exports.assetUrl = assetUrl;
  return module.exports;
});

$__System.registerDynamic("15", ["11", "18", "c", "10"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var core_private_2 = $__require('18');
  var compile_metadata_1 = $__require('c');
  var util_1 = $__require('10');
  var APP_VIEW_MODULE_URL = util_1.assetUrl('core', 'linker/view');
  var VIEW_UTILS_MODULE_URL = util_1.assetUrl('core', 'linker/view_utils');
  var CD_MODULE_URL = util_1.assetUrl('core', 'change_detection/change_detection');
  var impViewUtils = core_private_2.ViewUtils;
  var impAppView = core_private_2.AppView;
  var impDebugAppView = core_private_2.DebugAppView;
  var impDebugContext = core_private_2.DebugContext;
  var impAppElement = core_private_2.AppElement;
  var impElementRef = core_1.ElementRef;
  var impViewContainerRef = core_1.ViewContainerRef;
  var impChangeDetectorRef = core_1.ChangeDetectorRef;
  var impRenderComponentType = core_1.RenderComponentType;
  var impQueryList = core_1.QueryList;
  var impTemplateRef = core_1.TemplateRef;
  var impTemplateRef_ = core_private_2.TemplateRef_;
  var impValueUnwrapper = core_private_2.ValueUnwrapper;
  var impInjector = core_1.Injector;
  var impViewEncapsulation = core_1.ViewEncapsulation;
  var impViewType = core_private_2.ViewType;
  var impChangeDetectionStrategy = core_1.ChangeDetectionStrategy;
  var impStaticNodeDebugInfo = core_private_2.StaticNodeDebugInfo;
  var impRenderer = core_1.Renderer;
  var impSimpleChange = core_1.SimpleChange;
  var impUninitialized = core_private_2.uninitialized;
  var impChangeDetectorState = core_private_2.ChangeDetectorState;
  var impFlattenNestedViewRenderNodes = core_private_2.flattenNestedViewRenderNodes;
  var impDevModeEqual = core_private_2.devModeEqual;
  var impInterpolate = core_private_2.interpolate;
  var impCheckBinding = core_private_2.checkBinding;
  var impCastByValue = core_private_2.castByValue;
  var impEMPTY_ARRAY = core_private_2.EMPTY_ARRAY;
  var impEMPTY_MAP = core_private_2.EMPTY_MAP;
  var Identifiers = (function() {
    function Identifiers() {}
    Identifiers.ViewUtils = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ViewUtils',
      moduleUrl: util_1.assetUrl('core', 'linker/view_utils'),
      runtime: impViewUtils
    });
    Identifiers.AppView = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'AppView',
      moduleUrl: APP_VIEW_MODULE_URL,
      runtime: impAppView
    });
    Identifiers.DebugAppView = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'DebugAppView',
      moduleUrl: APP_VIEW_MODULE_URL,
      runtime: impDebugAppView
    });
    Identifiers.AppElement = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'AppElement',
      moduleUrl: util_1.assetUrl('core', 'linker/element'),
      runtime: impAppElement
    });
    Identifiers.ElementRef = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ElementRef',
      moduleUrl: util_1.assetUrl('core', 'linker/element_ref'),
      runtime: impElementRef
    });
    Identifiers.ViewContainerRef = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ViewContainerRef',
      moduleUrl: util_1.assetUrl('core', 'linker/view_container_ref'),
      runtime: impViewContainerRef
    });
    Identifiers.ChangeDetectorRef = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ChangeDetectorRef',
      moduleUrl: util_1.assetUrl('core', 'change_detection/change_detector_ref'),
      runtime: impChangeDetectorRef
    });
    Identifiers.RenderComponentType = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'RenderComponentType',
      moduleUrl: util_1.assetUrl('core', 'render/api'),
      runtime: impRenderComponentType
    });
    Identifiers.QueryList = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'QueryList',
      moduleUrl: util_1.assetUrl('core', 'linker/query_list'),
      runtime: impQueryList
    });
    Identifiers.TemplateRef = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'TemplateRef',
      moduleUrl: util_1.assetUrl('core', 'linker/template_ref'),
      runtime: impTemplateRef
    });
    Identifiers.TemplateRef_ = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'TemplateRef_',
      moduleUrl: util_1.assetUrl('core', 'linker/template_ref'),
      runtime: impTemplateRef_
    });
    Identifiers.ValueUnwrapper = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ValueUnwrapper',
      moduleUrl: CD_MODULE_URL,
      runtime: impValueUnwrapper
    });
    Identifiers.Injector = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'Injector',
      moduleUrl: util_1.assetUrl('core', 'di/injector'),
      runtime: impInjector
    });
    Identifiers.ViewEncapsulation = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ViewEncapsulation',
      moduleUrl: util_1.assetUrl('core', 'metadata/view'),
      runtime: impViewEncapsulation
    });
    Identifiers.ViewType = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ViewType',
      moduleUrl: util_1.assetUrl('core', 'linker/view_type'),
      runtime: impViewType
    });
    Identifiers.ChangeDetectionStrategy = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ChangeDetectionStrategy',
      moduleUrl: CD_MODULE_URL,
      runtime: impChangeDetectionStrategy
    });
    Identifiers.StaticNodeDebugInfo = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'StaticNodeDebugInfo',
      moduleUrl: util_1.assetUrl('core', 'linker/debug_context'),
      runtime: impStaticNodeDebugInfo
    });
    Identifiers.DebugContext = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'DebugContext',
      moduleUrl: util_1.assetUrl('core', 'linker/debug_context'),
      runtime: impDebugContext
    });
    Identifiers.Renderer = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'Renderer',
      moduleUrl: util_1.assetUrl('core', 'render/api'),
      runtime: impRenderer
    });
    Identifiers.SimpleChange = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'SimpleChange',
      moduleUrl: CD_MODULE_URL,
      runtime: impSimpleChange
    });
    Identifiers.uninitialized = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'uninitialized',
      moduleUrl: CD_MODULE_URL,
      runtime: impUninitialized
    });
    Identifiers.ChangeDetectorState = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'ChangeDetectorState',
      moduleUrl: CD_MODULE_URL,
      runtime: impChangeDetectorState
    });
    Identifiers.checkBinding = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'checkBinding',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impCheckBinding
    });
    Identifiers.flattenNestedViewRenderNodes = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'flattenNestedViewRenderNodes',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impFlattenNestedViewRenderNodes
    });
    Identifiers.devModeEqual = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'devModeEqual',
      moduleUrl: CD_MODULE_URL,
      runtime: impDevModeEqual
    });
    Identifiers.interpolate = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'interpolate',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impInterpolate
    });
    Identifiers.castByValue = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'castByValue',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impCastByValue
    });
    Identifiers.EMPTY_ARRAY = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'EMPTY_ARRAY',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impEMPTY_ARRAY
    });
    Identifiers.EMPTY_MAP = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'EMPTY_MAP',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: impEMPTY_MAP
    });
    Identifiers.pureProxies = [null, new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy1',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy1
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy2',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy2
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy3',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy3
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy4',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy4
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy5',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy5
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy6',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy6
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy7',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy7
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy8',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy8
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy9',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy9
    }), new compile_metadata_1.CompileIdentifierMetadata({
      name: 'pureProxy10',
      moduleUrl: VIEW_UTILS_MODULE_URL,
      runtime: core_private_2.pureProxy10
    })];
    Identifiers.SecurityContext = new compile_metadata_1.CompileIdentifierMetadata({
      name: 'SecurityContext',
      moduleUrl: util_1.assetUrl('core', 'security'),
      runtime: core_private_1.SecurityContext
    });
    return Identifiers;
  }());
  exports.Identifiers = Identifiers;
  function identifierToken(identifier) {
    return new compile_metadata_1.CompileTokenMetadata({identifier: identifier});
  }
  exports.identifierToken = identifierToken;
  return module.exports;
});

$__System.registerDynamic("30", ["13", "d", "15"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var identifiers_1 = $__require('15');
  var CompilerConfig = (function() {
    function CompilerConfig(genDebugInfo, logBindingUpdate, useJit, renderTypes) {
      if (renderTypes === void 0) {
        renderTypes = null;
      }
      this.genDebugInfo = genDebugInfo;
      this.logBindingUpdate = logBindingUpdate;
      this.useJit = useJit;
      if (lang_1.isBlank(renderTypes)) {
        renderTypes = new DefaultRenderTypes();
      }
      this.renderTypes = renderTypes;
    }
    return CompilerConfig;
  }());
  exports.CompilerConfig = CompilerConfig;
  var RenderTypes = (function() {
    function RenderTypes() {}
    Object.defineProperty(RenderTypes.prototype, "renderer", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderTypes.prototype, "renderText", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderTypes.prototype, "renderElement", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderTypes.prototype, "renderComment", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderTypes.prototype, "renderNode", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderTypes.prototype, "renderEvent", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return RenderTypes;
  }());
  exports.RenderTypes = RenderTypes;
  var DefaultRenderTypes = (function() {
    function DefaultRenderTypes() {
      this.renderer = identifiers_1.Identifiers.Renderer;
      this.renderText = null;
      this.renderElement = null;
      this.renderComment = null;
      this.renderNode = null;
      this.renderEvent = null;
    }
    return DefaultRenderTypes;
  }());
  exports.DefaultRenderTypes = DefaultRenderTypes;
  return module.exports;
});

$__System.registerDynamic("2d", ["11", "45", "41", "46", "4c", "30"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var compile_element_1 = $__require('45');
  var compile_view_1 = $__require('41');
  var view_builder_1 = $__require('46');
  var view_binder_1 = $__require('4c');
  var config_1 = $__require('30');
  var ViewCompileResult = (function() {
    function ViewCompileResult(statements, viewFactoryVar, dependencies) {
      this.statements = statements;
      this.viewFactoryVar = viewFactoryVar;
      this.dependencies = dependencies;
    }
    return ViewCompileResult;
  }());
  exports.ViewCompileResult = ViewCompileResult;
  var ViewCompiler = (function() {
    function ViewCompiler(_genConfig) {
      this._genConfig = _genConfig;
    }
    ViewCompiler.prototype.compileComponent = function(component, template, styles, pipes) {
      var statements = [];
      var dependencies = [];
      var view = new compile_view_1.CompileView(component, this._genConfig, pipes, styles, 0, compile_element_1.CompileElement.createNull(), []);
      view_builder_1.buildView(view, template, dependencies);
      view_binder_1.bindView(view, template);
      view_builder_1.finishView(view, statements);
      return new ViewCompileResult(statements, view.viewFactory.name, dependencies);
    };
    ViewCompiler.decorators = [{type: core_1.Injectable}];
    ViewCompiler.ctorParameters = [{type: config_1.CompilerConfig}];
    return ViewCompiler;
  }());
  exports.ViewCompiler = ViewCompiler;
  return module.exports;
});

$__System.registerDynamic("18", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  exports.isDefaultChangeDetectionStrategy = core_1.__core_private__.isDefaultChangeDetectionStrategy;
  exports.ChangeDetectorState = core_1.__core_private__.ChangeDetectorState;
  exports.CHANGE_DETECTION_STRATEGY_VALUES = core_1.__core_private__.CHANGE_DETECTION_STRATEGY_VALUES;
  exports.constructDependencies = core_1.__core_private__.constructDependencies;
  exports.LifecycleHooks = core_1.__core_private__.LifecycleHooks;
  exports.LIFECYCLE_HOOKS_VALUES = core_1.__core_private__.LIFECYCLE_HOOKS_VALUES;
  exports.ReflectorReader = core_1.__core_private__.ReflectorReader;
  exports.ReflectorComponentResolver = core_1.__core_private__.ReflectorComponentResolver;
  exports.AppElement = core_1.__core_private__.AppElement;
  exports.AppView = core_1.__core_private__.AppView;
  exports.DebugAppView = core_1.__core_private__.DebugAppView;
  exports.ViewType = core_1.__core_private__.ViewType;
  exports.MAX_INTERPOLATION_VALUES = core_1.__core_private__.MAX_INTERPOLATION_VALUES;
  exports.checkBinding = core_1.__core_private__.checkBinding;
  exports.flattenNestedViewRenderNodes = core_1.__core_private__.flattenNestedViewRenderNodes;
  exports.interpolate = core_1.__core_private__.interpolate;
  exports.ViewUtils = core_1.__core_private__.ViewUtils;
  exports.VIEW_ENCAPSULATION_VALUES = core_1.__core_private__.VIEW_ENCAPSULATION_VALUES;
  exports.DebugContext = core_1.__core_private__.DebugContext;
  exports.StaticNodeDebugInfo = core_1.__core_private__.StaticNodeDebugInfo;
  exports.devModeEqual = core_1.__core_private__.devModeEqual;
  exports.uninitialized = core_1.__core_private__.uninitialized;
  exports.ValueUnwrapper = core_1.__core_private__.ValueUnwrapper;
  exports.TemplateRef_ = core_1.__core_private__.TemplateRef_;
  exports.RenderDebugInfo = core_1.__core_private__.RenderDebugInfo;
  exports.SecurityContext = core_1.__core_private__.SecurityContext;
  exports.SanitizationService = core_1.__core_private__.SanitizationService;
  exports.createProvider = core_1.__core_private__.createProvider;
  exports.isProviderLiteral = core_1.__core_private__.isProviderLiteral;
  exports.EMPTY_ARRAY = core_1.__core_private__.EMPTY_ARRAY;
  exports.EMPTY_MAP = core_1.__core_private__.EMPTY_MAP;
  exports.pureProxy1 = core_1.__core_private__.pureProxy1;
  exports.pureProxy2 = core_1.__core_private__.pureProxy2;
  exports.pureProxy3 = core_1.__core_private__.pureProxy3;
  exports.pureProxy4 = core_1.__core_private__.pureProxy4;
  exports.pureProxy5 = core_1.__core_private__.pureProxy5;
  exports.pureProxy6 = core_1.__core_private__.pureProxy6;
  exports.pureProxy7 = core_1.__core_private__.pureProxy7;
  exports.pureProxy8 = core_1.__core_private__.pureProxy8;
  exports.pureProxy9 = core_1.__core_private__.pureProxy9;
  exports.pureProxy10 = core_1.__core_private__.pureProxy10;
  exports.castByValue = core_1.__core_private__.castByValue;
  exports.Console = core_1.__core_private__.Console;
  return module.exports;
});

$__System.registerDynamic("1e", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ElementSchemaRegistry = (function() {
    function ElementSchemaRegistry() {}
    return ElementSchemaRegistry;
  }());
  exports.ElementSchemaRegistry = ElementSchemaRegistry;
  return module.exports;
});

$__System.registerDynamic("4d", ["11", "18", "13", "e", "1e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var core_private_1 = $__require('18');
  var lang_1 = $__require('13');
  var collection_1 = $__require('e');
  var element_schema_registry_1 = $__require('1e');
  var EVENT = 'event';
  var BOOLEAN = 'boolean';
  var NUMBER = 'number';
  var STRING = 'string';
  var OBJECT = 'object';
  var SCHEMA = (['*|%classList,className,id,innerHTML,*beforecopy,*beforecut,*beforepaste,*copy,*cut,*paste,*search,*selectstart,*webkitfullscreenchange,*webkitfullscreenerror,*wheel,outerHTML,#scrollLeft,#scrollTop', '^*|accessKey,contentEditable,dir,!draggable,!hidden,innerText,lang,*abort,*autocomplete,*autocompleteerror,*beforecopy,*beforecut,*beforepaste,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*message,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*mozfullscreenchange,*mozfullscreenerror,*mozpointerlockchange,*mozpointerlockerror,*paste,*pause,*play,*playing,*progress,*ratechange,*reset,*resize,*scroll,*search,*seeked,*seeking,*select,*selectstart,*show,*stalled,*submit,*suspend,*timeupdate,*toggle,*volumechange,*waiting,*webglcontextcreationerror,*webglcontextlost,*webglcontextrestored,*webkitfullscreenchange,*webkitfullscreenerror,*wheel,outerText,!spellcheck,%style,#tabIndex,title,!translate', 'media|!autoplay,!controls,%crossOrigin,#currentTime,!defaultMuted,#defaultPlaybackRate,!disableRemotePlayback,!loop,!muted,*encrypted,#playbackRate,preload,src,#volume', '@svg:^*|*abort,*autocomplete,*autocompleteerror,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*cuechange,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*pause,*play,*playing,*progress,*ratechange,*reset,*resize,*scroll,*seeked,*seeking,*select,*show,*stalled,*submit,*suspend,*timeupdate,*toggle,*volumechange,*waiting,%style,#tabIndex', '@svg:graphics^@svg:|', '@svg:animation^@svg:|*begin,*end,*repeat', '@svg:geometry^@svg:|', '@svg:componentTransferFunction^@svg:|', '@svg:gradient^@svg:|', '@svg:textContent^@svg:graphics|', '@svg:textPositioning^@svg:textContent|', 'a|charset,coords,download,hash,host,hostname,href,hreflang,name,password,pathname,ping,port,protocol,rel,rev,search,shape,target,text,type,username', 'area|alt,coords,hash,host,hostname,href,!noHref,password,pathname,ping,port,protocol,search,shape,target,username', 'audio^media|', 'br|clear', 'base|href,target', 'body|aLink,background,bgColor,link,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,text,vLink', 'button|!autofocus,!disabled,formAction,formEnctype,formMethod,!formNoValidate,formTarget,name,type,value', 'canvas|#height,#width', 'content|select', 'dl|!compact', 'datalist|', 'details|!open', 'dialog|!open,returnValue', 'dir|!compact', 'div|align', 'embed|align,height,name,src,type,width', 'fieldset|!disabled,name', 'font|color,face,size', 'form|acceptCharset,action,autocomplete,encoding,enctype,method,name,!noValidate,target', 'frame|frameBorder,longDesc,marginHeight,marginWidth,name,!noResize,scrolling,src', 'frameset|cols,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,rows', 'hr|align,color,!noShade,size,width', 'head|', 'h1,h2,h3,h4,h5,h6|align', 'html|version', 'iframe|align,!allowFullscreen,frameBorder,height,longDesc,marginHeight,marginWidth,name,%sandbox,scrolling,src,srcdoc,width', 'img|align,alt,border,%crossOrigin,#height,#hspace,!isMap,longDesc,lowsrc,name,sizes,src,srcset,useMap,#vspace,#width', 'input|accept,align,alt,autocapitalize,autocomplete,!autofocus,!checked,!defaultChecked,defaultValue,dirName,!disabled,%files,formAction,formEnctype,formMethod,!formNoValidate,formTarget,#height,!incremental,!indeterminate,max,#maxLength,min,#minLength,!multiple,name,pattern,placeholder,!readOnly,!required,selectionDirection,#selectionEnd,#selectionStart,#size,src,step,type,useMap,value,%valueAsDate,#valueAsNumber,#width', 'keygen|!autofocus,challenge,!disabled,keytype,name', 'li|type,#value', 'label|htmlFor', 'legend|align', 'link|as,charset,%crossOrigin,!disabled,href,hreflang,integrity,media,rel,%relList,rev,%sizes,target,type', 'map|name', 'marquee|behavior,bgColor,direction,height,#hspace,#loop,#scrollAmount,#scrollDelay,!trueSpeed,#vspace,width', 'menu|!compact', 'meta|content,httpEquiv,name,scheme', 'meter|#high,#low,#max,#min,#optimum,#value', 'ins,del|cite,dateTime', 'ol|!compact,!reversed,#start,type', 'object|align,archive,border,code,codeBase,codeType,data,!declare,height,#hspace,name,standby,type,useMap,#vspace,width', 'optgroup|!disabled,label', 'option|!defaultSelected,!disabled,label,!selected,text,value', 'output|defaultValue,%htmlFor,name,value', 'p|align', 'param|name,type,value,valueType', 'picture|', 'pre|#width', 'progress|#max,#value', 'q,blockquote,cite|', 'script|!async,charset,%crossOrigin,!defer,event,htmlFor,integrity,src,text,type', 'select|!autofocus,!disabled,#length,!multiple,name,!required,#selectedIndex,#size,value', 'shadow|', 'source|media,sizes,src,srcset,type', 'span|', 'style|!disabled,media,type', 'caption|align', 'th,td|abbr,align,axis,bgColor,ch,chOff,#colSpan,headers,height,!noWrap,#rowSpan,scope,vAlign,width', 'col,colgroup|align,ch,chOff,#span,vAlign,width', 'table|align,bgColor,border,%caption,cellPadding,cellSpacing,frame,rules,summary,%tFoot,%tHead,width', 'tr|align,bgColor,ch,chOff,vAlign', 'tfoot,thead,tbody|align,ch,chOff,vAlign', 'template|', 'textarea|autocapitalize,!autofocus,#cols,defaultValue,dirName,!disabled,#maxLength,#minLength,name,placeholder,!readOnly,!required,#rows,selectionDirection,#selectionEnd,#selectionStart,value,wrap', 'title|text', 'track|!default,kind,label,src,srclang', 'ul|!compact,type', 'unknown|', 'video^media|#height,poster,#width', '@svg:a^@svg:graphics|', '@svg:animate^@svg:animation|', '@svg:animateMotion^@svg:animation|', '@svg:animateTransform^@svg:animation|', '@svg:circle^@svg:geometry|', '@svg:clipPath^@svg:graphics|', '@svg:cursor^@svg:|', '@svg:defs^@svg:graphics|', '@svg:desc^@svg:|', '@svg:discard^@svg:|', '@svg:ellipse^@svg:geometry|', '@svg:feBlend^@svg:|', '@svg:feColorMatrix^@svg:|', '@svg:feComponentTransfer^@svg:|', '@svg:feComposite^@svg:|', '@svg:feConvolveMatrix^@svg:|', '@svg:feDiffuseLighting^@svg:|', '@svg:feDisplacementMap^@svg:|', '@svg:feDistantLight^@svg:|', '@svg:feDropShadow^@svg:|', '@svg:feFlood^@svg:|', '@svg:feFuncA^@svg:componentTransferFunction|', '@svg:feFuncB^@svg:componentTransferFunction|', '@svg:feFuncG^@svg:componentTransferFunction|', '@svg:feFuncR^@svg:componentTransferFunction|', '@svg:feGaussianBlur^@svg:|', '@svg:feImage^@svg:|', '@svg:feMerge^@svg:|', '@svg:feMergeNode^@svg:|', '@svg:feMorphology^@svg:|', '@svg:feOffset^@svg:|', '@svg:fePointLight^@svg:|', '@svg:feSpecularLighting^@svg:|', '@svg:feSpotLight^@svg:|', '@svg:feTile^@svg:|', '@svg:feTurbulence^@svg:|', '@svg:filter^@svg:|', '@svg:foreignObject^@svg:graphics|', '@svg:g^@svg:graphics|', '@svg:image^@svg:graphics|', '@svg:line^@svg:geometry|', '@svg:linearGradient^@svg:gradient|', '@svg:mpath^@svg:|', '@svg:marker^@svg:|', '@svg:mask^@svg:|', '@svg:metadata^@svg:|', '@svg:path^@svg:geometry|', '@svg:pattern^@svg:|', '@svg:polygon^@svg:geometry|', '@svg:polyline^@svg:geometry|', '@svg:radialGradient^@svg:gradient|', '@svg:rect^@svg:geometry|', '@svg:svg^@svg:graphics|#currentScale,#zoomAndPan', '@svg:script^@svg:|type', '@svg:set^@svg:animation|', '@svg:stop^@svg:|', '@svg:style^@svg:|!disabled,media,title,type', '@svg:switch^@svg:graphics|', '@svg:symbol^@svg:|', '@svg:tspan^@svg:textPositioning|', '@svg:text^@svg:textPositioning|', '@svg:textPath^@svg:textContent|', '@svg:title^@svg:|', '@svg:use^@svg:graphics|', '@svg:view^@svg:|#zoomAndPan']);
  var attrToPropMap = {
    'class': 'className',
    'innerHtml': 'innerHTML',
    'readonly': 'readOnly',
    'tabindex': 'tabIndex'
  };
  var DomElementSchemaRegistry = (function(_super) {
    __extends(DomElementSchemaRegistry, _super);
    function DomElementSchemaRegistry() {
      var _this = this;
      _super.call(this);
      this.schema = {};
      SCHEMA.forEach(function(encodedType) {
        var parts = encodedType.split('|');
        var properties = parts[1].split(',');
        var typeParts = (parts[0] + '^').split('^');
        var typeName = typeParts[0];
        var type = {};
        typeName.split(',').forEach(function(tag) {
          return _this.schema[tag] = type;
        });
        var superType = _this.schema[typeParts[1]];
        if (lang_1.isPresent(superType)) {
          collection_1.StringMapWrapper.forEach(superType, function(v, k) {
            return type[k] = v;
          });
        }
        properties.forEach(function(property) {
          if (property == '') {} else if (property.startsWith('*')) {} else if (property.startsWith('!')) {
            type[property.substring(1)] = BOOLEAN;
          } else if (property.startsWith('#')) {
            type[property.substring(1)] = NUMBER;
          } else if (property.startsWith('%')) {
            type[property.substring(1)] = OBJECT;
          } else {
            type[property] = STRING;
          }
        });
      });
    }
    DomElementSchemaRegistry.prototype.hasProperty = function(tagName, propName) {
      if (tagName.indexOf('-') !== -1) {
        return true;
      } else {
        var elementProperties = this.schema[tagName.toLowerCase()];
        if (!lang_1.isPresent(elementProperties)) {
          elementProperties = this.schema['unknown'];
        }
        return lang_1.isPresent(elementProperties[propName]);
      }
    };
    DomElementSchemaRegistry.prototype.securityContext = function(tagName, propName) {
      if (propName === 'style')
        return core_private_1.SecurityContext.STYLE;
      if (tagName === 'a' && propName === 'href')
        return core_private_1.SecurityContext.URL;
      if (propName === 'innerHTML')
        return core_private_1.SecurityContext.HTML;
      return core_private_1.SecurityContext.NONE;
    };
    DomElementSchemaRegistry.prototype.getMappedPropName = function(propName) {
      var mappedPropName = collection_1.StringMapWrapper.get(attrToPropMap, propName);
      return lang_1.isPresent(mappedPropName) ? mappedPropName : propName;
    };
    DomElementSchemaRegistry.decorators = [{type: core_1.Injectable}];
    DomElementSchemaRegistry.ctorParameters = [];
    return DomElementSchemaRegistry;
  }(element_schema_registry_1.ElementSchemaRegistry));
  exports.DomElementSchemaRegistry = DomElementSchemaRegistry;
  return module.exports;
});

$__System.registerDynamic("19", ["e", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var __extends = (this && this.__extends) || function(d, b) {
      for (var p in b)
        if (b.hasOwnProperty(p))
          d[p] = b[p];
      function __() {
        this.constructor = d;
      }
      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
    var collection_1 = $__require('e');
    var AST = (function() {
      function AST() {}
      AST.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return null;
      };
      AST.prototype.toString = function() {
        return "AST";
      };
      return AST;
    }());
    exports.AST = AST;
    var Quote = (function(_super) {
      __extends(Quote, _super);
      function Quote(prefix, uninterpretedExpression, location) {
        _super.call(this);
        this.prefix = prefix;
        this.uninterpretedExpression = uninterpretedExpression;
        this.location = location;
      }
      Quote.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitQuote(this, context);
      };
      Quote.prototype.toString = function() {
        return "Quote";
      };
      return Quote;
    }(AST));
    exports.Quote = Quote;
    var EmptyExpr = (function(_super) {
      __extends(EmptyExpr, _super);
      function EmptyExpr() {
        _super.apply(this, arguments);
      }
      EmptyExpr.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
      };
      return EmptyExpr;
    }(AST));
    exports.EmptyExpr = EmptyExpr;
    var ImplicitReceiver = (function(_super) {
      __extends(ImplicitReceiver, _super);
      function ImplicitReceiver() {
        _super.apply(this, arguments);
      }
      ImplicitReceiver.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitImplicitReceiver(this, context);
      };
      return ImplicitReceiver;
    }(AST));
    exports.ImplicitReceiver = ImplicitReceiver;
    var Chain = (function(_super) {
      __extends(Chain, _super);
      function Chain(expressions) {
        _super.call(this);
        this.expressions = expressions;
      }
      Chain.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitChain(this, context);
      };
      return Chain;
    }(AST));
    exports.Chain = Chain;
    var Conditional = (function(_super) {
      __extends(Conditional, _super);
      function Conditional(condition, trueExp, falseExp) {
        _super.call(this);
        this.condition = condition;
        this.trueExp = trueExp;
        this.falseExp = falseExp;
      }
      Conditional.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitConditional(this, context);
      };
      return Conditional;
    }(AST));
    exports.Conditional = Conditional;
    var PropertyRead = (function(_super) {
      __extends(PropertyRead, _super);
      function PropertyRead(receiver, name) {
        _super.call(this);
        this.receiver = receiver;
        this.name = name;
      }
      PropertyRead.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitPropertyRead(this, context);
      };
      return PropertyRead;
    }(AST));
    exports.PropertyRead = PropertyRead;
    var PropertyWrite = (function(_super) {
      __extends(PropertyWrite, _super);
      function PropertyWrite(receiver, name, value) {
        _super.call(this);
        this.receiver = receiver;
        this.name = name;
        this.value = value;
      }
      PropertyWrite.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitPropertyWrite(this, context);
      };
      return PropertyWrite;
    }(AST));
    exports.PropertyWrite = PropertyWrite;
    var SafePropertyRead = (function(_super) {
      __extends(SafePropertyRead, _super);
      function SafePropertyRead(receiver, name) {
        _super.call(this);
        this.receiver = receiver;
        this.name = name;
      }
      SafePropertyRead.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitSafePropertyRead(this, context);
      };
      return SafePropertyRead;
    }(AST));
    exports.SafePropertyRead = SafePropertyRead;
    var KeyedRead = (function(_super) {
      __extends(KeyedRead, _super);
      function KeyedRead(obj, key) {
        _super.call(this);
        this.obj = obj;
        this.key = key;
      }
      KeyedRead.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitKeyedRead(this, context);
      };
      return KeyedRead;
    }(AST));
    exports.KeyedRead = KeyedRead;
    var KeyedWrite = (function(_super) {
      __extends(KeyedWrite, _super);
      function KeyedWrite(obj, key, value) {
        _super.call(this);
        this.obj = obj;
        this.key = key;
        this.value = value;
      }
      KeyedWrite.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitKeyedWrite(this, context);
      };
      return KeyedWrite;
    }(AST));
    exports.KeyedWrite = KeyedWrite;
    var BindingPipe = (function(_super) {
      __extends(BindingPipe, _super);
      function BindingPipe(exp, name, args) {
        _super.call(this);
        this.exp = exp;
        this.name = name;
        this.args = args;
      }
      BindingPipe.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitPipe(this, context);
      };
      return BindingPipe;
    }(AST));
    exports.BindingPipe = BindingPipe;
    var LiteralPrimitive = (function(_super) {
      __extends(LiteralPrimitive, _super);
      function LiteralPrimitive(value) {
        _super.call(this);
        this.value = value;
      }
      LiteralPrimitive.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitLiteralPrimitive(this, context);
      };
      return LiteralPrimitive;
    }(AST));
    exports.LiteralPrimitive = LiteralPrimitive;
    var LiteralArray = (function(_super) {
      __extends(LiteralArray, _super);
      function LiteralArray(expressions) {
        _super.call(this);
        this.expressions = expressions;
      }
      LiteralArray.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitLiteralArray(this, context);
      };
      return LiteralArray;
    }(AST));
    exports.LiteralArray = LiteralArray;
    var LiteralMap = (function(_super) {
      __extends(LiteralMap, _super);
      function LiteralMap(keys, values) {
        _super.call(this);
        this.keys = keys;
        this.values = values;
      }
      LiteralMap.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitLiteralMap(this, context);
      };
      return LiteralMap;
    }(AST));
    exports.LiteralMap = LiteralMap;
    var Interpolation = (function(_super) {
      __extends(Interpolation, _super);
      function Interpolation(strings, expressions) {
        _super.call(this);
        this.strings = strings;
        this.expressions = expressions;
      }
      Interpolation.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitInterpolation(this, context);
      };
      return Interpolation;
    }(AST));
    exports.Interpolation = Interpolation;
    var Binary = (function(_super) {
      __extends(Binary, _super);
      function Binary(operation, left, right) {
        _super.call(this);
        this.operation = operation;
        this.left = left;
        this.right = right;
      }
      Binary.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitBinary(this, context);
      };
      return Binary;
    }(AST));
    exports.Binary = Binary;
    var PrefixNot = (function(_super) {
      __extends(PrefixNot, _super);
      function PrefixNot(expression) {
        _super.call(this);
        this.expression = expression;
      }
      PrefixNot.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitPrefixNot(this, context);
      };
      return PrefixNot;
    }(AST));
    exports.PrefixNot = PrefixNot;
    var MethodCall = (function(_super) {
      __extends(MethodCall, _super);
      function MethodCall(receiver, name, args) {
        _super.call(this);
        this.receiver = receiver;
        this.name = name;
        this.args = args;
      }
      MethodCall.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitMethodCall(this, context);
      };
      return MethodCall;
    }(AST));
    exports.MethodCall = MethodCall;
    var SafeMethodCall = (function(_super) {
      __extends(SafeMethodCall, _super);
      function SafeMethodCall(receiver, name, args) {
        _super.call(this);
        this.receiver = receiver;
        this.name = name;
        this.args = args;
      }
      SafeMethodCall.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitSafeMethodCall(this, context);
      };
      return SafeMethodCall;
    }(AST));
    exports.SafeMethodCall = SafeMethodCall;
    var FunctionCall = (function(_super) {
      __extends(FunctionCall, _super);
      function FunctionCall(target, args) {
        _super.call(this);
        this.target = target;
        this.args = args;
      }
      FunctionCall.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return visitor.visitFunctionCall(this, context);
      };
      return FunctionCall;
    }(AST));
    exports.FunctionCall = FunctionCall;
    var ASTWithSource = (function(_super) {
      __extends(ASTWithSource, _super);
      function ASTWithSource(ast, source, location) {
        _super.call(this);
        this.ast = ast;
        this.source = source;
        this.location = location;
      }
      ASTWithSource.prototype.visit = function(visitor, context) {
        if (context === void 0) {
          context = null;
        }
        return this.ast.visit(visitor, context);
      };
      ASTWithSource.prototype.toString = function() {
        return this.source + " in " + this.location;
      };
      return ASTWithSource;
    }(AST));
    exports.ASTWithSource = ASTWithSource;
    var TemplateBinding = (function() {
      function TemplateBinding(key, keyIsVar, name, expression) {
        this.key = key;
        this.keyIsVar = keyIsVar;
        this.name = name;
        this.expression = expression;
      }
      return TemplateBinding;
    }());
    exports.TemplateBinding = TemplateBinding;
    var RecursiveAstVisitor = (function() {
      function RecursiveAstVisitor() {}
      RecursiveAstVisitor.prototype.visitBinary = function(ast, context) {
        ast.left.visit(this);
        ast.right.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitChain = function(ast, context) {
        return this.visitAll(ast.expressions, context);
      };
      RecursiveAstVisitor.prototype.visitConditional = function(ast, context) {
        ast.condition.visit(this);
        ast.trueExp.visit(this);
        ast.falseExp.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitPipe = function(ast, context) {
        ast.exp.visit(this);
        this.visitAll(ast.args, context);
        return null;
      };
      RecursiveAstVisitor.prototype.visitFunctionCall = function(ast, context) {
        ast.target.visit(this);
        this.visitAll(ast.args, context);
        return null;
      };
      RecursiveAstVisitor.prototype.visitImplicitReceiver = function(ast, context) {
        return null;
      };
      RecursiveAstVisitor.prototype.visitInterpolation = function(ast, context) {
        return this.visitAll(ast.expressions, context);
      };
      RecursiveAstVisitor.prototype.visitKeyedRead = function(ast, context) {
        ast.obj.visit(this);
        ast.key.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitKeyedWrite = function(ast, context) {
        ast.obj.visit(this);
        ast.key.visit(this);
        ast.value.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitLiteralArray = function(ast, context) {
        return this.visitAll(ast.expressions, context);
      };
      RecursiveAstVisitor.prototype.visitLiteralMap = function(ast, context) {
        return this.visitAll(ast.values, context);
      };
      RecursiveAstVisitor.prototype.visitLiteralPrimitive = function(ast, context) {
        return null;
      };
      RecursiveAstVisitor.prototype.visitMethodCall = function(ast, context) {
        ast.receiver.visit(this);
        return this.visitAll(ast.args, context);
      };
      RecursiveAstVisitor.prototype.visitPrefixNot = function(ast, context) {
        ast.expression.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitPropertyRead = function(ast, context) {
        ast.receiver.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitPropertyWrite = function(ast, context) {
        ast.receiver.visit(this);
        ast.value.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitSafePropertyRead = function(ast, context) {
        ast.receiver.visit(this);
        return null;
      };
      RecursiveAstVisitor.prototype.visitSafeMethodCall = function(ast, context) {
        ast.receiver.visit(this);
        return this.visitAll(ast.args, context);
      };
      RecursiveAstVisitor.prototype.visitAll = function(asts, context) {
        var _this = this;
        asts.forEach(function(ast) {
          return ast.visit(_this, context);
        });
        return null;
      };
      RecursiveAstVisitor.prototype.visitQuote = function(ast, context) {
        return null;
      };
      return RecursiveAstVisitor;
    }());
    exports.RecursiveAstVisitor = RecursiveAstVisitor;
    var AstTransformer = (function() {
      function AstTransformer() {}
      AstTransformer.prototype.visitImplicitReceiver = function(ast, context) {
        return ast;
      };
      AstTransformer.prototype.visitInterpolation = function(ast, context) {
        return new Interpolation(ast.strings, this.visitAll(ast.expressions));
      };
      AstTransformer.prototype.visitLiteralPrimitive = function(ast, context) {
        return new LiteralPrimitive(ast.value);
      };
      AstTransformer.prototype.visitPropertyRead = function(ast, context) {
        return new PropertyRead(ast.receiver.visit(this), ast.name);
      };
      AstTransformer.prototype.visitPropertyWrite = function(ast, context) {
        return new PropertyWrite(ast.receiver.visit(this), ast.name, ast.value);
      };
      AstTransformer.prototype.visitSafePropertyRead = function(ast, context) {
        return new SafePropertyRead(ast.receiver.visit(this), ast.name);
      };
      AstTransformer.prototype.visitMethodCall = function(ast, context) {
        return new MethodCall(ast.receiver.visit(this), ast.name, this.visitAll(ast.args));
      };
      AstTransformer.prototype.visitSafeMethodCall = function(ast, context) {
        return new SafeMethodCall(ast.receiver.visit(this), ast.name, this.visitAll(ast.args));
      };
      AstTransformer.prototype.visitFunctionCall = function(ast, context) {
        return new FunctionCall(ast.target.visit(this), this.visitAll(ast.args));
      };
      AstTransformer.prototype.visitLiteralArray = function(ast, context) {
        return new LiteralArray(this.visitAll(ast.expressions));
      };
      AstTransformer.prototype.visitLiteralMap = function(ast, context) {
        return new LiteralMap(ast.keys, this.visitAll(ast.values));
      };
      AstTransformer.prototype.visitBinary = function(ast, context) {
        return new Binary(ast.operation, ast.left.visit(this), ast.right.visit(this));
      };
      AstTransformer.prototype.visitPrefixNot = function(ast, context) {
        return new PrefixNot(ast.expression.visit(this));
      };
      AstTransformer.prototype.visitConditional = function(ast, context) {
        return new Conditional(ast.condition.visit(this), ast.trueExp.visit(this), ast.falseExp.visit(this));
      };
      AstTransformer.prototype.visitPipe = function(ast, context) {
        return new BindingPipe(ast.exp.visit(this), ast.name, this.visitAll(ast.args));
      };
      AstTransformer.prototype.visitKeyedRead = function(ast, context) {
        return new KeyedRead(ast.obj.visit(this), ast.key.visit(this));
      };
      AstTransformer.prototype.visitKeyedWrite = function(ast, context) {
        return new KeyedWrite(ast.obj.visit(this), ast.key.visit(this), ast.value.visit(this));
      };
      AstTransformer.prototype.visitAll = function(asts) {
        var res = collection_1.ListWrapper.createFixedSize(asts.length);
        for (var i = 0; i < asts.length; ++i) {
          res[i] = asts[i].visit(this);
        }
        return res;
      };
      AstTransformer.prototype.visitChain = function(ast, context) {
        return new Chain(this.visitAll(ast.expressions));
      };
      AstTransformer.prototype.visitQuote = function(ast, context) {
        return new Quote(ast.prefix, ast.uninterpretedExpression, ast.location);
      };
      return AstTransformer;
    }());
    exports.AstTransformer = AstTransformer;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1a", ["11", "13", "d", "e", "4e", "19"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  var collection_1 = $__require('e');
  var lexer_1 = $__require('4e');
  var ast_1 = $__require('19');
  var _implicitReceiver = new ast_1.ImplicitReceiver();
  var INTERPOLATION_REGEXP = /\{\{([\s\S]*?)\}\}/g;
  var ParseException = (function(_super) {
    __extends(ParseException, _super);
    function ParseException(message, input, errLocation, ctxLocation) {
      _super.call(this, "Parser Error: " + message + " " + errLocation + " [" + input + "] in " + ctxLocation);
    }
    return ParseException;
  }(exceptions_1.BaseException));
  var SplitInterpolation = (function() {
    function SplitInterpolation(strings, expressions) {
      this.strings = strings;
      this.expressions = expressions;
    }
    return SplitInterpolation;
  }());
  exports.SplitInterpolation = SplitInterpolation;
  var TemplateBindingParseResult = (function() {
    function TemplateBindingParseResult(templateBindings, warnings) {
      this.templateBindings = templateBindings;
      this.warnings = warnings;
    }
    return TemplateBindingParseResult;
  }());
  exports.TemplateBindingParseResult = TemplateBindingParseResult;
  var Parser = (function() {
    function Parser(_lexer) {
      this._lexer = _lexer;
    }
    Parser.prototype.parseAction = function(input, location) {
      this._checkNoInterpolation(input, location);
      var tokens = this._lexer.tokenize(this._stripComments(input));
      var ast = new _ParseAST(input, location, tokens, true).parseChain();
      return new ast_1.ASTWithSource(ast, input, location);
    };
    Parser.prototype.parseBinding = function(input, location) {
      var ast = this._parseBindingAst(input, location);
      return new ast_1.ASTWithSource(ast, input, location);
    };
    Parser.prototype.parseSimpleBinding = function(input, location) {
      var ast = this._parseBindingAst(input, location);
      if (!SimpleExpressionChecker.check(ast)) {
        throw new ParseException('Host binding expression can only contain field access and constants', input, location);
      }
      return new ast_1.ASTWithSource(ast, input, location);
    };
    Parser.prototype._parseBindingAst = function(input, location) {
      var quote = this._parseQuote(input, location);
      if (lang_1.isPresent(quote)) {
        return quote;
      }
      this._checkNoInterpolation(input, location);
      var tokens = this._lexer.tokenize(this._stripComments(input));
      return new _ParseAST(input, location, tokens, false).parseChain();
    };
    Parser.prototype._parseQuote = function(input, location) {
      if (lang_1.isBlank(input))
        return null;
      var prefixSeparatorIndex = input.indexOf(':');
      if (prefixSeparatorIndex == -1)
        return null;
      var prefix = input.substring(0, prefixSeparatorIndex).trim();
      if (!lexer_1.isIdentifier(prefix))
        return null;
      var uninterpretedExpression = input.substring(prefixSeparatorIndex + 1);
      return new ast_1.Quote(prefix, uninterpretedExpression, location);
    };
    Parser.prototype.parseTemplateBindings = function(input, location) {
      var tokens = this._lexer.tokenize(input);
      return new _ParseAST(input, location, tokens, false).parseTemplateBindings();
    };
    Parser.prototype.parseInterpolation = function(input, location) {
      var split = this.splitInterpolation(input, location);
      if (split == null)
        return null;
      var expressions = [];
      for (var i = 0; i < split.expressions.length; ++i) {
        var tokens = this._lexer.tokenize(this._stripComments(split.expressions[i]));
        var ast = new _ParseAST(input, location, tokens, false).parseChain();
        expressions.push(ast);
      }
      return new ast_1.ASTWithSource(new ast_1.Interpolation(split.strings, expressions), input, location);
    };
    Parser.prototype.splitInterpolation = function(input, location) {
      var parts = lang_1.StringWrapper.split(input, INTERPOLATION_REGEXP);
      if (parts.length <= 1) {
        return null;
      }
      var strings = [];
      var expressions = [];
      for (var i = 0; i < parts.length; i++) {
        var part = parts[i];
        if (i % 2 === 0) {
          strings.push(part);
        } else if (part.trim().length > 0) {
          expressions.push(part);
        } else {
          throw new ParseException('Blank expressions are not allowed in interpolated strings', input, "at column " + this._findInterpolationErrorColumn(parts, i) + " in", location);
        }
      }
      return new SplitInterpolation(strings, expressions);
    };
    Parser.prototype.wrapLiteralPrimitive = function(input, location) {
      return new ast_1.ASTWithSource(new ast_1.LiteralPrimitive(input), input, location);
    };
    Parser.prototype._stripComments = function(input) {
      var i = this._commentStart(input);
      return lang_1.isPresent(i) ? input.substring(0, i).trim() : input;
    };
    Parser.prototype._commentStart = function(input) {
      var outerQuote = null;
      for (var i = 0; i < input.length - 1; i++) {
        var char = lang_1.StringWrapper.charCodeAt(input, i);
        var nextChar = lang_1.StringWrapper.charCodeAt(input, i + 1);
        if (char === lexer_1.$SLASH && nextChar == lexer_1.$SLASH && lang_1.isBlank(outerQuote))
          return i;
        if (outerQuote === char) {
          outerQuote = null;
        } else if (lang_1.isBlank(outerQuote) && lexer_1.isQuote(char)) {
          outerQuote = char;
        }
      }
      return null;
    };
    Parser.prototype._checkNoInterpolation = function(input, location) {
      var parts = lang_1.StringWrapper.split(input, INTERPOLATION_REGEXP);
      if (parts.length > 1) {
        throw new ParseException('Got interpolation ({{}}) where expression was expected', input, "at column " + this._findInterpolationErrorColumn(parts, 1) + " in", location);
      }
    };
    Parser.prototype._findInterpolationErrorColumn = function(parts, partInErrIdx) {
      var errLocation = '';
      for (var j = 0; j < partInErrIdx; j++) {
        errLocation += j % 2 === 0 ? parts[j] : "{{" + parts[j] + "}}";
      }
      return errLocation.length;
    };
    Parser.decorators = [{type: core_1.Injectable}];
    Parser.ctorParameters = [{type: lexer_1.Lexer}];
    return Parser;
  }());
  exports.Parser = Parser;
  var _ParseAST = (function() {
    function _ParseAST(input, location, tokens, parseAction) {
      this.input = input;
      this.location = location;
      this.tokens = tokens;
      this.parseAction = parseAction;
      this.index = 0;
    }
    _ParseAST.prototype.peek = function(offset) {
      var i = this.index + offset;
      return i < this.tokens.length ? this.tokens[i] : lexer_1.EOF;
    };
    Object.defineProperty(_ParseAST.prototype, "next", {
      get: function() {
        return this.peek(0);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(_ParseAST.prototype, "inputIndex", {
      get: function() {
        return (this.index < this.tokens.length) ? this.next.index : this.input.length;
      },
      enumerable: true,
      configurable: true
    });
    _ParseAST.prototype.advance = function() {
      this.index++;
    };
    _ParseAST.prototype.optionalCharacter = function(code) {
      if (this.next.isCharacter(code)) {
        this.advance();
        return true;
      } else {
        return false;
      }
    };
    _ParseAST.prototype.peekKeywordLet = function() {
      return this.next.isKeywordLet();
    };
    _ParseAST.prototype.peekDeprecatedKeywordVar = function() {
      return this.next.isKeywordDeprecatedVar();
    };
    _ParseAST.prototype.peekDeprecatedOperatorHash = function() {
      return this.next.isOperator('#');
    };
    _ParseAST.prototype.expectCharacter = function(code) {
      if (this.optionalCharacter(code))
        return;
      this.error("Missing expected " + lang_1.StringWrapper.fromCharCode(code));
    };
    _ParseAST.prototype.optionalOperator = function(op) {
      if (this.next.isOperator(op)) {
        this.advance();
        return true;
      } else {
        return false;
      }
    };
    _ParseAST.prototype.expectOperator = function(operator) {
      if (this.optionalOperator(operator))
        return;
      this.error("Missing expected operator " + operator);
    };
    _ParseAST.prototype.expectIdentifierOrKeyword = function() {
      var n = this.next;
      if (!n.isIdentifier() && !n.isKeyword()) {
        this.error("Unexpected token " + n + ", expected identifier or keyword");
      }
      this.advance();
      return n.toString();
    };
    _ParseAST.prototype.expectIdentifierOrKeywordOrString = function() {
      var n = this.next;
      if (!n.isIdentifier() && !n.isKeyword() && !n.isString()) {
        this.error("Unexpected token " + n + ", expected identifier, keyword, or string");
      }
      this.advance();
      return n.toString();
    };
    _ParseAST.prototype.parseChain = function() {
      var exprs = [];
      while (this.index < this.tokens.length) {
        var expr = this.parsePipe();
        exprs.push(expr);
        if (this.optionalCharacter(lexer_1.$SEMICOLON)) {
          if (!this.parseAction) {
            this.error("Binding expression cannot contain chained expression");
          }
          while (this.optionalCharacter(lexer_1.$SEMICOLON)) {}
        } else if (this.index < this.tokens.length) {
          this.error("Unexpected token '" + this.next + "'");
        }
      }
      if (exprs.length == 0)
        return new ast_1.EmptyExpr();
      if (exprs.length == 1)
        return exprs[0];
      return new ast_1.Chain(exprs);
    };
    _ParseAST.prototype.parsePipe = function() {
      var result = this.parseExpression();
      if (this.optionalOperator("|")) {
        if (this.parseAction) {
          this.error("Cannot have a pipe in an action expression");
        }
        do {
          var name = this.expectIdentifierOrKeyword();
          var args = [];
          while (this.optionalCharacter(lexer_1.$COLON)) {
            args.push(this.parseExpression());
          }
          result = new ast_1.BindingPipe(result, name, args);
        } while (this.optionalOperator("|"));
      }
      return result;
    };
    _ParseAST.prototype.parseExpression = function() {
      return this.parseConditional();
    };
    _ParseAST.prototype.parseConditional = function() {
      var start = this.inputIndex;
      var result = this.parseLogicalOr();
      if (this.optionalOperator('?')) {
        var yes = this.parsePipe();
        if (!this.optionalCharacter(lexer_1.$COLON)) {
          var end = this.inputIndex;
          var expression = this.input.substring(start, end);
          this.error("Conditional expression " + expression + " requires all 3 expressions");
        }
        var no = this.parsePipe();
        return new ast_1.Conditional(result, yes, no);
      } else {
        return result;
      }
    };
    _ParseAST.prototype.parseLogicalOr = function() {
      var result = this.parseLogicalAnd();
      while (this.optionalOperator('||')) {
        result = new ast_1.Binary('||', result, this.parseLogicalAnd());
      }
      return result;
    };
    _ParseAST.prototype.parseLogicalAnd = function() {
      var result = this.parseEquality();
      while (this.optionalOperator('&&')) {
        result = new ast_1.Binary('&&', result, this.parseEquality());
      }
      return result;
    };
    _ParseAST.prototype.parseEquality = function() {
      var result = this.parseRelational();
      while (true) {
        if (this.optionalOperator('==')) {
          result = new ast_1.Binary('==', result, this.parseRelational());
        } else if (this.optionalOperator('===')) {
          result = new ast_1.Binary('===', result, this.parseRelational());
        } else if (this.optionalOperator('!=')) {
          result = new ast_1.Binary('!=', result, this.parseRelational());
        } else if (this.optionalOperator('!==')) {
          result = new ast_1.Binary('!==', result, this.parseRelational());
        } else {
          return result;
        }
      }
    };
    _ParseAST.prototype.parseRelational = function() {
      var result = this.parseAdditive();
      while (true) {
        if (this.optionalOperator('<')) {
          result = new ast_1.Binary('<', result, this.parseAdditive());
        } else if (this.optionalOperator('>')) {
          result = new ast_1.Binary('>', result, this.parseAdditive());
        } else if (this.optionalOperator('<=')) {
          result = new ast_1.Binary('<=', result, this.parseAdditive());
        } else if (this.optionalOperator('>=')) {
          result = new ast_1.Binary('>=', result, this.parseAdditive());
        } else {
          return result;
        }
      }
    };
    _ParseAST.prototype.parseAdditive = function() {
      var result = this.parseMultiplicative();
      while (true) {
        if (this.optionalOperator('+')) {
          result = new ast_1.Binary('+', result, this.parseMultiplicative());
        } else if (this.optionalOperator('-')) {
          result = new ast_1.Binary('-', result, this.parseMultiplicative());
        } else {
          return result;
        }
      }
    };
    _ParseAST.prototype.parseMultiplicative = function() {
      var result = this.parsePrefix();
      while (true) {
        if (this.optionalOperator('*')) {
          result = new ast_1.Binary('*', result, this.parsePrefix());
        } else if (this.optionalOperator('%')) {
          result = new ast_1.Binary('%', result, this.parsePrefix());
        } else if (this.optionalOperator('/')) {
          result = new ast_1.Binary('/', result, this.parsePrefix());
        } else {
          return result;
        }
      }
    };
    _ParseAST.prototype.parsePrefix = function() {
      if (this.optionalOperator('+')) {
        return this.parsePrefix();
      } else if (this.optionalOperator('-')) {
        return new ast_1.Binary('-', new ast_1.LiteralPrimitive(0), this.parsePrefix());
      } else if (this.optionalOperator('!')) {
        return new ast_1.PrefixNot(this.parsePrefix());
      } else {
        return this.parseCallChain();
      }
    };
    _ParseAST.prototype.parseCallChain = function() {
      var result = this.parsePrimary();
      while (true) {
        if (this.optionalCharacter(lexer_1.$PERIOD)) {
          result = this.parseAccessMemberOrMethodCall(result, false);
        } else if (this.optionalOperator('?.')) {
          result = this.parseAccessMemberOrMethodCall(result, true);
        } else if (this.optionalCharacter(lexer_1.$LBRACKET)) {
          var key = this.parsePipe();
          this.expectCharacter(lexer_1.$RBRACKET);
          if (this.optionalOperator("=")) {
            var value = this.parseConditional();
            result = new ast_1.KeyedWrite(result, key, value);
          } else {
            result = new ast_1.KeyedRead(result, key);
          }
        } else if (this.optionalCharacter(lexer_1.$LPAREN)) {
          var args = this.parseCallArguments();
          this.expectCharacter(lexer_1.$RPAREN);
          result = new ast_1.FunctionCall(result, args);
        } else {
          return result;
        }
      }
    };
    _ParseAST.prototype.parsePrimary = function() {
      if (this.optionalCharacter(lexer_1.$LPAREN)) {
        var result = this.parsePipe();
        this.expectCharacter(lexer_1.$RPAREN);
        return result;
      } else if (this.next.isKeywordNull() || this.next.isKeywordUndefined()) {
        this.advance();
        return new ast_1.LiteralPrimitive(null);
      } else if (this.next.isKeywordTrue()) {
        this.advance();
        return new ast_1.LiteralPrimitive(true);
      } else if (this.next.isKeywordFalse()) {
        this.advance();
        return new ast_1.LiteralPrimitive(false);
      } else if (this.optionalCharacter(lexer_1.$LBRACKET)) {
        var elements = this.parseExpressionList(lexer_1.$RBRACKET);
        this.expectCharacter(lexer_1.$RBRACKET);
        return new ast_1.LiteralArray(elements);
      } else if (this.next.isCharacter(lexer_1.$LBRACE)) {
        return this.parseLiteralMap();
      } else if (this.next.isIdentifier()) {
        return this.parseAccessMemberOrMethodCall(_implicitReceiver, false);
      } else if (this.next.isNumber()) {
        var value = this.next.toNumber();
        this.advance();
        return new ast_1.LiteralPrimitive(value);
      } else if (this.next.isString()) {
        var literalValue = this.next.toString();
        this.advance();
        return new ast_1.LiteralPrimitive(literalValue);
      } else if (this.index >= this.tokens.length) {
        this.error("Unexpected end of expression: " + this.input);
      } else {
        this.error("Unexpected token " + this.next);
      }
      throw new exceptions_1.BaseException("Fell through all cases in parsePrimary");
    };
    _ParseAST.prototype.parseExpressionList = function(terminator) {
      var result = [];
      if (!this.next.isCharacter(terminator)) {
        do {
          result.push(this.parsePipe());
        } while (this.optionalCharacter(lexer_1.$COMMA));
      }
      return result;
    };
    _ParseAST.prototype.parseLiteralMap = function() {
      var keys = [];
      var values = [];
      this.expectCharacter(lexer_1.$LBRACE);
      if (!this.optionalCharacter(lexer_1.$RBRACE)) {
        do {
          var key = this.expectIdentifierOrKeywordOrString();
          keys.push(key);
          this.expectCharacter(lexer_1.$COLON);
          values.push(this.parsePipe());
        } while (this.optionalCharacter(lexer_1.$COMMA));
        this.expectCharacter(lexer_1.$RBRACE);
      }
      return new ast_1.LiteralMap(keys, values);
    };
    _ParseAST.prototype.parseAccessMemberOrMethodCall = function(receiver, isSafe) {
      if (isSafe === void 0) {
        isSafe = false;
      }
      var id = this.expectIdentifierOrKeyword();
      if (this.optionalCharacter(lexer_1.$LPAREN)) {
        var args = this.parseCallArguments();
        this.expectCharacter(lexer_1.$RPAREN);
        return isSafe ? new ast_1.SafeMethodCall(receiver, id, args) : new ast_1.MethodCall(receiver, id, args);
      } else {
        if (isSafe) {
          if (this.optionalOperator("=")) {
            this.error("The '?.' operator cannot be used in the assignment");
          } else {
            return new ast_1.SafePropertyRead(receiver, id);
          }
        } else {
          if (this.optionalOperator("=")) {
            if (!this.parseAction) {
              this.error("Bindings cannot contain assignments");
            }
            var value = this.parseConditional();
            return new ast_1.PropertyWrite(receiver, id, value);
          } else {
            return new ast_1.PropertyRead(receiver, id);
          }
        }
      }
      return null;
    };
    _ParseAST.prototype.parseCallArguments = function() {
      if (this.next.isCharacter(lexer_1.$RPAREN))
        return [];
      var positionals = [];
      do {
        positionals.push(this.parsePipe());
      } while (this.optionalCharacter(lexer_1.$COMMA));
      return positionals;
    };
    _ParseAST.prototype.parseBlockContent = function() {
      if (!this.parseAction) {
        this.error("Binding expression cannot contain chained expression");
      }
      var exprs = [];
      while (this.index < this.tokens.length && !this.next.isCharacter(lexer_1.$RBRACE)) {
        var expr = this.parseExpression();
        exprs.push(expr);
        if (this.optionalCharacter(lexer_1.$SEMICOLON)) {
          while (this.optionalCharacter(lexer_1.$SEMICOLON)) {}
        }
      }
      if (exprs.length == 0)
        return new ast_1.EmptyExpr();
      if (exprs.length == 1)
        return exprs[0];
      return new ast_1.Chain(exprs);
    };
    _ParseAST.prototype.expectTemplateBindingKey = function() {
      var result = '';
      var operatorFound = false;
      do {
        result += this.expectIdentifierOrKeywordOrString();
        operatorFound = this.optionalOperator('-');
        if (operatorFound) {
          result += '-';
        }
      } while (operatorFound);
      return result.toString();
    };
    _ParseAST.prototype.parseTemplateBindings = function() {
      var bindings = [];
      var prefix = null;
      var warnings = [];
      while (this.index < this.tokens.length) {
        var keyIsVar = this.peekKeywordLet();
        if (!keyIsVar && this.peekDeprecatedKeywordVar()) {
          keyIsVar = true;
          warnings.push("\"var\" inside of expressions is deprecated. Use \"let\" instead!");
        }
        if (!keyIsVar && this.peekDeprecatedOperatorHash()) {
          keyIsVar = true;
          warnings.push("\"#\" inside of expressions is deprecated. Use \"let\" instead!");
        }
        if (keyIsVar) {
          this.advance();
        }
        var key = this.expectTemplateBindingKey();
        if (!keyIsVar) {
          if (prefix == null) {
            prefix = key;
          } else {
            key = prefix + key[0].toUpperCase() + key.substring(1);
          }
        }
        this.optionalCharacter(lexer_1.$COLON);
        var name = null;
        var expression = null;
        if (keyIsVar) {
          if (this.optionalOperator("=")) {
            name = this.expectTemplateBindingKey();
          } else {
            name = '\$implicit';
          }
        } else if (this.next !== lexer_1.EOF && !this.peekKeywordLet() && !this.peekDeprecatedKeywordVar() && !this.peekDeprecatedOperatorHash()) {
          var start = this.inputIndex;
          var ast = this.parsePipe();
          var source = this.input.substring(start, this.inputIndex);
          expression = new ast_1.ASTWithSource(ast, source, this.location);
        }
        bindings.push(new ast_1.TemplateBinding(key, keyIsVar, name, expression));
        if (!this.optionalCharacter(lexer_1.$SEMICOLON)) {
          this.optionalCharacter(lexer_1.$COMMA);
        }
      }
      return new TemplateBindingParseResult(bindings, warnings);
    };
    _ParseAST.prototype.error = function(message, index) {
      if (index === void 0) {
        index = null;
      }
      if (lang_1.isBlank(index))
        index = this.index;
      var location = (index < this.tokens.length) ? "at column " + (this.tokens[index].index + 1) + " in" : "at the end of the expression";
      throw new ParseException(message, this.input, location, this.location);
    };
    return _ParseAST;
  }());
  exports._ParseAST = _ParseAST;
  var SimpleExpressionChecker = (function() {
    function SimpleExpressionChecker() {
      this.simple = true;
    }
    SimpleExpressionChecker.check = function(ast) {
      var s = new SimpleExpressionChecker();
      ast.visit(s);
      return s.simple;
    };
    SimpleExpressionChecker.prototype.visitImplicitReceiver = function(ast, context) {};
    SimpleExpressionChecker.prototype.visitInterpolation = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitLiteralPrimitive = function(ast, context) {};
    SimpleExpressionChecker.prototype.visitPropertyRead = function(ast, context) {};
    SimpleExpressionChecker.prototype.visitPropertyWrite = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitSafePropertyRead = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitMethodCall = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitSafeMethodCall = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitFunctionCall = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitLiteralArray = function(ast, context) {
      this.visitAll(ast.expressions);
    };
    SimpleExpressionChecker.prototype.visitLiteralMap = function(ast, context) {
      this.visitAll(ast.values);
    };
    SimpleExpressionChecker.prototype.visitBinary = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitPrefixNot = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitConditional = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitPipe = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitKeyedRead = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitKeyedWrite = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitAll = function(asts) {
      var res = collection_1.ListWrapper.createFixedSize(asts.length);
      for (var i = 0; i < asts.length; ++i) {
        res[i] = asts[i].visit(this);
      }
      return res;
    };
    SimpleExpressionChecker.prototype.visitChain = function(ast, context) {
      this.simple = false;
    };
    SimpleExpressionChecker.prototype.visitQuote = function(ast, context) {
      this.simple = false;
    };
    return SimpleExpressionChecker;
  }());
  return module.exports;
});

$__System.registerDynamic("4e", ["11", "e", "13", "d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var collection_1 = $__require('e');
  var lang_1 = $__require('13');
  var exceptions_1 = $__require('d');
  (function(TokenType) {
    TokenType[TokenType["Character"] = 0] = "Character";
    TokenType[TokenType["Identifier"] = 1] = "Identifier";
    TokenType[TokenType["Keyword"] = 2] = "Keyword";
    TokenType[TokenType["String"] = 3] = "String";
    TokenType[TokenType["Operator"] = 4] = "Operator";
    TokenType[TokenType["Number"] = 5] = "Number";
  })(exports.TokenType || (exports.TokenType = {}));
  var TokenType = exports.TokenType;
  var Lexer = (function() {
    function Lexer() {}
    Lexer.prototype.tokenize = function(text) {
      var scanner = new _Scanner(text);
      var tokens = [];
      var token = scanner.scanToken();
      while (token != null) {
        tokens.push(token);
        token = scanner.scanToken();
      }
      return tokens;
    };
    Lexer.decorators = [{type: core_1.Injectable}];
    return Lexer;
  }());
  exports.Lexer = Lexer;
  var Token = (function() {
    function Token(index, type, numValue, strValue) {
      this.index = index;
      this.type = type;
      this.numValue = numValue;
      this.strValue = strValue;
    }
    Token.prototype.isCharacter = function(code) {
      return (this.type == TokenType.Character && this.numValue == code);
    };
    Token.prototype.isNumber = function() {
      return (this.type == TokenType.Number);
    };
    Token.prototype.isString = function() {
      return (this.type == TokenType.String);
    };
    Token.prototype.isOperator = function(operater) {
      return (this.type == TokenType.Operator && this.strValue == operater);
    };
    Token.prototype.isIdentifier = function() {
      return (this.type == TokenType.Identifier);
    };
    Token.prototype.isKeyword = function() {
      return (this.type == TokenType.Keyword);
    };
    Token.prototype.isKeywordDeprecatedVar = function() {
      return (this.type == TokenType.Keyword && this.strValue == "var");
    };
    Token.prototype.isKeywordLet = function() {
      return (this.type == TokenType.Keyword && this.strValue == "let");
    };
    Token.prototype.isKeywordNull = function() {
      return (this.type == TokenType.Keyword && this.strValue == "null");
    };
    Token.prototype.isKeywordUndefined = function() {
      return (this.type == TokenType.Keyword && this.strValue == "undefined");
    };
    Token.prototype.isKeywordTrue = function() {
      return (this.type == TokenType.Keyword && this.strValue == "true");
    };
    Token.prototype.isKeywordFalse = function() {
      return (this.type == TokenType.Keyword && this.strValue == "false");
    };
    Token.prototype.toNumber = function() {
      return (this.type == TokenType.Number) ? this.numValue : -1;
    };
    Token.prototype.toString = function() {
      switch (this.type) {
        case TokenType.Character:
        case TokenType.Identifier:
        case TokenType.Keyword:
        case TokenType.Operator:
        case TokenType.String:
          return this.strValue;
        case TokenType.Number:
          return this.numValue.toString();
        default:
          return null;
      }
    };
    return Token;
  }());
  exports.Token = Token;
  function newCharacterToken(index, code) {
    return new Token(index, TokenType.Character, code, lang_1.StringWrapper.fromCharCode(code));
  }
  function newIdentifierToken(index, text) {
    return new Token(index, TokenType.Identifier, 0, text);
  }
  function newKeywordToken(index, text) {
    return new Token(index, TokenType.Keyword, 0, text);
  }
  function newOperatorToken(index, text) {
    return new Token(index, TokenType.Operator, 0, text);
  }
  function newStringToken(index, text) {
    return new Token(index, TokenType.String, 0, text);
  }
  function newNumberToken(index, n) {
    return new Token(index, TokenType.Number, n, "");
  }
  exports.EOF = new Token(-1, TokenType.Character, 0, "");
  exports.$EOF = 0;
  exports.$TAB = 9;
  exports.$LF = 10;
  exports.$VTAB = 11;
  exports.$FF = 12;
  exports.$CR = 13;
  exports.$SPACE = 32;
  exports.$BANG = 33;
  exports.$DQ = 34;
  exports.$HASH = 35;
  exports.$$ = 36;
  exports.$PERCENT = 37;
  exports.$AMPERSAND = 38;
  exports.$SQ = 39;
  exports.$LPAREN = 40;
  exports.$RPAREN = 41;
  exports.$STAR = 42;
  exports.$PLUS = 43;
  exports.$COMMA = 44;
  exports.$MINUS = 45;
  exports.$PERIOD = 46;
  exports.$SLASH = 47;
  exports.$COLON = 58;
  exports.$SEMICOLON = 59;
  exports.$LT = 60;
  exports.$EQ = 61;
  exports.$GT = 62;
  exports.$QUESTION = 63;
  var $0 = 48;
  var $9 = 57;
  var $A = 65,
      $E = 69,
      $Z = 90;
  exports.$LBRACKET = 91;
  exports.$BACKSLASH = 92;
  exports.$RBRACKET = 93;
  var $CARET = 94;
  var $_ = 95;
  exports.$BT = 96;
  var $a = 97,
      $e = 101,
      $f = 102;
  var $n = 110,
      $r = 114,
      $t = 116,
      $u = 117,
      $v = 118,
      $z = 122;
  exports.$LBRACE = 123;
  exports.$BAR = 124;
  exports.$RBRACE = 125;
  var $NBSP = 160;
  var ScannerError = (function(_super) {
    __extends(ScannerError, _super);
    function ScannerError(message) {
      _super.call(this);
      this.message = message;
    }
    ScannerError.prototype.toString = function() {
      return this.message;
    };
    return ScannerError;
  }(exceptions_1.BaseException));
  exports.ScannerError = ScannerError;
  var _Scanner = (function() {
    function _Scanner(input) {
      this.input = input;
      this.peek = 0;
      this.index = -1;
      this.length = input.length;
      this.advance();
    }
    _Scanner.prototype.advance = function() {
      this.peek = ++this.index >= this.length ? exports.$EOF : lang_1.StringWrapper.charCodeAt(this.input, this.index);
    };
    _Scanner.prototype.scanToken = function() {
      var input = this.input,
          length = this.length,
          peek = this.peek,
          index = this.index;
      while (peek <= exports.$SPACE) {
        if (++index >= length) {
          peek = exports.$EOF;
          break;
        } else {
          peek = lang_1.StringWrapper.charCodeAt(input, index);
        }
      }
      this.peek = peek;
      this.index = index;
      if (index >= length) {
        return null;
      }
      if (isIdentifierStart(peek))
        return this.scanIdentifier();
      if (isDigit(peek))
        return this.scanNumber(index);
      var start = index;
      switch (peek) {
        case exports.$PERIOD:
          this.advance();
          return isDigit(this.peek) ? this.scanNumber(start) : newCharacterToken(start, exports.$PERIOD);
        case exports.$LPAREN:
        case exports.$RPAREN:
        case exports.$LBRACE:
        case exports.$RBRACE:
        case exports.$LBRACKET:
        case exports.$RBRACKET:
        case exports.$COMMA:
        case exports.$COLON:
        case exports.$SEMICOLON:
          return this.scanCharacter(start, peek);
        case exports.$SQ:
        case exports.$DQ:
          return this.scanString();
        case exports.$HASH:
        case exports.$PLUS:
        case exports.$MINUS:
        case exports.$STAR:
        case exports.$SLASH:
        case exports.$PERCENT:
        case $CARET:
          return this.scanOperator(start, lang_1.StringWrapper.fromCharCode(peek));
        case exports.$QUESTION:
          return this.scanComplexOperator(start, '?', exports.$PERIOD, '.');
        case exports.$LT:
        case exports.$GT:
          return this.scanComplexOperator(start, lang_1.StringWrapper.fromCharCode(peek), exports.$EQ, '=');
        case exports.$BANG:
        case exports.$EQ:
          return this.scanComplexOperator(start, lang_1.StringWrapper.fromCharCode(peek), exports.$EQ, '=', exports.$EQ, '=');
        case exports.$AMPERSAND:
          return this.scanComplexOperator(start, '&', exports.$AMPERSAND, '&');
        case exports.$BAR:
          return this.scanComplexOperator(start, '|', exports.$BAR, '|');
        case $NBSP:
          while (isWhitespace(this.peek))
            this.advance();
          return this.scanToken();
      }
      this.error("Unexpected character [" + lang_1.StringWrapper.fromCharCode(peek) + "]", 0);
      return null;
    };
    _Scanner.prototype.scanCharacter = function(start, code) {
      this.advance();
      return newCharacterToken(start, code);
    };
    _Scanner.prototype.scanOperator = function(start, str) {
      this.advance();
      return newOperatorToken(start, str);
    };
    _Scanner.prototype.scanComplexOperator = function(start, one, twoCode, two, threeCode, three) {
      this.advance();
      var str = one;
      if (this.peek == twoCode) {
        this.advance();
        str += two;
      }
      if (lang_1.isPresent(threeCode) && this.peek == threeCode) {
        this.advance();
        str += three;
      }
      return newOperatorToken(start, str);
    };
    _Scanner.prototype.scanIdentifier = function() {
      var start = this.index;
      this.advance();
      while (isIdentifierPart(this.peek))
        this.advance();
      var str = this.input.substring(start, this.index);
      if (collection_1.SetWrapper.has(KEYWORDS, str)) {
        return newKeywordToken(start, str);
      } else {
        return newIdentifierToken(start, str);
      }
    };
    _Scanner.prototype.scanNumber = function(start) {
      var simple = (this.index === start);
      this.advance();
      while (true) {
        if (isDigit(this.peek)) {} else if (this.peek == exports.$PERIOD) {
          simple = false;
        } else if (isExponentStart(this.peek)) {
          this.advance();
          if (isExponentSign(this.peek))
            this.advance();
          if (!isDigit(this.peek))
            this.error('Invalid exponent', -1);
          simple = false;
        } else {
          break;
        }
        this.advance();
      }
      var str = this.input.substring(start, this.index);
      var value = simple ? lang_1.NumberWrapper.parseIntAutoRadix(str) : lang_1.NumberWrapper.parseFloat(str);
      return newNumberToken(start, value);
    };
    _Scanner.prototype.scanString = function() {
      var start = this.index;
      var quote = this.peek;
      this.advance();
      var buffer;
      var marker = this.index;
      var input = this.input;
      while (this.peek != quote) {
        if (this.peek == exports.$BACKSLASH) {
          if (buffer == null)
            buffer = new lang_1.StringJoiner();
          buffer.add(input.substring(marker, this.index));
          this.advance();
          var unescapedCode;
          if (this.peek == $u) {
            var hex = input.substring(this.index + 1, this.index + 5);
            try {
              unescapedCode = lang_1.NumberWrapper.parseInt(hex, 16);
            } catch (e) {
              this.error("Invalid unicode escape [\\u" + hex + "]", 0);
            }
            for (var i = 0; i < 5; i++) {
              this.advance();
            }
          } else {
            unescapedCode = unescape(this.peek);
            this.advance();
          }
          buffer.add(lang_1.StringWrapper.fromCharCode(unescapedCode));
          marker = this.index;
        } else if (this.peek == exports.$EOF) {
          this.error('Unterminated quote', 0);
        } else {
          this.advance();
        }
      }
      var last = input.substring(marker, this.index);
      this.advance();
      var unescaped = last;
      if (buffer != null) {
        buffer.add(last);
        unescaped = buffer.toString();
      }
      return newStringToken(start, unescaped);
    };
    _Scanner.prototype.error = function(message, offset) {
      var position = this.index + offset;
      throw new ScannerError("Lexer Error: " + message + " at column " + position + " in expression [" + this.input + "]");
    };
    return _Scanner;
  }());
  function isWhitespace(code) {
    return (code >= exports.$TAB && code <= exports.$SPACE) || (code == $NBSP);
  }
  function isIdentifierStart(code) {
    return ($a <= code && code <= $z) || ($A <= code && code <= $Z) || (code == $_) || (code == exports.$$);
  }
  function isIdentifier(input) {
    if (input.length == 0)
      return false;
    var scanner = new _Scanner(input);
    if (!isIdentifierStart(scanner.peek))
      return false;
    scanner.advance();
    while (scanner.peek !== exports.$EOF) {
      if (!isIdentifierPart(scanner.peek))
        return false;
      scanner.advance();
    }
    return true;
  }
  exports.isIdentifier = isIdentifier;
  function isIdentifierPart(code) {
    return ($a <= code && code <= $z) || ($A <= code && code <= $Z) || ($0 <= code && code <= $9) || (code == $_) || (code == exports.$$);
  }
  function isDigit(code) {
    return $0 <= code && code <= $9;
  }
  function isExponentStart(code) {
    return code == $e || code == $E;
  }
  function isExponentSign(code) {
    return code == exports.$MINUS || code == exports.$PLUS;
  }
  function isQuote(code) {
    return code === exports.$SQ || code === exports.$DQ || code === exports.$BT;
  }
  exports.isQuote = isQuote;
  function unescape(code) {
    switch (code) {
      case $n:
        return exports.$LF;
      case $f:
        return exports.$FF;
      case $r:
        return exports.$CR;
      case $t:
        return exports.$TAB;
      case $v:
        return exports.$VTAB;
      default:
        return code;
    }
  }
  var OPERATORS = collection_1.SetWrapper.createFromList(['+', '-', '*', '/', '%', '^', '=', '==', '!=', '===', '!==', '<', '>', '<=', '>=', '&&', '||', '&', '|', '!', '?', '#', '?.']);
  var KEYWORDS = collection_1.SetWrapper.createFromList(['var', 'let', 'null', 'undefined', 'true', 'false', 'if', 'else']);
  return module.exports;
});

$__System.registerDynamic("4f", ["11", "13", "14", "17", "30", "c", "b", "2b", "38", "31", "3b", "39", "3a", "1b", "2e", "2f", "2c", "2d", "1e", "4d", "1a", "4e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  var core_1 = $__require('11');
  var lang_1 = $__require('13');
  __export($__require('14'));
  var template_parser_1 = $__require('17');
  exports.TEMPLATE_TRANSFORMS = template_parser_1.TEMPLATE_TRANSFORMS;
  var config_1 = $__require('30');
  exports.CompilerConfig = config_1.CompilerConfig;
  exports.RenderTypes = config_1.RenderTypes;
  __export($__require('c'));
  __export($__require('b'));
  var runtime_compiler_1 = $__require('2b');
  exports.RuntimeCompiler = runtime_compiler_1.RuntimeCompiler;
  __export($__require('38'));
  __export($__require('31'));
  var view_resolver_1 = $__require('3b');
  exports.ViewResolver = view_resolver_1.ViewResolver;
  var directive_resolver_1 = $__require('39');
  exports.DirectiveResolver = directive_resolver_1.DirectiveResolver;
  var pipe_resolver_1 = $__require('3a');
  exports.PipeResolver = pipe_resolver_1.PipeResolver;
  var template_parser_2 = $__require('17');
  var html_parser_1 = $__require('1b');
  var directive_normalizer_1 = $__require('2e');
  var metadata_resolver_1 = $__require('2f');
  var style_compiler_1 = $__require('2c');
  var view_compiler_1 = $__require('2d');
  var config_2 = $__require('30');
  var runtime_compiler_2 = $__require('2b');
  var element_schema_registry_1 = $__require('1e');
  var dom_element_schema_registry_1 = $__require('4d');
  var url_resolver_2 = $__require('38');
  var parser_1 = $__require('1a');
  var lexer_1 = $__require('4e');
  var view_resolver_2 = $__require('3b');
  var directive_resolver_2 = $__require('39');
  var pipe_resolver_2 = $__require('3a');
  function _createCompilerConfig() {
    return new config_2.CompilerConfig(lang_1.assertionsEnabled(), false, true);
  }
  exports.COMPILER_PROVIDERS = [lexer_1.Lexer, parser_1.Parser, html_parser_1.HtmlParser, template_parser_2.TemplateParser, directive_normalizer_1.DirectiveNormalizer, metadata_resolver_1.CompileMetadataResolver, url_resolver_2.DEFAULT_PACKAGE_URL_PROVIDER, style_compiler_1.StyleCompiler, view_compiler_1.ViewCompiler, {
    provide: config_2.CompilerConfig,
    useFactory: _createCompilerConfig,
    deps: []
  }, runtime_compiler_2.RuntimeCompiler, {
    provide: core_1.ComponentResolver,
    useExisting: runtime_compiler_2.RuntimeCompiler
  }, dom_element_schema_registry_1.DomElementSchemaRegistry, {
    provide: element_schema_registry_1.ElementSchemaRegistry,
    useExisting: dom_element_schema_registry_1.DomElementSchemaRegistry
  }, url_resolver_2.UrlResolver, view_resolver_2.ViewResolver, directive_resolver_2.DirectiveResolver, pipe_resolver_2.PipeResolver];
  return module.exports;
});

$__System.registerDynamic("14", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var TextAst = (function() {
    function TextAst(value, ngContentIndex, sourceSpan) {
      this.value = value;
      this.ngContentIndex = ngContentIndex;
      this.sourceSpan = sourceSpan;
    }
    TextAst.prototype.visit = function(visitor, context) {
      return visitor.visitText(this, context);
    };
    return TextAst;
  }());
  exports.TextAst = TextAst;
  var BoundTextAst = (function() {
    function BoundTextAst(value, ngContentIndex, sourceSpan) {
      this.value = value;
      this.ngContentIndex = ngContentIndex;
      this.sourceSpan = sourceSpan;
    }
    BoundTextAst.prototype.visit = function(visitor, context) {
      return visitor.visitBoundText(this, context);
    };
    return BoundTextAst;
  }());
  exports.BoundTextAst = BoundTextAst;
  var AttrAst = (function() {
    function AttrAst(name, value, sourceSpan) {
      this.name = name;
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    AttrAst.prototype.visit = function(visitor, context) {
      return visitor.visitAttr(this, context);
    };
    return AttrAst;
  }());
  exports.AttrAst = AttrAst;
  var BoundElementPropertyAst = (function() {
    function BoundElementPropertyAst(name, type, securityContext, value, unit, sourceSpan) {
      this.name = name;
      this.type = type;
      this.securityContext = securityContext;
      this.value = value;
      this.unit = unit;
      this.sourceSpan = sourceSpan;
    }
    BoundElementPropertyAst.prototype.visit = function(visitor, context) {
      return visitor.visitElementProperty(this, context);
    };
    return BoundElementPropertyAst;
  }());
  exports.BoundElementPropertyAst = BoundElementPropertyAst;
  var BoundEventAst = (function() {
    function BoundEventAst(name, target, handler, sourceSpan) {
      this.name = name;
      this.target = target;
      this.handler = handler;
      this.sourceSpan = sourceSpan;
    }
    BoundEventAst.prototype.visit = function(visitor, context) {
      return visitor.visitEvent(this, context);
    };
    Object.defineProperty(BoundEventAst.prototype, "fullName", {
      get: function() {
        if (lang_1.isPresent(this.target)) {
          return this.target + ":" + this.name;
        } else {
          return this.name;
        }
      },
      enumerable: true,
      configurable: true
    });
    return BoundEventAst;
  }());
  exports.BoundEventAst = BoundEventAst;
  var ReferenceAst = (function() {
    function ReferenceAst(name, value, sourceSpan) {
      this.name = name;
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    ReferenceAst.prototype.visit = function(visitor, context) {
      return visitor.visitReference(this, context);
    };
    return ReferenceAst;
  }());
  exports.ReferenceAst = ReferenceAst;
  var VariableAst = (function() {
    function VariableAst(name, value, sourceSpan) {
      this.name = name;
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    VariableAst.prototype.visit = function(visitor, context) {
      return visitor.visitVariable(this, context);
    };
    return VariableAst;
  }());
  exports.VariableAst = VariableAst;
  var ElementAst = (function() {
    function ElementAst(name, attrs, inputs, outputs, references, directives, providers, hasViewContainer, children, ngContentIndex, sourceSpan) {
      this.name = name;
      this.attrs = attrs;
      this.inputs = inputs;
      this.outputs = outputs;
      this.references = references;
      this.directives = directives;
      this.providers = providers;
      this.hasViewContainer = hasViewContainer;
      this.children = children;
      this.ngContentIndex = ngContentIndex;
      this.sourceSpan = sourceSpan;
    }
    ElementAst.prototype.visit = function(visitor, context) {
      return visitor.visitElement(this, context);
    };
    return ElementAst;
  }());
  exports.ElementAst = ElementAst;
  var EmbeddedTemplateAst = (function() {
    function EmbeddedTemplateAst(attrs, outputs, references, variables, directives, providers, hasViewContainer, children, ngContentIndex, sourceSpan) {
      this.attrs = attrs;
      this.outputs = outputs;
      this.references = references;
      this.variables = variables;
      this.directives = directives;
      this.providers = providers;
      this.hasViewContainer = hasViewContainer;
      this.children = children;
      this.ngContentIndex = ngContentIndex;
      this.sourceSpan = sourceSpan;
    }
    EmbeddedTemplateAst.prototype.visit = function(visitor, context) {
      return visitor.visitEmbeddedTemplate(this, context);
    };
    return EmbeddedTemplateAst;
  }());
  exports.EmbeddedTemplateAst = EmbeddedTemplateAst;
  var BoundDirectivePropertyAst = (function() {
    function BoundDirectivePropertyAst(directiveName, templateName, value, sourceSpan) {
      this.directiveName = directiveName;
      this.templateName = templateName;
      this.value = value;
      this.sourceSpan = sourceSpan;
    }
    BoundDirectivePropertyAst.prototype.visit = function(visitor, context) {
      return visitor.visitDirectiveProperty(this, context);
    };
    return BoundDirectivePropertyAst;
  }());
  exports.BoundDirectivePropertyAst = BoundDirectivePropertyAst;
  var DirectiveAst = (function() {
    function DirectiveAst(directive, inputs, hostProperties, hostEvents, sourceSpan) {
      this.directive = directive;
      this.inputs = inputs;
      this.hostProperties = hostProperties;
      this.hostEvents = hostEvents;
      this.sourceSpan = sourceSpan;
    }
    DirectiveAst.prototype.visit = function(visitor, context) {
      return visitor.visitDirective(this, context);
    };
    return DirectiveAst;
  }());
  exports.DirectiveAst = DirectiveAst;
  var ProviderAst = (function() {
    function ProviderAst(token, multiProvider, eager, providers, providerType, sourceSpan) {
      this.token = token;
      this.multiProvider = multiProvider;
      this.eager = eager;
      this.providers = providers;
      this.providerType = providerType;
      this.sourceSpan = sourceSpan;
    }
    ProviderAst.prototype.visit = function(visitor, context) {
      return null;
    };
    return ProviderAst;
  }());
  exports.ProviderAst = ProviderAst;
  (function(ProviderAstType) {
    ProviderAstType[ProviderAstType["PublicService"] = 0] = "PublicService";
    ProviderAstType[ProviderAstType["PrivateService"] = 1] = "PrivateService";
    ProviderAstType[ProviderAstType["Component"] = 2] = "Component";
    ProviderAstType[ProviderAstType["Directive"] = 3] = "Directive";
    ProviderAstType[ProviderAstType["Builtin"] = 4] = "Builtin";
  })(exports.ProviderAstType || (exports.ProviderAstType = {}));
  var ProviderAstType = exports.ProviderAstType;
  var NgContentAst = (function() {
    function NgContentAst(index, ngContentIndex, sourceSpan) {
      this.index = index;
      this.ngContentIndex = ngContentIndex;
      this.sourceSpan = sourceSpan;
    }
    NgContentAst.prototype.visit = function(visitor, context) {
      return visitor.visitNgContent(this, context);
    };
    return NgContentAst;
  }());
  exports.NgContentAst = NgContentAst;
  (function(PropertyBindingType) {
    PropertyBindingType[PropertyBindingType["Property"] = 0] = "Property";
    PropertyBindingType[PropertyBindingType["Attribute"] = 1] = "Attribute";
    PropertyBindingType[PropertyBindingType["Class"] = 2] = "Class";
    PropertyBindingType[PropertyBindingType["Style"] = 3] = "Style";
  })(exports.PropertyBindingType || (exports.PropertyBindingType = {}));
  var PropertyBindingType = exports.PropertyBindingType;
  function templateVisitAll(visitor, asts, context) {
    if (context === void 0) {
      context = null;
    }
    var result = [];
    asts.forEach(function(ast) {
      var astResult = ast.visit(visitor, context);
      if (lang_1.isPresent(astResult)) {
        result.push(astResult);
      }
    });
    return result;
  }
  exports.templateVisitAll = templateVisitAll;
  return module.exports;
});

$__System.registerDynamic("1d", ["e", "13", "d", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var collection_1 = $__require('e');
    var lang_1 = $__require('13');
    var exceptions_1 = $__require('d');
    var _EMPTY_ATTR_VALUE = '';
    var _SELECTOR_REGEXP = lang_1.RegExpWrapper.create('(\\:not\\()|' + '([-\\w]+)|' + '(?:\\.([-\\w]+))|' + '(?:\\[([-\\w*]+)(?:=([^\\]]*))?\\])|' + '(\\))|' + '(\\s*,\\s*)');
    var CssSelector = (function() {
      function CssSelector() {
        this.element = null;
        this.classNames = [];
        this.attrs = [];
        this.notSelectors = [];
      }
      CssSelector.parse = function(selector) {
        var results = [];
        var _addResult = function(res, cssSel) {
          if (cssSel.notSelectors.length > 0 && lang_1.isBlank(cssSel.element) && collection_1.ListWrapper.isEmpty(cssSel.classNames) && collection_1.ListWrapper.isEmpty(cssSel.attrs)) {
            cssSel.element = "*";
          }
          res.push(cssSel);
        };
        var cssSelector = new CssSelector();
        var matcher = lang_1.RegExpWrapper.matcher(_SELECTOR_REGEXP, selector);
        var match;
        var current = cssSelector;
        var inNot = false;
        while (lang_1.isPresent(match = lang_1.RegExpMatcherWrapper.next(matcher))) {
          if (lang_1.isPresent(match[1])) {
            if (inNot) {
              throw new exceptions_1.BaseException('Nesting :not is not allowed in a selector');
            }
            inNot = true;
            current = new CssSelector();
            cssSelector.notSelectors.push(current);
          }
          if (lang_1.isPresent(match[2])) {
            current.setElement(match[2]);
          }
          if (lang_1.isPresent(match[3])) {
            current.addClassName(match[3]);
          }
          if (lang_1.isPresent(match[4])) {
            current.addAttribute(match[4], match[5]);
          }
          if (lang_1.isPresent(match[6])) {
            inNot = false;
            current = cssSelector;
          }
          if (lang_1.isPresent(match[7])) {
            if (inNot) {
              throw new exceptions_1.BaseException('Multiple selectors in :not are not supported');
            }
            _addResult(results, cssSelector);
            cssSelector = current = new CssSelector();
          }
        }
        _addResult(results, cssSelector);
        return results;
      };
      CssSelector.prototype.isElementSelector = function() {
        return lang_1.isPresent(this.element) && collection_1.ListWrapper.isEmpty(this.classNames) && collection_1.ListWrapper.isEmpty(this.attrs) && this.notSelectors.length === 0;
      };
      CssSelector.prototype.setElement = function(element) {
        if (element === void 0) {
          element = null;
        }
        this.element = element;
      };
      CssSelector.prototype.getMatchingElementTemplate = function() {
        var tagName = lang_1.isPresent(this.element) ? this.element : 'div';
        var classAttr = this.classNames.length > 0 ? " class=\"" + this.classNames.join(' ') + "\"" : '';
        var attrs = '';
        for (var i = 0; i < this.attrs.length; i += 2) {
          var attrName = this.attrs[i];
          var attrValue = this.attrs[i + 1] !== '' ? "=\"" + this.attrs[i + 1] + "\"" : '';
          attrs += " " + attrName + attrValue;
        }
        return "<" + tagName + classAttr + attrs + "></" + tagName + ">";
      };
      CssSelector.prototype.addAttribute = function(name, value) {
        if (value === void 0) {
          value = _EMPTY_ATTR_VALUE;
        }
        this.attrs.push(name);
        if (lang_1.isPresent(value)) {
          value = value.toLowerCase();
        } else {
          value = _EMPTY_ATTR_VALUE;
        }
        this.attrs.push(value);
      };
      CssSelector.prototype.addClassName = function(name) {
        this.classNames.push(name.toLowerCase());
      };
      CssSelector.prototype.toString = function() {
        var res = '';
        if (lang_1.isPresent(this.element)) {
          res += this.element;
        }
        if (lang_1.isPresent(this.classNames)) {
          for (var i = 0; i < this.classNames.length; i++) {
            res += '.' + this.classNames[i];
          }
        }
        if (lang_1.isPresent(this.attrs)) {
          for (var i = 0; i < this.attrs.length; ) {
            var attrName = this.attrs[i++];
            var attrValue = this.attrs[i++];
            res += '[' + attrName;
            if (attrValue.length > 0) {
              res += '=' + attrValue;
            }
            res += ']';
          }
        }
        this.notSelectors.forEach(function(notSelector) {
          return res += ":not(" + notSelector + ")";
        });
        return res;
      };
      return CssSelector;
    }());
    exports.CssSelector = CssSelector;
    var SelectorMatcher = (function() {
      function SelectorMatcher() {
        this._elementMap = new collection_1.Map();
        this._elementPartialMap = new collection_1.Map();
        this._classMap = new collection_1.Map();
        this._classPartialMap = new collection_1.Map();
        this._attrValueMap = new collection_1.Map();
        this._attrValuePartialMap = new collection_1.Map();
        this._listContexts = [];
      }
      SelectorMatcher.createNotMatcher = function(notSelectors) {
        var notMatcher = new SelectorMatcher();
        notMatcher.addSelectables(notSelectors, null);
        return notMatcher;
      };
      SelectorMatcher.prototype.addSelectables = function(cssSelectors, callbackCtxt) {
        var listContext = null;
        if (cssSelectors.length > 1) {
          listContext = new SelectorListContext(cssSelectors);
          this._listContexts.push(listContext);
        }
        for (var i = 0; i < cssSelectors.length; i++) {
          this._addSelectable(cssSelectors[i], callbackCtxt, listContext);
        }
      };
      SelectorMatcher.prototype._addSelectable = function(cssSelector, callbackCtxt, listContext) {
        var matcher = this;
        var element = cssSelector.element;
        var classNames = cssSelector.classNames;
        var attrs = cssSelector.attrs;
        var selectable = new SelectorContext(cssSelector, callbackCtxt, listContext);
        if (lang_1.isPresent(element)) {
          var isTerminal = attrs.length === 0 && classNames.length === 0;
          if (isTerminal) {
            this._addTerminal(matcher._elementMap, element, selectable);
          } else {
            matcher = this._addPartial(matcher._elementPartialMap, element);
          }
        }
        if (lang_1.isPresent(classNames)) {
          for (var index = 0; index < classNames.length; index++) {
            var isTerminal = attrs.length === 0 && index === classNames.length - 1;
            var className = classNames[index];
            if (isTerminal) {
              this._addTerminal(matcher._classMap, className, selectable);
            } else {
              matcher = this._addPartial(matcher._classPartialMap, className);
            }
          }
        }
        if (lang_1.isPresent(attrs)) {
          for (var index = 0; index < attrs.length; ) {
            var isTerminal = index === attrs.length - 2;
            var attrName = attrs[index++];
            var attrValue = attrs[index++];
            if (isTerminal) {
              var terminalMap = matcher._attrValueMap;
              var terminalValuesMap = terminalMap.get(attrName);
              if (lang_1.isBlank(terminalValuesMap)) {
                terminalValuesMap = new collection_1.Map();
                terminalMap.set(attrName, terminalValuesMap);
              }
              this._addTerminal(terminalValuesMap, attrValue, selectable);
            } else {
              var parttialMap = matcher._attrValuePartialMap;
              var partialValuesMap = parttialMap.get(attrName);
              if (lang_1.isBlank(partialValuesMap)) {
                partialValuesMap = new collection_1.Map();
                parttialMap.set(attrName, partialValuesMap);
              }
              matcher = this._addPartial(partialValuesMap, attrValue);
            }
          }
        }
      };
      SelectorMatcher.prototype._addTerminal = function(map, name, selectable) {
        var terminalList = map.get(name);
        if (lang_1.isBlank(terminalList)) {
          terminalList = [];
          map.set(name, terminalList);
        }
        terminalList.push(selectable);
      };
      SelectorMatcher.prototype._addPartial = function(map, name) {
        var matcher = map.get(name);
        if (lang_1.isBlank(matcher)) {
          matcher = new SelectorMatcher();
          map.set(name, matcher);
        }
        return matcher;
      };
      SelectorMatcher.prototype.match = function(cssSelector, matchedCallback) {
        var result = false;
        var element = cssSelector.element;
        var classNames = cssSelector.classNames;
        var attrs = cssSelector.attrs;
        for (var i = 0; i < this._listContexts.length; i++) {
          this._listContexts[i].alreadyMatched = false;
        }
        result = this._matchTerminal(this._elementMap, element, cssSelector, matchedCallback) || result;
        result = this._matchPartial(this._elementPartialMap, element, cssSelector, matchedCallback) || result;
        if (lang_1.isPresent(classNames)) {
          for (var index = 0; index < classNames.length; index++) {
            var className = classNames[index];
            result = this._matchTerminal(this._classMap, className, cssSelector, matchedCallback) || result;
            result = this._matchPartial(this._classPartialMap, className, cssSelector, matchedCallback) || result;
          }
        }
        if (lang_1.isPresent(attrs)) {
          for (var index = 0; index < attrs.length; ) {
            var attrName = attrs[index++];
            var attrValue = attrs[index++];
            var terminalValuesMap = this._attrValueMap.get(attrName);
            if (!lang_1.StringWrapper.equals(attrValue, _EMPTY_ATTR_VALUE)) {
              result = this._matchTerminal(terminalValuesMap, _EMPTY_ATTR_VALUE, cssSelector, matchedCallback) || result;
            }
            result = this._matchTerminal(terminalValuesMap, attrValue, cssSelector, matchedCallback) || result;
            var partialValuesMap = this._attrValuePartialMap.get(attrName);
            if (!lang_1.StringWrapper.equals(attrValue, _EMPTY_ATTR_VALUE)) {
              result = this._matchPartial(partialValuesMap, _EMPTY_ATTR_VALUE, cssSelector, matchedCallback) || result;
            }
            result = this._matchPartial(partialValuesMap, attrValue, cssSelector, matchedCallback) || result;
          }
        }
        return result;
      };
      SelectorMatcher.prototype._matchTerminal = function(map, name, cssSelector, matchedCallback) {
        if (lang_1.isBlank(map) || lang_1.isBlank(name)) {
          return false;
        }
        var selectables = map.get(name);
        var starSelectables = map.get("*");
        if (lang_1.isPresent(starSelectables)) {
          selectables = selectables.concat(starSelectables);
        }
        if (lang_1.isBlank(selectables)) {
          return false;
        }
        var selectable;
        var result = false;
        for (var index = 0; index < selectables.length; index++) {
          selectable = selectables[index];
          result = selectable.finalize(cssSelector, matchedCallback) || result;
        }
        return result;
      };
      SelectorMatcher.prototype._matchPartial = function(map, name, cssSelector, matchedCallback) {
        if (lang_1.isBlank(map) || lang_1.isBlank(name)) {
          return false;
        }
        var nestedSelector = map.get(name);
        if (lang_1.isBlank(nestedSelector)) {
          return false;
        }
        return nestedSelector.match(cssSelector, matchedCallback);
      };
      return SelectorMatcher;
    }());
    exports.SelectorMatcher = SelectorMatcher;
    var SelectorListContext = (function() {
      function SelectorListContext(selectors) {
        this.selectors = selectors;
        this.alreadyMatched = false;
      }
      return SelectorListContext;
    }());
    exports.SelectorListContext = SelectorListContext;
    var SelectorContext = (function() {
      function SelectorContext(selector, cbContext, listContext) {
        this.selector = selector;
        this.cbContext = cbContext;
        this.listContext = listContext;
        this.notSelectors = selector.notSelectors;
      }
      SelectorContext.prototype.finalize = function(cssSelector, callback) {
        var result = true;
        if (this.notSelectors.length > 0 && (lang_1.isBlank(this.listContext) || !this.listContext.alreadyMatched)) {
          var notMatcher = SelectorMatcher.createNotMatcher(this.notSelectors);
          result = !notMatcher.match(cssSelector, null);
        }
        if (result && lang_1.isPresent(callback) && (lang_1.isBlank(this.listContext) || !this.listContext.alreadyMatched)) {
          if (lang_1.isPresent(this.listContext)) {
            this.listContext.alreadyMatched = true;
          }
          callback(this.selector, this.cbContext);
        }
        return result;
      };
      return SelectorContext;
    }());
    exports.SelectorContext = SelectorContext;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("50", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var BaseWrappedException = (function(_super) {
    __extends(BaseWrappedException, _super);
    function BaseWrappedException(message) {
      _super.call(this, message);
    }
    Object.defineProperty(BaseWrappedException.prototype, "wrapperMessage", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "wrapperStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalException", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "context", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "message", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    return BaseWrappedException;
  }(Error));
  exports.BaseWrappedException = BaseWrappedException;
  return module.exports;
});

$__System.registerDynamic("e", ["13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  exports.Map = lang_1.global.Map;
  exports.Set = lang_1.global.Set;
  var createMapFromPairs = (function() {
    try {
      if (new exports.Map([[1, 2]]).size === 1) {
        return function createMapFromPairs(pairs) {
          return new exports.Map(pairs);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromPairs(pairs) {
      var map = new exports.Map();
      for (var i = 0; i < pairs.length; i++) {
        var pair = pairs[i];
        map.set(pair[0], pair[1]);
      }
      return map;
    };
  })();
  var createMapFromMap = (function() {
    try {
      if (new exports.Map(new exports.Map())) {
        return function createMapFromMap(m) {
          return new exports.Map(m);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromMap(m) {
      var map = new exports.Map();
      m.forEach(function(v, k) {
        map.set(k, v);
      });
      return map;
    };
  })();
  var _clearValues = (function() {
    if ((new exports.Map()).keys().next) {
      return function _clearValues(m) {
        var keyIterator = m.keys();
        var k;
        while (!((k = keyIterator.next()).done)) {
          m.set(k.value, null);
        }
      };
    } else {
      return function _clearValuesWithForeEach(m) {
        m.forEach(function(v, k) {
          m.set(k, null);
        });
      };
    }
  })();
  var _arrayFromMap = (function() {
    try {
      if ((new exports.Map()).values().next) {
        return function createArrayFromMap(m, getValues) {
          return getValues ? Array.from(m.values()) : Array.from(m.keys());
        };
      }
    } catch (e) {}
    return function createArrayFromMapWithForeach(m, getValues) {
      var res = ListWrapper.createFixedSize(m.size),
          i = 0;
      m.forEach(function(v, k) {
        res[i] = getValues ? v : k;
        i++;
      });
      return res;
    };
  })();
  var MapWrapper = (function() {
    function MapWrapper() {}
    MapWrapper.clone = function(m) {
      return createMapFromMap(m);
    };
    MapWrapper.createFromStringMap = function(stringMap) {
      var result = new exports.Map();
      for (var prop in stringMap) {
        result.set(prop, stringMap[prop]);
      }
      return result;
    };
    MapWrapper.toStringMap = function(m) {
      var r = {};
      m.forEach(function(v, k) {
        return r[k] = v;
      });
      return r;
    };
    MapWrapper.createFromPairs = function(pairs) {
      return createMapFromPairs(pairs);
    };
    MapWrapper.clearValues = function(m) {
      _clearValues(m);
    };
    MapWrapper.iterable = function(m) {
      return m;
    };
    MapWrapper.keys = function(m) {
      return _arrayFromMap(m, false);
    };
    MapWrapper.values = function(m) {
      return _arrayFromMap(m, true);
    };
    return MapWrapper;
  }());
  exports.MapWrapper = MapWrapper;
  var StringMapWrapper = (function() {
    function StringMapWrapper() {}
    StringMapWrapper.create = function() {
      return {};
    };
    StringMapWrapper.contains = function(map, key) {
      return map.hasOwnProperty(key);
    };
    StringMapWrapper.get = function(map, key) {
      return map.hasOwnProperty(key) ? map[key] : undefined;
    };
    StringMapWrapper.set = function(map, key, value) {
      map[key] = value;
    };
    StringMapWrapper.keys = function(map) {
      return Object.keys(map);
    };
    StringMapWrapper.values = function(map) {
      return Object.keys(map).reduce(function(r, a) {
        r.push(map[a]);
        return r;
      }, []);
    };
    StringMapWrapper.isEmpty = function(map) {
      for (var prop in map) {
        return false;
      }
      return true;
    };
    StringMapWrapper.delete = function(map, key) {
      delete map[key];
    };
    StringMapWrapper.forEach = function(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    };
    StringMapWrapper.merge = function(m1, m2) {
      var m = {};
      for (var attr in m1) {
        if (m1.hasOwnProperty(attr)) {
          m[attr] = m1[attr];
        }
      }
      for (var attr in m2) {
        if (m2.hasOwnProperty(attr)) {
          m[attr] = m2[attr];
        }
      }
      return m;
    };
    StringMapWrapper.equals = function(m1, m2) {
      var k1 = Object.keys(m1);
      var k2 = Object.keys(m2);
      if (k1.length != k2.length) {
        return false;
      }
      var key;
      for (var i = 0; i < k1.length; i++) {
        key = k1[i];
        if (m1[key] !== m2[key]) {
          return false;
        }
      }
      return true;
    };
    return StringMapWrapper;
  }());
  exports.StringMapWrapper = StringMapWrapper;
  var ListWrapper = (function() {
    function ListWrapper() {}
    ListWrapper.createFixedSize = function(size) {
      return new Array(size);
    };
    ListWrapper.createGrowableSize = function(size) {
      return new Array(size);
    };
    ListWrapper.clone = function(array) {
      return array.slice(0);
    };
    ListWrapper.forEachWithIndex = function(array, fn) {
      for (var i = 0; i < array.length; i++) {
        fn(array[i], i);
      }
    };
    ListWrapper.first = function(array) {
      if (!array)
        return null;
      return array[0];
    };
    ListWrapper.last = function(array) {
      if (!array || array.length == 0)
        return null;
      return array[array.length - 1];
    };
    ListWrapper.indexOf = function(array, value, startIndex) {
      if (startIndex === void 0) {
        startIndex = 0;
      }
      return array.indexOf(value, startIndex);
    };
    ListWrapper.contains = function(list, el) {
      return list.indexOf(el) !== -1;
    };
    ListWrapper.reversed = function(array) {
      var a = ListWrapper.clone(array);
      return a.reverse();
    };
    ListWrapper.concat = function(a, b) {
      return a.concat(b);
    };
    ListWrapper.insert = function(list, index, value) {
      list.splice(index, 0, value);
    };
    ListWrapper.removeAt = function(list, index) {
      var res = list[index];
      list.splice(index, 1);
      return res;
    };
    ListWrapper.removeAll = function(list, items) {
      for (var i = 0; i < items.length; ++i) {
        var index = list.indexOf(items[i]);
        list.splice(index, 1);
      }
    };
    ListWrapper.remove = function(list, el) {
      var index = list.indexOf(el);
      if (index > -1) {
        list.splice(index, 1);
        return true;
      }
      return false;
    };
    ListWrapper.clear = function(list) {
      list.length = 0;
    };
    ListWrapper.isEmpty = function(list) {
      return list.length == 0;
    };
    ListWrapper.fill = function(list, value, start, end) {
      if (start === void 0) {
        start = 0;
      }
      if (end === void 0) {
        end = null;
      }
      list.fill(value, start, end === null ? list.length : end);
    };
    ListWrapper.equals = function(a, b) {
      if (a.length != b.length)
        return false;
      for (var i = 0; i < a.length; ++i) {
        if (a[i] !== b[i])
          return false;
      }
      return true;
    };
    ListWrapper.slice = function(l, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return l.slice(from, to === null ? undefined : to);
    };
    ListWrapper.splice = function(l, from, length) {
      return l.splice(from, length);
    };
    ListWrapper.sort = function(l, compareFn) {
      if (lang_1.isPresent(compareFn)) {
        l.sort(compareFn);
      } else {
        l.sort();
      }
    };
    ListWrapper.toString = function(l) {
      return l.toString();
    };
    ListWrapper.toJSON = function(l) {
      return JSON.stringify(l);
    };
    ListWrapper.maximum = function(list, predicate) {
      if (list.length == 0) {
        return null;
      }
      var solution = null;
      var maxValue = -Infinity;
      for (var index = 0; index < list.length; index++) {
        var candidate = list[index];
        if (lang_1.isBlank(candidate)) {
          continue;
        }
        var candidateValue = predicate(candidate);
        if (candidateValue > maxValue) {
          solution = candidate;
          maxValue = candidateValue;
        }
      }
      return solution;
    };
    ListWrapper.flatten = function(list) {
      var target = [];
      _flattenArray(list, target);
      return target;
    };
    ListWrapper.addAll = function(list, source) {
      for (var i = 0; i < source.length; i++) {
        list.push(source[i]);
      }
    };
    return ListWrapper;
  }());
  exports.ListWrapper = ListWrapper;
  function _flattenArray(source, target) {
    if (lang_1.isPresent(source)) {
      for (var i = 0; i < source.length; i++) {
        var item = source[i];
        if (lang_1.isArray(item)) {
          _flattenArray(item, target);
        } else {
          target.push(item);
        }
      }
    }
    return target;
  }
  function isListLikeIterable(obj) {
    if (!lang_1.isJsObject(obj))
      return false;
    return lang_1.isArray(obj) || (!(obj instanceof exports.Map) && lang_1.getSymbolIterator() in obj);
  }
  exports.isListLikeIterable = isListLikeIterable;
  function areIterablesEqual(a, b, comparator) {
    var iterator1 = a[lang_1.getSymbolIterator()]();
    var iterator2 = b[lang_1.getSymbolIterator()]();
    while (true) {
      var item1 = iterator1.next();
      var item2 = iterator2.next();
      if (item1.done && item2.done)
        return true;
      if (item1.done || item2.done)
        return false;
      if (!comparator(item1.value, item2.value))
        return false;
    }
  }
  exports.areIterablesEqual = areIterablesEqual;
  function iterateListLike(obj, fn) {
    if (lang_1.isArray(obj)) {
      for (var i = 0; i < obj.length; i++) {
        fn(obj[i]);
      }
    } else {
      var iterator = obj[lang_1.getSymbolIterator()]();
      var item;
      while (!((item = iterator.next()).done)) {
        fn(item.value);
      }
    }
  }
  exports.iterateListLike = iterateListLike;
  var createSetFromList = (function() {
    var test = new exports.Set([1, 2, 3]);
    if (test.size === 3) {
      return function createSetFromList(lst) {
        return new exports.Set(lst);
      };
    } else {
      return function createSetAndPopulateFromList(lst) {
        var res = new exports.Set(lst);
        if (res.size !== lst.length) {
          for (var i = 0; i < lst.length; i++) {
            res.add(lst[i]);
          }
        }
        return res;
      };
    }
  })();
  var SetWrapper = (function() {
    function SetWrapper() {}
    SetWrapper.createFromList = function(lst) {
      return createSetFromList(lst);
    };
    SetWrapper.has = function(s, key) {
      return s.has(key);
    };
    SetWrapper.delete = function(m, k) {
      m.delete(k);
    };
    return SetWrapper;
  }());
  exports.SetWrapper = SetWrapper;
  return module.exports;
});

$__System.registerDynamic("51", ["13", "50", "e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('13');
  var base_wrapped_exception_1 = $__require('50');
  var collection_1 = $__require('e');
  var _ArrayLogger = (function() {
    function _ArrayLogger() {
      this.res = [];
    }
    _ArrayLogger.prototype.log = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logError = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroup = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroupEnd = function() {};
    ;
    return _ArrayLogger;
  }());
  var ExceptionHandler = (function() {
    function ExceptionHandler(_logger, _rethrowException) {
      if (_rethrowException === void 0) {
        _rethrowException = true;
      }
      this._logger = _logger;
      this._rethrowException = _rethrowException;
    }
    ExceptionHandler.exceptionToString = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var l = new _ArrayLogger();
      var e = new ExceptionHandler(l, false);
      e.call(exception, stackTrace, reason);
      return l.res.join("\n");
    };
    ExceptionHandler.prototype.call = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var originalException = this._findOriginalException(exception);
      var originalStack = this._findOriginalStack(exception);
      var context = this._findContext(exception);
      this._logger.logGroup("EXCEPTION: " + this._extractMessage(exception));
      if (lang_1.isPresent(stackTrace) && lang_1.isBlank(originalStack)) {
        this._logger.logError("STACKTRACE:");
        this._logger.logError(this._longStackTrace(stackTrace));
      }
      if (lang_1.isPresent(reason)) {
        this._logger.logError("REASON: " + reason);
      }
      if (lang_1.isPresent(originalException)) {
        this._logger.logError("ORIGINAL EXCEPTION: " + this._extractMessage(originalException));
      }
      if (lang_1.isPresent(originalStack)) {
        this._logger.logError("ORIGINAL STACKTRACE:");
        this._logger.logError(this._longStackTrace(originalStack));
      }
      if (lang_1.isPresent(context)) {
        this._logger.logError("ERROR CONTEXT:");
        this._logger.logError(context);
      }
      this._logger.logGroupEnd();
      if (this._rethrowException)
        throw exception;
    };
    ExceptionHandler.prototype._extractMessage = function(exception) {
      return exception instanceof base_wrapped_exception_1.BaseWrappedException ? exception.wrapperMessage : exception.toString();
    };
    ExceptionHandler.prototype._longStackTrace = function(stackTrace) {
      return collection_1.isListLikeIterable(stackTrace) ? stackTrace.join("\n\n-----async gap-----\n") : stackTrace.toString();
    };
    ExceptionHandler.prototype._findContext = function(exception) {
      try {
        if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
          return null;
        return lang_1.isPresent(exception.context) ? exception.context : this._findContext(exception.originalException);
      } catch (e) {
        return null;
      }
    };
    ExceptionHandler.prototype._findOriginalException = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception.originalException;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
      }
      return e;
    };
    ExceptionHandler.prototype._findOriginalStack = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception;
      var stack = exception.originalStack;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
        if (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
          stack = e.originalStack;
        }
      }
      return stack;
    };
    return ExceptionHandler;
  }());
  exports.ExceptionHandler = ExceptionHandler;
  return module.exports;
});

$__System.registerDynamic("d", ["50", "51"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var base_wrapped_exception_1 = $__require('50');
  var exception_handler_1 = $__require('51');
  var exception_handler_2 = $__require('51');
  exports.ExceptionHandler = exception_handler_2.ExceptionHandler;
  var BaseException = (function(_super) {
    __extends(BaseException, _super);
    function BaseException(message) {
      if (message === void 0) {
        message = "--";
      }
      _super.call(this, message);
      this.message = message;
      this.stack = (new Error(message)).stack;
    }
    BaseException.prototype.toString = function() {
      return this.message;
    };
    return BaseException;
  }(Error));
  exports.BaseException = BaseException;
  var WrappedException = (function(_super) {
    __extends(WrappedException, _super);
    function WrappedException(_wrapperMessage, _originalException, _originalStack, _context) {
      _super.call(this, _wrapperMessage);
      this._wrapperMessage = _wrapperMessage;
      this._originalException = _originalException;
      this._originalStack = _originalStack;
      this._context = _context;
      this._wrapperStack = (new Error(_wrapperMessage)).stack;
    }
    Object.defineProperty(WrappedException.prototype, "wrapperMessage", {
      get: function() {
        return this._wrapperMessage;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "wrapperStack", {
      get: function() {
        return this._wrapperStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalException", {
      get: function() {
        return this._originalException;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalStack", {
      get: function() {
        return this._originalStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "context", {
      get: function() {
        return this._context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "message", {
      get: function() {
        return exception_handler_1.ExceptionHandler.exceptionToString(this);
      },
      enumerable: true,
      configurable: true
    });
    WrappedException.prototype.toString = function() {
      return this.message;
    };
    return WrappedException;
  }(base_wrapped_exception_1.BaseWrappedException));
  exports.WrappedException = WrappedException;
  function makeTypeError(message) {
    return new TypeError(message);
  }
  exports.makeTypeError = makeTypeError;
  function unimplemented() {
    throw new BaseException('unimplemented');
  }
  exports.unimplemented = unimplemented;
  return module.exports;
});

$__System.registerDynamic("13", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var globalScope;
  if (typeof window === 'undefined') {
    if (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) {
      globalScope = self;
    } else {
      globalScope = global;
    }
  } else {
    globalScope = window;
  }
  function scheduleMicroTask(fn) {
    Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
  }
  exports.scheduleMicroTask = scheduleMicroTask;
  exports.IS_DART = false;
  var _global = globalScope;
  exports.global = _global;
  exports.Type = Function;
  function getTypeNameForDebugging(type) {
    if (type['name']) {
      return type['name'];
    }
    return typeof type;
  }
  exports.getTypeNameForDebugging = getTypeNameForDebugging;
  exports.Math = _global.Math;
  exports.Date = _global.Date;
  var _devMode = true;
  var _modeLocked = false;
  function lockMode() {
    _modeLocked = true;
  }
  exports.lockMode = lockMode;
  function enableProdMode() {
    if (_modeLocked) {
      throw 'Cannot enable prod mode after platform setup.';
    }
    _devMode = false;
  }
  exports.enableProdMode = enableProdMode;
  function assertionsEnabled() {
    return _devMode;
  }
  exports.assertionsEnabled = assertionsEnabled;
  _global.assert = function assert(condition) {};
  function isPresent(obj) {
    return obj !== undefined && obj !== null;
  }
  exports.isPresent = isPresent;
  function isBlank(obj) {
    return obj === undefined || obj === null;
  }
  exports.isBlank = isBlank;
  function isBoolean(obj) {
    return typeof obj === "boolean";
  }
  exports.isBoolean = isBoolean;
  function isNumber(obj) {
    return typeof obj === "number";
  }
  exports.isNumber = isNumber;
  function isString(obj) {
    return typeof obj === "string";
  }
  exports.isString = isString;
  function isFunction(obj) {
    return typeof obj === "function";
  }
  exports.isFunction = isFunction;
  function isType(obj) {
    return isFunction(obj);
  }
  exports.isType = isType;
  function isStringMap(obj) {
    return typeof obj === 'object' && obj !== null;
  }
  exports.isStringMap = isStringMap;
  var STRING_MAP_PROTO = Object.getPrototypeOf({});
  function isStrictStringMap(obj) {
    return isStringMap(obj) && Object.getPrototypeOf(obj) === STRING_MAP_PROTO;
  }
  exports.isStrictStringMap = isStrictStringMap;
  function isPromise(obj) {
    return obj instanceof _global.Promise;
  }
  exports.isPromise = isPromise;
  function isArray(obj) {
    return Array.isArray(obj);
  }
  exports.isArray = isArray;
  function isDate(obj) {
    return obj instanceof exports.Date && !isNaN(obj.valueOf());
  }
  exports.isDate = isDate;
  function noop() {}
  exports.noop = noop;
  function stringify(token) {
    if (typeof token === 'string') {
      return token;
    }
    if (token === undefined || token === null) {
      return '' + token;
    }
    if (token.name) {
      return token.name;
    }
    if (token.overriddenName) {
      return token.overriddenName;
    }
    var res = token.toString();
    var newLineIndex = res.indexOf("\n");
    return (newLineIndex === -1) ? res : res.substring(0, newLineIndex);
  }
  exports.stringify = stringify;
  function serializeEnum(val) {
    return val;
  }
  exports.serializeEnum = serializeEnum;
  function deserializeEnum(val, values) {
    return val;
  }
  exports.deserializeEnum = deserializeEnum;
  function resolveEnumToken(enumValue, val) {
    return enumValue[val];
  }
  exports.resolveEnumToken = resolveEnumToken;
  var StringWrapper = (function() {
    function StringWrapper() {}
    StringWrapper.fromCharCode = function(code) {
      return String.fromCharCode(code);
    };
    StringWrapper.charCodeAt = function(s, index) {
      return s.charCodeAt(index);
    };
    StringWrapper.split = function(s, regExp) {
      return s.split(regExp);
    };
    StringWrapper.equals = function(s, s2) {
      return s === s2;
    };
    StringWrapper.stripLeft = function(s, charVal) {
      if (s && s.length) {
        var pos = 0;
        for (var i = 0; i < s.length; i++) {
          if (s[i] != charVal)
            break;
          pos++;
        }
        s = s.substring(pos);
      }
      return s;
    };
    StringWrapper.stripRight = function(s, charVal) {
      if (s && s.length) {
        var pos = s.length;
        for (var i = s.length - 1; i >= 0; i--) {
          if (s[i] != charVal)
            break;
          pos--;
        }
        s = s.substring(0, pos);
      }
      return s;
    };
    StringWrapper.replace = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.replaceAll = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.slice = function(s, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return s.slice(from, to === null ? undefined : to);
    };
    StringWrapper.replaceAllMapped = function(s, from, cb) {
      return s.replace(from, function() {
        var matches = [];
        for (var _i = 0; _i < arguments.length; _i++) {
          matches[_i - 0] = arguments[_i];
        }
        matches.splice(-2, 2);
        return cb(matches);
      });
    };
    StringWrapper.contains = function(s, substr) {
      return s.indexOf(substr) != -1;
    };
    StringWrapper.compare = function(a, b) {
      if (a < b) {
        return -1;
      } else if (a > b) {
        return 1;
      } else {
        return 0;
      }
    };
    return StringWrapper;
  }());
  exports.StringWrapper = StringWrapper;
  var StringJoiner = (function() {
    function StringJoiner(parts) {
      if (parts === void 0) {
        parts = [];
      }
      this.parts = parts;
    }
    StringJoiner.prototype.add = function(part) {
      this.parts.push(part);
    };
    StringJoiner.prototype.toString = function() {
      return this.parts.join("");
    };
    return StringJoiner;
  }());
  exports.StringJoiner = StringJoiner;
  var NumberParseError = (function(_super) {
    __extends(NumberParseError, _super);
    function NumberParseError(message) {
      _super.call(this);
      this.message = message;
    }
    NumberParseError.prototype.toString = function() {
      return this.message;
    };
    return NumberParseError;
  }(Error));
  exports.NumberParseError = NumberParseError;
  var NumberWrapper = (function() {
    function NumberWrapper() {}
    NumberWrapper.toFixed = function(n, fractionDigits) {
      return n.toFixed(fractionDigits);
    };
    NumberWrapper.equal = function(a, b) {
      return a === b;
    };
    NumberWrapper.parseIntAutoRadix = function(text) {
      var result = parseInt(text);
      if (isNaN(result)) {
        throw new NumberParseError("Invalid integer literal when parsing " + text);
      }
      return result;
    };
    NumberWrapper.parseInt = function(text, radix) {
      if (radix == 10) {
        if (/^(\-|\+)?[0-9]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else if (radix == 16) {
        if (/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else {
        var result = parseInt(text, radix);
        if (!isNaN(result)) {
          return result;
        }
      }
      throw new NumberParseError("Invalid integer literal when parsing " + text + " in base " + radix);
    };
    NumberWrapper.parseFloat = function(text) {
      return parseFloat(text);
    };
    Object.defineProperty(NumberWrapper, "NaN", {
      get: function() {
        return NaN;
      },
      enumerable: true,
      configurable: true
    });
    NumberWrapper.isNaN = function(value) {
      return isNaN(value);
    };
    NumberWrapper.isInteger = function(value) {
      return Number.isInteger(value);
    };
    return NumberWrapper;
  }());
  exports.NumberWrapper = NumberWrapper;
  exports.RegExp = _global.RegExp;
  var RegExpWrapper = (function() {
    function RegExpWrapper() {}
    RegExpWrapper.create = function(regExpStr, flags) {
      if (flags === void 0) {
        flags = '';
      }
      flags = flags.replace(/g/g, '');
      return new _global.RegExp(regExpStr, flags + 'g');
    };
    RegExpWrapper.firstMatch = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.exec(input);
    };
    RegExpWrapper.test = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.test(input);
    };
    RegExpWrapper.matcher = function(regExp, input) {
      regExp.lastIndex = 0;
      return {
        re: regExp,
        input: input
      };
    };
    RegExpWrapper.replaceAll = function(regExp, input, replace) {
      var c = regExp.exec(input);
      var res = '';
      regExp.lastIndex = 0;
      var prev = 0;
      while (c) {
        res += input.substring(prev, c.index);
        res += replace(c);
        prev = c.index + c[0].length;
        regExp.lastIndex = prev;
        c = regExp.exec(input);
      }
      res += input.substring(prev);
      return res;
    };
    return RegExpWrapper;
  }());
  exports.RegExpWrapper = RegExpWrapper;
  var RegExpMatcherWrapper = (function() {
    function RegExpMatcherWrapper() {}
    RegExpMatcherWrapper.next = function(matcher) {
      return matcher.re.exec(matcher.input);
    };
    return RegExpMatcherWrapper;
  }());
  exports.RegExpMatcherWrapper = RegExpMatcherWrapper;
  var FunctionWrapper = (function() {
    function FunctionWrapper() {}
    FunctionWrapper.apply = function(fn, posArgs) {
      return fn.apply(null, posArgs);
    };
    return FunctionWrapper;
  }());
  exports.FunctionWrapper = FunctionWrapper;
  function looseIdentical(a, b) {
    return a === b || typeof a === "number" && typeof b === "number" && isNaN(a) && isNaN(b);
  }
  exports.looseIdentical = looseIdentical;
  function getMapKey(value) {
    return value;
  }
  exports.getMapKey = getMapKey;
  function normalizeBlank(obj) {
    return isBlank(obj) ? null : obj;
  }
  exports.normalizeBlank = normalizeBlank;
  function normalizeBool(obj) {
    return isBlank(obj) ? false : obj;
  }
  exports.normalizeBool = normalizeBool;
  function isJsObject(o) {
    return o !== null && (typeof o === "function" || typeof o === "object");
  }
  exports.isJsObject = isJsObject;
  function print(obj) {
    console.log(obj);
  }
  exports.print = print;
  function warn(obj) {
    console.warn(obj);
  }
  exports.warn = warn;
  var Json = (function() {
    function Json() {}
    Json.parse = function(s) {
      return _global.JSON.parse(s);
    };
    Json.stringify = function(data) {
      return _global.JSON.stringify(data, null, 2);
    };
    return Json;
  }());
  exports.Json = Json;
  var DateWrapper = (function() {
    function DateWrapper() {}
    DateWrapper.create = function(year, month, day, hour, minutes, seconds, milliseconds) {
      if (month === void 0) {
        month = 1;
      }
      if (day === void 0) {
        day = 1;
      }
      if (hour === void 0) {
        hour = 0;
      }
      if (minutes === void 0) {
        minutes = 0;
      }
      if (seconds === void 0) {
        seconds = 0;
      }
      if (milliseconds === void 0) {
        milliseconds = 0;
      }
      return new exports.Date(year, month - 1, day, hour, minutes, seconds, milliseconds);
    };
    DateWrapper.fromISOString = function(str) {
      return new exports.Date(str);
    };
    DateWrapper.fromMillis = function(ms) {
      return new exports.Date(ms);
    };
    DateWrapper.toMillis = function(date) {
      return date.getTime();
    };
    DateWrapper.now = function() {
      return new exports.Date();
    };
    DateWrapper.toJson = function(date) {
      return date.toJSON();
    };
    return DateWrapper;
  }());
  exports.DateWrapper = DateWrapper;
  function setValueOnPath(global, path, value) {
    var parts = path.split('.');
    var obj = global;
    while (parts.length > 1) {
      var name = parts.shift();
      if (obj.hasOwnProperty(name) && isPresent(obj[name])) {
        obj = obj[name];
      } else {
        obj = obj[name] = {};
      }
    }
    if (obj === undefined || obj === null) {
      obj = {};
    }
    obj[parts.shift()] = value;
  }
  exports.setValueOnPath = setValueOnPath;
  var _symbolIterator = null;
  function getSymbolIterator() {
    if (isBlank(_symbolIterator)) {
      if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
        _symbolIterator = Symbol.iterator;
      } else {
        var keys = Object.getOwnPropertyNames(Map.prototype);
        for (var i = 0; i < keys.length; ++i) {
          var key = keys[i];
          if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
            _symbolIterator = key;
          }
        }
      }
    }
    return _symbolIterator;
  }
  exports.getSymbolIterator = getSymbolIterator;
  function evalExpression(sourceUrl, expr, declarations, vars) {
    var fnBody = declarations + "\nreturn " + expr + "\n//# sourceURL=" + sourceUrl;
    var fnArgNames = [];
    var fnArgValues = [];
    for (var argName in vars) {
      fnArgNames.push(argName);
      fnArgValues.push(vars[argName]);
    }
    return new (Function.bind.apply(Function, [void 0].concat(fnArgNames.concat(fnBody))))().apply(void 0, fnArgValues);
  }
  exports.evalExpression = evalExpression;
  function isPrimitive(obj) {
    return !isJsObject(obj);
  }
  exports.isPrimitive = isPrimitive;
  function hasConstructor(value, type) {
    return value.constructor === type;
  }
  exports.hasConstructor = hasConstructor;
  function bitWiseOr(values) {
    return values.reduce(function(a, b) {
      return a | b;
    });
  }
  exports.bitWiseOr = bitWiseOr;
  function bitWiseAnd(values) {
    return values.reduce(function(a, b) {
      return a & b;
    });
  }
  exports.bitWiseAnd = bitWiseAnd;
  function escape(s) {
    return _global.encodeURI(s);
  }
  exports.escape = escape;
  return module.exports;
});

$__System.registerDynamic("52", ["d", "13"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var exceptions_1 = $__require('d');
  var lang_1 = $__require('13');
  var _ASSET_URL_RE = /asset:([^\/]+)\/([^\/]+)\/(.+)/g;
  var ImportGenerator = (function() {
    function ImportGenerator() {}
    ImportGenerator.parseAssetUrl = function(url) {
      return AssetUrl.parse(url);
    };
    return ImportGenerator;
  }());
  exports.ImportGenerator = ImportGenerator;
  var AssetUrl = (function() {
    function AssetUrl(packageName, firstLevelDir, modulePath) {
      this.packageName = packageName;
      this.firstLevelDir = firstLevelDir;
      this.modulePath = modulePath;
    }
    AssetUrl.parse = function(url, allowNonMatching) {
      if (allowNonMatching === void 0) {
        allowNonMatching = true;
      }
      var match = lang_1.RegExpWrapper.firstMatch(_ASSET_URL_RE, url);
      if (lang_1.isPresent(match)) {
        return new AssetUrl(match[1], match[2], match[3]);
      }
      if (allowNonMatching) {
        return null;
      }
      throw new exceptions_1.BaseException("Url " + url + " is not a valid asset: url");
    };
    return AssetUrl;
  }());
  exports.AssetUrl = AssetUrl;
  return module.exports;
});

$__System.registerDynamic("53", ["1d", "52"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var selector = $__require('1d');
  var pathUtil = $__require('52');
  var __compiler_private__;
  (function(__compiler_private__) {
    __compiler_private__.SelectorMatcher = selector.SelectorMatcher;
    __compiler_private__.CssSelector = selector.CssSelector;
    __compiler_private__.AssetUrl = pathUtil.AssetUrl;
    __compiler_private__.ImportGenerator = pathUtil.ImportGenerator;
  })(__compiler_private__ = exports.__compiler_private__ || (exports.__compiler_private__ = {}));
  return module.exports;
});

$__System.registerDynamic("54", ["1e", "4f", "14", "53"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  var element_schema_registry_1 = $__require('1e');
  exports.ElementSchemaRegistry = element_schema_registry_1.ElementSchemaRegistry;
  var compiler_1 = $__require('4f');
  exports.COMPILER_PROVIDERS = compiler_1.COMPILER_PROVIDERS;
  exports.TEMPLATE_TRANSFORMS = compiler_1.TEMPLATE_TRANSFORMS;
  exports.CompilerConfig = compiler_1.CompilerConfig;
  exports.RenderTypes = compiler_1.RenderTypes;
  exports.UrlResolver = compiler_1.UrlResolver;
  exports.DEFAULT_PACKAGE_URL_PROVIDER = compiler_1.DEFAULT_PACKAGE_URL_PROVIDER;
  exports.createOfflineCompileUrlResolver = compiler_1.createOfflineCompileUrlResolver;
  exports.XHR = compiler_1.XHR;
  exports.ViewResolver = compiler_1.ViewResolver;
  exports.DirectiveResolver = compiler_1.DirectiveResolver;
  exports.PipeResolver = compiler_1.PipeResolver;
  exports.SourceModule = compiler_1.SourceModule;
  exports.NormalizedComponentWithViewDirectives = compiler_1.NormalizedComponentWithViewDirectives;
  exports.OfflineCompiler = compiler_1.OfflineCompiler;
  exports.CompileMetadataWithIdentifier = compiler_1.CompileMetadataWithIdentifier;
  exports.CompileMetadataWithType = compiler_1.CompileMetadataWithType;
  exports.CompileIdentifierMetadata = compiler_1.CompileIdentifierMetadata;
  exports.CompileDiDependencyMetadata = compiler_1.CompileDiDependencyMetadata;
  exports.CompileProviderMetadata = compiler_1.CompileProviderMetadata;
  exports.CompileFactoryMetadata = compiler_1.CompileFactoryMetadata;
  exports.CompileTokenMetadata = compiler_1.CompileTokenMetadata;
  exports.CompileTypeMetadata = compiler_1.CompileTypeMetadata;
  exports.CompileQueryMetadata = compiler_1.CompileQueryMetadata;
  exports.CompileTemplateMetadata = compiler_1.CompileTemplateMetadata;
  exports.CompileDirectiveMetadata = compiler_1.CompileDirectiveMetadata;
  exports.CompilePipeMetadata = compiler_1.CompilePipeMetadata;
  __export($__require('14'));
  __export($__require('53'));
  return module.exports;
});

$__System.registerDynamic("55", ["54"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('54'));
  return module.exports;
});

$__System.registerDynamic("a", ["55"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('55');
  return module.exports;
});

$__System.registerDynamic("9", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var PromiseCompleter = (function() {
    function PromiseCompleter() {
      var _this = this;
      this.promise = new Promise(function(res, rej) {
        _this.resolve = res;
        _this.reject = rej;
      });
    }
    return PromiseCompleter;
  }());
  exports.PromiseCompleter = PromiseCompleter;
  var PromiseWrapper = (function() {
    function PromiseWrapper() {}
    PromiseWrapper.resolve = function(obj) {
      return Promise.resolve(obj);
    };
    PromiseWrapper.reject = function(obj, _) {
      return Promise.reject(obj);
    };
    PromiseWrapper.catchError = function(promise, onError) {
      return promise.catch(onError);
    };
    PromiseWrapper.all = function(promises) {
      if (promises.length == 0)
        return Promise.resolve([]);
      return Promise.all(promises);
    };
    PromiseWrapper.then = function(promise, success, rejection) {
      return promise.then(success, rejection);
    };
    PromiseWrapper.wrap = function(computation) {
      return new Promise(function(res, rej) {
        try {
          res(computation());
        } catch (e) {
          rej(e);
        }
      });
    };
    PromiseWrapper.scheduleMicrotask = function(computation) {
      PromiseWrapper.then(PromiseWrapper.resolve(null), computation, function(_) {});
    };
    PromiseWrapper.isPromise = function(obj) {
      return obj instanceof Promise;
    };
    PromiseWrapper.completer = function() {
      return new PromiseCompleter();
    };
    return PromiseWrapper;
  }());
  exports.PromiseWrapper = PromiseWrapper;
  return module.exports;
});

$__System.registerDynamic("5", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var globalScope;
  if (typeof window === 'undefined') {
    if (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) {
      globalScope = self;
    } else {
      globalScope = global;
    }
  } else {
    globalScope = window;
  }
  function scheduleMicroTask(fn) {
    Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
  }
  exports.scheduleMicroTask = scheduleMicroTask;
  exports.IS_DART = false;
  var _global = globalScope;
  exports.global = _global;
  exports.Type = Function;
  function getTypeNameForDebugging(type) {
    if (type['name']) {
      return type['name'];
    }
    return typeof type;
  }
  exports.getTypeNameForDebugging = getTypeNameForDebugging;
  exports.Math = _global.Math;
  exports.Date = _global.Date;
  var _devMode = true;
  var _modeLocked = false;
  function lockMode() {
    _modeLocked = true;
  }
  exports.lockMode = lockMode;
  function enableProdMode() {
    if (_modeLocked) {
      throw 'Cannot enable prod mode after platform setup.';
    }
    _devMode = false;
  }
  exports.enableProdMode = enableProdMode;
  function assertionsEnabled() {
    return _devMode;
  }
  exports.assertionsEnabled = assertionsEnabled;
  _global.assert = function assert(condition) {};
  function isPresent(obj) {
    return obj !== undefined && obj !== null;
  }
  exports.isPresent = isPresent;
  function isBlank(obj) {
    return obj === undefined || obj === null;
  }
  exports.isBlank = isBlank;
  function isBoolean(obj) {
    return typeof obj === "boolean";
  }
  exports.isBoolean = isBoolean;
  function isNumber(obj) {
    return typeof obj === "number";
  }
  exports.isNumber = isNumber;
  function isString(obj) {
    return typeof obj === "string";
  }
  exports.isString = isString;
  function isFunction(obj) {
    return typeof obj === "function";
  }
  exports.isFunction = isFunction;
  function isType(obj) {
    return isFunction(obj);
  }
  exports.isType = isType;
  function isStringMap(obj) {
    return typeof obj === 'object' && obj !== null;
  }
  exports.isStringMap = isStringMap;
  var STRING_MAP_PROTO = Object.getPrototypeOf({});
  function isStrictStringMap(obj) {
    return isStringMap(obj) && Object.getPrototypeOf(obj) === STRING_MAP_PROTO;
  }
  exports.isStrictStringMap = isStrictStringMap;
  function isPromise(obj) {
    return obj instanceof _global.Promise;
  }
  exports.isPromise = isPromise;
  function isArray(obj) {
    return Array.isArray(obj);
  }
  exports.isArray = isArray;
  function isDate(obj) {
    return obj instanceof exports.Date && !isNaN(obj.valueOf());
  }
  exports.isDate = isDate;
  function noop() {}
  exports.noop = noop;
  function stringify(token) {
    if (typeof token === 'string') {
      return token;
    }
    if (token === undefined || token === null) {
      return '' + token;
    }
    if (token.name) {
      return token.name;
    }
    if (token.overriddenName) {
      return token.overriddenName;
    }
    var res = token.toString();
    var newLineIndex = res.indexOf("\n");
    return (newLineIndex === -1) ? res : res.substring(0, newLineIndex);
  }
  exports.stringify = stringify;
  function serializeEnum(val) {
    return val;
  }
  exports.serializeEnum = serializeEnum;
  function deserializeEnum(val, values) {
    return val;
  }
  exports.deserializeEnum = deserializeEnum;
  function resolveEnumToken(enumValue, val) {
    return enumValue[val];
  }
  exports.resolveEnumToken = resolveEnumToken;
  var StringWrapper = (function() {
    function StringWrapper() {}
    StringWrapper.fromCharCode = function(code) {
      return String.fromCharCode(code);
    };
    StringWrapper.charCodeAt = function(s, index) {
      return s.charCodeAt(index);
    };
    StringWrapper.split = function(s, regExp) {
      return s.split(regExp);
    };
    StringWrapper.equals = function(s, s2) {
      return s === s2;
    };
    StringWrapper.stripLeft = function(s, charVal) {
      if (s && s.length) {
        var pos = 0;
        for (var i = 0; i < s.length; i++) {
          if (s[i] != charVal)
            break;
          pos++;
        }
        s = s.substring(pos);
      }
      return s;
    };
    StringWrapper.stripRight = function(s, charVal) {
      if (s && s.length) {
        var pos = s.length;
        for (var i = s.length - 1; i >= 0; i--) {
          if (s[i] != charVal)
            break;
          pos--;
        }
        s = s.substring(0, pos);
      }
      return s;
    };
    StringWrapper.replace = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.replaceAll = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.slice = function(s, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return s.slice(from, to === null ? undefined : to);
    };
    StringWrapper.replaceAllMapped = function(s, from, cb) {
      return s.replace(from, function() {
        var matches = [];
        for (var _i = 0; _i < arguments.length; _i++) {
          matches[_i - 0] = arguments[_i];
        }
        matches.splice(-2, 2);
        return cb(matches);
      });
    };
    StringWrapper.contains = function(s, substr) {
      return s.indexOf(substr) != -1;
    };
    StringWrapper.compare = function(a, b) {
      if (a < b) {
        return -1;
      } else if (a > b) {
        return 1;
      } else {
        return 0;
      }
    };
    return StringWrapper;
  }());
  exports.StringWrapper = StringWrapper;
  var StringJoiner = (function() {
    function StringJoiner(parts) {
      if (parts === void 0) {
        parts = [];
      }
      this.parts = parts;
    }
    StringJoiner.prototype.add = function(part) {
      this.parts.push(part);
    };
    StringJoiner.prototype.toString = function() {
      return this.parts.join("");
    };
    return StringJoiner;
  }());
  exports.StringJoiner = StringJoiner;
  var NumberParseError = (function(_super) {
    __extends(NumberParseError, _super);
    function NumberParseError(message) {
      _super.call(this);
      this.message = message;
    }
    NumberParseError.prototype.toString = function() {
      return this.message;
    };
    return NumberParseError;
  }(Error));
  exports.NumberParseError = NumberParseError;
  var NumberWrapper = (function() {
    function NumberWrapper() {}
    NumberWrapper.toFixed = function(n, fractionDigits) {
      return n.toFixed(fractionDigits);
    };
    NumberWrapper.equal = function(a, b) {
      return a === b;
    };
    NumberWrapper.parseIntAutoRadix = function(text) {
      var result = parseInt(text);
      if (isNaN(result)) {
        throw new NumberParseError("Invalid integer literal when parsing " + text);
      }
      return result;
    };
    NumberWrapper.parseInt = function(text, radix) {
      if (radix == 10) {
        if (/^(\-|\+)?[0-9]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else if (radix == 16) {
        if (/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else {
        var result = parseInt(text, radix);
        if (!isNaN(result)) {
          return result;
        }
      }
      throw new NumberParseError("Invalid integer literal when parsing " + text + " in base " + radix);
    };
    NumberWrapper.parseFloat = function(text) {
      return parseFloat(text);
    };
    Object.defineProperty(NumberWrapper, "NaN", {
      get: function() {
        return NaN;
      },
      enumerable: true,
      configurable: true
    });
    NumberWrapper.isNaN = function(value) {
      return isNaN(value);
    };
    NumberWrapper.isInteger = function(value) {
      return Number.isInteger(value);
    };
    return NumberWrapper;
  }());
  exports.NumberWrapper = NumberWrapper;
  exports.RegExp = _global.RegExp;
  var RegExpWrapper = (function() {
    function RegExpWrapper() {}
    RegExpWrapper.create = function(regExpStr, flags) {
      if (flags === void 0) {
        flags = '';
      }
      flags = flags.replace(/g/g, '');
      return new _global.RegExp(regExpStr, flags + 'g');
    };
    RegExpWrapper.firstMatch = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.exec(input);
    };
    RegExpWrapper.test = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.test(input);
    };
    RegExpWrapper.matcher = function(regExp, input) {
      regExp.lastIndex = 0;
      return {
        re: regExp,
        input: input
      };
    };
    RegExpWrapper.replaceAll = function(regExp, input, replace) {
      var c = regExp.exec(input);
      var res = '';
      regExp.lastIndex = 0;
      var prev = 0;
      while (c) {
        res += input.substring(prev, c.index);
        res += replace(c);
        prev = c.index + c[0].length;
        regExp.lastIndex = prev;
        c = regExp.exec(input);
      }
      res += input.substring(prev);
      return res;
    };
    return RegExpWrapper;
  }());
  exports.RegExpWrapper = RegExpWrapper;
  var RegExpMatcherWrapper = (function() {
    function RegExpMatcherWrapper() {}
    RegExpMatcherWrapper.next = function(matcher) {
      return matcher.re.exec(matcher.input);
    };
    return RegExpMatcherWrapper;
  }());
  exports.RegExpMatcherWrapper = RegExpMatcherWrapper;
  var FunctionWrapper = (function() {
    function FunctionWrapper() {}
    FunctionWrapper.apply = function(fn, posArgs) {
      return fn.apply(null, posArgs);
    };
    return FunctionWrapper;
  }());
  exports.FunctionWrapper = FunctionWrapper;
  function looseIdentical(a, b) {
    return a === b || typeof a === "number" && typeof b === "number" && isNaN(a) && isNaN(b);
  }
  exports.looseIdentical = looseIdentical;
  function getMapKey(value) {
    return value;
  }
  exports.getMapKey = getMapKey;
  function normalizeBlank(obj) {
    return isBlank(obj) ? null : obj;
  }
  exports.normalizeBlank = normalizeBlank;
  function normalizeBool(obj) {
    return isBlank(obj) ? false : obj;
  }
  exports.normalizeBool = normalizeBool;
  function isJsObject(o) {
    return o !== null && (typeof o === "function" || typeof o === "object");
  }
  exports.isJsObject = isJsObject;
  function print(obj) {
    console.log(obj);
  }
  exports.print = print;
  function warn(obj) {
    console.warn(obj);
  }
  exports.warn = warn;
  var Json = (function() {
    function Json() {}
    Json.parse = function(s) {
      return _global.JSON.parse(s);
    };
    Json.stringify = function(data) {
      return _global.JSON.stringify(data, null, 2);
    };
    return Json;
  }());
  exports.Json = Json;
  var DateWrapper = (function() {
    function DateWrapper() {}
    DateWrapper.create = function(year, month, day, hour, minutes, seconds, milliseconds) {
      if (month === void 0) {
        month = 1;
      }
      if (day === void 0) {
        day = 1;
      }
      if (hour === void 0) {
        hour = 0;
      }
      if (minutes === void 0) {
        minutes = 0;
      }
      if (seconds === void 0) {
        seconds = 0;
      }
      if (milliseconds === void 0) {
        milliseconds = 0;
      }
      return new exports.Date(year, month - 1, day, hour, minutes, seconds, milliseconds);
    };
    DateWrapper.fromISOString = function(str) {
      return new exports.Date(str);
    };
    DateWrapper.fromMillis = function(ms) {
      return new exports.Date(ms);
    };
    DateWrapper.toMillis = function(date) {
      return date.getTime();
    };
    DateWrapper.now = function() {
      return new exports.Date();
    };
    DateWrapper.toJson = function(date) {
      return date.toJSON();
    };
    return DateWrapper;
  }());
  exports.DateWrapper = DateWrapper;
  function setValueOnPath(global, path, value) {
    var parts = path.split('.');
    var obj = global;
    while (parts.length > 1) {
      var name = parts.shift();
      if (obj.hasOwnProperty(name) && isPresent(obj[name])) {
        obj = obj[name];
      } else {
        obj = obj[name] = {};
      }
    }
    if (obj === undefined || obj === null) {
      obj = {};
    }
    obj[parts.shift()] = value;
  }
  exports.setValueOnPath = setValueOnPath;
  var _symbolIterator = null;
  function getSymbolIterator() {
    if (isBlank(_symbolIterator)) {
      if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
        _symbolIterator = Symbol.iterator;
      } else {
        var keys = Object.getOwnPropertyNames(Map.prototype);
        for (var i = 0; i < keys.length; ++i) {
          var key = keys[i];
          if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
            _symbolIterator = key;
          }
        }
      }
    }
    return _symbolIterator;
  }
  exports.getSymbolIterator = getSymbolIterator;
  function evalExpression(sourceUrl, expr, declarations, vars) {
    var fnBody = declarations + "\nreturn " + expr + "\n//# sourceURL=" + sourceUrl;
    var fnArgNames = [];
    var fnArgValues = [];
    for (var argName in vars) {
      fnArgNames.push(argName);
      fnArgValues.push(vars[argName]);
    }
    return new (Function.bind.apply(Function, [void 0].concat(fnArgNames.concat(fnBody))))().apply(void 0, fnArgValues);
  }
  exports.evalExpression = evalExpression;
  function isPrimitive(obj) {
    return !isJsObject(obj);
  }
  exports.isPrimitive = isPrimitive;
  function hasConstructor(value, type) {
    return value.constructor === type;
  }
  exports.hasConstructor = hasConstructor;
  function bitWiseOr(values) {
    return values.reduce(function(a, b) {
      return a | b;
    });
  }
  exports.bitWiseOr = bitWiseOr;
  function bitWiseAnd(values) {
    return values.reduce(function(a, b) {
      return a & b;
    });
  }
  exports.bitWiseAnd = bitWiseAnd;
  function escape(s) {
    return _global.encodeURI(s);
  }
  exports.escape = escape;
  return module.exports;
});

$__System.registerDynamic("56", ["a", "9", "5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var compiler_1 = $__require('a');
  var promise_1 = $__require('9');
  var lang_1 = $__require('5');
  var XHRImpl = (function(_super) {
    __extends(XHRImpl, _super);
    function XHRImpl() {
      _super.apply(this, arguments);
    }
    XHRImpl.prototype.get = function(url) {
      var completer = promise_1.PromiseWrapper.completer();
      var xhr = new XMLHttpRequest();
      xhr.open('GET', url, true);
      xhr.responseType = 'text';
      xhr.onload = function() {
        var response = lang_1.isPresent(xhr.response) ? xhr.response : xhr.responseText;
        var status = xhr.status === 1223 ? 204 : xhr.status;
        if (status === 0) {
          status = response ? 200 : 0;
        }
        if (200 <= status && status <= 300) {
          completer.resolve(response);
        } else {
          completer.reject("Failed to load " + url, null);
        }
      };
      xhr.onerror = function() {
        completer.reject("Failed to load " + url, null);
      };
      xhr.send();
      return completer.promise;
    };
    return XHRImpl;
  }(compiler_1.XHR));
  exports.XHRImpl = XHRImpl;
  return module.exports;
});

$__System.registerDynamic("57", ["58", "59", "5a", "5b", "5c", "5d", "5e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var animation_builder = $__require('58');
  var css_animation_builder = $__require('59');
  var browser_details = $__require('5a');
  var css_animation_options = $__require('5b');
  var animation = $__require('5c');
  var dom_adapter = $__require('5d');
  var browser_adapter = $__require('5e');
  var __platform_browser_private__;
  (function(__platform_browser_private__) {
    __platform_browser_private__.DomAdapter = dom_adapter.DomAdapter;
    function getDOM() {
      return dom_adapter.getDOM();
    }
    __platform_browser_private__.getDOM = getDOM;
    function setDOM(adapter) {
      return dom_adapter.setDOM(adapter);
    }
    __platform_browser_private__.setDOM = setDOM;
    __platform_browser_private__.setRootDomAdapter = dom_adapter.setRootDomAdapter;
    __platform_browser_private__.BrowserDomAdapter = browser_adapter.BrowserDomAdapter;
    __platform_browser_private__.AnimationBuilder = animation_builder.AnimationBuilder;
    __platform_browser_private__.CssAnimationBuilder = css_animation_builder.CssAnimationBuilder;
    __platform_browser_private__.CssAnimationOptions = css_animation_options.CssAnimationOptions;
    __platform_browser_private__.Animation = animation.Animation;
    __platform_browser_private__.BrowserDetails = browser_details.BrowserDetails;
  })(__platform_browser_private__ = exports.__platform_browser_private__ || (exports.__platform_browser_private__ = {}));
  return module.exports;
});

$__System.registerDynamic("5f", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi;
  function sanitizeUrl(url) {
    if (String(url).match(SAFE_URL_PATTERN))
      return url;
    return 'unsafe:' + url;
  }
  exports.sanitizeUrl = sanitizeUrl;
  return module.exports;
});

$__System.registerDynamic("60", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var SAFE_STYLE_VALUE = /^([-,."'%_!# a-zA-Z0-9]+|(?:rgb|hsl)a?\([0-9.%, ]+\))$/;
  function hasBalancedQuotes(value) {
    var outsideSingle = true;
    var outsideDouble = true;
    for (var i = 0; i < value.length; i++) {
      var c = value.charAt(i);
      if (c === '\'' && outsideDouble) {
        outsideSingle = !outsideSingle;
      } else if (c === '"' && outsideSingle) {
        outsideDouble = !outsideDouble;
      }
    }
    return outsideSingle && outsideDouble;
  }
  function sanitizeStyle(value) {
    if (String(value).match(SAFE_STYLE_VALUE) && hasBalancedQuotes(value))
      return value;
    return 'unsafe';
  }
  exports.sanitizeStyle = sanitizeStyle;
  return module.exports;
});

$__System.registerDynamic("61", ["5f", "60", "62", "11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var url_sanitizer_1 = $__require('5f');
  var style_sanitizer_1 = $__require('60');
  var core_private_1 = $__require('62');
  exports.SecurityContext = core_private_1.SecurityContext;
  var core_1 = $__require('11');
  var DomSanitizationService = (function() {
    function DomSanitizationService() {}
    return DomSanitizationService;
  }());
  exports.DomSanitizationService = DomSanitizationService;
  var DomSanitizationServiceImpl = (function(_super) {
    __extends(DomSanitizationServiceImpl, _super);
    function DomSanitizationServiceImpl() {
      _super.apply(this, arguments);
    }
    DomSanitizationServiceImpl.prototype.sanitize = function(ctx, value) {
      if (value == null)
        return null;
      switch (ctx) {
        case core_private_1.SecurityContext.NONE:
          return value;
        case core_private_1.SecurityContext.HTML:
          if (value instanceof SafeHtmlImpl)
            return value.changingThisBreaksApplicationSecurity;
          this.checkNotSafeValue(value, 'HTML');
          return this.sanitizeHtml(String(value));
        case core_private_1.SecurityContext.STYLE:
          if (value instanceof SafeStyleImpl)
            return value.changingThisBreaksApplicationSecurity;
          this.checkNotSafeValue(value, 'Style');
          return style_sanitizer_1.sanitizeStyle(value);
        case core_private_1.SecurityContext.SCRIPT:
          if (value instanceof SafeScriptImpl)
            return value.changingThisBreaksApplicationSecurity;
          this.checkNotSafeValue(value, 'Script');
          throw new Error('unsafe value used in a script context');
        case core_private_1.SecurityContext.URL:
          if (value instanceof SafeUrlImpl)
            return value.changingThisBreaksApplicationSecurity;
          this.checkNotSafeValue(value, 'URL');
          return url_sanitizer_1.sanitizeUrl(String(value));
        case core_private_1.SecurityContext.RESOURCE_URL:
          if (value instanceof SafeResourceUrlImpl) {
            return value.changingThisBreaksApplicationSecurity;
          }
          this.checkNotSafeValue(value, 'ResourceURL');
          throw new Error('unsafe value used in a resource URL context');
        default:
          throw new Error("Unexpected SecurityContext " + ctx);
      }
    };
    DomSanitizationServiceImpl.prototype.checkNotSafeValue = function(value, expectedType) {
      if (value instanceof SafeValueImpl) {
        throw new Error('Required a safe ' + expectedType + ', got a ' + value.getTypeName());
      }
    };
    DomSanitizationServiceImpl.prototype.sanitizeHtml = function(value) {
      return value;
    };
    DomSanitizationServiceImpl.prototype.bypassSecurityTrustHtml = function(value) {
      return new SafeHtmlImpl(value);
    };
    DomSanitizationServiceImpl.prototype.bypassSecurityTrustStyle = function(value) {
      return new SafeStyleImpl(value);
    };
    DomSanitizationServiceImpl.prototype.bypassSecurityTrustScript = function(value) {
      return new SafeScriptImpl(value);
    };
    DomSanitizationServiceImpl.prototype.bypassSecurityTrustUrl = function(value) {
      return new SafeUrlImpl(value);
    };
    DomSanitizationServiceImpl.prototype.bypassSecurityTrustResourceUrl = function(value) {
      return new SafeResourceUrlImpl(value);
    };
    DomSanitizationServiceImpl.decorators = [{type: core_1.Injectable}];
    return DomSanitizationServiceImpl;
  }(DomSanitizationService));
  exports.DomSanitizationServiceImpl = DomSanitizationServiceImpl;
  var SafeValueImpl = (function() {
    function SafeValueImpl(changingThisBreaksApplicationSecurity) {
      this.changingThisBreaksApplicationSecurity = changingThisBreaksApplicationSecurity;
    }
    return SafeValueImpl;
  }());
  var SafeHtmlImpl = (function(_super) {
    __extends(SafeHtmlImpl, _super);
    function SafeHtmlImpl() {
      _super.apply(this, arguments);
    }
    SafeHtmlImpl.prototype.getTypeName = function() {
      return 'HTML';
    };
    return SafeHtmlImpl;
  }(SafeValueImpl));
  var SafeStyleImpl = (function(_super) {
    __extends(SafeStyleImpl, _super);
    function SafeStyleImpl() {
      _super.apply(this, arguments);
    }
    SafeStyleImpl.prototype.getTypeName = function() {
      return 'Style';
    };
    return SafeStyleImpl;
  }(SafeValueImpl));
  var SafeScriptImpl = (function(_super) {
    __extends(SafeScriptImpl, _super);
    function SafeScriptImpl() {
      _super.apply(this, arguments);
    }
    SafeScriptImpl.prototype.getTypeName = function() {
      return 'Script';
    };
    return SafeScriptImpl;
  }(SafeValueImpl));
  var SafeUrlImpl = (function(_super) {
    __extends(SafeUrlImpl, _super);
    function SafeUrlImpl() {
      _super.apply(this, arguments);
    }
    SafeUrlImpl.prototype.getTypeName = function() {
      return 'URL';
    };
    return SafeUrlImpl;
  }(SafeValueImpl));
  var SafeResourceUrlImpl = (function(_super) {
    __extends(SafeResourceUrlImpl, _super);
    function SafeResourceUrlImpl() {
      _super.apply(this, arguments);
    }
    SafeResourceUrlImpl.prototype.getTypeName = function() {
      return 'ResourceURL';
    };
    return SafeResourceUrlImpl;
  }(SafeValueImpl));
  return module.exports;
});

$__System.registerDynamic("63", ["11", "64", "65", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var collection_1 = $__require('64');
  var lang_1 = $__require('65');
  var dom_adapter_1 = $__require('5d');
  var PublicTestability = (function() {
    function PublicTestability(testability) {
      this._testability = testability;
    }
    PublicTestability.prototype.isStable = function() {
      return this._testability.isStable();
    };
    PublicTestability.prototype.whenStable = function(callback) {
      this._testability.whenStable(callback);
    };
    PublicTestability.prototype.findBindings = function(using, provider, exactMatch) {
      return this.findProviders(using, provider, exactMatch);
    };
    PublicTestability.prototype.findProviders = function(using, provider, exactMatch) {
      return this._testability.findBindings(using, provider, exactMatch);
    };
    return PublicTestability;
  }());
  var BrowserGetTestability = (function() {
    function BrowserGetTestability() {}
    BrowserGetTestability.init = function() {
      core_1.setTestabilityGetter(new BrowserGetTestability());
    };
    BrowserGetTestability.prototype.addToWindow = function(registry) {
      lang_1.global.getAngularTestability = function(elem, findInAncestors) {
        if (findInAncestors === void 0) {
          findInAncestors = true;
        }
        var testability = registry.findTestabilityInTree(elem, findInAncestors);
        if (testability == null) {
          throw new Error('Could not find testability for element.');
        }
        return new PublicTestability(testability);
      };
      lang_1.global.getAllAngularTestabilities = function() {
        var testabilities = registry.getAllTestabilities();
        return testabilities.map(function(testability) {
          return new PublicTestability(testability);
        });
      };
      lang_1.global.getAllAngularRootElements = function() {
        return registry.getAllRootElements();
      };
      var whenAllStable = function(callback) {
        var testabilities = lang_1.global.getAllAngularTestabilities();
        var count = testabilities.length;
        var didWork = false;
        var decrement = function(didWork_) {
          didWork = didWork || didWork_;
          count--;
          if (count == 0) {
            callback(didWork);
          }
        };
        testabilities.forEach(function(testability) {
          testability.whenStable(decrement);
        });
      };
      if (!lang_1.global.frameworkStabilizers) {
        lang_1.global.frameworkStabilizers = collection_1.ListWrapper.createGrowableSize(0);
      }
      lang_1.global.frameworkStabilizers.push(whenAllStable);
    };
    BrowserGetTestability.prototype.findTestabilityInTree = function(registry, elem, findInAncestors) {
      if (elem == null) {
        return null;
      }
      var t = registry.getTestability(elem);
      if (lang_1.isPresent(t)) {
        return t;
      } else if (!findInAncestors) {
        return null;
      }
      if (dom_adapter_1.getDOM().isShadowRoot(elem)) {
        return this.findTestabilityInTree(registry, dom_adapter_1.getDOM().getHost(elem), true);
      }
      return this.findTestabilityInTree(registry, dom_adapter_1.getDOM().parentElement(elem), true);
    };
    return BrowserGetTestability;
  }());
  exports.BrowserGetTestability = BrowserGetTestability;
  return module.exports;
});

$__System.registerDynamic("66", ["11", "65", "64", "5d", "67", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var __extends = (this && this.__extends) || function(d, b) {
      for (var p in b)
        if (b.hasOwnProperty(p))
          d[p] = b[p];
      function __() {
        this.constructor = d;
      }
      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
    var core_1 = $__require('11');
    var lang_1 = $__require('65');
    var collection_1 = $__require('64');
    var dom_adapter_1 = $__require('5d');
    var event_manager_1 = $__require('67');
    var modifierKeys = ['alt', 'control', 'meta', 'shift'];
    var modifierKeyGetters = {
      'alt': function(event) {
        return event.altKey;
      },
      'control': function(event) {
        return event.ctrlKey;
      },
      'meta': function(event) {
        return event.metaKey;
      },
      'shift': function(event) {
        return event.shiftKey;
      }
    };
    var KeyEventsPlugin = (function(_super) {
      __extends(KeyEventsPlugin, _super);
      function KeyEventsPlugin() {
        _super.call(this);
      }
      KeyEventsPlugin.prototype.supports = function(eventName) {
        return lang_1.isPresent(KeyEventsPlugin.parseEventName(eventName));
      };
      KeyEventsPlugin.prototype.addEventListener = function(element, eventName, handler) {
        var parsedEvent = KeyEventsPlugin.parseEventName(eventName);
        var outsideHandler = KeyEventsPlugin.eventCallback(element, collection_1.StringMapWrapper.get(parsedEvent, 'fullKey'), handler, this.manager.getZone());
        return this.manager.getZone().runOutsideAngular(function() {
          return dom_adapter_1.getDOM().onAndCancel(element, collection_1.StringMapWrapper.get(parsedEvent, 'domEventName'), outsideHandler);
        });
      };
      KeyEventsPlugin.parseEventName = function(eventName) {
        var parts = eventName.toLowerCase().split('.');
        var domEventName = parts.shift();
        if ((parts.length === 0) || !(lang_1.StringWrapper.equals(domEventName, 'keydown') || lang_1.StringWrapper.equals(domEventName, 'keyup'))) {
          return null;
        }
        var key = KeyEventsPlugin._normalizeKey(parts.pop());
        var fullKey = '';
        modifierKeys.forEach(function(modifierName) {
          if (collection_1.ListWrapper.contains(parts, modifierName)) {
            collection_1.ListWrapper.remove(parts, modifierName);
            fullKey += modifierName + '.';
          }
        });
        fullKey += key;
        if (parts.length != 0 || key.length === 0) {
          return null;
        }
        var result = collection_1.StringMapWrapper.create();
        collection_1.StringMapWrapper.set(result, 'domEventName', domEventName);
        collection_1.StringMapWrapper.set(result, 'fullKey', fullKey);
        return result;
      };
      KeyEventsPlugin.getEventFullKey = function(event) {
        var fullKey = '';
        var key = dom_adapter_1.getDOM().getEventKey(event);
        key = key.toLowerCase();
        if (lang_1.StringWrapper.equals(key, ' ')) {
          key = 'space';
        } else if (lang_1.StringWrapper.equals(key, '.')) {
          key = 'dot';
        }
        modifierKeys.forEach(function(modifierName) {
          if (modifierName != key) {
            var modifierGetter = collection_1.StringMapWrapper.get(modifierKeyGetters, modifierName);
            if (modifierGetter(event)) {
              fullKey += modifierName + '.';
            }
          }
        });
        fullKey += key;
        return fullKey;
      };
      KeyEventsPlugin.eventCallback = function(element, fullKey, handler, zone) {
        return function(event) {
          if (lang_1.StringWrapper.equals(KeyEventsPlugin.getEventFullKey(event), fullKey)) {
            zone.runGuarded(function() {
              return handler(event);
            });
          }
        };
      };
      KeyEventsPlugin._normalizeKey = function(keyName) {
        switch (keyName) {
          case 'esc':
            return 'escape';
          default:
            return keyName;
        }
      };
      KeyEventsPlugin.decorators = [{type: core_1.Injectable}];
      KeyEventsPlugin.ctorParameters = [];
      return KeyEventsPlugin;
    }(event_manager_1.EventManagerPlugin));
    exports.KeyEventsPlugin = KeyEventsPlugin;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("68", ["11", "5d", "67"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var dom_adapter_1 = $__require('5d');
  var event_manager_1 = $__require('67');
  var DomEventsPlugin = (function(_super) {
    __extends(DomEventsPlugin, _super);
    function DomEventsPlugin() {
      _super.apply(this, arguments);
    }
    DomEventsPlugin.prototype.supports = function(eventName) {
      return true;
    };
    DomEventsPlugin.prototype.addEventListener = function(element, eventName, handler) {
      var zone = this.manager.getZone();
      var outsideHandler = function(event) {
        return zone.runGuarded(function() {
          return handler(event);
        });
      };
      return this.manager.getZone().runOutsideAngular(function() {
        return dom_adapter_1.getDOM().onAndCancel(element, eventName, outsideHandler);
      });
    };
    DomEventsPlugin.prototype.addGlobalEventListener = function(target, eventName, handler) {
      var element = dom_adapter_1.getDOM().getGlobalEventTarget(target);
      var zone = this.manager.getZone();
      var outsideHandler = function(event) {
        return zone.runGuarded(function() {
          return handler(event);
        });
      };
      return this.manager.getZone().runOutsideAngular(function() {
        return dom_adapter_1.getDOM().onAndCancel(element, eventName, outsideHandler);
      });
    };
    DomEventsPlugin.decorators = [{type: core_1.Injectable}];
    return DomEventsPlugin;
  }(event_manager_1.EventManagerPlugin));
  exports.DomEventsPlugin = DomEventsPlugin;
  return module.exports;
});

$__System.registerDynamic("69", ["67", "64"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var event_manager_1 = $__require('67');
  var collection_1 = $__require('64');
  var _eventNames = {
    'pan': true,
    'panstart': true,
    'panmove': true,
    'panend': true,
    'pancancel': true,
    'panleft': true,
    'panright': true,
    'panup': true,
    'pandown': true,
    'pinch': true,
    'pinchstart': true,
    'pinchmove': true,
    'pinchend': true,
    'pinchcancel': true,
    'pinchin': true,
    'pinchout': true,
    'press': true,
    'pressup': true,
    'rotate': true,
    'rotatestart': true,
    'rotatemove': true,
    'rotateend': true,
    'rotatecancel': true,
    'swipe': true,
    'swipeleft': true,
    'swiperight': true,
    'swipeup': true,
    'swipedown': true,
    'tap': true
  };
  var HammerGesturesPluginCommon = (function(_super) {
    __extends(HammerGesturesPluginCommon, _super);
    function HammerGesturesPluginCommon() {
      _super.call(this);
    }
    HammerGesturesPluginCommon.prototype.supports = function(eventName) {
      eventName = eventName.toLowerCase();
      return collection_1.StringMapWrapper.contains(_eventNames, eventName);
    };
    return HammerGesturesPluginCommon;
  }(event_manager_1.EventManagerPlugin));
  exports.HammerGesturesPluginCommon = HammerGesturesPluginCommon;
  return module.exports;
});

$__System.registerDynamic("6a", ["11", "65", "6b", "69"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('65');
  var exceptions_1 = $__require('6b');
  var hammer_common_1 = $__require('69');
  exports.HAMMER_GESTURE_CONFIG = new core_1.OpaqueToken("HammerGestureConfig");
  var HammerGestureConfig = (function() {
    function HammerGestureConfig() {
      this.events = [];
      this.overrides = {};
    }
    HammerGestureConfig.prototype.buildHammer = function(element) {
      var mc = new Hammer(element);
      mc.get('pinch').set({enable: true});
      mc.get('rotate').set({enable: true});
      for (var eventName in this.overrides) {
        mc.get(eventName).set(this.overrides[eventName]);
      }
      return mc;
    };
    HammerGestureConfig.decorators = [{type: core_1.Injectable}];
    return HammerGestureConfig;
  }());
  exports.HammerGestureConfig = HammerGestureConfig;
  var HammerGesturesPlugin = (function(_super) {
    __extends(HammerGesturesPlugin, _super);
    function HammerGesturesPlugin(_config) {
      _super.call(this);
      this._config = _config;
    }
    HammerGesturesPlugin.prototype.supports = function(eventName) {
      if (!_super.prototype.supports.call(this, eventName) && !this.isCustomEvent(eventName))
        return false;
      if (!lang_1.isPresent(window['Hammer'])) {
        throw new exceptions_1.BaseException("Hammer.js is not loaded, can not bind " + eventName + " event");
      }
      return true;
    };
    HammerGesturesPlugin.prototype.addEventListener = function(element, eventName, handler) {
      var _this = this;
      var zone = this.manager.getZone();
      eventName = eventName.toLowerCase();
      return zone.runOutsideAngular(function() {
        var mc = _this._config.buildHammer(element);
        var callback = function(eventObj) {
          zone.runGuarded(function() {
            handler(eventObj);
          });
        };
        mc.on(eventName, callback);
        return function() {
          mc.off(eventName, callback);
        };
      });
    };
    HammerGesturesPlugin.prototype.isCustomEvent = function(eventName) {
      return this._config.events.indexOf(eventName) > -1;
    };
    HammerGesturesPlugin.decorators = [{type: core_1.Injectable}];
    HammerGesturesPlugin.ctorParameters = [{
      type: HammerGestureConfig,
      decorators: [{
        type: core_1.Inject,
        args: [exports.HAMMER_GESTURE_CONFIG]
      }]
    }];
    return HammerGesturesPlugin;
  }(hammer_common_1.HammerGesturesPluginCommon));
  exports.HammerGesturesPlugin = HammerGesturesPlugin;
  return module.exports;
});

$__System.registerDynamic("6c", ["5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var dom_adapter_1 = $__require('5d');
  var Title = (function() {
    function Title() {}
    Title.prototype.getTitle = function() {
      return dom_adapter_1.getDOM().getTitle();
    };
    Title.prototype.setTitle = function(newTitle) {
      dom_adapter_1.getDOM().setTitle(newTitle);
    };
    return Title;
  }());
  exports.Title = Title;
  return module.exports;
});

$__System.registerDynamic("6d", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var win = typeof window !== 'undefined' && window || {};
  exports.window = win;
  exports.document = win.document;
  exports.location = win.location;
  exports.gc = win['gc'] ? function() {
    return win['gc']();
  } : function() {
    return null;
  };
  exports.performance = win['performance'] ? win['performance'] : null;
  exports.Event = win['Event'];
  exports.MouseEvent = win['MouseEvent'];
  exports.KeyboardEvent = win['KeyboardEvent'];
  exports.EventTarget = win['EventTarget'];
  exports.History = win['History'];
  exports.Location = win['Location'];
  exports.EventListener = win['EventListener'];
  return module.exports;
});

$__System.registerDynamic("6e", ["11", "65", "6d", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('65');
  var browser_1 = $__require('6d');
  var dom_adapter_1 = $__require('5d');
  var ChangeDetectionPerfRecord = (function() {
    function ChangeDetectionPerfRecord(msPerTick, numTicks) {
      this.msPerTick = msPerTick;
      this.numTicks = numTicks;
    }
    return ChangeDetectionPerfRecord;
  }());
  exports.ChangeDetectionPerfRecord = ChangeDetectionPerfRecord;
  var AngularTools = (function() {
    function AngularTools(ref) {
      this.profiler = new AngularProfiler(ref);
    }
    return AngularTools;
  }());
  exports.AngularTools = AngularTools;
  var AngularProfiler = (function() {
    function AngularProfiler(ref) {
      this.appRef = ref.injector.get(core_1.ApplicationRef);
    }
    AngularProfiler.prototype.timeChangeDetection = function(config) {
      var record = lang_1.isPresent(config) && config['record'];
      var profileName = 'Change Detection';
      var isProfilerAvailable = lang_1.isPresent(browser_1.window.console.profile);
      if (record && isProfilerAvailable) {
        browser_1.window.console.profile(profileName);
      }
      var start = dom_adapter_1.getDOM().performanceNow();
      var numTicks = 0;
      while (numTicks < 5 || (dom_adapter_1.getDOM().performanceNow() - start) < 500) {
        this.appRef.tick();
        numTicks++;
      }
      var end = dom_adapter_1.getDOM().performanceNow();
      if (record && isProfilerAvailable) {
        browser_1.window.console.profileEnd(profileName);
      }
      var msPerTick = (end - start) / numTicks;
      browser_1.window.console.log("ran " + numTicks + " change detection cycles");
      browser_1.window.console.log(lang_1.NumberWrapper.toFixed(msPerTick, 2) + " ms per check");
      return new ChangeDetectionPerfRecord(msPerTick, numTicks);
    };
    return AngularProfiler;
  }());
  exports.AngularProfiler = AngularProfiler;
  return module.exports;
});

$__System.registerDynamic("6f", ["65", "6e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var common_tools_1 = $__require('6e');
  var context = lang_1.global;
  function enableDebugTools(ref) {
    context.ng = new common_tools_1.AngularTools(ref);
  }
  exports.enableDebugTools = enableDebugTools;
  function disableDebugTools() {
    delete context.ng;
  }
  exports.disableDebugTools = disableDebugTools;
  return module.exports;
});

$__System.registerDynamic("70", ["65", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var dom_adapter_1 = $__require('5d');
  var By = (function() {
    function By() {}
    By.all = function() {
      return function(debugElement) {
        return true;
      };
    };
    By.css = function(selector) {
      return function(debugElement) {
        return lang_1.isPresent(debugElement.nativeElement) ? dom_adapter_1.getDOM().elementMatches(debugElement.nativeElement, selector) : false;
      };
    };
    By.directive = function(type) {
      return function(debugElement) {
        return debugElement.providerTokens.indexOf(type) !== -1;
      };
    };
    return By;
  }());
  exports.By = By;
  return module.exports;
});

$__System.registerDynamic("71", ["11", "62", "76", "61", "65", "5e", "63", "5d", "72", "67", "73", "74", "66", "75", "68", "6a", "58", "5a", "6c", "6f", "70"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('62');
  var common_1 = $__require('76');
  var dom_sanitization_service_1 = $__require('61');
  var lang_1 = $__require('65');
  var browser_adapter_1 = $__require('5e');
  var testability_1 = $__require('63');
  var dom_adapter_1 = $__require('5d');
  var dom_tokens_1 = $__require('72');
  var event_manager_1 = $__require('67');
  var dom_renderer_1 = $__require('73');
  var shared_styles_host_1 = $__require('74');
  var key_events_1 = $__require('66');
  var ng_probe_1 = $__require('75');
  var dom_events_1 = $__require('68');
  var hammer_gestures_1 = $__require('6a');
  var shared_styles_host_2 = $__require('74');
  var animation_builder_1 = $__require('58');
  var browser_details_1 = $__require('5a');
  var title_1 = $__require('6c');
  exports.Title = title_1.Title;
  var browser_adapter_2 = $__require('5e');
  exports.BrowserDomAdapter = browser_adapter_2.BrowserDomAdapter;
  var tools_1 = $__require('6f');
  exports.enableDebugTools = tools_1.enableDebugTools;
  exports.disableDebugTools = tools_1.disableDebugTools;
  var by_1 = $__require('70');
  exports.By = by_1.By;
  exports.BROWSER_PLATFORM_MARKER = new core_1.OpaqueToken('BrowserPlatformMarker');
  exports.BROWSER_PROVIDERS = [{
    provide: exports.BROWSER_PLATFORM_MARKER,
    useValue: true
  }, core_1.PLATFORM_COMMON_PROVIDERS, {
    provide: core_1.PLATFORM_INITIALIZER,
    useValue: initDomAdapter,
    multi: true
  }];
  function _exceptionHandler() {
    return new core_1.ExceptionHandler(dom_adapter_1.getDOM(), !lang_1.IS_DART);
  }
  function _document() {
    return dom_adapter_1.getDOM().defaultDoc();
  }
  exports.BROWSER_SANITIZATION_PROVIDERS = [{
    provide: core_private_1.SanitizationService,
    useExisting: dom_sanitization_service_1.DomSanitizationService
  }, {
    provide: dom_sanitization_service_1.DomSanitizationService,
    useClass: dom_sanitization_service_1.DomSanitizationServiceImpl
  }];
  exports.BROWSER_APP_COMMON_PROVIDERS = [core_1.APPLICATION_COMMON_PROVIDERS, common_1.FORM_PROVIDERS, exports.BROWSER_SANITIZATION_PROVIDERS, {
    provide: core_1.PLATFORM_PIPES,
    useValue: common_1.COMMON_PIPES,
    multi: true
  }, {
    provide: core_1.PLATFORM_DIRECTIVES,
    useValue: common_1.COMMON_DIRECTIVES,
    multi: true
  }, {
    provide: core_1.ExceptionHandler,
    useFactory: _exceptionHandler,
    deps: []
  }, {
    provide: dom_tokens_1.DOCUMENT,
    useFactory: _document,
    deps: []
  }, {
    provide: event_manager_1.EVENT_MANAGER_PLUGINS,
    useClass: dom_events_1.DomEventsPlugin,
    multi: true
  }, {
    provide: event_manager_1.EVENT_MANAGER_PLUGINS,
    useClass: key_events_1.KeyEventsPlugin,
    multi: true
  }, {
    provide: event_manager_1.EVENT_MANAGER_PLUGINS,
    useClass: hammer_gestures_1.HammerGesturesPlugin,
    multi: true
  }, {
    provide: hammer_gestures_1.HAMMER_GESTURE_CONFIG,
    useClass: hammer_gestures_1.HammerGestureConfig
  }, {
    provide: dom_renderer_1.DomRootRenderer,
    useClass: dom_renderer_1.DomRootRenderer_
  }, {
    provide: core_1.RootRenderer,
    useExisting: dom_renderer_1.DomRootRenderer
  }, {
    provide: shared_styles_host_1.SharedStylesHost,
    useExisting: shared_styles_host_2.DomSharedStylesHost
  }, shared_styles_host_2.DomSharedStylesHost, core_1.Testability, browser_details_1.BrowserDetails, animation_builder_1.AnimationBuilder, event_manager_1.EventManager, ng_probe_1.ELEMENT_PROBE_PROVIDERS];
  var hammer_gestures_2 = $__require('6a');
  exports.HAMMER_GESTURE_CONFIG = hammer_gestures_2.HAMMER_GESTURE_CONFIG;
  exports.HammerGestureConfig = hammer_gestures_2.HammerGestureConfig;
  function initDomAdapter() {
    browser_adapter_1.BrowserDomAdapter.makeCurrent();
    core_private_1.wtfInit();
    testability_1.BrowserGetTestability.init();
  }
  exports.initDomAdapter = initDomAdapter;
  return module.exports;
});

$__System.registerDynamic("62", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  exports.RenderDebugInfo = core_1.__core_private__.RenderDebugInfo;
  exports.wtfInit = core_1.__core_private__.wtfInit;
  exports.ReflectionCapabilities = core_1.__core_private__.ReflectionCapabilities;
  exports.VIEW_ENCAPSULATION_VALUES = core_1.__core_private__.VIEW_ENCAPSULATION_VALUES;
  exports.DebugDomRootRenderer = core_1.__core_private__.DebugDomRootRenderer;
  exports.SecurityContext = core_1.__core_private__.SecurityContext;
  exports.SanitizationService = core_1.__core_private__.SanitizationService;
  return module.exports;
});

$__System.registerDynamic("5b", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var CssAnimationOptions = (function() {
    function CssAnimationOptions() {
      this.classesToAdd = [];
      this.classesToRemove = [];
      this.animationClasses = [];
    }
    return CssAnimationOptions;
  }());
  exports.CssAnimationOptions = CssAnimationOptions;
  return module.exports;
});

$__System.registerDynamic("5c", ["65", "77", "64", "78", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var math_1 = $__require('77');
  var collection_1 = $__require('64');
  var util_1 = $__require('78');
  var dom_adapter_1 = $__require('5d');
  var Animation = (function() {
    function Animation(element, data, browserDetails) {
      var _this = this;
      this.element = element;
      this.data = data;
      this.browserDetails = browserDetails;
      this.callbacks = [];
      this.eventClearFunctions = [];
      this.completed = false;
      this._stringPrefix = '';
      this.startTime = lang_1.DateWrapper.toMillis(lang_1.DateWrapper.now());
      this._stringPrefix = dom_adapter_1.getDOM().getAnimationPrefix();
      this.setup();
      this.wait(function(timestamp) {
        return _this.start();
      });
    }
    Object.defineProperty(Animation.prototype, "totalTime", {
      get: function() {
        var delay = this.computedDelay != null ? this.computedDelay : 0;
        var duration = this.computedDuration != null ? this.computedDuration : 0;
        return delay + duration;
      },
      enumerable: true,
      configurable: true
    });
    Animation.prototype.wait = function(callback) {
      this.browserDetails.raf(callback, 2);
    };
    Animation.prototype.setup = function() {
      if (this.data.fromStyles != null)
        this.applyStyles(this.data.fromStyles);
      if (this.data.duration != null)
        this.applyStyles({'transitionDuration': this.data.duration.toString() + 'ms'});
      if (this.data.delay != null)
        this.applyStyles({'transitionDelay': this.data.delay.toString() + 'ms'});
    };
    Animation.prototype.start = function() {
      this.addClasses(this.data.classesToAdd);
      this.addClasses(this.data.animationClasses);
      this.removeClasses(this.data.classesToRemove);
      if (this.data.toStyles != null)
        this.applyStyles(this.data.toStyles);
      var computedStyles = dom_adapter_1.getDOM().getComputedStyle(this.element);
      this.computedDelay = math_1.Math.max(this.parseDurationString(computedStyles.getPropertyValue(this._stringPrefix + 'transition-delay')), this.parseDurationString(this.element.style.getPropertyValue(this._stringPrefix + 'transition-delay')));
      this.computedDuration = math_1.Math.max(this.parseDurationString(computedStyles.getPropertyValue(this._stringPrefix + 'transition-duration')), this.parseDurationString(this.element.style.getPropertyValue(this._stringPrefix + 'transition-duration')));
      this.addEvents();
    };
    Animation.prototype.applyStyles = function(styles) {
      var _this = this;
      collection_1.StringMapWrapper.forEach(styles, function(value, key) {
        var dashCaseKey = util_1.camelCaseToDashCase(key);
        if (lang_1.isPresent(dom_adapter_1.getDOM().getStyle(_this.element, dashCaseKey))) {
          dom_adapter_1.getDOM().setStyle(_this.element, dashCaseKey, value.toString());
        } else {
          dom_adapter_1.getDOM().setStyle(_this.element, _this._stringPrefix + dashCaseKey, value.toString());
        }
      });
    };
    Animation.prototype.addClasses = function(classes) {
      for (var i = 0,
          len = classes.length; i < len; i++)
        dom_adapter_1.getDOM().addClass(this.element, classes[i]);
    };
    Animation.prototype.removeClasses = function(classes) {
      for (var i = 0,
          len = classes.length; i < len; i++)
        dom_adapter_1.getDOM().removeClass(this.element, classes[i]);
    };
    Animation.prototype.addEvents = function() {
      var _this = this;
      if (this.totalTime > 0) {
        this.eventClearFunctions.push(dom_adapter_1.getDOM().onAndCancel(this.element, dom_adapter_1.getDOM().getTransitionEnd(), function(event) {
          return _this.handleAnimationEvent(event);
        }));
      } else {
        this.handleAnimationCompleted();
      }
    };
    Animation.prototype.handleAnimationEvent = function(event) {
      var elapsedTime = math_1.Math.round(event.elapsedTime * 1000);
      if (!this.browserDetails.elapsedTimeIncludesDelay)
        elapsedTime += this.computedDelay;
      event.stopPropagation();
      if (elapsedTime >= this.totalTime)
        this.handleAnimationCompleted();
    };
    Animation.prototype.handleAnimationCompleted = function() {
      this.removeClasses(this.data.animationClasses);
      this.callbacks.forEach(function(callback) {
        return callback();
      });
      this.callbacks = [];
      this.eventClearFunctions.forEach(function(fn) {
        return fn();
      });
      this.eventClearFunctions = [];
      this.completed = true;
    };
    Animation.prototype.onComplete = function(callback) {
      if (this.completed) {
        callback();
      } else {
        this.callbacks.push(callback);
      }
      return this;
    };
    Animation.prototype.parseDurationString = function(duration) {
      var maxValue = 0;
      if (duration == null || duration.length < 2) {
        return maxValue;
      } else if (duration.substring(duration.length - 2) == 'ms') {
        var value = lang_1.NumberWrapper.parseInt(this.stripLetters(duration), 10);
        if (value > maxValue)
          maxValue = value;
      } else if (duration.substring(duration.length - 1) == 's') {
        var ms = lang_1.NumberWrapper.parseFloat(this.stripLetters(duration)) * 1000;
        var value = math_1.Math.floor(ms);
        if (value > maxValue)
          maxValue = value;
      }
      return maxValue;
    };
    Animation.prototype.stripLetters = function(str) {
      return lang_1.StringWrapper.replaceAll(str, lang_1.RegExpWrapper.create('[^0-9]+$', ''), '');
    };
    return Animation;
  }());
  exports.Animation = Animation;
  return module.exports;
});

$__System.registerDynamic("59", ["5b", "5c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var css_animation_options_1 = $__require('5b');
  var animation_1 = $__require('5c');
  var CssAnimationBuilder = (function() {
    function CssAnimationBuilder(browserDetails) {
      this.browserDetails = browserDetails;
      this.data = new css_animation_options_1.CssAnimationOptions();
    }
    CssAnimationBuilder.prototype.addAnimationClass = function(className) {
      this.data.animationClasses.push(className);
      return this;
    };
    CssAnimationBuilder.prototype.addClass = function(className) {
      this.data.classesToAdd.push(className);
      return this;
    };
    CssAnimationBuilder.prototype.removeClass = function(className) {
      this.data.classesToRemove.push(className);
      return this;
    };
    CssAnimationBuilder.prototype.setDuration = function(duration) {
      this.data.duration = duration;
      return this;
    };
    CssAnimationBuilder.prototype.setDelay = function(delay) {
      this.data.delay = delay;
      return this;
    };
    CssAnimationBuilder.prototype.setStyles = function(from, to) {
      return this.setFromStyles(from).setToStyles(to);
    };
    CssAnimationBuilder.prototype.setFromStyles = function(from) {
      this.data.fromStyles = from;
      return this;
    };
    CssAnimationBuilder.prototype.setToStyles = function(to) {
      this.data.toStyles = to;
      return this;
    };
    CssAnimationBuilder.prototype.start = function(element) {
      return new animation_1.Animation(element, this.data, this.browserDetails);
    };
    return CssAnimationBuilder;
  }());
  exports.CssAnimationBuilder = CssAnimationBuilder;
  return module.exports;
});

$__System.registerDynamic("77", ["65"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  exports.Math = lang_1.global.Math;
  exports.NaN = typeof exports.NaN;
  return module.exports;
});

$__System.registerDynamic("5a", ["11", "77", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var math_1 = $__require('77');
  var dom_adapter_1 = $__require('5d');
  var BrowserDetails = (function() {
    function BrowserDetails() {
      this.elapsedTimeIncludesDelay = false;
      this.doesElapsedTimeIncludesDelay();
    }
    BrowserDetails.prototype.doesElapsedTimeIncludesDelay = function() {
      var _this = this;
      var div = dom_adapter_1.getDOM().createElement('div');
      dom_adapter_1.getDOM().setAttribute(div, 'style', "position: absolute; top: -9999px; left: -9999px; width: 1px;\n      height: 1px; transition: all 1ms linear 1ms;");
      this.raf(function(timestamp) {
        dom_adapter_1.getDOM().on(div, 'transitionend', function(event) {
          var elapsed = math_1.Math.round(event.elapsedTime * 1000);
          _this.elapsedTimeIncludesDelay = elapsed == 2;
          dom_adapter_1.getDOM().remove(div);
        });
        dom_adapter_1.getDOM().setStyle(div, 'width', '2px');
      }, 2);
    };
    BrowserDetails.prototype.raf = function(callback, frames) {
      if (frames === void 0) {
        frames = 1;
      }
      var queue = new RafQueue(callback, frames);
      return function() {
        return queue.cancel();
      };
    };
    BrowserDetails.decorators = [{type: core_1.Injectable}];
    BrowserDetails.ctorParameters = [];
    return BrowserDetails;
  }());
  exports.BrowserDetails = BrowserDetails;
  var RafQueue = (function() {
    function RafQueue(callback, frames) {
      this.callback = callback;
      this.frames = frames;
      this._raf();
    }
    RafQueue.prototype._raf = function() {
      var _this = this;
      this.currentFrameId = dom_adapter_1.getDOM().requestAnimationFrame(function(timestamp) {
        return _this._nextFrame(timestamp);
      });
    };
    RafQueue.prototype._nextFrame = function(timestamp) {
      this.frames--;
      if (this.frames > 0) {
        this._raf();
      } else {
        this.callback(timestamp);
      }
    };
    RafQueue.prototype.cancel = function() {
      dom_adapter_1.getDOM().cancelAnimationFrame(this.currentFrameId);
      this.currentFrameId = null;
    };
    return RafQueue;
  }());
  return module.exports;
});

$__System.registerDynamic("58", ["11", "59", "5a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var css_animation_builder_1 = $__require('59');
  var browser_details_1 = $__require('5a');
  var AnimationBuilder = (function() {
    function AnimationBuilder(browserDetails) {
      this.browserDetails = browserDetails;
    }
    AnimationBuilder.prototype.css = function() {
      return new css_animation_builder_1.CssAnimationBuilder(this.browserDetails);
    };
    AnimationBuilder.decorators = [{type: core_1.Injectable}];
    AnimationBuilder.ctorParameters = [{type: browser_details_1.BrowserDetails}];
    return AnimationBuilder;
  }());
  exports.AnimationBuilder = AnimationBuilder;
  return module.exports;
});

$__System.registerDynamic("74", ["11", "64", "5d", "72"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var collection_1 = $__require('64');
  var dom_adapter_1 = $__require('5d');
  var dom_tokens_1 = $__require('72');
  var SharedStylesHost = (function() {
    function SharedStylesHost() {
      this._styles = [];
      this._stylesSet = new Set();
    }
    SharedStylesHost.prototype.addStyles = function(styles) {
      var _this = this;
      var additions = [];
      styles.forEach(function(style) {
        if (!collection_1.SetWrapper.has(_this._stylesSet, style)) {
          _this._stylesSet.add(style);
          _this._styles.push(style);
          additions.push(style);
        }
      });
      this.onStylesAdded(additions);
    };
    SharedStylesHost.prototype.onStylesAdded = function(additions) {};
    SharedStylesHost.prototype.getAllStyles = function() {
      return this._styles;
    };
    SharedStylesHost.decorators = [{type: core_1.Injectable}];
    SharedStylesHost.ctorParameters = [];
    return SharedStylesHost;
  }());
  exports.SharedStylesHost = SharedStylesHost;
  var DomSharedStylesHost = (function(_super) {
    __extends(DomSharedStylesHost, _super);
    function DomSharedStylesHost(doc) {
      _super.call(this);
      this._hostNodes = new Set();
      this._hostNodes.add(doc.head);
    }
    DomSharedStylesHost.prototype._addStylesToHost = function(styles, host) {
      for (var i = 0; i < styles.length; i++) {
        var style = styles[i];
        dom_adapter_1.getDOM().appendChild(host, dom_adapter_1.getDOM().createStyleElement(style));
      }
    };
    DomSharedStylesHost.prototype.addHost = function(hostNode) {
      this._addStylesToHost(this._styles, hostNode);
      this._hostNodes.add(hostNode);
    };
    DomSharedStylesHost.prototype.removeHost = function(hostNode) {
      collection_1.SetWrapper.delete(this._hostNodes, hostNode);
    };
    DomSharedStylesHost.prototype.onStylesAdded = function(additions) {
      var _this = this;
      this._hostNodes.forEach(function(hostNode) {
        _this._addStylesToHost(additions, hostNode);
      });
    };
    DomSharedStylesHost.decorators = [{type: core_1.Injectable}];
    DomSharedStylesHost.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Inject,
        args: [dom_tokens_1.DOCUMENT]
      }]
    }];
    return DomSharedStylesHost;
  }(SharedStylesHost));
  exports.DomSharedStylesHost = DomSharedStylesHost;
  return module.exports;
});

$__System.registerDynamic("79", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var BaseWrappedException = (function(_super) {
    __extends(BaseWrappedException, _super);
    function BaseWrappedException(message) {
      _super.call(this, message);
    }
    Object.defineProperty(BaseWrappedException.prototype, "wrapperMessage", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "wrapperStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalException", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "context", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "message", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    return BaseWrappedException;
  }(Error));
  exports.BaseWrappedException = BaseWrappedException;
  return module.exports;
});

$__System.registerDynamic("7a", ["65", "79", "64"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var base_wrapped_exception_1 = $__require('79');
  var collection_1 = $__require('64');
  var _ArrayLogger = (function() {
    function _ArrayLogger() {
      this.res = [];
    }
    _ArrayLogger.prototype.log = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logError = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroup = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroupEnd = function() {};
    ;
    return _ArrayLogger;
  }());
  var ExceptionHandler = (function() {
    function ExceptionHandler(_logger, _rethrowException) {
      if (_rethrowException === void 0) {
        _rethrowException = true;
      }
      this._logger = _logger;
      this._rethrowException = _rethrowException;
    }
    ExceptionHandler.exceptionToString = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var l = new _ArrayLogger();
      var e = new ExceptionHandler(l, false);
      e.call(exception, stackTrace, reason);
      return l.res.join("\n");
    };
    ExceptionHandler.prototype.call = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var originalException = this._findOriginalException(exception);
      var originalStack = this._findOriginalStack(exception);
      var context = this._findContext(exception);
      this._logger.logGroup("EXCEPTION: " + this._extractMessage(exception));
      if (lang_1.isPresent(stackTrace) && lang_1.isBlank(originalStack)) {
        this._logger.logError("STACKTRACE:");
        this._logger.logError(this._longStackTrace(stackTrace));
      }
      if (lang_1.isPresent(reason)) {
        this._logger.logError("REASON: " + reason);
      }
      if (lang_1.isPresent(originalException)) {
        this._logger.logError("ORIGINAL EXCEPTION: " + this._extractMessage(originalException));
      }
      if (lang_1.isPresent(originalStack)) {
        this._logger.logError("ORIGINAL STACKTRACE:");
        this._logger.logError(this._longStackTrace(originalStack));
      }
      if (lang_1.isPresent(context)) {
        this._logger.logError("ERROR CONTEXT:");
        this._logger.logError(context);
      }
      this._logger.logGroupEnd();
      if (this._rethrowException)
        throw exception;
    };
    ExceptionHandler.prototype._extractMessage = function(exception) {
      return exception instanceof base_wrapped_exception_1.BaseWrappedException ? exception.wrapperMessage : exception.toString();
    };
    ExceptionHandler.prototype._longStackTrace = function(stackTrace) {
      return collection_1.isListLikeIterable(stackTrace) ? stackTrace.join("\n\n-----async gap-----\n") : stackTrace.toString();
    };
    ExceptionHandler.prototype._findContext = function(exception) {
      try {
        if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
          return null;
        return lang_1.isPresent(exception.context) ? exception.context : this._findContext(exception.originalException);
      } catch (e) {
        return null;
      }
    };
    ExceptionHandler.prototype._findOriginalException = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception.originalException;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
      }
      return e;
    };
    ExceptionHandler.prototype._findOriginalStack = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception;
      var stack = exception.originalStack;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
        if (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
          stack = e.originalStack;
        }
      }
      return stack;
    };
    return ExceptionHandler;
  }());
  exports.ExceptionHandler = ExceptionHandler;
  return module.exports;
});

$__System.registerDynamic("6b", ["79", "7a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var base_wrapped_exception_1 = $__require('79');
  var exception_handler_1 = $__require('7a');
  var exception_handler_2 = $__require('7a');
  exports.ExceptionHandler = exception_handler_2.ExceptionHandler;
  var BaseException = (function(_super) {
    __extends(BaseException, _super);
    function BaseException(message) {
      if (message === void 0) {
        message = "--";
      }
      _super.call(this, message);
      this.message = message;
      this.stack = (new Error(message)).stack;
    }
    BaseException.prototype.toString = function() {
      return this.message;
    };
    return BaseException;
  }(Error));
  exports.BaseException = BaseException;
  var WrappedException = (function(_super) {
    __extends(WrappedException, _super);
    function WrappedException(_wrapperMessage, _originalException, _originalStack, _context) {
      _super.call(this, _wrapperMessage);
      this._wrapperMessage = _wrapperMessage;
      this._originalException = _originalException;
      this._originalStack = _originalStack;
      this._context = _context;
      this._wrapperStack = (new Error(_wrapperMessage)).stack;
    }
    Object.defineProperty(WrappedException.prototype, "wrapperMessage", {
      get: function() {
        return this._wrapperMessage;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "wrapperStack", {
      get: function() {
        return this._wrapperStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalException", {
      get: function() {
        return this._originalException;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalStack", {
      get: function() {
        return this._originalStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "context", {
      get: function() {
        return this._context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "message", {
      get: function() {
        return exception_handler_1.ExceptionHandler.exceptionToString(this);
      },
      enumerable: true,
      configurable: true
    });
    WrappedException.prototype.toString = function() {
      return this.message;
    };
    return WrappedException;
  }(base_wrapped_exception_1.BaseWrappedException));
  exports.WrappedException = WrappedException;
  function makeTypeError(message) {
    return new TypeError(message);
  }
  exports.makeTypeError = makeTypeError;
  function unimplemented() {
    throw new BaseException('unimplemented');
  }
  exports.unimplemented = unimplemented;
  return module.exports;
});

$__System.registerDynamic("67", ["11", "6b", "64"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var exceptions_1 = $__require('6b');
  var collection_1 = $__require('64');
  exports.EVENT_MANAGER_PLUGINS = new core_1.OpaqueToken("EventManagerPlugins");
  var EventManager = (function() {
    function EventManager(plugins, _zone) {
      var _this = this;
      this._zone = _zone;
      plugins.forEach(function(p) {
        return p.manager = _this;
      });
      this._plugins = collection_1.ListWrapper.reversed(plugins);
    }
    EventManager.prototype.addEventListener = function(element, eventName, handler) {
      var plugin = this._findPluginFor(eventName);
      return plugin.addEventListener(element, eventName, handler);
    };
    EventManager.prototype.addGlobalEventListener = function(target, eventName, handler) {
      var plugin = this._findPluginFor(eventName);
      return plugin.addGlobalEventListener(target, eventName, handler);
    };
    EventManager.prototype.getZone = function() {
      return this._zone;
    };
    EventManager.prototype._findPluginFor = function(eventName) {
      var plugins = this._plugins;
      for (var i = 0; i < plugins.length; i++) {
        var plugin = plugins[i];
        if (plugin.supports(eventName)) {
          return plugin;
        }
      }
      throw new exceptions_1.BaseException("No event manager plugin found for event " + eventName);
    };
    EventManager.decorators = [{type: core_1.Injectable}];
    EventManager.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Inject,
        args: [exports.EVENT_MANAGER_PLUGINS]
      }]
    }, {type: core_1.NgZone}];
    return EventManager;
  }());
  exports.EventManager = EventManager;
  var EventManagerPlugin = (function() {
    function EventManagerPlugin() {}
    EventManagerPlugin.prototype.supports = function(eventName) {
      return false;
    };
    EventManagerPlugin.prototype.addEventListener = function(element, eventName, handler) {
      throw "not implemented";
    };
    EventManagerPlugin.prototype.addGlobalEventListener = function(element, eventName, handler) {
      throw "not implemented";
    };
    return EventManagerPlugin;
  }());
  exports.EventManagerPlugin = EventManagerPlugin;
  return module.exports;
});

$__System.registerDynamic("72", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  exports.DOCUMENT = new core_1.OpaqueToken('DocumentToken');
  return module.exports;
});

$__System.registerDynamic("78", ["65"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var CAMEL_CASE_REGEXP = /([A-Z])/g;
  var DASH_CASE_REGEXP = /-([a-z])/g;
  function camelCaseToDashCase(input) {
    return lang_1.StringWrapper.replaceAllMapped(input, CAMEL_CASE_REGEXP, function(m) {
      return '-' + m[1].toLowerCase();
    });
  }
  exports.camelCaseToDashCase = camelCaseToDashCase;
  function dashCaseToCamelCase(input) {
    return lang_1.StringWrapper.replaceAllMapped(input, DASH_CASE_REGEXP, function(m) {
      return m[1].toUpperCase();
    });
  }
  exports.dashCaseToCamelCase = dashCaseToCamelCase;
  return module.exports;
});

$__System.registerDynamic("73", ["11", "58", "65", "6b", "74", "67", "72", "5d", "78"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var animation_builder_1 = $__require('58');
  var lang_1 = $__require('65');
  var exceptions_1 = $__require('6b');
  var shared_styles_host_1 = $__require('74');
  var event_manager_1 = $__require('67');
  var dom_tokens_1 = $__require('72');
  var dom_adapter_1 = $__require('5d');
  var util_1 = $__require('78');
  var NAMESPACE_URIS = {
    'xlink': 'http://www.w3.org/1999/xlink',
    'svg': 'http://www.w3.org/2000/svg'
  };
  var TEMPLATE_COMMENT_TEXT = 'template bindings={}';
  var TEMPLATE_BINDINGS_EXP = /^template bindings=(.*)$/g;
  var DomRootRenderer = (function() {
    function DomRootRenderer(document, eventManager, sharedStylesHost, animate) {
      this.document = document;
      this.eventManager = eventManager;
      this.sharedStylesHost = sharedStylesHost;
      this.animate = animate;
      this._registeredComponents = new Map();
    }
    DomRootRenderer.prototype.renderComponent = function(componentProto) {
      var renderer = this._registeredComponents.get(componentProto.id);
      if (lang_1.isBlank(renderer)) {
        renderer = new DomRenderer(this, componentProto);
        this._registeredComponents.set(componentProto.id, renderer);
      }
      return renderer;
    };
    return DomRootRenderer;
  }());
  exports.DomRootRenderer = DomRootRenderer;
  var DomRootRenderer_ = (function(_super) {
    __extends(DomRootRenderer_, _super);
    function DomRootRenderer_(_document, _eventManager, sharedStylesHost, animate) {
      _super.call(this, _document, _eventManager, sharedStylesHost, animate);
    }
    DomRootRenderer_.decorators = [{type: core_1.Injectable}];
    DomRootRenderer_.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Inject,
        args: [dom_tokens_1.DOCUMENT]
      }]
    }, {type: event_manager_1.EventManager}, {type: shared_styles_host_1.DomSharedStylesHost}, {type: animation_builder_1.AnimationBuilder}];
    return DomRootRenderer_;
  }(DomRootRenderer));
  exports.DomRootRenderer_ = DomRootRenderer_;
  var DomRenderer = (function() {
    function DomRenderer(_rootRenderer, componentProto) {
      this._rootRenderer = _rootRenderer;
      this.componentProto = componentProto;
      this._styles = _flattenStyles(componentProto.id, componentProto.styles, []);
      if (componentProto.encapsulation !== core_1.ViewEncapsulation.Native) {
        this._rootRenderer.sharedStylesHost.addStyles(this._styles);
      }
      if (this.componentProto.encapsulation === core_1.ViewEncapsulation.Emulated) {
        this._contentAttr = _shimContentAttribute(componentProto.id);
        this._hostAttr = _shimHostAttribute(componentProto.id);
      } else {
        this._contentAttr = null;
        this._hostAttr = null;
      }
    }
    DomRenderer.prototype.selectRootElement = function(selectorOrNode, debugInfo) {
      var el;
      if (lang_1.isString(selectorOrNode)) {
        el = dom_adapter_1.getDOM().querySelector(this._rootRenderer.document, selectorOrNode);
        if (lang_1.isBlank(el)) {
          throw new exceptions_1.BaseException("The selector \"" + selectorOrNode + "\" did not match any elements");
        }
      } else {
        el = selectorOrNode;
      }
      dom_adapter_1.getDOM().clearNodes(el);
      return el;
    };
    DomRenderer.prototype.createElement = function(parent, name, debugInfo) {
      var nsAndName = splitNamespace(name);
      var el = lang_1.isPresent(nsAndName[0]) ? dom_adapter_1.getDOM().createElementNS(NAMESPACE_URIS[nsAndName[0]], nsAndName[1]) : dom_adapter_1.getDOM().createElement(nsAndName[1]);
      if (lang_1.isPresent(this._contentAttr)) {
        dom_adapter_1.getDOM().setAttribute(el, this._contentAttr, '');
      }
      if (lang_1.isPresent(parent)) {
        dom_adapter_1.getDOM().appendChild(parent, el);
      }
      return el;
    };
    DomRenderer.prototype.createViewRoot = function(hostElement) {
      var nodesParent;
      if (this.componentProto.encapsulation === core_1.ViewEncapsulation.Native) {
        nodesParent = dom_adapter_1.getDOM().createShadowRoot(hostElement);
        this._rootRenderer.sharedStylesHost.addHost(nodesParent);
        for (var i = 0; i < this._styles.length; i++) {
          dom_adapter_1.getDOM().appendChild(nodesParent, dom_adapter_1.getDOM().createStyleElement(this._styles[i]));
        }
      } else {
        if (lang_1.isPresent(this._hostAttr)) {
          dom_adapter_1.getDOM().setAttribute(hostElement, this._hostAttr, '');
        }
        nodesParent = hostElement;
      }
      return nodesParent;
    };
    DomRenderer.prototype.createTemplateAnchor = function(parentElement, debugInfo) {
      var comment = dom_adapter_1.getDOM().createComment(TEMPLATE_COMMENT_TEXT);
      if (lang_1.isPresent(parentElement)) {
        dom_adapter_1.getDOM().appendChild(parentElement, comment);
      }
      return comment;
    };
    DomRenderer.prototype.createText = function(parentElement, value, debugInfo) {
      var node = dom_adapter_1.getDOM().createTextNode(value);
      if (lang_1.isPresent(parentElement)) {
        dom_adapter_1.getDOM().appendChild(parentElement, node);
      }
      return node;
    };
    DomRenderer.prototype.projectNodes = function(parentElement, nodes) {
      if (lang_1.isBlank(parentElement))
        return;
      appendNodes(parentElement, nodes);
    };
    DomRenderer.prototype.attachViewAfter = function(node, viewRootNodes) {
      moveNodesAfterSibling(node, viewRootNodes);
      for (var i = 0; i < viewRootNodes.length; i++)
        this.animateNodeEnter(viewRootNodes[i]);
    };
    DomRenderer.prototype.detachView = function(viewRootNodes) {
      for (var i = 0; i < viewRootNodes.length; i++) {
        var node = viewRootNodes[i];
        dom_adapter_1.getDOM().remove(node);
        this.animateNodeLeave(node);
      }
    };
    DomRenderer.prototype.destroyView = function(hostElement, viewAllNodes) {
      if (this.componentProto.encapsulation === core_1.ViewEncapsulation.Native && lang_1.isPresent(hostElement)) {
        this._rootRenderer.sharedStylesHost.removeHost(dom_adapter_1.getDOM().getShadowRoot(hostElement));
      }
    };
    DomRenderer.prototype.listen = function(renderElement, name, callback) {
      return this._rootRenderer.eventManager.addEventListener(renderElement, name, decoratePreventDefault(callback));
    };
    DomRenderer.prototype.listenGlobal = function(target, name, callback) {
      return this._rootRenderer.eventManager.addGlobalEventListener(target, name, decoratePreventDefault(callback));
    };
    DomRenderer.prototype.setElementProperty = function(renderElement, propertyName, propertyValue) {
      dom_adapter_1.getDOM().setProperty(renderElement, propertyName, propertyValue);
    };
    DomRenderer.prototype.setElementAttribute = function(renderElement, attributeName, attributeValue) {
      var attrNs;
      var nsAndName = splitNamespace(attributeName);
      if (lang_1.isPresent(nsAndName[0])) {
        attributeName = nsAndName[0] + ':' + nsAndName[1];
        attrNs = NAMESPACE_URIS[nsAndName[0]];
      }
      if (lang_1.isPresent(attributeValue)) {
        if (lang_1.isPresent(attrNs)) {
          dom_adapter_1.getDOM().setAttributeNS(renderElement, attrNs, attributeName, attributeValue);
        } else {
          dom_adapter_1.getDOM().setAttribute(renderElement, attributeName, attributeValue);
        }
      } else {
        if (lang_1.isPresent(attrNs)) {
          dom_adapter_1.getDOM().removeAttributeNS(renderElement, attrNs, nsAndName[1]);
        } else {
          dom_adapter_1.getDOM().removeAttribute(renderElement, attributeName);
        }
      }
    };
    DomRenderer.prototype.setBindingDebugInfo = function(renderElement, propertyName, propertyValue) {
      var dashCasedPropertyName = util_1.camelCaseToDashCase(propertyName);
      if (dom_adapter_1.getDOM().isCommentNode(renderElement)) {
        var existingBindings = lang_1.RegExpWrapper.firstMatch(TEMPLATE_BINDINGS_EXP, lang_1.StringWrapper.replaceAll(dom_adapter_1.getDOM().getText(renderElement), /\n/g, ''));
        var parsedBindings = lang_1.Json.parse(existingBindings[1]);
        parsedBindings[dashCasedPropertyName] = propertyValue;
        dom_adapter_1.getDOM().setText(renderElement, lang_1.StringWrapper.replace(TEMPLATE_COMMENT_TEXT, '{}', lang_1.Json.stringify(parsedBindings)));
      } else {
        this.setElementAttribute(renderElement, propertyName, propertyValue);
      }
    };
    DomRenderer.prototype.setElementClass = function(renderElement, className, isAdd) {
      if (isAdd) {
        dom_adapter_1.getDOM().addClass(renderElement, className);
      } else {
        dom_adapter_1.getDOM().removeClass(renderElement, className);
      }
    };
    DomRenderer.prototype.setElementStyle = function(renderElement, styleName, styleValue) {
      if (lang_1.isPresent(styleValue)) {
        dom_adapter_1.getDOM().setStyle(renderElement, styleName, lang_1.stringify(styleValue));
      } else {
        dom_adapter_1.getDOM().removeStyle(renderElement, styleName);
      }
    };
    DomRenderer.prototype.invokeElementMethod = function(renderElement, methodName, args) {
      dom_adapter_1.getDOM().invoke(renderElement, methodName, args);
    };
    DomRenderer.prototype.setText = function(renderNode, text) {
      dom_adapter_1.getDOM().setText(renderNode, text);
    };
    DomRenderer.prototype.animateNodeEnter = function(node) {
      if (dom_adapter_1.getDOM().isElementNode(node) && dom_adapter_1.getDOM().hasClass(node, 'ng-animate')) {
        dom_adapter_1.getDOM().addClass(node, 'ng-enter');
        this._rootRenderer.animate.css().addAnimationClass('ng-enter-active').start(node).onComplete(function() {
          dom_adapter_1.getDOM().removeClass(node, 'ng-enter');
        });
      }
    };
    DomRenderer.prototype.animateNodeLeave = function(node) {
      if (dom_adapter_1.getDOM().isElementNode(node) && dom_adapter_1.getDOM().hasClass(node, 'ng-animate')) {
        dom_adapter_1.getDOM().addClass(node, 'ng-leave');
        this._rootRenderer.animate.css().addAnimationClass('ng-leave-active').start(node).onComplete(function() {
          dom_adapter_1.getDOM().removeClass(node, 'ng-leave');
          dom_adapter_1.getDOM().remove(node);
        });
      } else {
        dom_adapter_1.getDOM().remove(node);
      }
    };
    return DomRenderer;
  }());
  exports.DomRenderer = DomRenderer;
  function moveNodesAfterSibling(sibling, nodes) {
    var parent = dom_adapter_1.getDOM().parentElement(sibling);
    if (nodes.length > 0 && lang_1.isPresent(parent)) {
      var nextSibling = dom_adapter_1.getDOM().nextSibling(sibling);
      if (lang_1.isPresent(nextSibling)) {
        for (var i = 0; i < nodes.length; i++) {
          dom_adapter_1.getDOM().insertBefore(nextSibling, nodes[i]);
        }
      } else {
        for (var i = 0; i < nodes.length; i++) {
          dom_adapter_1.getDOM().appendChild(parent, nodes[i]);
        }
      }
    }
  }
  function appendNodes(parent, nodes) {
    for (var i = 0; i < nodes.length; i++) {
      dom_adapter_1.getDOM().appendChild(parent, nodes[i]);
    }
  }
  function decoratePreventDefault(eventHandler) {
    return function(event) {
      var allowDefaultBehavior = eventHandler(event);
      if (allowDefaultBehavior === false) {
        dom_adapter_1.getDOM().preventDefault(event);
      }
    };
  }
  var COMPONENT_REGEX = /%COMP%/g;
  exports.COMPONENT_VARIABLE = '%COMP%';
  exports.HOST_ATTR = "_nghost-" + exports.COMPONENT_VARIABLE;
  exports.CONTENT_ATTR = "_ngcontent-" + exports.COMPONENT_VARIABLE;
  function _shimContentAttribute(componentShortId) {
    return lang_1.StringWrapper.replaceAll(exports.CONTENT_ATTR, COMPONENT_REGEX, componentShortId);
  }
  function _shimHostAttribute(componentShortId) {
    return lang_1.StringWrapper.replaceAll(exports.HOST_ATTR, COMPONENT_REGEX, componentShortId);
  }
  function _flattenStyles(compId, styles, target) {
    for (var i = 0; i < styles.length; i++) {
      var style = styles[i];
      if (lang_1.isArray(style)) {
        _flattenStyles(compId, style, target);
      } else {
        style = lang_1.StringWrapper.replaceAll(style, COMPONENT_REGEX, compId);
        target.push(style);
      }
    }
    return target;
  }
  var NS_PREFIX_RE = /^@([^:]+):(.+)/g;
  function splitNamespace(name) {
    if (name[0] != '@') {
      return [null, name];
    }
    var match = lang_1.RegExpWrapper.firstMatch(NS_PREFIX_RE, name);
    return [match[1], match[2]];
  }
  return module.exports;
});

$__System.registerDynamic("75", ["11", "62", "65", "5d", "73"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var core_private_1 = $__require('62');
  var lang_1 = $__require('65');
  var dom_adapter_1 = $__require('5d');
  var dom_renderer_1 = $__require('73');
  var CORE_TOKENS = {
    'ApplicationRef': core_1.ApplicationRef,
    'NgZone': core_1.NgZone
  };
  var INSPECT_GLOBAL_NAME = 'ng.probe';
  var CORE_TOKENS_GLOBAL_NAME = 'ng.coreTokens';
  function inspectNativeElement(element) {
    return core_1.getDebugNode(element);
  }
  exports.inspectNativeElement = inspectNativeElement;
  function _createConditionalRootRenderer(rootRenderer) {
    if (lang_1.assertionsEnabled()) {
      return _createRootRenderer(rootRenderer);
    }
    return rootRenderer;
  }
  function _createRootRenderer(rootRenderer) {
    dom_adapter_1.getDOM().setGlobalVar(INSPECT_GLOBAL_NAME, inspectNativeElement);
    dom_adapter_1.getDOM().setGlobalVar(CORE_TOKENS_GLOBAL_NAME, CORE_TOKENS);
    return new core_private_1.DebugDomRootRenderer(rootRenderer);
  }
  exports.ELEMENT_PROBE_PROVIDERS = [{
    provide: core_1.RootRenderer,
    useFactory: _createConditionalRootRenderer,
    deps: [dom_renderer_1.DomRootRenderer]
  }];
  exports.ELEMENT_PROBE_PROVIDERS_PROD_MODE = [{
    provide: core_1.RootRenderer,
    useFactory: _createRootRenderer,
    deps: [dom_renderer_1.DomRootRenderer]
  }];
  return module.exports;
});

$__System.registerDynamic("7b", ["11", "76", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var common_1 = $__require('76');
  var dom_adapter_1 = $__require('5d');
  var BrowserPlatformLocation = (function(_super) {
    __extends(BrowserPlatformLocation, _super);
    function BrowserPlatformLocation() {
      _super.call(this);
      this._init();
    }
    BrowserPlatformLocation.prototype._init = function() {
      this._location = dom_adapter_1.getDOM().getLocation();
      this._history = dom_adapter_1.getDOM().getHistory();
    };
    Object.defineProperty(BrowserPlatformLocation.prototype, "location", {
      get: function() {
        return this._location;
      },
      enumerable: true,
      configurable: true
    });
    BrowserPlatformLocation.prototype.getBaseHrefFromDOM = function() {
      return dom_adapter_1.getDOM().getBaseHref();
    };
    BrowserPlatformLocation.prototype.onPopState = function(fn) {
      dom_adapter_1.getDOM().getGlobalEventTarget('window').addEventListener('popstate', fn, false);
    };
    BrowserPlatformLocation.prototype.onHashChange = function(fn) {
      dom_adapter_1.getDOM().getGlobalEventTarget('window').addEventListener('hashchange', fn, false);
    };
    Object.defineProperty(BrowserPlatformLocation.prototype, "pathname", {
      get: function() {
        return this._location.pathname;
      },
      set: function(newPath) {
        this._location.pathname = newPath;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BrowserPlatformLocation.prototype, "search", {
      get: function() {
        return this._location.search;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BrowserPlatformLocation.prototype, "hash", {
      get: function() {
        return this._location.hash;
      },
      enumerable: true,
      configurable: true
    });
    BrowserPlatformLocation.prototype.pushState = function(state, title, url) {
      this._history.pushState(state, title, url);
    };
    BrowserPlatformLocation.prototype.replaceState = function(state, title, url) {
      this._history.replaceState(state, title, url);
    };
    BrowserPlatformLocation.prototype.forward = function() {
      this._history.forward();
    };
    BrowserPlatformLocation.prototype.back = function() {
      this._history.back();
    };
    BrowserPlatformLocation.decorators = [{type: core_1.Injectable}];
    BrowserPlatformLocation.ctorParameters = [];
    return BrowserPlatformLocation;
  }(common_1.PlatformLocation));
  exports.BrowserPlatformLocation = BrowserPlatformLocation;
  return module.exports;
});

$__System.registerDynamic("7c", ["11", "65", "71", "75", "7b"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('65');
  var browser_common_1 = $__require('71');
  var ng_probe_1 = $__require('75');
  exports.ELEMENT_PROBE_PROVIDERS = ng_probe_1.ELEMENT_PROBE_PROVIDERS;
  var browser_platform_location_1 = $__require('7b');
  exports.BrowserPlatformLocation = browser_platform_location_1.BrowserPlatformLocation;
  var browser_common_2 = $__require('71');
  exports.BROWSER_PROVIDERS = browser_common_2.BROWSER_PROVIDERS;
  exports.By = browser_common_2.By;
  exports.Title = browser_common_2.Title;
  exports.enableDebugTools = browser_common_2.enableDebugTools;
  exports.disableDebugTools = browser_common_2.disableDebugTools;
  exports.BROWSER_APP_STATIC_PROVIDERS = browser_common_1.BROWSER_APP_COMMON_PROVIDERS;
  function browserStaticPlatform() {
    if (lang_1.isBlank(core_1.getPlatform())) {
      core_1.createPlatform(core_1.ReflectiveInjector.resolveAndCreate(browser_common_1.BROWSER_PROVIDERS));
    }
    return core_1.assertPlatform(browser_common_1.BROWSER_PLATFORM_MARKER);
  }
  exports.browserStaticPlatform = browserStaticPlatform;
  function bootstrapStatic(appComponentType, customProviders, initReflector) {
    if (lang_1.isPresent(initReflector)) {
      initReflector();
    }
    var appProviders = lang_1.isPresent(customProviders) ? [exports.BROWSER_APP_STATIC_PROVIDERS, customProviders] : exports.BROWSER_APP_STATIC_PROVIDERS;
    var appInjector = core_1.ReflectiveInjector.resolveAndCreate(appProviders, browserStaticPlatform().injector);
    return core_1.coreLoadAndBootstrap(appInjector, appComponentType);
  }
  exports.bootstrapStatic = bootstrapStatic;
  return module.exports;
});

$__System.registerDynamic("7d", ["11", "65", "71", "68", "67", "75", "57", "72", "61", "7c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  var core_1 = $__require('11');
  var lang_1 = $__require('65');
  var browser_common_1 = $__require('71');
  var dom_events_1 = $__require('68');
  exports.DomEventsPlugin = dom_events_1.DomEventsPlugin;
  var event_manager_1 = $__require('67');
  exports.EventManager = event_manager_1.EventManager;
  exports.EVENT_MANAGER_PLUGINS = event_manager_1.EVENT_MANAGER_PLUGINS;
  var ng_probe_1 = $__require('75');
  exports.ELEMENT_PROBE_PROVIDERS = ng_probe_1.ELEMENT_PROBE_PROVIDERS;
  var browser_common_2 = $__require('71');
  exports.BROWSER_APP_COMMON_PROVIDERS = browser_common_2.BROWSER_APP_COMMON_PROVIDERS;
  exports.BROWSER_SANITIZATION_PROVIDERS = browser_common_2.BROWSER_SANITIZATION_PROVIDERS;
  exports.BROWSER_PROVIDERS = browser_common_2.BROWSER_PROVIDERS;
  exports.By = browser_common_2.By;
  exports.Title = browser_common_2.Title;
  exports.enableDebugTools = browser_common_2.enableDebugTools;
  exports.disableDebugTools = browser_common_2.disableDebugTools;
  exports.HAMMER_GESTURE_CONFIG = browser_common_2.HAMMER_GESTURE_CONFIG;
  exports.HammerGestureConfig = browser_common_2.HammerGestureConfig;
  __export($__require('57'));
  var dom_tokens_1 = $__require('72');
  exports.DOCUMENT = dom_tokens_1.DOCUMENT;
  var dom_sanitization_service_1 = $__require('61');
  exports.DomSanitizationService = dom_sanitization_service_1.DomSanitizationService;
  exports.SecurityContext = dom_sanitization_service_1.SecurityContext;
  var platform_browser_static_1 = $__require('7c');
  exports.bootstrapStatic = platform_browser_static_1.bootstrapStatic;
  exports.browserStaticPlatform = platform_browser_static_1.browserStaticPlatform;
  exports.BROWSER_APP_STATIC_PROVIDERS = platform_browser_static_1.BROWSER_APP_STATIC_PROVIDERS;
  exports.BrowserPlatformLocation = platform_browser_static_1.BrowserPlatformLocation;
  function browserPlatform() {
    if (lang_1.isBlank(core_1.getPlatform())) {
      core_1.createPlatform(core_1.ReflectiveInjector.resolveAndCreate(browser_common_1.BROWSER_PROVIDERS));
    }
    return core_1.assertPlatform(browser_common_1.BROWSER_PLATFORM_MARKER);
  }
  exports.browserPlatform = browserPlatform;
  return module.exports;
});

$__System.registerDynamic("7e", ["7d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('7d'));
  return module.exports;
});

$__System.registerDynamic("7f", ["7e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('7e');
  return module.exports;
});

$__System.registerDynamic("80", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  exports.ReflectionCapabilities = core_1.__core_private__.ReflectionCapabilities;
  return module.exports;
});

$__System.registerDynamic("81", ["a", "8", "5", "56", "7f", "11", "80", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var compiler_1 = $__require('a');
    var xhr_cache_1 = $__require('8');
    var lang_1 = $__require('5');
    var xhr_impl_1 = $__require('56');
    var platform_browser_1 = $__require('7f');
    var core_1 = $__require('11');
    var core_private_1 = $__require('80');
    exports.CACHED_TEMPLATE_PROVIDER = [{
      provide: compiler_1.XHR,
      useClass: xhr_cache_1.CachedXHR
    }];
    exports.BROWSER_APP_DYNAMIC_PROVIDERS = [platform_browser_1.BROWSER_APP_COMMON_PROVIDERS, compiler_1.COMPILER_PROVIDERS, {
      provide: compiler_1.XHR,
      useClass: xhr_impl_1.XHRImpl
    }];
    function bootstrap(appComponentType, customProviders) {
      core_1.reflector.reflectionCapabilities = new core_private_1.ReflectionCapabilities();
      var appInjector = core_1.ReflectiveInjector.resolveAndCreate([exports.BROWSER_APP_DYNAMIC_PROVIDERS, lang_1.isPresent(customProviders) ? customProviders : []], platform_browser_1.browserPlatform().injector);
      return core_1.coreLoadAndBootstrap(appInjector, appComponentType);
    }
    exports.bootstrap = bootstrap;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("82", ["81"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('81'));
  return module.exports;
});

$__System.registerDynamic("83", ["82"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('82');
  return module.exports;
});

$__System.register('84', ['85', '86', '87', '88', '89', '8a'], function (_export) {
  var SchemaManager, RedocComponent, BaseComponent, OptionsService, _get, _inherits, _createClass, _classCallCheck, ApiInfo;

  return {
    setters: [function (_4) {
      SchemaManager = _4.SchemaManager;
      RedocComponent = _4.RedocComponent;
      BaseComponent = _4.BaseComponent;
    }, function (_5) {
      OptionsService = _5.OptionsService;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {
      'use strict';

      ApiInfo = (function (_BaseComponent) {
        _inherits(ApiInfo, _BaseComponent);

        function ApiInfo(schemaMgr, optionsService) {
          _classCallCheck(this, _ApiInfo);

          _get(Object.getPrototypeOf(_ApiInfo.prototype), 'constructor', this).call(this, schemaMgr);
          this.optionsService = optionsService;
        }

        _createClass(ApiInfo, [{
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = this.componentSchema.info;
            this.specUrl = this.optionsService.options.specUrl;
          }
        }]);

        var _ApiInfo = ApiInfo;
        ApiInfo = Reflect.metadata('parameters', [[SchemaManager], [OptionsService]])(ApiInfo) || ApiInfo;
        ApiInfo = RedocComponent({
          selector: 'api-info',
          styles: ['\n    .api-info-header{font-weight:normal}:host>div{width:60%}a.openapi-button{padding:3px 8px 4px 8px;color:#0033a0;border:1px solid #0033a0;margin-left:0.5em;font-weight:normal}\n  '],
          template: '\n    <div>\n      <h1 class="api-info-header">{{data.title}} ({{data.version}})</h1>\n      <p *ngIf="data.description" innerHtml="{{data.description | marked}}"> </p>\n      <p>\n        <!-- TODO: create separate components for contact and license ? -->\n        <span *ngIf="data.contact"> Contact:\n          <a *ngIf="data.contact.url" href="{{data.contact.url}}">\n            {{data.contact.name || data.contact.url}}</a>\n          <a *ngIf="data.contact.email" href="mailto:{{data.contact.email}}">\n            {{data.contact.email}}</a>\n        </span>\n        <span *ngIf="data.license"> License:\n          <a *ngIf="data.license.url" href="{{data.license.url}}"> {{data.license.name}} </a>\n          <span *ngIf="!data.license.url"> {{data.license.name}} </span>\n        </span>\n      </p>\n      <p>\n        Download OpenAPI (fka Swagger) specification:\n        <a class="openapi-button" target="_blank" attr.href=\'{{specUrl}}\'> Download </a>\n      </p>\n    </div>\n  '
        })(ApiInfo) || ApiInfo;
        return ApiInfo;
      })(BaseComponent);

      _export('ApiInfo', ApiInfo);
    }
  };
});
$__System.register('8b', ['85', '87', '88', '89', '8a'], function (_export) {
  var RedocComponent, BaseComponent, _get, _inherits, _createClass, _classCallCheck, ApiLogo;

  return {
    setters: [function (_4) {
      RedocComponent = _4.RedocComponent;
      BaseComponent = _4.BaseComponent;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {
      'use strict';

      ApiLogo = (function (_BaseComponent) {
        _inherits(ApiLogo, _BaseComponent);

        function ApiLogo(schemaMgr) {
          _classCallCheck(this, _ApiLogo);

          _get(Object.getPrototypeOf(_ApiLogo.prototype), 'constructor', this).call(this, schemaMgr);
        }

        _createClass(ApiLogo, [{
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = {};
            var logoInfo = this.componentSchema.info['x-logo'];
            if (!logoInfo) return;
            this.data.imgUrl = logoInfo.url;
            this.data.bgColor = logoInfo.backgroundColor || 'transparent';
          }
        }]);

        var _ApiLogo = ApiLogo;
        ApiLogo = RedocComponent({
          selector: 'api-logo',
          styles: ['\n    img{max-height:150px;width:auto;display:inline-block;max-width:100%;box-sizing:border-box}\n  '],
          template: '\n    <img *ngIf="data.imgUrl" [attr.src]="data.imgUrl" [ngStyle]="{\'background-color\': data.bgColor}">\n  '
        })(ApiLogo) || ApiLogo;
        return ApiLogo;
      })(BaseComponent);

      _export('ApiLogo', ApiLogo);
    }
  };
});
$__System.register('8c', ['85', '87', '88', '89', '8a', '8f', '8d', '8e'], function (_export) {
  var RedocComponent, BaseComponent, _get, _inherits, _createClass, _classCallCheck, _Object$keys, JsonSchema, JsonSchemaLazy, ParamsList;

  function safePush(obj, prop, item) {
    if (!obj[prop]) obj[prop] = [];
    obj[prop].push(item);
  }

  return {
    setters: [function (_4) {
      RedocComponent = _4.RedocComponent;
      BaseComponent = _4.BaseComponent;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_d) {
      JsonSchema = _d.JsonSchema;
    }, function (_e) {
      JsonSchemaLazy = _e.JsonSchemaLazy;
    }],
    execute: function () {
      'use strict';

      ParamsList = (function (_BaseComponent) {
        _inherits(ParamsList, _BaseComponent);

        function ParamsList(schemaMgr) {
          _classCallCheck(this, _ParamsList);

          _get(Object.getPrototypeOf(_ParamsList.prototype), 'constructor', this).call(this, schemaMgr);
        }

        _createClass(ParamsList, [{
          key: 'prepareModel',
          value: function prepareModel() {
            var _this = this;

            this.data = {};
            var paramsList = this.schemaMgr.getMethodParams(this.pointer, true);

            paramsList = paramsList.map(function (paramData) {
              var propPointer = paramData._pointer;
              if (paramData['in'] === 'body') return paramData;
              return JsonSchema.injectPropertyData(paramData, paramData.name, propPointer, _this.pointer);
            });

            var paramsMap = this.orderParams(paramsList);

            if (paramsMap.body && paramsMap.body.length) {
              var bodyParam = paramsMap.body[0];
              bodyParam.pointer = bodyParam._pointer;
              this.data.bodyParam = bodyParam;
              paramsMap.body = undefined;
            }

            this.data.noParams = !(_Object$keys(paramsMap).length || this.data.bodyParam);

            var paramsPlaces = ['path', 'query', 'formData', 'header', 'body'];
            var placeHint = {
              path: 'Used together with Path Templating, where the parameter value is actually part\n        of the operation\'s URL. This does not include the host or base path of the API.\n        For example, in /items/{itemId}, the path parameter is itemId',
              query: 'Parameters that are appended to the URL.\n        For example, in /items?id=###, the query parameter is id',
              formData: 'Parameters that are submitted through a form.\n        application/x-www-form-urlencoded, multipart/form-data or both are usually\n        used as the content type of the request',
              header: 'Custom headers that are expected as part of the request'
            };
            var params = [];
            paramsPlaces.forEach(function (place) {
              if (paramsMap[place] && paramsMap[place].length) {
                params.push({ place: place, placeHint: placeHint[place], params: paramsMap[place] });
              }
            });
            this.data.params = params;
          }
        }, {
          key: 'orderParams',
          value: function orderParams(params) {
            var res = {};
            params.forEach(function (param) {
              return safePush(res, param['in'], param);
            });
            return res;
          }
        }]);

        var _ParamsList = ParamsList;
        ParamsList = RedocComponent({
          selector: 'params-list',
          template: '\n    <h5 class="param-list-header" *ngIf="data.params.length"> Parameters </h5>\n    <template ngFor [ngForOf]="data.params" let-paramType="$implicit">\n      <header class="paramType">\n        {{paramType.place}} Parameters\n        <span class="hint--top-right hint--large" [attr.data-hint]="paramType.placeHint">?</span>\n      </header>\n      <br>\n      <div class="params-wrap">\n        <div *ngFor="let param of paramType.params" class="param">\n            <div class="param-name">\n              <span class="param-name-content"> {{param.name}} </span>\n            </div>\n            <div class="param-info">\n              <div>\n                <span class="param-type {{param.type}}" [ngClass]="{\'with-hint\': param._displayTypeHint}"\n                title="{{param._displayTypeHint}}"> {{param._displayType}} {{param._displayFormat}}</span>\n                <span *ngIf="param.required" class="param-required">Required</span>\n                <div *ngIf="param.enum" class="param-enum">\n                  <span *ngFor="let enumItem of param.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>\n                </div>\n              </div>\n              <div class="param-description" innerHtml="{{param.description | marked}}"></div>\n            </div>\n        </div>\n      </div>\n    </template>\n\n    <div *ngIf="data.bodyParam">\n      <h5 class="param-list-header" *ngIf="data.bodyParam"> Request Body </h5>\n\n      <div class="body-param-description" innerHtml="{{data.bodyParam.description | marked}}"></div>\n      <div>\n        <br>\n        <json-schema-lazy [isRequestSchema]="true" [auto]="true" pointer="{{data.bodyParam.pointer}}/schema">\n        </json-schema-lazy>\n      </div>\n    </div>\n  ',
          styles: ['\n    .param-list-header{border-bottom:1px solid rgba(38,50,56,0.3);padding:0.2em 0;margin:3.5em 0 .8em 0;color:rgba(38,50,56,0.5);font-weight:normal;text-transform:uppercase}.param-name{font-size:0.929em;padding:10px 0 10px 0;font-weight:400;box-sizing:border-box;line-height:20px;border-left:1px solid rgba(0,51,160,0.5);white-space:nowrap;position:relative;vertical-align:top}.param-name-content{padding-right:25px;display:inline-block;font-family:Montserrat,sans-serif}.param-info{padding:10px 0;box-sizing:border-box;border-bottom:1px solid #ccc;width:75%}.param-range{color:rgba(0,51,160,0.7);position:relative;top:1px;padding:0 4px;border-radius:2px;background-color:rgba(0,51,160,0.1);margin-left:6px}.param-description{font-size:13px}.param-required{color:red;font-weight:bold;font-size:12px;line-height:20px;vertical-align:middle}.param-type{color:rgba(38,50,56,0.4);font-size:0.929em;line-height:20px;vertical-align:middle;font-weight:normal}.param-type.array:before{content:"Array of ";color:#263238;font-weight:300}.param-type.with-hint{display:inline-block;margin-bottom:0.4em;border-bottom:1px dotted rgba(38,50,56,0.4);padding:0;cursor:help}.param-type-trivial{margin:10px 10px 0;display:inline-block}.param-name>span:before{content:"";display:inline-block;width:1px;height:7px;background-color:#0033a0;margin:0 10px;vertical-align:middle}.param-name>span:after{content:"";position:absolute;border-top:1px solid rgba(0,51,160,0.5);width:10px;left:0;top:21px}.param:first-of-type>.param-name:before{content:"";display:block;position:absolute;left:-1px;top:0;border-left:2px solid #fff;height:21px}.param:last-of-type>.param-name,.param.last>.param-name{position:relative}.param:last-of-type>.param-name:after,.param.last>.param-name:after{content:"";display:block;position:absolute;left:-2px;border-left:2px solid #fff;top:22px;background-color:white;bottom:0}.param-wrap:last-of-type>.param-schema{border-left-color:transparent}.param-schema .param-wrap:first-of-type .param-name:before{display:none !important}.param-schema.last>td{border-left:0}.param-enum{color:#263238;font-size:13px}.param-enum:before{content:"Values: {"}.param-enum:after{content:"}"}.param-enum>.enum-value:after{content:", "}.param-enum>.enum-value:last-of-type:after{content:none}header.paramType{margin:10px 0;text-transform:capitalize}.params-wrap{display:table;width:100%}.param-name{display:table-cell;vertical-align:top}.param-info{display:table-cell;width:100%}.param{display:table-row}.param:last-of-type>.param-name{border-left:0}.param:last-of-type>.param-name:after{content:"";display:block;position:absolute;left:0;border-left:1px solid rgba(0,51,160,0.5);height:21px;background-color:white;top:0}.param:first-of-type .param-name:after{content:"";display:block;position:absolute;left:-1px;border-left:2px solid #fff;height:20px;background-color:white;top:0}[data-hint]{width:1.2em;text-align:center;border-radius:50%;vertical-align:middle;color:#999;line-height:1.2;text-transform:none;cursor:help;border:1px solid #999;margin-left:0.5em}@media (max-width: 520px){[data-hint]{float:right}[data-hint]:after{margin-left:12px;transform:translateX(-100%) translateY(-8px);-moz-transform:translateX(-100%) translateY(-8px);-webkit-transform:translateX(-100%) translateY(-8px)}}\n  '],
          directives: [JsonSchema, JsonSchemaLazy]
        })(ParamsList) || ParamsList;
        return ParamsList;
      })(BaseComponent);

      _export('ParamsList', ParamsList);
    }
  };
});
$__System.register('8d', ['11', '85', '87', '88', '89', '90', '91', '92', '8a', '8f'], function (_export) {
  var ElementRef, RedocComponent, BaseComponent, SchemaManager, _get, _inherits, _createClass, DropDown, JsonPointer, _Object$assign, _classCallCheck, _Object$keys, JsonSchema, injectors;

  function runInjectors(injectTo, propertySchema, propertyPointer, hostPointer) {
    for (var injName in injectors) {
      var injector = injectors[injName];
      if (injector.check(propertySchema)) {
        injector.inject(injectTo, propertySchema, propertyPointer, hostPointer);
      }
    }
  }

  return {
    setters: [function (_5) {
      ElementRef = _5.ElementRef;
    }, function (_6) {
      RedocComponent = _6.RedocComponent;
      BaseComponent = _6.BaseComponent;
      SchemaManager = _6.SchemaManager;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_7) {
      DropDown = _7.DropDown;
    }, function (_8) {
      JsonPointer = _8['default'];
    }, function (_4) {
      _Object$assign = _4['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }],
    execute: function () {
      'use strict';

      JsonSchema = (function (_BaseComponent) {
        _inherits(JsonSchema, _BaseComponent);

        function JsonSchema(schemaMgr, elementRef) {
          _classCallCheck(this, _JsonSchema);

          _get(Object.getPrototypeOf(_JsonSchema.prototype), 'constructor', this).call(this, schemaMgr);
          this.$element = elementRef.nativeElement;
          this.final = false;
        }

        _createClass(JsonSchema, [{
          key: 'selectDerived',
          value: function selectDerived(subClassIdx) {
            var subClass = this.schema.derived[subClassIdx];
            if (!subClass || subClass.active) return;
            this.schema.derived.forEach(function (subSchema) {
              subSchema.active = false;
            });
            subClass.active = true;
            this.derivedEmtpy = false;
            if (subClass.empty) this.derivedEmtpy = true;
          }
        }, {
          key: 'unwrapArray',
          value: function unwrapArray(schema) {
            var res = schema;
            if (schema && schema.type === 'array') {
              var ptr = schema.items._pointer || JsonPointer.join(schema._pointer || this.pointer, ['items']);
              res = schema.items;
              res._isArray = true;
              res._pointer = ptr;
              res = this.unwrapArray(res);
            }
            return res;
          }
        }, {
          key: 'prepareModel',
          value: function prepareModel() {
            if (!this.componentSchema) {
              throw new Error('Can\'t load component schema at ' + this.pointer);
            }
            this.dereference();

            var schema = this.componentSchema;
            BaseComponent.joinAllOf(schema, { omitParent: true });
            this.schema = schema = this.unwrapArray(schema);
            runInjectors(schema, schema, schema._pointer || this.pointer, this.pointer);

            schema.derived = schema.derived || [];

            if (!schema.isTrivial) {
              this.prepareObjectPropertiesData(schema);
            }

            this.initDerived();
          }
        }, {
          key: 'initDerived',
          value: function initDerived() {
            var _this = this;

            if (!this.schema.derived.length) return;
            var enumArr = this.schema.properties[this.schema.properties.length - 1]['enum'];
            if (enumArr) {
              (function () {
                var enumOrder = {};
                enumArr.forEach(function (enumItem, idx) {
                  enumOrder[enumItem.val] = idx;
                });

                _this.schema.derived.sort(function (a, b) {
                  return enumOrder[a.name] > enumOrder[b.name];
                });
              })();
            }
            this.selectDerived(0);
          }
        }, {
          key: 'prepareObjectPropertiesData',
          value: function prepareObjectPropertiesData(schema) {
            var _this2 = this;

            var requiredMap = {};
            if (schema.required) {
              schema.required.forEach(function (prop) {
                return requiredMap[prop] = true;
              });
            }

            var discriminatorFieldIdx = -1;
            var props = schema.properties && _Object$keys(schema.properties).map(function (prop, idx) {
              var propertySchema = schema.properties[prop];
              var propPointer = propertySchema._pointer || JsonPointer.join(schema._pointer || _this2.pointer, ['properties', prop]);
              propertySchema = JsonSchema.injectPropertyData(propertySchema, prop, propPointer);
              // stop endless discriminator recursion
              if (propertySchema._pointer === _this2.childFor) {
                propertySchema._pointer = null;
              }
              propertySchema.required = !!requiredMap[prop];
              propertySchema.isDiscriminator = schema.discriminator === prop;
              if (propertySchema.isDiscriminator) {
                discriminatorFieldIdx = idx;
              }
              return propertySchema;
            });

            props = props || [];

            if (schema.additionalProperties && schema.additionalProperties !== false) {
              var propsSchema = this.prepareAdditionalProperties(schema);
              propsSchema._additional = true;
              props.push(propsSchema);
            }

            // Move discriminator field to the end of properties list
            if (discriminatorFieldIdx > -1) {
              var discrProp = props.splice(discriminatorFieldIdx, 1);
              props.push(discrProp[0]);
            }
            // filter readOnly props for request schemas
            if (this.isRequestSchema) {
              props = props.filter(function (prop) {
                return !prop.readOnly;
              });
            }
            schema.properties = props;
          }
        }, {
          key: 'prepareAdditionalProperties',
          value: function prepareAdditionalProperties(schema) {
            var addProps = schema.additionalProperties;
            return JsonSchema.injectPropertyData(addProps, '<Additional Properties> *', JsonPointer.join(addProps._pointer || schema._pointer || this.pointer, ['additionalProperties']));
          }
        }], [{
          key: 'injectPropertyData',
          value: function injectPropertyData(propertySchema, propertyName, propPointer, hostPointer) {
            propertySchema = _Object$assign({}, propertySchema);

            propertySchema._name = propertyName;
            runInjectors(propertySchema, propertySchema, propPointer, hostPointer);

            return propertySchema;
          }
        }]);

        var _JsonSchema = JsonSchema;
        JsonSchema = Reflect.metadata('parameters', [[SchemaManager], [ElementRef]])(JsonSchema) || JsonSchema;
        JsonSchema = RedocComponent({
          selector: 'json-schema',
          template: '\n    <span *ngIf="schema.isFile" class="param-wrap">\n      <span class="param-file">file</span>\n      <div *ngIf="schema._produces && !isRequestSchema" class="file produces">\n        Produces: {{ schema._produces | json }}\n      </div>\n      <div *ngIf="schema._consumes && isRequestSchema" class="file consume">\n        Consumes: {{ schema._consumes | json }}\n      </div>\n    </span>\n    <span *ngIf="schema.isTrivial && !schema.isFile" class="param-wrap">\n      <span class="param-type param-type-trivial {{schema.type}}"\n        [ngClass]="{\'with-hint\': schema._displayTypeHint}"\n        title="{{schema._displayTypeHint}}">{{schema._displayType}} {{schema._displayFormat}}\n        <span class="param-range" *ngIf="schema._range"> {{schema._range}} </span>\n      </span>\n      <div *ngIf="schema.enum" class="param-enum">\n        <span *ngFor="let enumItem of schema.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>\n      </div>\n    </span>\n    <table *ngIf="!schema.isTrivial" class="params-wrap" [ngClass]="{\'params-array\': schema._isArray}">\n      <!-- <caption> {{_displayType}} </caption> -->\n      <template ngFor [ngForOf]="schema.properties" let-prop="$implicit" let-last="last">\n        <tr class="param" [ngClass]="{\'last\': last,\n            \'discriminator\': prop.isDiscriminator && !derivedEmtpy,\n            \'complex\': prop._pointer,\n            \'additional\': prop._additional\n          }">\n          <td class="param-name">\n            <span class="param-name-content">{{prop._name}}</span>\n          </td>\n          <td class="param-info">\n            <div>\n              <span class="param-type {{prop.type}}" [ngClass]="{\'with-hint\': prop._displayTypeHint}"\n              title="{{prop._displayTypeHint}}"> {{prop._displayType}} {{prop._displayFormat}}\n              <span class="param-range" *ngIf="prop._range"> {{prop._range}} </span>\n              </span>\n              <span *ngIf="prop.required" class="param-required">Required</span>\n              <div *ngIf="prop.enum && !prop.isDiscriminator" class="param-enum">\n                <span *ngFor="let enumItem of prop.enum" class="enum-value {{enumItem.type}}"> {{enumItem.val | json}} </span>\n              </div>\n            </div>\n            <div class="param-description" innerHtml="{{prop.description | marked}}"></div>\n            <div class="discriminator-info" *ngIf="prop.isDiscriminator">\n              <span>This field value determines the exact schema:</span>\n              <dropdown (change)="selectDerived($event)">\n                <option *ngFor="let derived of schema.derived; let i=index"\n                [value]="i">{{derived.name}}</option>\n              </dropdown>\n            </div>\n          </td>\n        </tr>\n        <tr class="param-schema" [ngClass]="{\'param-array\': prop._isArray, \'last\': last}" *ngIf="prop._pointer">\n          <td colspan="2">\n            <json-schema class="nested-schema" pointer="{{prop._pointer}}" [isArray]=\'prop._isArray\'\n            [nestOdd]="!nestOdd" [isRequestSchema]="isRequestSchema" [attr.nesteven]="!nestOdd">\n            </json-schema>\n          </td>\n        </tr>\n      </template>\n      <tr *ngIf="schema.derived.length" class="param-wrap discriminator-wrap" [ngClass]="{\'empty\': derivedEmtpy}">\n        <td colspan="2">\n          <div class="derived-schema" *ngFor="let derived of schema.derived" [ngClass]="{active: derived.active}">\n            <json-schema class="discriminator-part" *ngIf="!derived.empty" [childFor]="pointer"\n            pointer="{{derived.$ref}}" [final]="derived.final" [isRequestSchema]="isRequestSchema">\n            </json-schema>\n          </div>\n        </td>\n      </tr>\n    </table>\n  ',
          styles: ['\n    .param-name{font-size:0.929em;padding:10px 0 10px 0;font-weight:400;box-sizing:border-box;line-height:20px;border-left:1px solid rgba(0,51,160,0.5);white-space:nowrap;position:relative;vertical-align:top}.param-name-content{padding-right:25px;display:inline-block;font-family:Montserrat,sans-serif}.param-info{padding:10px 0;box-sizing:border-box;border-bottom:1px solid #ccc;width:75%}.param-range{color:rgba(0,51,160,0.7);position:relative;top:1px;padding:0 4px;border-radius:2px;background-color:rgba(0,51,160,0.1);margin-left:6px}.param-description{font-size:13px}.param-required{color:red;font-weight:bold;font-size:12px;line-height:20px;vertical-align:middle}.param-type{color:rgba(38,50,56,0.4);font-size:0.929em;line-height:20px;vertical-align:middle;font-weight:normal}.param-type.array:before{content:"Array of ";color:#263238;font-weight:300}.param-type.with-hint{display:inline-block;margin-bottom:0.4em;border-bottom:1px dotted rgba(38,50,56,0.4);padding:0;cursor:help}.param-type-trivial{margin:10px 10px 0;display:inline-block}.param-name>span:before{content:"";display:inline-block;width:1px;height:7px;background-color:#0033a0;margin:0 10px;vertical-align:middle}.param-name>span:after{content:"";position:absolute;border-top:1px solid rgba(0,51,160,0.5);width:10px;left:0;top:21px}.param:first-of-type>.param-name:before{content:"";display:block;position:absolute;left:-1px;top:0;border-left:2px solid #fff;height:21px}.param:last-of-type>.param-name,.param.last>.param-name{position:relative}.param:last-of-type>.param-name:after,.param.last>.param-name:after{content:"";display:block;position:absolute;left:-2px;border-left:2px solid #fff;top:22px;background-color:white;bottom:0}.param-wrap:last-of-type>.param-schema{border-left-color:transparent}.param-schema .param-wrap:first-of-type .param-name:before{display:none !important}.param-schema.last>td{border-left:0}.param-enum{color:#263238;font-size:13px}.param-enum:before{content:"Values: {"}.param-enum:after{content:"}"}.param-enum>.enum-value:after{content:", "}.param-enum>.enum-value:last-of-type:after{content:none}:host{display:block}.param-schema>td{border-left:1px solid rgba(0,51,160,0.5);padding:0 10px}.derived-schema{display:none}.derived-schema.active{display:block}json-schema.nested-schema{background-color:white;padding:10px 20px;position:relative;border-radius:2px}json-schema.nested-schema:before,json-schema.nested-schema:after{content:"";width:0;height:0;position:absolute;top:0;border-style:solid;border-color:transparent;border-width:10px 15px 0;margin-left:-7.5px;border-top-color:#f0f0f0}json-schema.nested-schema:before{left:10%}json-schema.nested-schema:after{right:10%}json-schema.nested-schema .param:first-of-type>.param-name:before,json-schema.nested-schema .param:last-of-type>.param-name:after{border-color:white}json-schema[nesteven="true"]{background-color:#f0f0f0;border-radius:2px}json-schema[nesteven="true"]:before,json-schema[nesteven="true"]:after{border-top-color:white}json-schema[nesteven="true"]>.params-wrap>.param:first-of-type>.param-name:before,json-schema[nesteven="true"]>.params-wrap>.param:last-of-type>.param-name:after{border-color:#f0f0f0}json-schema[nesteven="true"]>.params-wrap>.param:last-of-type>.param-name:after,json-schema[nesteven="true"]>.params-wrap>.param.last>.param-name:after{border-color:#f0f0f0}.param.complex>.param-info{border-bottom:0}.param.additional>.param-name{color:rgba(38,50,56,0.4)}.params-wrap{border-collapse:collapse;width:100%}.params-wrap.params-array:before,.params-wrap.params-array:after{display:block;font-weight:300;color:#263238;font-size:13px;line-height:1.5}.params-wrap.params-array:after{content:"]"}.params-wrap.params-array:before{content:"Array [";padding-top:1em}.params-wrap.params-array{padding-left:10px}.param-schema.param-array:before{bottom:9.75px;width:10px;border-left-style:dashed;border-bottom:1px dashed rgba(0,51,160,0.5)}.params-wrap.params-array>.param-wrap:first-of-type>.param>.param-name:after{content:"";display:block;position:absolute;left:-1px;top:0;border-left:2px solid #fff;height:20px}.params-wrap>.param>.param-schema.param-array{border-left-color:transparent}.param.discriminator>.param-info{padding-bottom:0;border-bottom:0}.param.discriminator>.param-name:after{display:none}.discriminator-info{font-weight:400;margin-bottom:10px}.discriminator-info>span{font-size:0.9em;font-weight:300}.discriminator-wrap:not(.empty)>td{padding:0;position:relative}.discriminator-wrap:not(.empty)>td:before{content:"";display:block;position:absolute;left:0;top:0;border-left:1px solid rgba(0,51,160,0.5);height:21px;z-index:1}ul{text-align:left;margin:0;padding:0;display:block}li{margin:0.5em 0.3em 0.2em 0;font-family:Montserrat,sans-serif;font-size:.929em;line-height:.929em;border:0;color:white;padding:2px 8px 4px 8px;border-radius:2px;background-color:rgba(38,50,56,0.3);display:inline-block;cursor:pointer}li:last-of-type{margin-right:0}li.active{background-color:#0033a0}\n  '],
          directives: [JsonSchema, DropDown],
          inputs: ['isArray', 'final', 'nestOdd', 'childFor', 'isRequestSchema']
        })(JsonSchema) || JsonSchema;
        return JsonSchema;
      })(BaseComponent);

      _export('JsonSchema', JsonSchema);

      injectors = {
        general: {
          check: function check() {
            return true;
          },
          inject: function inject(injectTo, propertySchema, pointer) {
            injectTo._pointer = propertySchema._pointer || pointer;
            injectTo._displayType = propertySchema.type;
            if (propertySchema.format) injectTo._displayFormat = '<' + propertySchema.format + '>';
            if (propertySchema['enum']) {
              injectTo['enum'] = propertySchema['enum'].map(function (value) {
                return { val: value, type: typeof value };
              });
            }
          }
        },
        discriminator: {
          check: function check(propertySchema) {
            return propertySchema.discriminator;
          },
          inject: function inject(injectTo, propertySchema, pointer) {
            if (propertySchema === undefined) propertySchema = injectTo;
            return (function () {
              injectTo.derived = SchemaManager.instance().findDerivedDefinitions(pointer);
              injectTo.discriminator = propertySchema.discriminator;
            })();
          }
        },
        array: {
          check: function check(propertySchema) {
            return propertySchema.type === 'array';
          },
          inject: function inject(injectTo, propertySchema, propPointer) {
            if (propertySchema === undefined) propertySchema = injectTo;
            return (function () {
              injectTo._isArray = true;
              injectTo._pointer = propertySchema.items._pointer || JsonPointer.join(propertySchema._pointer || propPointer, ['items']);

              runInjectors(injectTo, propertySchema.items, propPointer);
            })();
          }
        },
        object: {
          check: function check(propertySchema) {
            return propertySchema.type === 'object' && propertySchema.properties;
          },
          inject: function inject(injectTo) {
            var propertySchema = arguments.length <= 1 || arguments[1] === undefined ? injectTo : arguments[1];
            return (function () {
              var baseName = propertySchema._pointer && JsonPointer.baseName(propertySchema._pointer);
              injectTo._displayType = propertySchema.title || baseName || 'object';
            })();
          }
        },
        noType: {
          check: function check(propertySchema) {
            return !propertySchema.type;
          },
          inject: function inject(injectTo) {
            injectTo._displayType = '< * >';
            injectTo._displayTypeHint = 'This field may contain data of any type';
            injectTo.isTrivial = true;
          }
        },
        simpleType: {
          check: function check(propertySchema) {
            if (propertySchema.type === 'object') {
              return (!propertySchema.properties || !_Object$keys(propertySchema.properties).length) && typeof propertySchema.additionalProperties !== 'object';
            }
            return propertySchema.type !== 'array' && propertySchema.type;
          },
          inject: function inject(injectTo) {
            var propertySchema = arguments.length <= 1 || arguments[1] === undefined ? injectTo : arguments[1];
            return (function () {
              injectTo.isTrivial = true;
              if (injectTo._pointer) {
                injectTo._pointer = undefined;
                injectTo._displayType = propertySchema.title ? propertySchema.title + ' (' + propertySchema.type + ')' : propertySchema.type;
              }
            })();
          }
        },
        integer: {
          check: function check(propertySchema) {
            return propertySchema.type === 'integer' || propertySchema.type === 'number';
          },
          inject: function inject(injectTo) {
            var propertySchema = arguments.length <= 1 || arguments[1] === undefined ? injectTo : arguments[1];
            return (function () {
              var range = '';
              if (propertySchema.minimum && propertySchema.maximum) {
                range += propertySchema.exclusiveMinimum ? '( ' : '[ ';
                range += propertySchema.minimum;
                range += ' .. ';
                range += propertySchema.maximum;
                range += propertySchema.exclusiveMaximum ? ' )' : ' ]';
              } else if (propertySchema.maximum) {
                range += propertySchema.exclusiveMaximum ? '< ' : '<= ';
                range += propertySchema.maximum;
              } else if (propertySchema.minimum) {
                range += propertySchema.exclusiveMinimum ? '> ' : '>= ';
                range += propertySchema.minimum;
              }

              if (range) {
                injectTo._range = range;
              }
            })();
          }
        },
        string: {
          check: function check(propertySchema) {
            return propertySchema.type === 'string';
          },
          inject: function inject(injectTo) {
            var propertySchema = arguments.length <= 1 || arguments[1] === undefined ? injectTo : arguments[1];
            return (function () {
              var range;
              if (propertySchema.minLength && propertySchema.maxLength) {
                range = '[ ' + propertySchema.minLength + ' .. ' + propertySchema.maxLength + ' ]';
              } else if (propertySchema.maxLength) {
                range = '<= ' + propertySchema.maxLength;
              } else if (propertySchema.minimum) {
                range = '>= ' + propertySchema.minLength;
              }

              if (range) {
                injectTo._range = range + ' characters';
              }
            })();
          }
        },
        file: {
          check: function check(propertySchema) {
            return propertySchema.type === 'file';
          },
          inject: function inject(injectTo, propertySchema, propPointer, hostPointer) {
            if (propertySchema === undefined) propertySchema = injectTo;
            return (function () {
              injectTo.isFile = true;
              var parentPtr = undefined;
              if (propertySchema['in'] === 'formData') {
                parentPtr = JsonPointer.dirName(hostPointer, 1);
              } else {
                parentPtr = JsonPointer.dirName(hostPointer, 3);
              }

              var parentParam = SchemaManager.instance().byPointer(parentPtr);
              var root = SchemaManager.instance().schema;
              injectTo._produces = parentParam && parentParam.produces || root.produces;
              injectTo._consumes = parentParam && parentParam.consumes || root.consumes;
            })();
          }
        }
      };
    }
  };
});
$__System.register('8e', ['11', '76', '86', '89', '93', '8a', '8d'], function (_export) {
  var Component, ElementRef, ViewContainerRef, DynamicComponentLoader, CORE_DIRECTIVES, OptionsService, _createClass, SchemaManager, _classCallCheck, JsonSchema, cache, JsonSchemaLazy;

  function insertAfter(newNode, referenceNode) {
    referenceNode.parentNode.insertBefore(newNode, referenceNode.nextSibling);
  }
  return {
    setters: [function (_2) {
      Component = _2.Component;
      ElementRef = _2.ElementRef;
      ViewContainerRef = _2.ViewContainerRef;
      DynamicComponentLoader = _2.DynamicComponentLoader;
    }, function (_3) {
      CORE_DIRECTIVES = _3.CORE_DIRECTIVES;
    }, function (_4) {
      OptionsService = _4.OptionsService;
    }, function (_) {
      _createClass = _['default'];
    }, function (_5) {
      SchemaManager = _5['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_d) {
      JsonSchema = _d.JsonSchema;
    }],
    execute: function () {
      'use strict';

      cache = {};

      JsonSchemaLazy = (function () {
        function JsonSchemaLazy(schemaMgr, viewRef, elementRef, dcl, optionsService) {
          _classCallCheck(this, _JsonSchemaLazy);

          this.viewRef = viewRef;
          this.elementRef = elementRef;
          this.dcl = dcl;
          this.optionsService = optionsService;
          this.schemaMgr = schemaMgr;
        }

        _createClass(JsonSchemaLazy, [{
          key: 'normalizePointer',
          value: function normalizePointer() {
            var schema = this.schemaMgr.byPointer(this.pointer);
            return schema && schema.$ref || this.pointer;
          }
        }, {
          key: 'load',
          value: function load() {
            var _this = this;

            if (this.optionsService.options.disableLazySchemas) return;
            if (this.loaded) return;
            if (this.pointer) {
              this.dcl.loadNextToLocation(JsonSchema, this.viewRef).then(function (compRef) {
                _this.initComponent(compRef);
                // trigger change detection
                if (compRef.changeDetectorRef) {
                  compRef.changeDetectorRef.detectChanges();
                } else {
                  compRef.hostView.changeDetectorRef.detectChanges();
                }
              });
            }
            this.loaded = true;
          }

          // cache JsonSchema view
        }, {
          key: 'loadCached',
          value: function loadCached() {
            var _this2 = this;

            this.pointer = this.normalizePointer(this.pointer);
            if (cache[this.pointer]) {
              cache[this.pointer].then(function (compRef) {
                setTimeout(function () {
                  var $element = compRef.location.nativeElement;

                  // skip caching view with tabs inside (discriminator) as it needs attached controller
                  // FIXME: get rid of dependency on selector
                  if ($element.querySelector('.discriminator-wrap')) {
                    _this2.dcl.loadNextToLocation(JsonSchema, _this2.viewRef).then(function (compRef) {
                      _this2.initComponent(compRef);
                      if (compRef.changeDetectorRef) {
                        compRef.changeDetectorRef.detectChanges();
                      } else {
                        compRef.hostView.changeDetectorRef.detectChanges();
                      }
                    });
                    return;
                  }
                  insertAfter($element.cloneNode(true), _this2.elementRef.nativeElement);
                });
              });
            } else {
              cache[this.pointer] = this.dcl.loadNextToLocation(JsonSchema, this.viewRef).then(function (compRef) {
                _this2.initComponent(compRef);
                if (compRef.changeDetectorRef) {
                  compRef.changeDetectorRef.detectChanges();
                } else {
                  compRef.hostView.changeDetectorRef.detectChanges();
                }
                return compRef;
              });
            }
          }
        }, {
          key: 'initComponent',
          value: function initComponent(compRef) {
            compRef.instance.pointer = this.pointer;
            compRef.instance.isRequestSchema = this.isRequestSchema;
          }
        }, {
          key: 'ngAfterViewInit',
          value: function ngAfterViewInit() {
            if (!this.auto) return;
            this.loadCached();
          }
        }, {
          key: 'ngOnDestroy',
          value: function ngOnDestroy() {
            // clear cache
            cache = {};
          }
        }]);

        var _JsonSchemaLazy = JsonSchemaLazy;
        JsonSchemaLazy = Reflect.metadata('parameters', [[SchemaManager], [ViewContainerRef], [ElementRef], [DynamicComponentLoader], [OptionsService]])(JsonSchemaLazy) || JsonSchemaLazy;
        JsonSchemaLazy = Component({
          selector: 'json-schema-lazy',
          inputs: ['pointer', 'auto', 'isRequestSchema'],
          template: '',
          directives: [CORE_DIRECTIVES]
        })(JsonSchemaLazy) || JsonSchemaLazy;
        return JsonSchemaLazy;
      })();

      _export('JsonSchemaLazy', JsonSchemaLazy);
    }
  };
});
$__System.register('94', ['85', '86', '87', '88', '89', '90', '91', '95', '8a', '8f', '8d', '8e'], function (_export) {
  var RedocComponent, BaseComponent, SchemaManager, OptionsService, _get, _inherits, _createClass, Zippy, JsonPointer, statusCodeType, _classCallCheck, _Object$keys, JsonSchema, JsonSchemaLazy, ResponsesList;

  function isNumeric(n) {
    return !isNaN(parseFloat(n)) && isFinite(n);
  }

  return {
    setters: [function (_4) {
      RedocComponent = _4.RedocComponent;
      BaseComponent = _4.BaseComponent;
      SchemaManager = _4.SchemaManager;
    }, function (_8) {
      OptionsService = _8.OptionsService;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_6) {
      Zippy = _6.Zippy;
    }, function (_5) {
      JsonPointer = _5['default'];
    }, function (_7) {
      statusCodeType = _7.statusCodeType;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_d) {
      JsonSchema = _d.JsonSchema;
    }, function (_e) {
      JsonSchemaLazy = _e.JsonSchemaLazy;
    }],
    execute: function () {
      'use strict';

      ResponsesList = (function (_BaseComponent) {
        _inherits(ResponsesList, _BaseComponent);

        function ResponsesList(schemaMgr, optionsMgr) {
          _classCallCheck(this, _ResponsesList);

          _get(Object.getPrototypeOf(_ResponsesList.prototype), 'constructor', this).call(this, schemaMgr);
          this.options = optionsMgr.options;
        }

        _createClass(ResponsesList, [{
          key: 'prepareModel',
          value: function prepareModel() {
            var _this = this;

            this.data = {};
            this.data.responses = [];

            var responses = this.componentSchema;
            if (!responses) return;

            responses = _Object$keys(responses).filter(function (respCode) {
              // only response-codes and "default"
              return isNumeric(respCode) || respCode === 'default';
            }).map(function (respCode) {
              var resp = responses[respCode];
              resp.pointer = JsonPointer.join(_this.pointer, respCode);
              if (resp.$ref) {
                var ref = resp.$ref;
                resp = _this.schemaMgr.byPointer(resp.$ref);
                resp.pointer = ref;
              }

              resp.empty = !resp.schema;
              resp.code = respCode;
              resp.type = statusCodeType(resp.code);
              if (resp.headers) {
                resp.headers = _Object$keys(resp.headers).map(function (k) {
                  var respInfo = resp.headers[k];
                  respInfo.name = k;
                  return respInfo;
                });
                resp.empty = false;
              }
              resp.extendable = resp.headers || resp.length;
              return resp;
            });
            this.data.responses = responses;
          }
        }]);

        var _ResponsesList = ResponsesList;
        ResponsesList = Reflect.metadata('parameters', [[SchemaManager], [OptionsService]])(ResponsesList) || ResponsesList;
        ResponsesList = RedocComponent({
          selector: 'responses-list',
          template: '\n    <h2 class="responses-list-header" *ngIf="data.responses.length"> Responses </h2>\n    <zippy *ngFor="let response of data.responses" title="{{response.code}} {{response.description}}"\n      [type]="response.type" [empty]="response.empty" (open)="lazySchema.load()">\n      <div *ngIf="response.headers" class="response-headers">\n        <header>\n          Headers\n        </header>\n        <div class="header" *ngFor="let header of response.headers">\n          <div class="header-name"> {{header.name}} </div>\n          <div class="header-type"> {{header.type}} </div>\n          <div class="header-description" innerHtml="{{header.description | marked}}"> </div>\n        </div>\n      </div>\n      <json-schema *ngIf="response.schema && options.disableLazySchemas" class="schema type" pointer="{{response.pointer}}/schema">\n      </json-schema>\n      <json-schema-lazy #lazySchema pointer="{{response.schema ? response.pointer + \'/schema\' : null}}">\n      </json-schema-lazy>\n    </zippy>\n  ',
          styles: ['\n    .responses-list-header{font-size:18px;padding:0.2em 0;margin:3em 0 1.1em 0;color:#253137;font-weight:normal}:host .zippy-title{font-family:Montserrat,sans-serif}.header-name{font-weight:bold;display:inline-block}.header-type{display:inline-block;font-weight:bold;color:#999}header{font-size:14px;font-weight:bold;text-transform:uppercase;margin-bottom:15px}.header{margin-bottom:10px}\n  '],
          directives: [JsonSchema, Zippy, JsonSchemaLazy]
        })(ResponsesList) || ResponsesList;
        return ResponsesList;
      })(BaseComponent);

      _export('ResponsesList', ResponsesList);
    }
  };
});
$__System.register('95', [], function (_export) {
  'use strict';

  _export('statusCodeType', statusCodeType);

  function statusCodeType(statusCode) {
    if (statusCode < 100 || statusCode > 599) {
      throw new Error('invalid HTTP code');
    }
    var res = 'success';
    if (statusCode >= 300 && statusCode < 400) {
      res = 'redirect';
    } else if (statusCode >= 400) {
      res = 'error';
    } else if (statusCode < 200) {
      res = 'info';
    }
    return res;
  }

  return {
    setters: [],
    execute: function () {}
  };
});
$__System.register('96', ['11', '85', '87', '88', '89', '90', '91', '95', '97', '8a', '8f'], function (_export) {
  var forwardRef, RedocComponent, BaseComponent, _get, _inherits, _createClass, Tabs, Tab, JsonPointer, statusCodeType, SchemaSample, _classCallCheck, _Object$keys, ResponsesSamples;

  function isNumeric(n) {
    return !isNaN(parseFloat(n)) && isFinite(n);
  }

  function hasExample(response) {
    return response.examples && response.examples['application/json'] || response.schema;
  }

  return {
    setters: [function (_4) {
      forwardRef = _4.forwardRef;
    }, function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_7) {
      Tabs = _7.Tabs;
      Tab = _7.Tab;
    }, function (_6) {
      JsonPointer = _6['default'];
    }, function (_9) {
      statusCodeType = _9.statusCodeType;
    }, function (_8) {
      SchemaSample = _8.SchemaSample;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }],
    execute: function () {
      'use strict';

      ResponsesSamples = (function (_BaseComponent) {
        _inherits(ResponsesSamples, _BaseComponent);

        function ResponsesSamples(schemaMgr) {
          _classCallCheck(this, _ResponsesSamples);

          _get(Object.getPrototypeOf(_ResponsesSamples.prototype), 'constructor', this).call(this, schemaMgr);
        }

        _createClass(ResponsesSamples, [{
          key: 'prepareModel',
          value: function prepareModel() {
            var _this = this;

            this.data = {};
            this.data.responses = [];

            var responses = this.componentSchema;
            if (!responses) return;

            responses = _Object$keys(responses).filter(function (respCode) {
              // only response-codes and "default"
              return isNumeric(respCode) || respCode === 'default';
            }).map(function (respCode) {
              var resp = responses[respCode];
              resp.pointer = JsonPointer.join(_this.pointer, respCode);
              if (resp.$ref) {
                var ref = resp.$ref;
                resp = _this.schemaMgr.byPointer(resp.$ref);
                resp.pointer = ref;
              }

              resp.code = respCode;
              resp.type = statusCodeType(resp.code);
              return resp;
            }).filter(function (response) {
              return hasExample(response);
            });
            this.data.responses = responses;
          }
        }]);

        var _ResponsesSamples = ResponsesSamples;
        ResponsesSamples = RedocComponent({
          selector: 'responses-samples',
          template: '\n    <header *ngIf="data.responses.length"> Response samples </header>\n    <tabs *ngIf="data.responses.length">\n      <tab *ngFor="let response of data.responses" tabTitle="{{response.code}} {{response.description}}"\n        [tabStatus]="response.type">\n        <schema-sample [pointer]="response.pointer"></schema-sample>\n      </tab>\n    </tabs>\n  ',
          styles: ['\n    tab,tabs{display:block}schema-sample{display:block}header{font-family:Montserrat;font-size:0.929em;text-transform:uppercase;margin:0;color:#9fb4be;text-transform:uppercase;font-weight:normal}:host>tabs>ul li{font-family:Montserrat;font-size:0.929em;border-radius:2px;margin:2px 0;padding:2px 8px 3px 8px;color:#9fb4be;line-height:1.25}:host>tabs>ul li:hover{color:#ffffff;background-color:rgba(255,255,255,0.1)}:host>tabs>ul li.active{background-color:white;color:#263238}:host tabs ul{padding-top:10px}\n  '],
          directives: [forwardRef(function () {
            return SchemaSample;
          }), Tabs, Tab]
        })(ResponsesSamples) || ResponsesSamples;
        return ResponsesSamples;
      })(BaseComponent);

      _export('ResponsesSamples', ResponsesSamples);
    }
  };
});
$__System.registerDynamic("98", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var typesInstantiator = {
    'string': '',
    'number': 0,
    'integer': 0,
    'null': null,
    'boolean': false,
    'object': {}
  };
  function isPrimitive(obj) {
    var type = obj.type;
    return typesInstantiator[type] !== undefined;
  }
  function instantiatePrimitive(val) {
    var type = val.type;
    if (val.default) {
      return val.default;
    }
    return typesInstantiator[type];
  }
  function instantiate(schema) {
    function visit(obj, name, data) {
      if (!obj) {
        return;
      }
      var i;
      var type = obj.type;
      if (type === 'object' && obj.properties) {
        data[name] = data[name] || {};
        for (var property in obj.properties) {
          if (obj.properties.hasOwnProperty(property)) {
            visit(obj.properties[property], property, data[name]);
          }
        }
      } else if (obj.allOf) {
        for (i = 0; i < obj.allOf.length; i++) {
          visit(obj.allOf[i], name, data);
        }
      } else if (type === 'array') {
        data[name] = [];
        var len = 1;
        if (obj.minItems || obj.minItems === 0) {
          len = obj.minItems;
        }
        for (i = 0; i < len; i++) {
          visit(obj.items, i, data[name]);
        }
      } else if (isPrimitive(obj)) {
        data[name] = instantiatePrimitive(obj);
      }
    }
    var data = {};
    visit(schema, 'kek', data);
    return data['kek'];
  }
  if (typeof module !== 'undefined') {
    module.exports = {instantiate: instantiate};
  }
  return module.exports;
});

$__System.registerDynamic("99", ["98"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('98');
  return module.exports;
});

$__System.registerDynamic("9a", ["99"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('99');
  return module.exports;
});

$__System.register('9b', ['11', '89', '8a', '8f', '9c'], function (_export) {
  var Pipe, _createClass, _classCallCheck, _Object$keys, isBlank, level, COLLAPSE_LEVEL, JsonFormatter;

  function htmlEncode(t) {
    return t != null ? t.toString().replace(/&/g, '&amp;').replace(/"/g, '&quot;').replace(/</g, '&lt;').replace(/>/g, '&gt;') : '';
  }

  function decorateWithSpan(value, className) {
    return '<span class="' + className + '">' + htmlEncode(value) + '</span>';
  }

  function valueToHTML(value) {
    var valueType = typeof value,
        output = '';
    if (value == null) {
      output += decorateWithSpan('null', 'type-null');
    } else if (value && value.constructor === Array) {
      level++;
      output += arrayToHTML(value);
      level--;
    } else if (valueType === 'object') {
      level++;
      output += objectToHTML(value);
      level--;
    } else if (valueType === 'number') {
      output += decorateWithSpan(value, 'type-number');
    } else if (valueType === 'string') {
      if (/^(http|https):\/\/[^\\s]+$/.test(value)) {
        output += decorateWithSpan('"', 'type-string') + '<a href="' + value + '">' + htmlEncode(value) + '</a>' + decorateWithSpan('"', 'type-string');
      } else {
        output += decorateWithSpan('"' + value + '"', 'type-string');
      }
    } else if (valueType === 'boolean') {
      output += decorateWithSpan(value, 'type-boolean');
    }

    return output;
  }

  function arrayToHTML(json) {
    var collapsed = level > COLLAPSE_LEVEL ? 'collapsed' : '';
    var i, length;
    var output = '<div class="collapser"></div>[<span class="ellipsis"></span><ul class="array collapsible">';
    var hasContents = false;
    for (i = 0, length = json.length; i < length; i++) {
      hasContents = true;
      output += '<li><div class="hoverable ' + collapsed + '">';
      output += valueToHTML(json[i]);
      if (i < length - 1) {
        output += ',';
      }
      output += '</div></li>';
    }
    output += '</ul>]';
    if (!hasContents) {
      output = '[ ]';
    }
    return output;
  }

  function objectToHTML(json) {
    var collapsed = level > COLLAPSE_LEVEL ? 'collapsed' : '';
    var i,
        key,
        length,
        keys = _Object$keys(json);
    var output = '<div class="collapser"></div>{<span class="ellipsis"></span><ul class="obj collapsible">';
    var hasContents = false;
    for (i = 0, length = keys.length; i < length; i++) {
      key = keys[i];
      hasContents = true;
      output += '<li><div class="hoverable ' + collapsed + '">';
      output += '<span class="property">' + htmlEncode(key) + '</span>: ';
      output += valueToHTML(json[key]);
      if (i < length - 1) {
        output += ',';
      }
      output += '</div></li>';
    }
    output += '</ul>}';
    if (!hasContents) {
      output = '{ }';
    }
    return output;
  }

  function jsonToHTML(json) {
    level = 1;
    var output = '';
    output += '<div class="redoc-json">';
    output += valueToHTML(json);
    output += '</div>';
    return output;
  }
  return {
    setters: [function (_2) {
      Pipe = _2.Pipe;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_c) {
      isBlank = _c.isBlank;
    }],
    execute: function () {
      'use strict';
      level = 1;
      COLLAPSE_LEVEL = 2;

      JsonFormatter = (function () {
        function JsonFormatter() {
          _classCallCheck(this, _JsonFormatter);
        }

        _createClass(JsonFormatter, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            return jsonToHTML(value);
          }
        }]);

        var _JsonFormatter = JsonFormatter;
        JsonFormatter = Pipe({ name: 'jsonFormatter' })(JsonFormatter) || JsonFormatter;
        return JsonFormatter;
      })();

      _export('JsonFormatter', JsonFormatter);
    }
  };
});
$__System.register('9d', ['11', '85', '87', '88', '89', '8a', '9a', '9b'], function (_export) {
  var ElementRef, RedocComponent, BaseComponent, SchemaManager, _get, _inherits, _createClass, _classCallCheck, SchemaSampler, JsonFormatter, SchemaSample;

  return {
    setters: [function (_4) {
      ElementRef = _4.ElementRef;
    }, function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
      SchemaManager = _5.SchemaManager;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_a2) {
      SchemaSampler = _a2['default'];
    }, function (_b) {
      JsonFormatter = _b.JsonFormatter;
    }],
    execute: function () {
      'use strict';

      SchemaSample = (function (_BaseComponent) {
        _inherits(SchemaSample, _BaseComponent);

        function SchemaSample(schemaMgr, elementRef) {
          _classCallCheck(this, _SchemaSample);

          _get(Object.getPrototypeOf(_SchemaSample.prototype), 'constructor', this).call(this, schemaMgr);
          this.element = elementRef.nativeElement;
        }

        _createClass(SchemaSample, [{
          key: 'init',
          value: function init() {
            this.data = {};

            var base = {};
            var sample = undefined;

            // got pointer not directly to the schema but e.g. to response obj
            if (this.componentSchema.schema) {
              base = this.componentSchema;
              this.componentSchema = this.componentSchema.schema;
            }

            if (base.examples && base.examples['application/json']) {
              sample = base.examples['application/json'];
            } else {
              this.dereference(this.componentSchema);
              sample = SchemaSampler.instantiate(this.componentSchema);
            }

            this.data.sample = sample;

            this.element.addEventListener('click', function (event) {
              var collapsed,
                  target = event.target;
              if (event.target.className === 'collapser') {
                collapsed = target.parentNode.getElementsByClassName('collapsible')[0];
                if (collapsed.parentNode.classList.contains('collapsed')) {
                  collapsed.parentNode.classList.remove('collapsed');
                } else {
                  collapsed.parentNode.classList.add('collapsed');
                }
              }
            });
          }
        }]);

        var _SchemaSample = SchemaSample;
        SchemaSample = Reflect.metadata('parameters', [[SchemaManager], [ElementRef]])(SchemaSample) || SchemaSample;
        SchemaSample = RedocComponent({
          selector: 'schema-sample',
          template: '\n    <div class="snippet">\n      <!-- in case sample is not available for some reason -->\n      <pre *ngIf="data.sample == null"> Sample unavailable </pre>\n      <pre innerHtml="{{data.sample | jsonFormatter}}"></pre>\n    </div>\n  ',
          pipes: [JsonFormatter],
          styles: ['\n    pre{background-color:transparent;padding:0}:host .type-null{color:gray}:host .type-boolean{color:firebrick}:host .type-number{color:#4A8BB3}:host .type-string{color:#66B16E}:host .callback-function{color:gray}:host .collapser:after{content:"-";cursor:pointer}:host .collapsed>.collapser:after{content:"+";cursor:pointer}:host .ellipsis:after{content:" … "}:host .collapsible{margin-left:2em}:host .hoverable{padding-top:1px;padding-bottom:1px;padding-left:2px;padding-right:2px;border-radius:2px}:host .hovered{background-color:#ebeef9}:host .collapser{padding-right:6px;padding-left:6px}:host .redoc-json{padding:20px;border-radius:4px;background-color:#222d32;margin-bottom:36px}:host ul,:host .redoc-json ul{list-style-type:none;padding:0px;margin:0px 0px 0px 26px}:host li{position:relative}:host .hoverable{transition:background-color .2s ease-out 0s;-webkit-transition:background-color .2s ease-out 0s;display:inline-block}:host .hovered{transition-delay:.2s;-webkit-transition-delay:.2s}:host .selected{outline-style:solid;outline-width:1px;outline-style:dotted}:host .collapsed>.collapsible{display:none}:host .ellipsis{display:none}:host .collapsed>.ellipsis{display:inherit}:host .collapser{position:absolute;top:1px;left:-1.5em;cursor:default;user-select:none;-webkit-user-select:none}\n  ']
        })(SchemaSample) || SchemaSample;
        return SchemaSample;
      })(BaseComponent);

      _export('SchemaSample', SchemaSample);
    }
  };
});
$__System.register('9e', ['11', '85', '86', '87', '88', '89', '90', '91', '8a', '9d', '9f'], function (_export) {
  var ViewChildren, QueryList, RedocComponent, BaseComponent, SchemaManager, RedocEventsService, _get, _inherits, _createClass, Tabs, Tab, JsonPointer, _classCallCheck, SchemaSample, PrismPipe, RequestSamples;

  return {
    setters: [function (_4) {
      ViewChildren = _4.ViewChildren;
      QueryList = _4.QueryList;
    }, function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
      SchemaManager = _5.SchemaManager;
    }, function (_8) {
      RedocEventsService = _8.RedocEventsService;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_7) {
      Tabs = _7.Tabs;
      Tab = _7.Tab;
    }, function (_6) {
      JsonPointer = _6['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_d) {
      SchemaSample = _d.SchemaSample;
    }, function (_f) {
      PrismPipe = _f.PrismPipe;
    }],
    execute: function () {
      'use strict';

      RequestSamples = (function (_BaseComponent) {
        _inherits(RequestSamples, _BaseComponent);

        function RequestSamples(schemaMgr, events, childQuery) {
          var _this = this;

          _classCallCheck(this, _RequestSamples);

          _get(Object.getPrototypeOf(_RequestSamples.prototype), 'constructor', this).call(this, schemaMgr);
          childQuery.changes.subscribe(function () {
            _this.childTabs = childQuery.first;
          });
          this.events = events;
        }

        _createClass(RequestSamples, [{
          key: 'init',
          value: function init() {
            this.subscribeForEvents();
          }
        }, {
          key: 'changeLangNotify',
          value: function changeLangNotify(lang) {
            this.events.samplesLanguageChanged.next(lang);
          }
        }, {
          key: 'subscribeForEvents',
          value: function subscribeForEvents() {
            var _this2 = this;

            this.events.samplesLanguageChanged.subscribe(function (sampleLang) {
              if (!_this2.childTabs) return;
              _this2.childTabs.selectyByTitle(sampleLang);
            });
          }
        }, {
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = {};
            this.data.schemaPointer = JsonPointer.join(this.schemaPointer, 'schema');
            this.data.samples = this.componentSchema['x-code-samples'] || [];
          }
        }]);

        var _RequestSamples = RequestSamples;
        RequestSamples = Reflect.metadata('parameters', [[SchemaManager], [RedocEventsService], [new ViewChildren(Tabs), QueryList]])(RequestSamples) || RequestSamples;
        RequestSamples = RedocComponent({
          selector: 'request-samples',
          template: '\n    <header *ngIf="data.schemaPointer || data.samples.length"> Request samples </header>\n    <schema-sample *ngIf="!data.samples.length" [pointer]="data.schemaPointer"> </schema-sample>\n    <tabs *ngIf="data.samples.length" (change)=changeLangNotify($event)>\n      <tab tabTitle="JSON">\n        <schema-sample [pointer]="data.schemaPointer"> </schema-sample>\n      </tab>\n      <tab *ngFor="let sample of data.samples" [tabTitle]="sample.lang">\n        <pre innerHtml="{{sample.source | prism:sample.lang}}"></pre>\n      </tab>\n    </tabs>\n  ',
          styles: ['\n    header{font-family:Montserrat;font-size:0.929em;text-transform:uppercase;margin:0;color:#9fb4be;text-transform:uppercase;font-weight:normal}:host>tabs>ul li{font-family:Montserrat;font-size:.9em;border-radius:2px;margin:2px 0;padding:3px 10px 2px 10px;line-height:1.25;color:#9fb4be}:host>tabs>ul li:hover{background-color:rgba(255,255,255,0.1);color:#ffffff}:host>tabs>ul li.active{background-color:#ffffff;color:#263238}:host tabs ul{padding-top:10px}pre{overflow-x:auto;word-break:break-all;word-wrap:break-word;white-space:pre-wrap}\n  '],
          directives: [SchemaSample, Tabs, Tab],
          inputs: ['schemaPointer'],
          pipes: [PrismPipe]
        })(RequestSamples) || RequestSamples;
        return RequestSamples;
      })(BaseComponent);

      _export('RequestSamples', RequestSamples);
    }
  };
});
$__System.register('2', ['85', '87', '88', '89', '91', '94', '96', '8a', '8c', '9d', '9e'], function (_export) {
  var RedocComponent, BaseComponent, _get, _inherits, _createClass, JsonPointer, ResponsesList, ResponsesSamples, _classCallCheck, ParamsList, SchemaSample, RequestSamples, Method;

  return {
    setters: [function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_4) {
      JsonPointer = _4.JsonPointer;
    }, function (_6) {
      ResponsesList = _6.ResponsesList;
    }, function (_7) {
      ResponsesSamples = _7.ResponsesSamples;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_c) {
      ParamsList = _c.ParamsList;
    }, function (_d) {
      SchemaSample = _d.SchemaSample;
    }, function (_e) {
      RequestSamples = _e.RequestSamples;
    }],
    execute: function () {
      'use strict';

      Method = (function (_BaseComponent) {
        _inherits(Method, _BaseComponent);

        function Method(schemaMgr) {
          _classCallCheck(this, _Method);

          _get(Object.getPrototypeOf(_Method.prototype), 'constructor', this).call(this, schemaMgr);
        }

        _createClass(Method, [{
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = {};
            this.data.apiUrl = this.schemaMgr.apiUrl;
            this.data.httpMethod = JsonPointer.baseName(this.pointer);
            this.data.path = JsonPointer.baseName(this.pointer, 2);
            this.data.methodInfo = this.componentSchema;
            this.data.methodInfo.tags = this.filterMainTags(this.data.methodInfo.tags);
            this.data.bodyParam = this.findBodyParam();
            if (this.componentSchema.operationId) {
              this.data.methodAnchor = 'operation/' + encodeURIComponent(this.componentSchema.operationId);
            } else {
              this.data.methodAnchor = 'tag/' + encodeURIComponent(this.tag + this.pointer);
            }
          }
        }, {
          key: 'filterMainTags',
          value: function filterMainTags(tags) {
            var tagsMap = this.schemaMgr.getTagsMap();
            if (!tags) return [];
            return tags.filter(function (tag) {
              return tagsMap[tag] && tagsMap[tag]['x-traitTag'];
            });
          }
        }, {
          key: 'findBodyParam',
          value: function findBodyParam() {
            var pathParams = this.schemaMgr.getMethodParams(this.pointer, true);
            var bodyParam = pathParams.find(function (param) {
              return param['in'] === 'body';
            });
            return bodyParam;
          }
        }]);

        var _Method = Method;
        Method = RedocComponent({
          selector: 'method',
          template: '\n    <div class="method">\n        <div class="method-content">\n            <h2 class="method-header sharable-header">\n                <a class="share-link" href="#{{data.methodAnchor}}"></a>{{data.methodInfo.summary}}\n            </h2>\n            <div class="method-tags" *ngIf="data.methodInfo.tags.length">\n                <a *ngFor="let tag of data.methodInfo.tags" attr.href="#{{tag}}"> {{tag}} </a>\n            </div>\n            <p *ngIf="data.methodInfo.description" class="method-description"\n            innerHtml="{{data.methodInfo.description | marked}}">\n        </p>\n        <params-list pointer="{{pointer}}/parameters"> </params-list>\n        <responses-list pointer="{{pointer}}/responses"> </responses-list>\n    </div>\n    <div class="method-samples">\n        <h5>Definition</h5>\n        <span class="method-endpoint">\n            <h5 class="http-method" [ngClass]="data.httpMethod">{{data.httpMethod}}</h5>\n            <span class="api-url">{{data.apiUrl}}</span><span class="path">{{data.path}}</span>\n        </span>\n        <div *ngIf="data.bodyParam">\n            <br>\n            <request-samples [pointer]="pointer" [schemaPointer]="data.bodyParam._pointer">\n            </request-samples>\n        </div>\n        <div>\n            <br>\n            <responses-samples pointer="{{pointer}}/responses"> </responses-samples>\n        </div>\n    </div>\n    <div>\n  ',
          styles: ['\n    .share-link{cursor:pointer;margin-left:-15px;padding:0;line-height:1;width:15px;display:inline-block}.share-link:before{content:"";width:15px;height:15px;background-size:contain;background-image:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgeD0iMCIgeT0iMCIgd2lkdGg9IjUxMiIgaGVpZ2h0PSI1MTIiIHZpZXdCb3g9IjAgMCA1MTIgNTEyIiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDAgMCA1MTIgNTEyIiB4bWw6c3BhY2U9InByZXNlcnZlIj48cGF0aCBmaWxsPSIjMDEwMTAxIiBkPSJNNDU5LjcgMjMzLjRsLTkwLjUgOTAuNWMtNTAgNTAtMTMxIDUwLTE4MSAwIC03LjktNy44LTE0LTE2LjctMTkuNC0yNS44bDQyLjEtNDIuMWMyLTIgNC41LTMuMiA2LjgtNC41IDIuOSA5LjkgOCAxOS4zIDE1LjggMjcuMiAyNSAyNSA2NS42IDI0LjkgOTAuNSAwbDkwLjUtOTAuNWMyNS0yNSAyNS02NS42IDAtOTAuNSAtMjQuOS0yNS02NS41LTI1LTkwLjUgMGwtMzIuMiAzMi4yYy0yNi4xLTEwLjItNTQuMi0xMi45LTgxLjYtOC45bDY4LjYtNjguNmM1MC01MCAxMzEtNTAgMTgxIDBDNTA5LjYgMTAyLjMgNTA5LjYgMTgzLjQgNDU5LjcgMjMzLjR6TTIyMC4zIDM4Mi4ybC0zMi4yIDMyLjJjLTI1IDI0LjktNjUuNiAyNC45LTkwLjUgMCAtMjUtMjUtMjUtNjUuNiAwLTkwLjVsOTAuNS05MC41YzI1LTI1IDY1LjUtMjUgOTAuNSAwIDcuOCA3LjggMTIuOSAxNy4yIDE1LjggMjcuMSAyLjQtMS40IDQuOC0yLjUgNi44LTQuNWw0Mi4xLTQyYy01LjQtOS4yLTExLjYtMTgtMTkuNC0yNS44IC01MC01MC0xMzEtNTAtMTgxIDBsLTkwLjUgOTAuNWMtNTAgNTAtNTAgMTMxIDAgMTgxIDUwIDUwIDEzMSA1MCAxODEgMGw2OC42LTY4LjZDMjc0LjYgMzk1LjEgMjQ2LjQgMzkyLjMgMjIwLjMgMzgyLjJ6Ii8+PC9zdmc+Cg==");opacity:0.5;visibility:hidden;display:inline-block;vertical-align:middle}.sharable-header{color:#263238}.sharable-header:hover .share-link:before,.share-link:hover:before{visibility:visible}:host{padding-bottom:100px;display:block;border-bottom:1px solid rgba(127,127,127,0.25)}responses-list,params-list{display:block}.method-header{margin-bottom:.9em}.method-endpoint{margin:0 0 2em 0;padding:10px 20px;border-radius:4px;background-color:#222d32;display:block;font-weight:300}.method-endpoint>h5{padding-top:1px;padding-bottom:0;margin:0;font-size:.8em;color:#263238;vertical-align:middle;display:inline-block;border-radius:2px}.api-url{color:rgba(255,255,255,0.8);margin-left:10px;margin-top:2px;position:relative;top:1px;font-family:Montserrat,sans-serif;font-size:0.929em !important}.path{font-family:Montserrat,sans-serif;position:relative;top:1px;color:#ffffff;font-size:0.929em !important}.method-tags{margin-top:20px}.method-tags a{font-size:16px;color:#999;display:inline-block;padding:0 0.5em;text-decoration:none}.method-tags a:before{content:\'#\';margin-right:-0.4em}.method-tags a:first-of-type{padding:0}.method-content,.method-samples{display:block;box-sizing:border-box;float:left}.method-content{width:60%;padding:40px}.method-samples{color:#fafbfc;width:40%;padding:40px;background:#263238}responses-samples{display:block}.method-samples header,.method-samples>h5{color:#9fb4be;text-transform:uppercase}.method-samples>h5{margin-bottom:8px}.method-samples schema-sample{display:block}.method:after{content:"";display:table;clear:both}.method-description{padding:6px 0 10px 0;margin:0}.http-method{color:#263238;background:#ffffff;padding:3px 10px;text-transform:uppercase}@media (max-width: 1100px){.methods:before{display:none}.method-samples,.method-content{width:100%}.method-samples{margin-top:2em}:host{padding-bottom:0}}\n  '],
          directives: [ParamsList, ResponsesList, ResponsesSamples, SchemaSample, RequestSamples],
          inputs: ['tag']
        })(Method) || Method;
        return Method;
      })(BaseComponent);

      _export('Method', Method);
    }
  };
});
$__System.register('a0', ['2', '11', '85', '87', '88', '89', '8a', 'a1', 'a2', '9f'], function (_export) {
  var Method, forwardRef, RedocComponent, BaseComponent, _get, _inherits, _createClass, _classCallCheck, _slicedToArray, _Array$from, EncodeURIComponentPipe, MethodsList;

  return {
    setters: [function (_6) {
      Method = _6.Method;
    }, function (_4) {
      forwardRef = _4.forwardRef;
    }, function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_a1) {
      _slicedToArray = _a1['default'];
    }, function (_a2) {
      _Array$from = _a2['default'];
    }, function (_f) {
      EncodeURIComponentPipe = _f.EncodeURIComponentPipe;
    }],
    execute: function () {
      'use strict';

      MethodsList = (function (_BaseComponent) {
        _inherits(MethodsList, _BaseComponent);

        function MethodsList(schemaMgr) {
          _classCallCheck(this, _MethodsList);

          _get(Object.getPrototypeOf(_MethodsList.prototype), 'constructor', this).call(this, schemaMgr);
        }

        _createClass(MethodsList, [{
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = {};
            // follow SwaggerUI behavior for cases when one method has more than one tag:
            // duplicate methods

            var menuStructure = this.schemaMgr.buildMenuTree();
            var tags = _Array$from(menuStructure.entries()).map(function (entry) {
              var _entry = _slicedToArray(entry, 2);

              var tag = _entry[0];
              var _entry$1 = _entry[1];
              var description = _entry$1.description;
              var methods = _entry$1.methods;

              // inject tag name into method info
              methods = methods || [];
              methods.forEach(function (method) {
                method.tag = tag;
              });
              return {
                name: tag,
                description: description,
                methods: methods
              };
            });
            this.data.tags = tags;
            // TODO: check $ref field
          }
        }]);

        var _MethodsList = MethodsList;
        MethodsList = RedocComponent({
          selector: 'methods-list',
          template: '\n    <div class="methods">\n      <div class="tag" *ngFor="let tag of data.tags">\n        <div class="tag-info" [attr.tag]="tag.name">\n          <h1 class="sharable-header"> <a class="share-link" href="#tag/{{tag.name | encodeURIComponent}}"></a>{{tag.name}} </h1>\n          <p *ngIf="tag.description" innerHtml="{{ tag.description | marked }}"> </p>\n        </div>\n        <method *ngFor="let method of tag.methods" [pointer]="method.pointer" [attr.pointer]="method.pointer"\n        [attr.tag]="method.tag" [tag]="method.tag" [attr.operation-id]="method.operationId"></method>\n      </div>\n    </div>\n  ',
          styles: ['\n    .share-link{cursor:pointer;margin-left:-15px;padding:0;line-height:1;width:15px;display:inline-block}.share-link:before{content:"";width:15px;height:15px;background-size:contain;background-image:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZlcnNpb249IjEuMSIgeD0iMCIgeT0iMCIgd2lkdGg9IjUxMiIgaGVpZ2h0PSI1MTIiIHZpZXdCb3g9IjAgMCA1MTIgNTEyIiBlbmFibGUtYmFja2dyb3VuZD0ibmV3IDAgMCA1MTIgNTEyIiB4bWw6c3BhY2U9InByZXNlcnZlIj48cGF0aCBmaWxsPSIjMDEwMTAxIiBkPSJNNDU5LjcgMjMzLjRsLTkwLjUgOTAuNWMtNTAgNTAtMTMxIDUwLTE4MSAwIC03LjktNy44LTE0LTE2LjctMTkuNC0yNS44bDQyLjEtNDIuMWMyLTIgNC41LTMuMiA2LjgtNC41IDIuOSA5LjkgOCAxOS4zIDE1LjggMjcuMiAyNSAyNSA2NS42IDI0LjkgOTAuNSAwbDkwLjUtOTAuNWMyNS0yNSAyNS02NS42IDAtOTAuNSAtMjQuOS0yNS02NS41LTI1LTkwLjUgMGwtMzIuMiAzMi4yYy0yNi4xLTEwLjItNTQuMi0xMi45LTgxLjYtOC45bDY4LjYtNjguNmM1MC01MCAxMzEtNTAgMTgxIDBDNTA5LjYgMTAyLjMgNTA5LjYgMTgzLjQgNDU5LjcgMjMzLjR6TTIyMC4zIDM4Mi4ybC0zMi4yIDMyLjJjLTI1IDI0LjktNjUuNiAyNC45LTkwLjUgMCAtMjUtMjUtMjUtNjUuNiAwLTkwLjVsOTAuNS05MC41YzI1LTI1IDY1LjUtMjUgOTAuNSAwIDcuOCA3LjggMTIuOSAxNy4yIDE1LjggMjcuMSAyLjQtMS40IDQuOC0yLjUgNi44LTQuNWw0Mi4xLTQyYy01LjQtOS4yLTExLjYtMTgtMTkuNC0yNS44IC01MC01MC0xMzEtNTAtMTgxIDBsLTkwLjUgOTAuNWMtNTAgNTAtNTAgMTMxIDAgMTgxIDUwIDUwIDEzMSA1MCAxODEgMGw2OC42LTY4LjZDMjc0LjYgMzk1LjEgMjQ2LjQgMzkyLjMgMjIwLjMgMzgyLjJ6Ii8+PC9zdmc+Cg==");opacity:0.5;visibility:hidden;display:inline-block;vertical-align:middle}.sharable-header{color:#263238}.sharable-header:hover .share-link:before,.share-link:hover:before{visibility:visible}.tag-info{padding:40px;box-sizing:border-box;background-color:white;width:60%}@media (max-width: 1100px){.tag-info{width:100%}}.tag-info:after,.tag-info:before{content:"";display:table}.tag-info h1{color:#0033a0;text-transform:capitalize;font-weight:normal}.methods{display:block;position:relative}\n  '],
          directives: [forwardRef(function () {
            return Method;
          })],
          pipes: [EncodeURIComponentPipe]
        })(MethodsList) || MethodsList;
        return MethodsList;
      })(BaseComponent);

      _export('MethodsList', MethodsList);
    }
  };
});
$__System.registerDynamic("a3", ["a2"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _Array$from = $__require('a2')["default"];
  exports["default"] = function(arr) {
    if (Array.isArray(arr)) {
      for (var i = 0,
          arr2 = Array(arr.length); i < arr.length; i++)
        arr2[i] = arr[i];
      return arr2;
    } else {
      return _Array$from(arr);
    }
  };
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("a4", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _self = (typeof window !== 'undefined') ? window : ((typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) ? self : {});
  var Prism = (function() {
    var lang = /\blang(?:uage)?-(?!\*)(\w+)\b/i;
    var _ = _self.Prism = {
      util: {
        encode: function(tokens) {
          if (tokens instanceof Token) {
            return new Token(tokens.type, _.util.encode(tokens.content), tokens.alias);
          } else if (_.util.type(tokens) === 'Array') {
            return tokens.map(_.util.encode);
          } else {
            return tokens.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/\u00a0/g, ' ');
          }
        },
        type: function(o) {
          return Object.prototype.toString.call(o).match(/\[object (\w+)\]/)[1];
        },
        clone: function(o) {
          var type = _.util.type(o);
          switch (type) {
            case 'Object':
              var clone = {};
              for (var key in o) {
                if (o.hasOwnProperty(key)) {
                  clone[key] = _.util.clone(o[key]);
                }
              }
              return clone;
            case 'Array':
              return o.map && o.map(function(v) {
                return _.util.clone(v);
              });
          }
          return o;
        }
      },
      languages: {
        extend: function(id, redef) {
          var lang = _.util.clone(_.languages[id]);
          for (var key in redef) {
            lang[key] = redef[key];
          }
          return lang;
        },
        insertBefore: function(inside, before, insert, root) {
          root = root || _.languages;
          var grammar = root[inside];
          if (arguments.length == 2) {
            insert = arguments[1];
            for (var newToken in insert) {
              if (insert.hasOwnProperty(newToken)) {
                grammar[newToken] = insert[newToken];
              }
            }
            return grammar;
          }
          var ret = {};
          for (var token in grammar) {
            if (grammar.hasOwnProperty(token)) {
              if (token == before) {
                for (var newToken in insert) {
                  if (insert.hasOwnProperty(newToken)) {
                    ret[newToken] = insert[newToken];
                  }
                }
              }
              ret[token] = grammar[token];
            }
          }
          _.languages.DFS(_.languages, function(key, value) {
            if (value === root[inside] && key != inside) {
              this[key] = ret;
            }
          });
          return root[inside] = ret;
        },
        DFS: function(o, callback, type) {
          for (var i in o) {
            if (o.hasOwnProperty(i)) {
              callback.call(o, i, o[i], type || i);
              if (_.util.type(o[i]) === 'Object') {
                _.languages.DFS(o[i], callback);
              } else if (_.util.type(o[i]) === 'Array') {
                _.languages.DFS(o[i], callback, i);
              }
            }
          }
        }
      },
      plugins: {},
      highlightAll: function(async, callback) {
        var elements = document.querySelectorAll('code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code');
        for (var i = 0,
            element; element = elements[i++]; ) {
          _.highlightElement(element, async === true, callback);
        }
      },
      highlightElement: function(element, async, callback) {
        var language,
            grammar,
            parent = element;
        while (parent && !lang.test(parent.className)) {
          parent = parent.parentNode;
        }
        if (parent) {
          language = (parent.className.match(lang) || [, ''])[1];
          grammar = _.languages[language];
        }
        element.className = element.className.replace(lang, '').replace(/\s+/g, ' ') + ' language-' + language;
        parent = element.parentNode;
        if (/pre/i.test(parent.nodeName)) {
          parent.className = parent.className.replace(lang, '').replace(/\s+/g, ' ') + ' language-' + language;
        }
        var code = element.textContent;
        var env = {
          element: element,
          language: language,
          grammar: grammar,
          code: code
        };
        if (!code || !grammar) {
          _.hooks.run('complete', env);
          return;
        }
        _.hooks.run('before-highlight', env);
        if (async && _self.Worker) {
          var worker = new Worker(_.filename);
          worker.onmessage = function(evt) {
            env.highlightedCode = evt.data;
            _.hooks.run('before-insert', env);
            env.element.innerHTML = env.highlightedCode;
            callback && callback.call(env.element);
            _.hooks.run('after-highlight', env);
            _.hooks.run('complete', env);
          };
          worker.postMessage(JSON.stringify({
            language: env.language,
            code: env.code,
            immediateClose: true
          }));
        } else {
          env.highlightedCode = _.highlight(env.code, env.grammar, env.language);
          _.hooks.run('before-insert', env);
          env.element.innerHTML = env.highlightedCode;
          callback && callback.call(element);
          _.hooks.run('after-highlight', env);
          _.hooks.run('complete', env);
        }
      },
      highlight: function(text, grammar, language) {
        var tokens = _.tokenize(text, grammar);
        return Token.stringify(_.util.encode(tokens), language);
      },
      tokenize: function(text, grammar, language) {
        var Token = _.Token;
        var strarr = [text];
        var rest = grammar.rest;
        if (rest) {
          for (var token in rest) {
            grammar[token] = rest[token];
          }
          delete grammar.rest;
        }
        tokenloop: for (var token in grammar) {
          if (!grammar.hasOwnProperty(token) || !grammar[token]) {
            continue;
          }
          var patterns = grammar[token];
          patterns = (_.util.type(patterns) === "Array") ? patterns : [patterns];
          for (var j = 0; j < patterns.length; ++j) {
            var pattern = patterns[j],
                inside = pattern.inside,
                lookbehind = !!pattern.lookbehind,
                lookbehindLength = 0,
                alias = pattern.alias;
            pattern = pattern.pattern || pattern;
            for (var i = 0; i < strarr.length; i++) {
              var str = strarr[i];
              if (strarr.length > text.length) {
                break tokenloop;
              }
              if (str instanceof Token) {
                continue;
              }
              pattern.lastIndex = 0;
              var match = pattern.exec(str);
              if (match) {
                if (lookbehind) {
                  lookbehindLength = match[1].length;
                }
                var from = match.index - 1 + lookbehindLength,
                    match = match[0].slice(lookbehindLength),
                    len = match.length,
                    to = from + len,
                    before = str.slice(0, from + 1),
                    after = str.slice(to + 1);
                var args = [i, 1];
                if (before) {
                  args.push(before);
                }
                var wrapped = new Token(token, inside ? _.tokenize(match, inside) : match, alias);
                args.push(wrapped);
                if (after) {
                  args.push(after);
                }
                Array.prototype.splice.apply(strarr, args);
              }
            }
          }
        }
        return strarr;
      },
      hooks: {
        all: {},
        add: function(name, callback) {
          var hooks = _.hooks.all;
          hooks[name] = hooks[name] || [];
          hooks[name].push(callback);
        },
        run: function(name, env) {
          var callbacks = _.hooks.all[name];
          if (!callbacks || !callbacks.length) {
            return;
          }
          for (var i = 0,
              callback; callback = callbacks[i++]; ) {
            callback(env);
          }
        }
      }
    };
    var Token = _.Token = function(type, content, alias) {
      this.type = type;
      this.content = content;
      this.alias = alias;
    };
    Token.stringify = function(o, language, parent) {
      if (typeof o == 'string') {
        return o;
      }
      if (_.util.type(o) === 'Array') {
        return o.map(function(element) {
          return Token.stringify(element, language, o);
        }).join('');
      }
      var env = {
        type: o.type,
        content: Token.stringify(o.content, language, parent),
        tag: 'span',
        classes: ['token', o.type],
        attributes: {},
        language: language,
        parent: parent
      };
      if (env.type == 'comment') {
        env.attributes['spellcheck'] = 'true';
      }
      if (o.alias) {
        var aliases = _.util.type(o.alias) === 'Array' ? o.alias : [o.alias];
        Array.prototype.push.apply(env.classes, aliases);
      }
      _.hooks.run('wrap', env);
      var attributes = '';
      for (var name in env.attributes) {
        attributes += (attributes ? ' ' : '') + name + '="' + (env.attributes[name] || '') + '"';
      }
      return '<' + env.tag + ' class="' + env.classes.join(' ') + '" ' + attributes + '>' + env.content + '</' + env.tag + '>';
    };
    if (!_self.document) {
      if (!_self.addEventListener) {
        return _self.Prism;
      }
      _self.addEventListener('message', function(evt) {
        var message = JSON.parse(evt.data),
            lang = message.language,
            code = message.code,
            immediateClose = message.immediateClose;
        _self.postMessage(_.highlight(code, _.languages[lang], lang));
        if (immediateClose) {
          _self.close();
        }
      }, false);
      return _self.Prism;
    }
    var script = document.getElementsByTagName('script');
    script = script[script.length - 1];
    if (script) {
      _.filename = script.src;
      if (document.addEventListener && !script.hasAttribute('data-manual')) {
        document.addEventListener('DOMContentLoaded', _.highlightAll);
      }
    }
    return _self.Prism;
  })();
  if (typeof module !== 'undefined' && module.exports) {
    module.exports = Prism;
  }
  if (typeof global !== 'undefined') {
    global.Prism = Prism;
  }
  Prism.languages.markup = {
    'comment': /<!--[\w\W]*?-->/,
    'prolog': /<\?[\w\W]+?\?>/,
    'doctype': /<!DOCTYPE[\w\W]+?>/,
    'cdata': /<!\[CDATA\[[\w\W]*?]]>/i,
    'tag': {
      pattern: /<\/?(?!\d)[^\s>\/=.$<]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\\1|\\?(?!\1)[\w\W])*\1|[^\s'">=]+))?)*\s*\/?>/i,
      inside: {
        'tag': {
          pattern: /^<\/?[^\s>\/]+/i,
          inside: {
            'punctuation': /^<\/?/,
            'namespace': /^[^\s>\/:]+:/
          }
        },
        'attr-value': {
          pattern: /=(?:('|")[\w\W]*?(\1)|[^\s>]+)/i,
          inside: {'punctuation': /[=>"']/}
        },
        'punctuation': /\/?>/,
        'attr-name': {
          pattern: /[^\s>\/]+/,
          inside: {'namespace': /^[^\s>\/:]+:/}
        }
      }
    },
    'entity': /&#?[\da-z]{1,8};/i
  };
  Prism.hooks.add('wrap', function(env) {
    if (env.type === 'entity') {
      env.attributes['title'] = env.content.replace(/&amp;/, '&');
    }
  });
  Prism.languages.xml = Prism.languages.markup;
  Prism.languages.html = Prism.languages.markup;
  Prism.languages.mathml = Prism.languages.markup;
  Prism.languages.svg = Prism.languages.markup;
  Prism.languages.css = {
    'comment': /\/\*[\w\W]*?\*\//,
    'atrule': {
      pattern: /@[\w-]+?.*?(;|(?=\s*\{))/i,
      inside: {'rule': /@[\w-]+/}
    },
    'url': /url\((?:(["'])(\\(?:\r\n|[\w\W])|(?!\1)[^\\\r\n])*\1|.*?)\)/i,
    'selector': /[^\{\}\s][^\{\};]*?(?=\s*\{)/,
    'string': /("|')(\\(?:\r\n|[\w\W])|(?!\1)[^\\\r\n])*\1/,
    'property': /(\b|\B)[\w-]+(?=\s*:)/i,
    'important': /\B!important\b/i,
    'function': /[-a-z0-9]+(?=\()/i,
    'punctuation': /[(){};:]/
  };
  Prism.languages.css['atrule'].inside.rest = Prism.util.clone(Prism.languages.css);
  if (Prism.languages.markup) {
    Prism.languages.insertBefore('markup', 'tag', {'style': {
        pattern: /(<style[\w\W]*?>)[\w\W]*?(?=<\/style>)/i,
        lookbehind: true,
        inside: Prism.languages.css,
        alias: 'language-css'
      }});
    Prism.languages.insertBefore('inside', 'attr-value', {'style-attr': {
        pattern: /\s*style=("|').*?\1/i,
        inside: {
          'attr-name': {
            pattern: /^\s*style/i,
            inside: Prism.languages.markup.tag.inside
          },
          'punctuation': /^\s*=\s*['"]|['"]\s*$/,
          'attr-value': {
            pattern: /.+/i,
            inside: Prism.languages.css
          }
        },
        alias: 'language-css'
      }}, Prism.languages.markup.tag);
  }
  Prism.languages.clike = {
    'comment': [{
      pattern: /(^|[^\\])\/\*[\w\W]*?\*\//,
      lookbehind: true
    }, {
      pattern: /(^|[^\\:])\/\/.*/,
      lookbehind: true
    }],
    'string': /(["'])(\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,
    'class-name': {
      pattern: /((?:\b(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,
      lookbehind: true,
      inside: {punctuation: /(\.|\\)/}
    },
    'keyword': /\b(if|else|while|do|for|return|in|instanceof|function|new|try|throw|catch|finally|null|break|continue)\b/,
    'boolean': /\b(true|false)\b/,
    'function': /[a-z0-9_]+(?=\()/i,
    'number': /\b-?(?:0x[\da-f]+|\d*\.?\d+(?:e[+-]?\d+)?)\b/i,
    'operator': /--?|\+\+?|!=?=?|<=?|>=?|==?=?|&&?|\|\|?|\?|\*|\/|~|\^|%/,
    'punctuation': /[{}[\];(),.:]/
  };
  Prism.languages.javascript = Prism.languages.extend('clike', {
    'keyword': /\b(as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|var|void|while|with|yield)\b/,
    'number': /\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,
    'function': /[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*(?=\()/i
  });
  Prism.languages.insertBefore('javascript', 'keyword', {'regex': {
      pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\\\r\n])+\/[gimyu]{0,5}(?=\s*($|[\r\n,.;})]))/,
      lookbehind: true
    }});
  Prism.languages.insertBefore('javascript', 'class-name', {'template-string': {
      pattern: /`(?:\\`|\\?[^`])*`/,
      inside: {
        'interpolation': {
          pattern: /\$\{[^}]+\}/,
          inside: {
            'interpolation-punctuation': {
              pattern: /^\$\{|\}$/,
              alias: 'punctuation'
            },
            rest: Prism.languages.javascript
          }
        },
        'string': /[\s\S]+/
      }
    }});
  if (Prism.languages.markup) {
    Prism.languages.insertBefore('markup', 'tag', {'script': {
        pattern: /(<script[\w\W]*?>)[\w\W]*?(?=<\/script>)/i,
        lookbehind: true,
        inside: Prism.languages.javascript,
        alias: 'language-javascript'
      }});
  }
  Prism.languages.js = Prism.languages.javascript;
  (function() {
    if (typeof self === 'undefined' || !self.Prism || !self.document || !document.querySelector) {
      return;
    }
    self.Prism.fileHighlight = function() {
      var Extensions = {
        'js': 'javascript',
        'html': 'markup',
        'svg': 'markup',
        'xml': 'markup',
        'py': 'python',
        'rb': 'ruby',
        'ps1': 'powershell',
        'psm1': 'powershell'
      };
      if (Array.prototype.forEach) {
        Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach(function(pre) {
          var src = pre.getAttribute('data-src');
          var language,
              parent = pre;
          var lang = /\blang(?:uage)?-(?!\*)(\w+)\b/i;
          while (parent && !lang.test(parent.className)) {
            parent = parent.parentNode;
          }
          if (parent) {
            language = (pre.className.match(lang) || [, ''])[1];
          }
          if (!language) {
            var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
            language = Extensions[extension] || extension;
          }
          var code = document.createElement('code');
          code.className = 'language-' + language;
          pre.textContent = '';
          code.textContent = 'Loading…';
          pre.appendChild(code);
          var xhr = new XMLHttpRequest();
          xhr.open('GET', src, true);
          xhr.onreadystatechange = function() {
            if (xhr.readyState == 4) {
              if (xhr.status < 400 && xhr.responseText) {
                code.textContent = xhr.responseText;
                Prism.highlightElement(code);
              } else if (xhr.status >= 400) {
                code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
              } else {
                code.textContent = '✖ Error: File does not exist or is empty';
              }
            }
          };
          xhr.send(null);
        });
      }
    };
    self.Prism.fileHighlight();
  })();
  "format cjs";
  Prism.languages.actionscript = Prism.languages.extend('javascript', {
    'keyword': /\b(?:as|break|case|catch|class|const|default|delete|do|else|extends|finally|for|function|if|implements|import|in|instanceof|interface|internal|is|native|new|null|package|private|protected|public|return|super|switch|this|throw|try|typeof|use|var|void|while|with|dynamic|each|final|get|include|namespace|native|override|set|static)\b/,
    'operator': /\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<<?|>>?>?|[!=]=?)=?|[~?@]/
  });
  Prism.languages.actionscript['class-name'].alias = 'function';
  if (Prism.languages.markup) {
    Prism.languages.insertBefore('actionscript', 'string', {'xml': {
        pattern: /(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\\1|\\?(?!\1)[\w\W])*\2)*\s*\/?>/,
        lookbehind: true,
        inside: {rest: Prism.languages.markup}
      }});
  }
  "format cjs";
  Prism.languages.c = Prism.languages.extend('clike', {
    'keyword': /\b(asm|typeof|inline|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|union|unsigned|void|volatile|while)\b/,
    'operator': /\-[>-]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|?\||[~^%?*\/]/,
    'number': /\b-?(?:0x[\da-f]+|\d*\.?\d+(?:e[+-]?\d+)?)[ful]*\b/i
  });
  Prism.languages.insertBefore('c', 'string', {
    'macro': {
      pattern: /(^\s*)#\s*[a-z]+([^\r\n\\]|\\.|\\(?:\r\n?|\n))*/im,
      lookbehind: true,
      alias: 'property',
      inside: {
        'string': {
          pattern: /(#\s*include\s*)(<.+?>|("|')(\\?.)+?\3)/,
          lookbehind: true
        },
        'directive': {
          pattern: /(#\s*)\b(define|elif|else|endif|error|ifdef|ifndef|if|import|include|line|pragma|undef|using)\b/,
          lookbehind: true,
          alias: 'keyword'
        }
      }
    },
    'constant': /\b(__FILE__|__LINE__|__DATE__|__TIME__|__TIMESTAMP__|__func__|EOF|NULL|stdin|stdout|stderr)\b/
  });
  delete Prism.languages.c['class-name'];
  delete Prism.languages.c['boolean'];
  "format cjs";
  Prism.languages.cpp = Prism.languages.extend('c', {
    'keyword': /\b(alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|class|compl|const|constexpr|const_cast|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|float|for|friend|goto|if|inline|int|long|mutable|namespace|new|noexcept|nullptr|operator|private|protected|public|register|reinterpret_cast|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,
    'boolean': /\b(true|false)\b/,
    'operator': /[-+]{1,2}|!=?|<{1,2}=?|>{1,2}=?|\->|:{1,2}|={1,2}|\^|~|%|&{1,2}|\|?\||\?|\*|\/|\b(and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/
  });
  Prism.languages.insertBefore('cpp', 'keyword', {'class-name': {
      pattern: /(class\s+)[a-z0-9_]+/i,
      lookbehind: true
    }});
  "format cjs";
  Prism.languages.csharp = Prism.languages.extend('clike', {
    'keyword': /\b(abstract|as|async|await|base|bool|break|byte|case|catch|char|checked|class|const|continue|decimal|default|delegate|do|double|else|enum|event|explicit|extern|false|finally|fixed|float|for|foreach|goto|if|implicit|in|int|interface|internal|is|lock|long|namespace|new|null|object|operator|out|override|params|private|protected|public|readonly|ref|return|sbyte|sealed|short|sizeof|stackalloc|static|string|struct|switch|this|throw|true|try|typeof|uint|ulong|unchecked|unsafe|ushort|using|virtual|void|volatile|while|add|alias|ascending|async|await|descending|dynamic|from|get|global|group|into|join|let|orderby|partial|remove|select|set|value|var|where|yield)\b/,
    'string': [/@("|')(\1\1|\\\1|\\?(?!\1)[\s\S])*\1/, /("|')(\\?.)*?\1/],
    'number': /\b-?(0x[\da-f]+|\d*\.?\d+f?)\b/i
  });
  Prism.languages.insertBefore('csharp', 'keyword', {'preprocessor': {
      pattern: /(^\s*)#.*/m,
      lookbehind: true,
      alias: 'property',
      inside: {'directive': {
          pattern: /(\s*#)\b(define|elif|else|endif|endregion|error|if|line|pragma|region|undef|warning)\b/,
          lookbehind: true,
          alias: 'keyword'
        }}
    }});
  "format cjs";
  Prism.languages.php = Prism.languages.extend('clike', {
    'keyword': /\b(and|or|xor|array|as|break|case|cfunction|class|const|continue|declare|default|die|do|else|elseif|enddeclare|endfor|endforeach|endif|endswitch|endwhile|extends|for|foreach|function|include|include_once|global|if|new|return|static|switch|use|require|require_once|var|while|abstract|interface|public|implements|private|protected|parent|throw|null|echo|print|trait|namespace|final|yield|goto|instanceof|finally|try|catch)\b/i,
    'constant': /\b[A-Z0-9_]{2,}\b/,
    'comment': {
      pattern: /(^|[^\\])(?:\/\*[\w\W]*?\*\/|\/\/.*)/,
      lookbehind: true
    }
  });
  Prism.languages.insertBefore('php', 'class-name', {'shell-comment': {
      pattern: /(^|[^\\])#.*/,
      lookbehind: true,
      alias: 'comment'
    }});
  Prism.languages.insertBefore('php', 'keyword', {
    'delimiter': /\?>|<\?(?:php)?/i,
    'variable': /\$\w+\b/i,
    'package': {
      pattern: /(\\|namespace\s+|use\s+)[\w\\]+/,
      lookbehind: true,
      inside: {punctuation: /\\/}
    }
  });
  Prism.languages.insertBefore('php', 'operator', {'property': {
      pattern: /(->)[\w]+/,
      lookbehind: true
    }});
  if (Prism.languages.markup) {
    Prism.hooks.add('before-highlight', function(env) {
      if (env.language !== 'php') {
        return;
      }
      env.tokenStack = [];
      env.backupCode = env.code;
      env.code = env.code.replace(/(?:<\?php|<\?)[\w\W]*?(?:\?>)/ig, function(match) {
        env.tokenStack.push(match);
        return '{{{PHP' + env.tokenStack.length + '}}}';
      });
    });
    Prism.hooks.add('before-insert', function(env) {
      if (env.language === 'php') {
        env.code = env.backupCode;
        delete env.backupCode;
      }
    });
    Prism.hooks.add('after-highlight', function(env) {
      if (env.language !== 'php') {
        return;
      }
      for (var i = 0,
          t; t = env.tokenStack[i]; i++) {
        env.highlightedCode = env.highlightedCode.replace('{{{PHP' + (i + 1) + '}}}', Prism.highlight(t, env.grammar, 'php').replace(/\$/g, '$$$$'));
      }
      env.element.innerHTML = env.highlightedCode;
    });
    Prism.hooks.add('wrap', function(env) {
      if (env.language === 'php' && env.type === 'markup') {
        env.content = env.content.replace(/(\{\{\{PHP[0-9]+\}\}\})/g, "<span class=\"token php\">$1</span>");
      }
    });
    Prism.languages.insertBefore('php', 'comment', {
      'markup': {
        pattern: /<[^?]\/?(.*?)>/,
        inside: Prism.languages.markup
      },
      'php': /\{\{\{PHP[0-9]+\}\}\}/
    });
  }
  "format cjs";
  (function(Prism) {
    var comment = /#(?!\{).+/,
        interpolation = {
          pattern: /#\{[^}]+\}/,
          alias: 'variable'
        };
    Prism.languages.coffeescript = Prism.languages.extend('javascript', {
      'comment': comment,
      'string': [/'(?:\\?[^\\])*?'/, {
        pattern: /"(?:\\?[^\\])*?"/,
        inside: {'interpolation': interpolation}
      }],
      'keyword': /\b(and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,
      'class-member': {
        pattern: /@(?!\d)\w+/,
        alias: 'variable'
      }
    });
    Prism.languages.insertBefore('coffeescript', 'comment', {
      'multiline-comment': {
        pattern: /###[\s\S]+?###/,
        alias: 'comment'
      },
      'block-regex': {
        pattern: /\/{3}[\s\S]*?\/{3}/,
        alias: 'regex',
        inside: {
          'comment': comment,
          'interpolation': interpolation
        }
      }
    });
    Prism.languages.insertBefore('coffeescript', 'string', {
      'inline-javascript': {
        pattern: /`(?:\\?[\s\S])*?`/,
        inside: {
          'delimiter': {
            pattern: /^`|`$/,
            alias: 'punctuation'
          },
          rest: Prism.languages.javascript
        }
      },
      'multiline-string': [{
        pattern: /'''[\s\S]*?'''/,
        alias: 'string'
      }, {
        pattern: /"""[\s\S]*?"""/,
        alias: 'string',
        inside: {interpolation: interpolation}
      }]
    });
    Prism.languages.insertBefore('coffeescript', 'keyword', {'property': /(?!\d)\w+(?=\s*:(?!:))/});
  }(Prism));
  "format cjs";
  Prism.languages.go = Prism.languages.extend('clike', {
    'keyword': /\b(break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,
    'builtin': /\b(bool|byte|complex(64|128)|error|float(32|64)|rune|string|u?int(8|16|32|64|)|uintptr|append|cap|close|complex|copy|delete|imag|len|make|new|panic|print(ln)?|real|recover)\b/,
    'boolean': /\b(_|iota|nil|true|false)\b/,
    'operator': /[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,
    'number': /\b(-?(0x[a-f\d]+|(\d+\.?\d*|\.\d+)(e[-+]?\d+)?)i?)\b/i,
    'string': /("|'|`)(\\?.|\r|\n)*?\1/
  });
  delete Prism.languages.go['class-name'];
  "format cjs";
  Prism.languages.haskell = {
    'comment': {
      pattern: /(^|[^-!#$%*+=?&@|~.:<>^\\\/])(--[^-!#$%*+=?&@|~.:<>^\\\/].*|{-[\w\W]*?-})/m,
      lookbehind: true
    },
    'char': /'([^\\']|\\([abfnrtv\\"'&]|\^[A-Z@[\]\^_]|NUL|SOH|STX|ETX|EOT|ENQ|ACK|BEL|BS|HT|LF|VT|FF|CR|SO|SI|DLE|DC1|DC2|DC3|DC4|NAK|SYN|ETB|CAN|EM|SUB|ESC|FS|GS|RS|US|SP|DEL|\d+|o[0-7]+|x[0-9a-fA-F]+))'/,
    'string': /"([^\\"]|\\([abfnrtv\\"'&]|\^[A-Z@[\]\^_]|NUL|SOH|STX|ETX|EOT|ENQ|ACK|BEL|BS|HT|LF|VT|FF|CR|SO|SI|DLE|DC1|DC2|DC3|DC4|NAK|SYN|ETB|CAN|EM|SUB|ESC|FS|GS|RS|US|SP|DEL|\d+|o[0-7]+|x[0-9a-fA-F]+)|\\\s+\\)*"/,
    'keyword': /\b(case|class|data|deriving|do|else|if|in|infixl|infixr|instance|let|module|newtype|of|primitive|then|type|where)\b/,
    'import_statement': {
      pattern: /(\r?\n|\r|^)\s*import\s+(qualified\s+)?([A-Z][_a-zA-Z0-9']*)(\.[A-Z][_a-zA-Z0-9']*)*(\s+as\s+([A-Z][_a-zA-Z0-9']*)(\.[A-Z][_a-zA-Z0-9']*)*)?(\s+hiding\b)?/m,
      inside: {'keyword': /\b(import|qualified|as|hiding)\b/}
    },
    'builtin': /\b(abs|acos|acosh|all|and|any|appendFile|approxRational|asTypeOf|asin|asinh|atan|atan2|atanh|basicIORun|break|catch|ceiling|chr|compare|concat|concatMap|const|cos|cosh|curry|cycle|decodeFloat|denominator|digitToInt|div|divMod|drop|dropWhile|either|elem|encodeFloat|enumFrom|enumFromThen|enumFromThenTo|enumFromTo|error|even|exp|exponent|fail|filter|flip|floatDigits|floatRadix|floatRange|floor|fmap|foldl|foldl1|foldr|foldr1|fromDouble|fromEnum|fromInt|fromInteger|fromIntegral|fromRational|fst|gcd|getChar|getContents|getLine|group|head|id|inRange|index|init|intToDigit|interact|ioError|isAlpha|isAlphaNum|isAscii|isControl|isDenormalized|isDigit|isHexDigit|isIEEE|isInfinite|isLower|isNaN|isNegativeZero|isOctDigit|isPrint|isSpace|isUpper|iterate|last|lcm|length|lex|lexDigits|lexLitChar|lines|log|logBase|lookup|map|mapM|mapM_|max|maxBound|maximum|maybe|min|minBound|minimum|mod|negate|not|notElem|null|numerator|odd|or|ord|otherwise|pack|pi|pred|primExitWith|print|product|properFraction|putChar|putStr|putStrLn|quot|quotRem|range|rangeSize|read|readDec|readFile|readFloat|readHex|readIO|readInt|readList|readLitChar|readLn|readOct|readParen|readSigned|reads|readsPrec|realToFrac|recip|rem|repeat|replicate|return|reverse|round|scaleFloat|scanl|scanl1|scanr|scanr1|seq|sequence|sequence_|show|showChar|showInt|showList|showLitChar|showParen|showSigned|showString|shows|showsPrec|significand|signum|sin|sinh|snd|sort|span|splitAt|sqrt|subtract|succ|sum|tail|take|takeWhile|tan|tanh|threadToIOResult|toEnum|toInt|toInteger|toLower|toRational|toUpper|truncate|uncurry|undefined|unlines|until|unwords|unzip|unzip3|userError|words|writeFile|zip|zip3|zipWith|zipWith3)\b/,
    'number': /\b(\d+(\.\d+)?(e[+-]?\d+)?|0o[0-7]+|0x[0-9a-f]+)\b/i,
    'operator': /\s\.\s|[-!#$%*+=?&@|~.:<>^\\\/]*\.[-!#$%*+=?&@|~.:<>^\\\/]+|[-!#$%*+=?&@|~.:<>^\\\/]+\.[-!#$%*+=?&@|~.:<>^\\\/]*|[-!#$%*+=?&@|~:<>^\\\/]+|`([A-Z][_a-zA-Z0-9']*\.)*[_a-z][_a-zA-Z0-9']*`/,
    'hvariable': /\b([A-Z][_a-zA-Z0-9']*\.)*[_a-z][_a-zA-Z0-9']*\b/,
    'constant': /\b([A-Z][_a-zA-Z0-9']*\.)*[A-Z][_a-zA-Z0-9']*\b/,
    'punctuation': /[{}[\];(),.:]/
  };
  "format cjs";
  Prism.languages.java = Prism.languages.extend('clike', {
    'keyword': /\b(abstract|continue|for|new|switch|assert|default|goto|package|synchronized|boolean|do|if|private|this|break|double|implements|protected|throw|byte|else|import|public|throws|case|enum|instanceof|return|transient|catch|extends|int|short|try|char|final|interface|static|void|class|finally|long|strictfp|volatile|const|float|native|super|while)\b/,
    'number': /\b0b[01]+\b|\b0x[\da-f]*\.?[\da-fp\-]+\b|\b\d*\.?\d+(?:e[+-]?\d+)?[df]?\b/i,
    'operator': {
      pattern: /(^|[^.])(?:\+[+=]?|-[-=]?|!=?|<<?=?|>>?>?=?|==?|&[&=]?|\|[|=]?|\*=?|\/=?|%=?|\^=?|[?:~])/m,
      lookbehind: true
    }
  });
  "format cjs";
  Prism.languages.lua = {
    'comment': /^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,
    'string': /(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[\s\S]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,
    'number': /\b0x[a-f\d]+\.?[a-f\d]*(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|\.?\d*(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,
    'keyword': /\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,
    'function': /(?!\d)\w+(?=\s*(?:[({]))/,
    'operator': [/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/, {
      pattern: /(^|[^.])\.\.(?!\.)/,
      lookbehind: true
    }],
    'punctuation': /[\[\](){},;]|\.+|:+/
  };
  "format cjs";
  Prism.languages.matlab = {
    'string': /\B'(?:''|[^'\n])*'/,
    'comment': [/%\{[\s\S]*?\}%/, /%.+/],
    'number': /\b-?(?:\d*\.?\d+(?:[eE][+-]?\d+)?(?:[ij])?|[ij])\b/,
    'keyword': /\b(?:break|case|catch|continue|else|elseif|end|for|function|if|inf|NaN|otherwise|parfor|pause|pi|return|switch|try|while)\b/,
    'function': /(?!\d)\w+(?=\s*\()/,
    'operator': /\.?[*^\/\\']|[+\-:@]|[<>=~]=?|&&?|\|\|?/,
    'punctuation': /\.{3}|[.,;\[\](){}!]/
  };
  "format cjs";
  Prism.languages.perl = {
    'comment': [{
      pattern: /(^\s*)=\w+[\s\S]*?=cut.*/m,
      lookbehind: true
    }, {
      pattern: /(^|[^\\$])#.*/,
      lookbehind: true
    }],
    'string': [/\b(?:q|qq|qx|qw)\s*([^a-zA-Z0-9\s\{\(\[<])(?:[^\\]|\\[\s\S])*?\1/, /\b(?:q|qq|qx|qw)\s+([a-zA-Z0-9])(?:[^\\]|\\[\s\S])*?\1/, /\b(?:q|qq|qx|qw)\s*\((?:[^()\\]|\\[\s\S])*\)/, /\b(?:q|qq|qx|qw)\s*\{(?:[^{}\\]|\\[\s\S])*\}/, /\b(?:q|qq|qx|qw)\s*\[(?:[^[\]\\]|\\[\s\S])*\]/, /\b(?:q|qq|qx|qw)\s*<(?:[^<>\\]|\\[\s\S])*>/, /("|`)(?:[^\\]|\\[\s\S])*?\1/, /'(?:[^'\\\r\n]|\\.)*'/],
    'regex': [/\b(?:m|qr)\s*([^a-zA-Z0-9\s\{\(\[<])(?:[^\\]|\\[\s\S])*?\1[msixpodualngc]*/, /\b(?:m|qr)\s+([a-zA-Z0-9])(?:[^\\]|\\.)*?\1[msixpodualngc]*/, /\b(?:m|qr)\s*\((?:[^()\\]|\\[\s\S])*\)[msixpodualngc]*/, /\b(?:m|qr)\s*\{(?:[^{}\\]|\\[\s\S])*\}[msixpodualngc]*/, /\b(?:m|qr)\s*\[(?:[^[\]\\]|\\[\s\S])*\][msixpodualngc]*/, /\b(?:m|qr)\s*<(?:[^<>\\]|\\[\s\S])*>[msixpodualngc]*/, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s*([^a-zA-Z0-9\s\{\(\[<])(?:[^\\]|\\[\s\S])*?\2(?:[^\\]|\\[\s\S])*?\2[msixpodualngcer]*/,
      lookbehind: true
    }, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s+([a-zA-Z0-9])(?:[^\\]|\\[\s\S])*?\2(?:[^\\]|\\[\s\S])*?\2[msixpodualngcer]*/,
      lookbehind: true
    }, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s*\((?:[^()\\]|\\[\s\S])*\)\s*\((?:[^()\\]|\\[\s\S])*\)[msixpodualngcer]*/,
      lookbehind: true
    }, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s*\{(?:[^{}\\]|\\[\s\S])*\}\s*\{(?:[^{}\\]|\\[\s\S])*\}[msixpodualngcer]*/,
      lookbehind: true
    }, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s*\[(?:[^[\]\\]|\\[\s\S])*\]\s*\[(?:[^[\]\\]|\\[\s\S])*\][msixpodualngcer]*/,
      lookbehind: true
    }, {
      pattern: /(^|[^-]\b)(?:s|tr|y)\s*<(?:[^<>\\]|\\[\s\S])*>\s*<(?:[^<>\\]|\\[\s\S])*>[msixpodualngcer]*/,
      lookbehind: true
    }, /\/(?:[^\/\\\r\n]|\\.)*\/[msixpodualngc]*(?=\s*(?:$|[\r\n,.;})&|\-+*~<>!?^]|(lt|gt|le|ge|eq|ne|cmp|not|and|or|xor|x)\b))/],
    'variable': [/[&*$@%]\{\^[A-Z]+\}/, /[&*$@%]\^[A-Z_]/, /[&*$@%]#?(?=\{)/, /[&*$@%]#?((::)*'?(?!\d)[\w$]+)+(::)*/i, /[&*$@%]\d+/, /(?!%=)[$@%][!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/],
    'filehandle': {
      pattern: /<(?![<=])\S*>|\b_\b/,
      alias: 'symbol'
    },
    'vstring': {
      pattern: /v\d+(\.\d+)*|\d+(\.\d+){2,}/,
      alias: 'string'
    },
    'function': {
      pattern: /sub [a-z0-9_]+/i,
      inside: {keyword: /sub/}
    },
    'keyword': /\b(any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|say|state|sub|switch|undef|unless|until|use|when|while)\b/,
    'number': /\b-?(0x[\dA-Fa-f](_?[\dA-Fa-f])*|0b[01](_?[01])*|(\d(_?\d)*)?\.?\d(_?\d)*([Ee][+-]?\d+)?)\b/,
    'operator': /-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|\+[+=]?|-[-=>]?|\*\*?=?|\/\/?=?|=[=~>]?|~[~=]?|\|\|?=?|&&?=?|<(?:=>?|<=?)?|>>?=?|![~=]?|[%^]=?|\.(?:=|\.\.?)?|[\\?]|\bx(?:=|\b)|\b(lt|gt|le|ge|eq|ne|cmp|not|and|or|xor)\b/,
    'punctuation': /[{}[\];(),:]/
  };
  "format cjs";
  Prism.languages.python = {
    'triple-quoted-string': {
      pattern: /"""[\s\S]+?"""|'''[\s\S]+?'''/,
      alias: 'string'
    },
    'comment': {
      pattern: /(^|[^\\])#.*/,
      lookbehind: true
    },
    'string': /("|')(?:\\?.)*?\1/,
    'function': {
      pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_][a-zA-Z0-9_]*(?=\()/g,
      lookbehind: true
    },
    'class-name': {
      pattern: /(\bclass\s+)[a-z0-9_]+/i,
      lookbehind: true
    },
    'keyword': /\b(?:as|assert|async|await|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|pass|print|raise|return|try|while|with|yield)\b/,
    'boolean': /\b(?:True|False)\b/,
    'number': /\b-?(?:0[bo])?(?:(?:\d|0x[\da-f])[\da-f]*\.?\d*|\.\d+)(?:e[+-]?\d+)?j?\b/i,
    'operator': /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]|\b(?:or|and|not)\b/,
    'punctuation': /[{}[\];(),.:]/
  };
  "format cjs";
  Prism.languages.r = {
    'comment': /#.*/,
    'string': /(['"])(?:\\?.)*?\1/,
    'percent-operator': {
      pattern: /%[^%\s]*%/,
      alias: 'operator'
    },
    'boolean': /\b(?:TRUE|FALSE)\b/,
    'ellipsis': /\.\.(?:\.|\d+)/,
    'number': [/\b(?:NaN|Inf)\b/, /\b(?:0x[\dA-Fa-f]+(?:\.\d*)?|\d*\.?\d+)(?:[EePp][+-]?\d+)?[iL]?\b/],
    'keyword': /\b(?:if|else|repeat|while|function|for|in|next|break|NULL|NA|NA_integer_|NA_real_|NA_complex_|NA_character_)\b/,
    'operator': /->?>?|<(?:=|<?-)?|[>=!]=?|::?|&&?|\|\|?|[+*\/^$@~]/,
    'punctuation': /[(){}\[\],;]/
  };
  "format cjs";
  (function(Prism) {
    Prism.languages.ruby = Prism.languages.extend('clike', {
      'comment': /#(?!\{[^\r\n]*?\}).*/,
      'keyword': /\b(alias|and|BEGIN|begin|break|case|class|def|define_method|defined|do|each|else|elsif|END|end|ensure|false|for|if|in|module|new|next|nil|not|or|raise|redo|require|rescue|retry|return|self|super|then|throw|true|undef|unless|until|when|while|yield)\b/
    });
    var interpolation = {
      pattern: /#\{[^}]+\}/,
      inside: {
        'delimiter': {
          pattern: /^#\{|\}$/,
          alias: 'tag'
        },
        rest: Prism.util.clone(Prism.languages.ruby)
      }
    };
    Prism.languages.insertBefore('ruby', 'keyword', {
      'regex': [{
        pattern: /%r([^a-zA-Z0-9\s\{\(\[<])(?:[^\\]|\\[\s\S])*?\1[gim]{0,3}/,
        inside: {'interpolation': interpolation}
      }, {
        pattern: /%r\((?:[^()\\]|\\[\s\S])*\)[gim]{0,3}/,
        inside: {'interpolation': interpolation}
      }, {
        pattern: /%r\{(?:[^#{}\\]|#(?:\{[^}]+\})?|\\[\s\S])*\}[gim]{0,3}/,
        inside: {'interpolation': interpolation}
      }, {
        pattern: /%r\[(?:[^\[\]\\]|\\[\s\S])*\][gim]{0,3}/,
        inside: {'interpolation': interpolation}
      }, {
        pattern: /%r<(?:[^<>\\]|\\[\s\S])*>[gim]{0,3}/,
        inside: {'interpolation': interpolation}
      }, {
        pattern: /(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\r\n])+\/[gim]{0,3}(?=\s*($|[\r\n,.;})]))/,
        lookbehind: true
      }],
      'variable': /[@$]+[a-zA-Z_][a-zA-Z_0-9]*(?:[?!]|\b)/,
      'symbol': /:[a-zA-Z_][a-zA-Z_0-9]*(?:[?!]|\b)/
    });
    Prism.languages.insertBefore('ruby', 'number', {
      'builtin': /\b(Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Stat|File|Fixnum|Fload|Hash|Integer|IO|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|String|Struct|TMS|Symbol|ThreadGroup|Thread|Time|TrueClass)\b/,
      'constant': /\b[A-Z][a-zA-Z_0-9]*(?:[?!]|\b)/
    });
    Prism.languages.ruby.string = [{
      pattern: /%[qQiIwWxs]?([^a-zA-Z0-9\s\{\(\[<])(?:[^\\]|\\[\s\S])*?\1/,
      inside: {'interpolation': interpolation}
    }, {
      pattern: /%[qQiIwWxs]?\((?:[^()\\]|\\[\s\S])*\)/,
      inside: {'interpolation': interpolation}
    }, {
      pattern: /%[qQiIwWxs]?\{(?:[^#{}\\]|#(?:\{[^}]+\})?|\\[\s\S])*\}/,
      inside: {'interpolation': interpolation}
    }, {
      pattern: /%[qQiIwWxs]?\[(?:[^\[\]\\]|\\[\s\S])*\]/,
      inside: {'interpolation': interpolation}
    }, {
      pattern: /%[qQiIwWxs]?<(?:[^<>\\]|\\[\s\S])*>/,
      inside: {'interpolation': interpolation}
    }, {
      pattern: /("|')(#\{[^}]+\}|\\(?:\r?\n|\r)|\\?.)*?\1/,
      inside: {'interpolation': interpolation}
    }];
  }(Prism));
  "format cjs";
  (function(Prism) {
    var insideString = {variable: [{
        pattern: /\$?\(\([\w\W]+?\)\)/,
        inside: {
          variable: [{
            pattern: /(^\$\(\([\w\W]+)\)\)/,
            lookbehind: true
          }, /^\$\(\(/],
          number: /\b-?(?:0x[\dA-Fa-f]+|\d*\.?\d+(?:[Ee]-?\d+)?)\b/,
          operator: /--?|-=|\+\+?|\+=|!=?|~|\*\*?|\*=|\/=?|%=?|<<=?|>>=?|<=?|>=?|==?|&&?|&=|\^=?|\|\|?|\|=|\?|:/,
          punctuation: /\(\(?|\)\)?|,|;/
        }
      }, {
        pattern: /\$\([^)]+\)|`[^`]+`/,
        inside: {variable: /^\$\(|^`|\)$|`$/}
      }, /\$(?:[a-z0-9_#\?\*!@]+|\{[^}]+\})/i]};
    Prism.languages.bash = {
      'shebang': {
        pattern: /^#!\s*\/bin\/bash|^#!\s*\/bin\/sh/,
        alias: 'important'
      },
      'comment': {
        pattern: /(^|[^"{\\])#.*/,
        lookbehind: true
      },
      'string': [{
        pattern: /((?:^|[^<])<<\s*)(?:"|')?(\w+?)(?:"|')?\s*\r?\n(?:[\s\S])*?\r?\n\2/g,
        lookbehind: true,
        inside: insideString
      }, {
        pattern: /("|')(?:\\?[\s\S])*?\1/g,
        inside: insideString
      }],
      'variable': insideString.variable,
      'function': {
        pattern: /(^|\s|;|\||&)(?:alias|apropos|apt-get|aptitude|aspell|awk|basename|bash|bc|bg|builtin|bzip2|cal|cat|cd|cfdisk|chgrp|chmod|chown|chroot|chkconfig|cksum|clear|cmp|comm|command|cp|cron|crontab|csplit|cut|date|dc|dd|ddrescue|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|du|egrep|eject|enable|env|ethtool|eval|exec|expand|expect|export|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|getopts|git|grep|groupadd|groupdel|groupmod|groups|gzip|hash|head|help|hg|history|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|jobs|join|kill|killall|less|link|ln|locate|logname|logout|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|make|man|mkdir|mkfifo|mkisofs|mknod|more|most|mount|mtools|mtr|mv|mmv|nano|netstat|nice|nl|nohup|notify-send|nslookup|open|op|passwd|paste|pathchk|ping|pkill|popd|pr|printcap|printenv|printf|ps|pushd|pv|pwd|quota|quotacheck|quotactl|ram|rar|rcp|read|readarray|readonly|reboot|rename|renice|remsync|rev|rm|rmdir|rsync|screen|scp|sdiff|sed|seq|service|sftp|shift|shopt|shutdown|sleep|slocate|sort|source|split|ssh|stat|strace|su|sudo|sum|suspend|sync|tail|tar|tee|test|time|timeout|times|touch|top|traceroute|trap|tr|tsort|tty|type|ulimit|umask|umount|unalias|uname|unexpand|uniq|units|unrar|unshar|uptime|useradd|userdel|usermod|users|uuencode|uudecode|v|vdir|vi|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yes|zip)(?=$|\s|;|\||&)/,
        lookbehind: true
      },
      'keyword': {
        pattern: /(^|\s|;|\||&)(?:let|:|\.|if|then|else|elif|fi|for|break|continue|while|in|case|function|select|do|done|until|echo|exit|return|set|declare)(?=$|\s|;|\||&)/,
        lookbehind: true
      },
      'boolean': {
        pattern: /(^|\s|;|\||&)(?:true|false)(?=$|\s|;|\||&)/,
        lookbehind: true
      },
      'operator': /&&?|\|\|?|==?|!=?|<<<?|>>|<=?|>=?|=~/,
      'punctuation': /\$?\(\(?|\)\)?|\.\.|[{}[\];]/
    };
    var inside = insideString.variable[1].inside;
    inside['function'] = Prism.languages.bash['function'];
    inside.keyword = Prism.languages.bash.keyword;
    inside.boolean = Prism.languages.bash.boolean;
    inside.operator = Prism.languages.bash.operator;
    inside.punctuation = Prism.languages.bash.punctuation;
  })(Prism);
  "format cjs";
  Prism.languages.swift = Prism.languages.extend('clike', {
    'string': {
      pattern: /("|')(\\(?:\((?:[^()]|\([^)]+\))+\)|\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,
      inside: {'interpolation': {
          pattern: /\\\((?:[^()]|\([^)]+\))+\)/,
          inside: {delimiter: {
              pattern: /^\\\(|\)$/,
              alias: 'variable'
            }}
        }}
    },
    'keyword': /\b(as|associativity|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic(?:Type)?|else|enum|extension|fallthrough|final|for|func|get|guard|if|import|in|infix|init|inout|internal|is|lazy|left|let|mutating|new|none|nonmutating|operator|optional|override|postfix|precedence|prefix|private|Protocol|public|repeat|required|rethrows|return|right|safe|self|Self|set|static|struct|subscript|super|switch|throws?|try|Type|typealias|unowned|unsafe|var|weak|where|while|willSet|__(?:COLUMN__|FILE__|FUNCTION__|LINE__))\b/,
    'number': /\b([\d_]+(\.[\de_]+)?|0x[a-f0-9_]+(\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,
    'constant': /\b(nil|[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,
    'atrule': /@\b(IB(?:Outlet|Designable|Action|Inspectable)|class_protocol|exported|noreturn|NS(?:Copying|Managed)|objc|UIApplicationMain|auto_closure)\b/,
    'builtin': /\b([A-Z]\S+|abs|advance|alignof(?:Value)?|assert|contains|count(?:Elements)?|debugPrint(?:ln)?|distance|drop(?:First|Last)|dump|enumerate|equal|filter|find|first|getVaList|indices|isEmpty|join|last|lexicographicalCompare|map|max(?:Element)?|min(?:Element)?|numericCast|overlaps|partition|print(?:ln)?|reduce|reflect|reverse|sizeof(?:Value)?|sort(?:ed)?|split|startsWith|stride(?:of(?:Value)?)?|suffix|swap|toDebugString|toString|transcode|underestimateCount|unsafeBitCast|with(?:ExtendedLifetime|Unsafe(?:MutablePointers?|Pointers?)|VaList))\b/
  });
  Prism.languages.swift['string'].inside['interpolation'].inside.rest = Prism.util.clone(Prism.languages.swift);
  "format cjs";
  Prism.languages.objectivec = Prism.languages.extend('c', {
    'keyword': /\b(asm|typeof|inline|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|union|unsigned|void|volatile|while|in|self|super)\b|(@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,
    'string': /("|')(\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1|@"(\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,
    'operator': /-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/
  });
  "format cjs";
  Prism.languages.scala = Prism.languages.extend('java', {
    'keyword': /<-|=>|\b(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|null|object|override|package|private|protected|return|sealed|self|super|this|throw|trait|try|type|val|var|while|with|yield)\b/,
    'string': /"""[\W\w]*?"""|"(?:[^"\\\r\n]|\\.)*"|'(?:[^\\\r\n']|\\.[^\\']*)'/,
    'builtin': /\b(?:String|Int|Long|Short|Byte|Boolean|Double|Float|Char|Any|AnyRef|AnyVal|Unit|Nothing)\b/,
    'number': /\b(?:0x[\da-f]*\.?[\da-f]+|\d*\.?\d+e?\d*[dfl]?)\b/i,
    'symbol': /'[^\d\s\\]\w*/
  });
  delete Prism.languages.scala['class-name'];
  delete Prism.languages.scala['function'];
  return module.exports;
});

$__System.register("a5", [], function() { return { setters: [], execute: function() {} } });

$__System.register("a6", [], function() { return { setters: [], execute: function() {} } });

$__System.registerDynamic("a7", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  ;
  (function() {
    var block = {
      newline: /^\n+/,
      code: /^( {4}[^\n]+\n*)+/,
      fences: noop,
      hr: /^( *[-*_]){3,} *(?:\n+|$)/,
      heading: /^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,
      nptable: noop,
      lheading: /^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,
      blockquote: /^( *>[^\n]+(\n(?!def)[^\n]+)*\n*)+/,
      list: /^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,
      html: /^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,
      def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,
      table: noop,
      paragraph: /^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,
      text: /^[^\n]+/
    };
    block.bullet = /(?:[*+-]|\d+\.)/;
    block.item = /^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/;
    block.item = replace(block.item, 'gm')(/bull/g, block.bullet)();
    block.list = replace(block.list)(/bull/g, block.bullet)('hr', '\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))')('def', '\\n+(?=' + block.def.source + ')')();
    block.blockquote = replace(block.blockquote)('def', block.def)();
    block._tag = '(?!(?:' + 'a|em|strong|small|s|cite|q|dfn|abbr|data|time|code' + '|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo' + '|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b';
    block.html = replace(block.html)('comment', /<!--[\s\S]*?-->/)('closed', /<(tag)[\s\S]+?<\/\1>/)('closing', /<tag(?:"[^"]*"|'[^']*'|[^'">])*?>/)(/tag/g, block._tag)();
    block.paragraph = replace(block.paragraph)('hr', block.hr)('heading', block.heading)('lheading', block.lheading)('blockquote', block.blockquote)('tag', '<' + block._tag)('def', block.def)();
    block.normal = merge({}, block);
    block.gfm = merge({}, block.normal, {
      fences: /^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/,
      paragraph: /^/,
      heading: /^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/
    });
    block.gfm.paragraph = replace(block.paragraph)('(?!', '(?!' + block.gfm.fences.source.replace('\\1', '\\2') + '|' + block.list.source.replace('\\1', '\\3') + '|')();
    block.tables = merge({}, block.gfm, {
      nptable: /^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,
      table: /^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/
    });
    function Lexer(options) {
      this.tokens = [];
      this.tokens.links = {};
      this.options = options || marked.defaults;
      this.rules = block.normal;
      if (this.options.gfm) {
        if (this.options.tables) {
          this.rules = block.tables;
        } else {
          this.rules = block.gfm;
        }
      }
    }
    Lexer.rules = block;
    Lexer.lex = function(src, options) {
      var lexer = new Lexer(options);
      return lexer.lex(src);
    };
    Lexer.prototype.lex = function(src) {
      src = src.replace(/\r\n|\r/g, '\n').replace(/\t/g, '    ').replace(/\u00a0/g, ' ').replace(/\u2424/g, '\n');
      return this.token(src, true);
    };
    Lexer.prototype.token = function(src, top, bq) {
      var src = src.replace(/^ +$/gm, ''),
          next,
          loose,
          cap,
          bull,
          b,
          item,
          space,
          i,
          l;
      while (src) {
        if (cap = this.rules.newline.exec(src)) {
          src = src.substring(cap[0].length);
          if (cap[0].length > 1) {
            this.tokens.push({type: 'space'});
          }
        }
        if (cap = this.rules.code.exec(src)) {
          src = src.substring(cap[0].length);
          cap = cap[0].replace(/^ {4}/gm, '');
          this.tokens.push({
            type: 'code',
            text: !this.options.pedantic ? cap.replace(/\n+$/, '') : cap
          });
          continue;
        }
        if (cap = this.rules.fences.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: 'code',
            lang: cap[2],
            text: cap[3] || ''
          });
          continue;
        }
        if (cap = this.rules.heading.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: 'heading',
            depth: cap[1].length,
            text: cap[2]
          });
          continue;
        }
        if (top && (cap = this.rules.nptable.exec(src))) {
          src = src.substring(cap[0].length);
          item = {
            type: 'table',
            header: cap[1].replace(/^ *| *\| *$/g, '').split(/ *\| */),
            align: cap[2].replace(/^ *|\| *$/g, '').split(/ *\| */),
            cells: cap[3].replace(/\n$/, '').split('\n')
          };
          for (i = 0; i < item.align.length; i++) {
            if (/^ *-+: *$/.test(item.align[i])) {
              item.align[i] = 'right';
            } else if (/^ *:-+: *$/.test(item.align[i])) {
              item.align[i] = 'center';
            } else if (/^ *:-+ *$/.test(item.align[i])) {
              item.align[i] = 'left';
            } else {
              item.align[i] = null;
            }
          }
          for (i = 0; i < item.cells.length; i++) {
            item.cells[i] = item.cells[i].split(/ *\| */);
          }
          this.tokens.push(item);
          continue;
        }
        if (cap = this.rules.lheading.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: 'heading',
            depth: cap[2] === '=' ? 1 : 2,
            text: cap[1]
          });
          continue;
        }
        if (cap = this.rules.hr.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({type: 'hr'});
          continue;
        }
        if (cap = this.rules.blockquote.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({type: 'blockquote_start'});
          cap = cap[0].replace(/^ *> ?/gm, '');
          this.token(cap, top, true);
          this.tokens.push({type: 'blockquote_end'});
          continue;
        }
        if (cap = this.rules.list.exec(src)) {
          src = src.substring(cap[0].length);
          bull = cap[2];
          this.tokens.push({
            type: 'list_start',
            ordered: bull.length > 1
          });
          cap = cap[0].match(this.rules.item);
          next = false;
          l = cap.length;
          i = 0;
          for (; i < l; i++) {
            item = cap[i];
            space = item.length;
            item = item.replace(/^ *([*+-]|\d+\.) +/, '');
            if (~item.indexOf('\n ')) {
              space -= item.length;
              item = !this.options.pedantic ? item.replace(new RegExp('^ {1,' + space + '}', 'gm'), '') : item.replace(/^ {1,4}/gm, '');
            }
            if (this.options.smartLists && i !== l - 1) {
              b = block.bullet.exec(cap[i + 1])[0];
              if (bull !== b && !(bull.length > 1 && b.length > 1)) {
                src = cap.slice(i + 1).join('\n') + src;
                i = l - 1;
              }
            }
            loose = next || /\n\n(?!\s*$)/.test(item);
            if (i !== l - 1) {
              next = item.charAt(item.length - 1) === '\n';
              if (!loose)
                loose = next;
            }
            this.tokens.push({type: loose ? 'loose_item_start' : 'list_item_start'});
            this.token(item, false, bq);
            this.tokens.push({type: 'list_item_end'});
          }
          this.tokens.push({type: 'list_end'});
          continue;
        }
        if (cap = this.rules.html.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: this.options.sanitize ? 'paragraph' : 'html',
            pre: !this.options.sanitizer && (cap[1] === 'pre' || cap[1] === 'script' || cap[1] === 'style'),
            text: cap[0]
          });
          continue;
        }
        if ((!bq && top) && (cap = this.rules.def.exec(src))) {
          src = src.substring(cap[0].length);
          this.tokens.links[cap[1].toLowerCase()] = {
            href: cap[2],
            title: cap[3]
          };
          continue;
        }
        if (top && (cap = this.rules.table.exec(src))) {
          src = src.substring(cap[0].length);
          item = {
            type: 'table',
            header: cap[1].replace(/^ *| *\| *$/g, '').split(/ *\| */),
            align: cap[2].replace(/^ *|\| *$/g, '').split(/ *\| */),
            cells: cap[3].replace(/(?: *\| *)?\n$/, '').split('\n')
          };
          for (i = 0; i < item.align.length; i++) {
            if (/^ *-+: *$/.test(item.align[i])) {
              item.align[i] = 'right';
            } else if (/^ *:-+: *$/.test(item.align[i])) {
              item.align[i] = 'center';
            } else if (/^ *:-+ *$/.test(item.align[i])) {
              item.align[i] = 'left';
            } else {
              item.align[i] = null;
            }
          }
          for (i = 0; i < item.cells.length; i++) {
            item.cells[i] = item.cells[i].replace(/^ *\| *| *\| *$/g, '').split(/ *\| */);
          }
          this.tokens.push(item);
          continue;
        }
        if (top && (cap = this.rules.paragraph.exec(src))) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: 'paragraph',
            text: cap[1].charAt(cap[1].length - 1) === '\n' ? cap[1].slice(0, -1) : cap[1]
          });
          continue;
        }
        if (cap = this.rules.text.exec(src)) {
          src = src.substring(cap[0].length);
          this.tokens.push({
            type: 'text',
            text: cap[0]
          });
          continue;
        }
        if (src) {
          throw new Error('Infinite loop on byte: ' + src.charCodeAt(0));
        }
      }
      return this.tokens;
    };
    var inline = {
      escape: /^\\([\\`*{}\[\]()#+\-.!_>])/,
      autolink: /^<([^ >]+(@|:\/)[^ >]+)>/,
      url: noop,
      tag: /^<!--[\s\S]*?-->|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,
      link: /^!?\[(inside)\]\(href\)/,
      reflink: /^!?\[(inside)\]\s*\[([^\]]*)\]/,
      nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,
      strong: /^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,
      em: /^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,
      code: /^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,
      br: /^ {2,}\n(?!\s*$)/,
      del: noop,
      text: /^[\s\S]+?(?=[\\<!\[_*`]| {2,}\n|$)/
    };
    inline._inside = /(?:\[[^\]]*\]|[^\[\]]|\](?=[^\[]*\]))*/;
    inline._href = /\s*<?([\s\S]*?)>?(?:\s+['"]([\s\S]*?)['"])?\s*/;
    inline.link = replace(inline.link)('inside', inline._inside)('href', inline._href)();
    inline.reflink = replace(inline.reflink)('inside', inline._inside)();
    inline.normal = merge({}, inline);
    inline.pedantic = merge({}, inline.normal, {
      strong: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,
      em: /^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/
    });
    inline.gfm = merge({}, inline.normal, {
      escape: replace(inline.escape)('])', '~|])')(),
      url: /^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,
      del: /^~~(?=\S)([\s\S]*?\S)~~/,
      text: replace(inline.text)(']|', '~]|')('|', '|https?://|')()
    });
    inline.breaks = merge({}, inline.gfm, {
      br: replace(inline.br)('{2,}', '*')(),
      text: replace(inline.gfm.text)('{2,}', '*')()
    });
    function InlineLexer(links, options) {
      this.options = options || marked.defaults;
      this.links = links;
      this.rules = inline.normal;
      this.renderer = this.options.renderer || new Renderer;
      this.renderer.options = this.options;
      if (!this.links) {
        throw new Error('Tokens array requires a `links` property.');
      }
      if (this.options.gfm) {
        if (this.options.breaks) {
          this.rules = inline.breaks;
        } else {
          this.rules = inline.gfm;
        }
      } else if (this.options.pedantic) {
        this.rules = inline.pedantic;
      }
    }
    InlineLexer.rules = inline;
    InlineLexer.output = function(src, links, options) {
      var inline = new InlineLexer(links, options);
      return inline.output(src);
    };
    InlineLexer.prototype.output = function(src) {
      var out = '',
          link,
          text,
          href,
          cap;
      while (src) {
        if (cap = this.rules.escape.exec(src)) {
          src = src.substring(cap[0].length);
          out += cap[1];
          continue;
        }
        if (cap = this.rules.autolink.exec(src)) {
          src = src.substring(cap[0].length);
          if (cap[2] === '@') {
            text = cap[1].charAt(6) === ':' ? this.mangle(cap[1].substring(7)) : this.mangle(cap[1]);
            href = this.mangle('mailto:') + text;
          } else {
            text = escape(cap[1]);
            href = text;
          }
          out += this.renderer.link(href, null, text);
          continue;
        }
        if (!this.inLink && (cap = this.rules.url.exec(src))) {
          src = src.substring(cap[0].length);
          text = escape(cap[1]);
          href = text;
          out += this.renderer.link(href, null, text);
          continue;
        }
        if (cap = this.rules.tag.exec(src)) {
          if (!this.inLink && /^<a /i.test(cap[0])) {
            this.inLink = true;
          } else if (this.inLink && /^<\/a>/i.test(cap[0])) {
            this.inLink = false;
          }
          src = src.substring(cap[0].length);
          out += this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(cap[0]) : escape(cap[0]) : cap[0];
          continue;
        }
        if (cap = this.rules.link.exec(src)) {
          src = src.substring(cap[0].length);
          this.inLink = true;
          out += this.outputLink(cap, {
            href: cap[2],
            title: cap[3]
          });
          this.inLink = false;
          continue;
        }
        if ((cap = this.rules.reflink.exec(src)) || (cap = this.rules.nolink.exec(src))) {
          src = src.substring(cap[0].length);
          link = (cap[2] || cap[1]).replace(/\s+/g, ' ');
          link = this.links[link.toLowerCase()];
          if (!link || !link.href) {
            out += cap[0].charAt(0);
            src = cap[0].substring(1) + src;
            continue;
          }
          this.inLink = true;
          out += this.outputLink(cap, link);
          this.inLink = false;
          continue;
        }
        if (cap = this.rules.strong.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.strong(this.output(cap[2] || cap[1]));
          continue;
        }
        if (cap = this.rules.em.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.em(this.output(cap[2] || cap[1]));
          continue;
        }
        if (cap = this.rules.code.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.codespan(escape(cap[2], true));
          continue;
        }
        if (cap = this.rules.br.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.br();
          continue;
        }
        if (cap = this.rules.del.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.del(this.output(cap[1]));
          continue;
        }
        if (cap = this.rules.text.exec(src)) {
          src = src.substring(cap[0].length);
          out += this.renderer.text(escape(this.smartypants(cap[0])));
          continue;
        }
        if (src) {
          throw new Error('Infinite loop on byte: ' + src.charCodeAt(0));
        }
      }
      return out;
    };
    InlineLexer.prototype.outputLink = function(cap, link) {
      var href = escape(link.href),
          title = link.title ? escape(link.title) : null;
      return cap[0].charAt(0) !== '!' ? this.renderer.link(href, title, this.output(cap[1])) : this.renderer.image(href, title, escape(cap[1]));
    };
    InlineLexer.prototype.smartypants = function(text) {
      if (!this.options.smartypants)
        return text;
      return text.replace(/---/g, '\u2014').replace(/--/g, '\u2013').replace(/(^|[-\u2014/(\[{"\s])'/g, '$1\u2018').replace(/'/g, '\u2019').replace(/(^|[-\u2014/(\[{\u2018\s])"/g, '$1\u201c').replace(/"/g, '\u201d').replace(/\.{3}/g, '\u2026');
    };
    InlineLexer.prototype.mangle = function(text) {
      if (!this.options.mangle)
        return text;
      var out = '',
          l = text.length,
          i = 0,
          ch;
      for (; i < l; i++) {
        ch = text.charCodeAt(i);
        if (Math.random() > 0.5) {
          ch = 'x' + ch.toString(16);
        }
        out += '&#' + ch + ';';
      }
      return out;
    };
    function Renderer(options) {
      this.options = options || {};
    }
    Renderer.prototype.code = function(code, lang, escaped) {
      if (this.options.highlight) {
        var out = this.options.highlight(code, lang);
        if (out != null && out !== code) {
          escaped = true;
          code = out;
        }
      }
      if (!lang) {
        return '<pre><code>' + (escaped ? code : escape(code, true)) + '\n</code></pre>';
      }
      return '<pre><code class="' + this.options.langPrefix + escape(lang, true) + '">' + (escaped ? code : escape(code, true)) + '\n</code></pre>\n';
    };
    Renderer.prototype.blockquote = function(quote) {
      return '<blockquote>\n' + quote + '</blockquote>\n';
    };
    Renderer.prototype.html = function(html) {
      return html;
    };
    Renderer.prototype.heading = function(text, level, raw) {
      return '<h' + level + ' id="' + this.options.headerPrefix + raw.toLowerCase().replace(/[^\w]+/g, '-') + '">' + text + '</h' + level + '>\n';
    };
    Renderer.prototype.hr = function() {
      return this.options.xhtml ? '<hr/>\n' : '<hr>\n';
    };
    Renderer.prototype.list = function(body, ordered) {
      var type = ordered ? 'ol' : 'ul';
      return '<' + type + '>\n' + body + '</' + type + '>\n';
    };
    Renderer.prototype.listitem = function(text) {
      return '<li>' + text + '</li>\n';
    };
    Renderer.prototype.paragraph = function(text) {
      return '<p>' + text + '</p>\n';
    };
    Renderer.prototype.table = function(header, body) {
      return '<table>\n' + '<thead>\n' + header + '</thead>\n' + '<tbody>\n' + body + '</tbody>\n' + '</table>\n';
    };
    Renderer.prototype.tablerow = function(content) {
      return '<tr>\n' + content + '</tr>\n';
    };
    Renderer.prototype.tablecell = function(content, flags) {
      var type = flags.header ? 'th' : 'td';
      var tag = flags.align ? '<' + type + ' style="text-align:' + flags.align + '">' : '<' + type + '>';
      return tag + content + '</' + type + '>\n';
    };
    Renderer.prototype.strong = function(text) {
      return '<strong>' + text + '</strong>';
    };
    Renderer.prototype.em = function(text) {
      return '<em>' + text + '</em>';
    };
    Renderer.prototype.codespan = function(text) {
      return '<code>' + text + '</code>';
    };
    Renderer.prototype.br = function() {
      return this.options.xhtml ? '<br/>' : '<br>';
    };
    Renderer.prototype.del = function(text) {
      return '<del>' + text + '</del>';
    };
    Renderer.prototype.link = function(href, title, text) {
      if (this.options.sanitize) {
        try {
          var prot = decodeURIComponent(unescape(href)).replace(/[^\w:]/g, '').toLowerCase();
        } catch (e) {
          return '';
        }
        if (prot.indexOf('javascript:') === 0 || prot.indexOf('vbscript:') === 0) {
          return '';
        }
      }
      var out = '<a href="' + href + '"';
      if (title) {
        out += ' title="' + title + '"';
      }
      out += '>' + text + '</a>';
      return out;
    };
    Renderer.prototype.image = function(href, title, text) {
      var out = '<img src="' + href + '" alt="' + text + '"';
      if (title) {
        out += ' title="' + title + '"';
      }
      out += this.options.xhtml ? '/>' : '>';
      return out;
    };
    Renderer.prototype.text = function(text) {
      return text;
    };
    function Parser(options) {
      this.tokens = [];
      this.token = null;
      this.options = options || marked.defaults;
      this.options.renderer = this.options.renderer || new Renderer;
      this.renderer = this.options.renderer;
      this.renderer.options = this.options;
    }
    Parser.parse = function(src, options, renderer) {
      var parser = new Parser(options, renderer);
      return parser.parse(src);
    };
    Parser.prototype.parse = function(src) {
      this.inline = new InlineLexer(src.links, this.options, this.renderer);
      this.tokens = src.reverse();
      var out = '';
      while (this.next()) {
        out += this.tok();
      }
      return out;
    };
    Parser.prototype.next = function() {
      return this.token = this.tokens.pop();
    };
    Parser.prototype.peek = function() {
      return this.tokens[this.tokens.length - 1] || 0;
    };
    Parser.prototype.parseText = function() {
      var body = this.token.text;
      while (this.peek().type === 'text') {
        body += '\n' + this.next().text;
      }
      return this.inline.output(body);
    };
    Parser.prototype.tok = function() {
      switch (this.token.type) {
        case 'space':
          {
            return '';
          }
        case 'hr':
          {
            return this.renderer.hr();
          }
        case 'heading':
          {
            return this.renderer.heading(this.inline.output(this.token.text), this.token.depth, this.token.text);
          }
        case 'code':
          {
            return this.renderer.code(this.token.text, this.token.lang, this.token.escaped);
          }
        case 'table':
          {
            var header = '',
                body = '',
                i,
                row,
                cell,
                flags,
                j;
            cell = '';
            for (i = 0; i < this.token.header.length; i++) {
              flags = {
                header: true,
                align: this.token.align[i]
              };
              cell += this.renderer.tablecell(this.inline.output(this.token.header[i]), {
                header: true,
                align: this.token.align[i]
              });
            }
            header += this.renderer.tablerow(cell);
            for (i = 0; i < this.token.cells.length; i++) {
              row = this.token.cells[i];
              cell = '';
              for (j = 0; j < row.length; j++) {
                cell += this.renderer.tablecell(this.inline.output(row[j]), {
                  header: false,
                  align: this.token.align[j]
                });
              }
              body += this.renderer.tablerow(cell);
            }
            return this.renderer.table(header, body);
          }
        case 'blockquote_start':
          {
            var body = '';
            while (this.next().type !== 'blockquote_end') {
              body += this.tok();
            }
            return this.renderer.blockquote(body);
          }
        case 'list_start':
          {
            var body = '',
                ordered = this.token.ordered;
            while (this.next().type !== 'list_end') {
              body += this.tok();
            }
            return this.renderer.list(body, ordered);
          }
        case 'list_item_start':
          {
            var body = '';
            while (this.next().type !== 'list_item_end') {
              body += this.token.type === 'text' ? this.parseText() : this.tok();
            }
            return this.renderer.listitem(body);
          }
        case 'loose_item_start':
          {
            var body = '';
            while (this.next().type !== 'list_item_end') {
              body += this.tok();
            }
            return this.renderer.listitem(body);
          }
        case 'html':
          {
            var html = !this.token.pre && !this.options.pedantic ? this.inline.output(this.token.text) : this.token.text;
            return this.renderer.html(html);
          }
        case 'paragraph':
          {
            return this.renderer.paragraph(this.inline.output(this.token.text));
          }
        case 'text':
          {
            return this.renderer.paragraph(this.parseText());
          }
      }
    };
    function escape(html, encode) {
      return html.replace(!encode ? /&(?!#?\w+;)/g : /&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/"/g, '&quot;').replace(/'/g, '&#39;');
    }
    function unescape(html) {
      return html.replace(/&([#\w]+);/g, function(_, n) {
        n = n.toLowerCase();
        if (n === 'colon')
          return ':';
        if (n.charAt(0) === '#') {
          return n.charAt(1) === 'x' ? String.fromCharCode(parseInt(n.substring(2), 16)) : String.fromCharCode(+n.substring(1));
        }
        return '';
      });
    }
    function replace(regex, opt) {
      regex = regex.source;
      opt = opt || '';
      return function self(name, val) {
        if (!name)
          return new RegExp(regex, opt);
        val = val.source || val;
        val = val.replace(/(^|[^\[])\^/g, '$1');
        regex = regex.replace(name, val);
        return self;
      };
    }
    function noop() {}
    noop.exec = noop;
    function merge(obj) {
      var i = 1,
          target,
          key;
      for (; i < arguments.length; i++) {
        target = arguments[i];
        for (key in target) {
          if (Object.prototype.hasOwnProperty.call(target, key)) {
            obj[key] = target[key];
          }
        }
      }
      return obj;
    }
    function marked(src, opt, callback) {
      if (callback || typeof opt === 'function') {
        if (!callback) {
          callback = opt;
          opt = null;
        }
        opt = merge({}, marked.defaults, opt || {});
        var highlight = opt.highlight,
            tokens,
            pending,
            i = 0;
        try {
          tokens = Lexer.lex(src, opt);
        } catch (e) {
          return callback(e);
        }
        pending = tokens.length;
        var done = function(err) {
          if (err) {
            opt.highlight = highlight;
            return callback(err);
          }
          var out;
          try {
            out = Parser.parse(tokens, opt);
          } catch (e) {
            err = e;
          }
          opt.highlight = highlight;
          return err ? callback(err) : callback(null, out);
        };
        if (!highlight || highlight.length < 3) {
          return done();
        }
        delete opt.highlight;
        if (!pending)
          return done();
        for (; i < tokens.length; i++) {
          (function(token) {
            if (token.type !== 'code') {
              return --pending || done();
            }
            return highlight(token.text, token.lang, function(err, code) {
              if (err)
                return done(err);
              if (code == null || code === token.text) {
                return --pending || done();
              }
              token.text = code;
              token.escaped = true;
              --pending || done();
            });
          })(tokens[i]);
        }
        return;
      }
      try {
        if (opt)
          opt = merge({}, marked.defaults, opt);
        return Parser.parse(Lexer.lex(src, opt), opt);
      } catch (e) {
        e.message += '\nPlease report this to https://github.com/chjj/marked.';
        if ((opt || marked.defaults).silent) {
          return '<p>An error occured:</p><pre>' + escape(e.message + '', true) + '</pre>';
        }
        throw e;
      }
    }
    marked.options = marked.setOptions = function(opt) {
      merge(marked.defaults, opt);
      return marked;
    };
    marked.defaults = {
      gfm: true,
      tables: true,
      breaks: false,
      pedantic: false,
      sanitize: false,
      sanitizer: null,
      mangle: true,
      smartLists: false,
      silent: false,
      highlight: null,
      langPrefix: 'lang-',
      smartypants: false,
      headerPrefix: '',
      renderer: new Renderer,
      xhtml: false
    };
    marked.Parser = Parser;
    marked.parser = Parser.parse;
    marked.Renderer = Renderer;
    marked.Lexer = Lexer;
    marked.lexer = Lexer.lex;
    marked.InlineLexer = InlineLexer;
    marked.inlineLexer = InlineLexer.output;
    marked.parse = marked;
    if (typeof module !== 'undefined' && typeof exports === 'object') {
      module.exports = marked;
    } else if (typeof define === 'function' && define.amd) {
      define(function() {
        return marked;
      });
    } else {
      this.marked = marked;
    }
  }).call(function() {
    return this || (typeof window !== 'undefined' ? window : global);
  }());
  return module.exports;
});

$__System.registerDynamic("a8", ["a7"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('a7');
  return module.exports;
});

$__System.register('9f', ['11', '87', '88', '89', '91', '8a', '8f', '9c', 'a9', 'a4', 'a5', 'a6', 'a8'], function (_export) {
  var Pipe, _get, _inherits, _createClass, JsonPointer, _classCallCheck, _Object$keys, isString, stringify, isBlank, BaseException, Prism, marked, InvalidPipeArgumentException, KeysPipe, ValuesPipe, JsonPointerEscapePipe, MarkedPipe, langMap, PrismPipe, EncodeURIComponentPipe;

  return {
    setters: [function (_4) {
      Pipe = _4.Pipe;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_5) {
      JsonPointer = _5.JsonPointer;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_c) {
      isString = _c.isString;
      stringify = _c.stringify;
      isBlank = _c.isBlank;
    }, function (_a9) {
      BaseException = _a9.BaseException;
    }, function (_a4) {
      Prism = _a4['default'];
    }, function (_a5) {}, function (_a6) {}, function (_a8) {
      marked = _a8['default'];
    }],
    execute: function () {

      // in gfm mode marked doesn't parse #Heading (without space after #) as heading
      // https://github.com/chjj/marked/issues/642
      'use strict';

      marked.Lexer.rules.gfm.heading = marked.Lexer.rules.normal.heading;
      marked.Lexer.rules.tables.heading = marked.Lexer.rules.normal.heading;

      marked.setOptions({
        renderer: new marked.Renderer(),
        gfm: true,
        tables: true,
        breaks: false,
        pedantic: false,
        smartLists: true,
        smartypants: false
      });

      InvalidPipeArgumentException = (function (_BaseException) {
        _inherits(InvalidPipeArgumentException, _BaseException);

        function InvalidPipeArgumentException(type, value) {
          _classCallCheck(this, InvalidPipeArgumentException);

          _get(Object.getPrototypeOf(InvalidPipeArgumentException.prototype), 'constructor', this).call(this, 'Invalid argument \'' + value + '\' for pipe \'' + stringify(type) + '\'');
        }

        return InvalidPipeArgumentException;
      })(BaseException);

      KeysPipe = (function () {
        function KeysPipe() {
          _classCallCheck(this, _KeysPipe);
        }

        _createClass(KeysPipe, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            if (typeof value !== 'object') {
              throw new InvalidPipeArgumentException(ValuesPipe, value);
            }
            return _Object$keys(value);
          }
        }]);

        var _KeysPipe = KeysPipe;
        KeysPipe = Pipe({ name: 'keys' })(KeysPipe) || KeysPipe;
        return KeysPipe;
      })();

      _export('KeysPipe', KeysPipe);

      ValuesPipe = (function () {
        function ValuesPipe() {
          _classCallCheck(this, _ValuesPipe);
        }

        _createClass(ValuesPipe, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            if (typeof value !== 'object') {
              throw new InvalidPipeArgumentException(ValuesPipe, value);
            }
            return _Object$keys(value).map(function (key) {
              return value[key];
            });
          }
        }]);

        var _ValuesPipe = ValuesPipe;
        ValuesPipe = Pipe({ name: 'values' })(ValuesPipe) || ValuesPipe;
        return ValuesPipe;
      })();

      _export('ValuesPipe', ValuesPipe);

      JsonPointerEscapePipe = (function () {
        function JsonPointerEscapePipe() {
          _classCallCheck(this, _JsonPointerEscapePipe);
        }

        _createClass(JsonPointerEscapePipe, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            if (!isString(value)) {
              throw new InvalidPipeArgumentException(JsonPointerEscapePipe, value);
            }
            return JsonPointer.escape(value);
          }
        }]);

        var _JsonPointerEscapePipe = JsonPointerEscapePipe;
        JsonPointerEscapePipe = Pipe({ name: 'jsonPointerEscape' })(JsonPointerEscapePipe) || JsonPointerEscapePipe;
        return JsonPointerEscapePipe;
      })();

      _export('JsonPointerEscapePipe', JsonPointerEscapePipe);

      MarkedPipe = (function () {
        function MarkedPipe() {
          _classCallCheck(this, _MarkedPipe);
        }

        _createClass(MarkedPipe, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            if (!isString(value)) {
              throw new InvalidPipeArgumentException(JsonPointerEscapePipe, value);
            }
            return '<span class="redoc-markdown-block">' + marked(value) + '</span>';
          }
        }]);

        var _MarkedPipe = MarkedPipe;
        MarkedPipe = Pipe({ name: 'marked' })(MarkedPipe) || MarkedPipe;
        return MarkedPipe;
      })();

      _export('MarkedPipe', MarkedPipe);

      langMap = {
        'c++': 'cpp',
        'c#': 'csharp',
        'objective-c': 'objectivec',
        'shell': 'bash',
        'viml': 'vim'
      };

      PrismPipe = (function () {
        function PrismPipe() {
          _classCallCheck(this, _PrismPipe);
        }

        _createClass(PrismPipe, [{
          key: 'transform',
          value: function transform(value, args) {
            if (isBlank(args) || args.length === 0) {
              throw new BaseException('Prism pipe requires one argument');
            }
            if (isBlank(value)) return value;
            if (!isString(value)) {
              throw new InvalidPipeArgumentException(JsonPointerEscapePipe, value);
            }
            var lang = args[0].toString().trim().toLowerCase();
            if (langMap[lang]) lang = langMap[lang];

            var grammar = Prism.languages[lang];
            //fallback to clike
            if (!grammar) grammar = Prism.languages.clike;
            return Prism.highlight(value, grammar);
          }
        }]);

        var _PrismPipe = PrismPipe;
        PrismPipe = Pipe({ name: 'prism' })(PrismPipe) || PrismPipe;
        return PrismPipe;
      })();

      _export('PrismPipe', PrismPipe);

      EncodeURIComponentPipe = (function () {
        function EncodeURIComponentPipe() {
          _classCallCheck(this, _EncodeURIComponentPipe);
        }

        _createClass(EncodeURIComponentPipe, [{
          key: 'transform',
          value: function transform(value) {
            if (isBlank(value)) return value;
            if (!isString(value)) {
              throw new InvalidPipeArgumentException(EncodeURIComponentPipe, value);
            }
            return encodeURIComponent(value);
          }
        }]);

        var _EncodeURIComponentPipe = EncodeURIComponentPipe;
        EncodeURIComponentPipe = Pipe({ name: 'encodeURIComponent' })(EncodeURIComponentPipe) || EncodeURIComponentPipe;
        return EncodeURIComponentPipe;
      })();

      _export('EncodeURIComponentPipe', EncodeURIComponentPipe);
    }
  };
});
$__System.register('85', ['11', '76', '89', '91', '92', '93', '8a', 'a3', '8f', 'aa', '9f'], function (_export) {
  var Component, ChangeDetectionStrategy, CORE_DIRECTIVES, JsonPipe, AsyncPipe, _createClass, JsonPointer, _Object$assign, SchemaManager, _classCallCheck, _toConsumableArray, _Object$keys, _getIterator, MarkedPipe, JsonPointerEscapePipe, commonInputs, BaseComponent;

  // json pointer to the schema chunk

  // internal helper function
  function safeConcat(a, b) {
    var res = a && a.slice() || [];
    b = b == null ? [] : b;
    return res.concat(b);
  }

  function defaults(target, src) {
    var props = _Object$keys(src);

    var index = -1,
        length = props.length;

    while (++index < length) {
      var key = props[index];
      if (target[key] === undefined) {
        target[key] = src[key];
      }
    }
    return target;
  }

  function snapshot(obj) {
    if (obj == null || typeof obj != 'object') {
      return obj;
    }

    var temp = new obj.constructor();

    for (var key in obj) {
      if (obj.hasOwnProperty(key)) {
        temp[key] = snapshot(obj[key]);
      }
    }

    return temp;
  }

  /**
   * Class decorator
   * Simplifies setup of component metainfo
   * All options are options from either Component or View angular2 decorator
   * For detailed info look angular2 doc
   * @param {Object} options - component options
   * @param {string[]} options.inputs - component inputs
   * @param {*[]} options.directives - directives used by component
   *   (except CORE_DIRECTIVES)
   * @param {*[]} options.pipes - pipes used by component
   * @param {*[]} options.providers - component providers
   * @param {string} options.templateUrl - path to component template
   * @param {string} options.template - component template html
   * @param {string} options.styles - component css styles
   */

  function RedocComponent(options) {
    var inputs = safeConcat(options.inputs, commonInputs);
    var directives = safeConcat(options.directives, CORE_DIRECTIVES);
    var pipes = safeConcat(options.pipes, [JsonPointerEscapePipe, MarkedPipe, JsonPipe, AsyncPipe]);

    return function decorator(target) {

      var componentDecorator = Component({
        selector: options.selector,
        inputs: inputs,
        outputs: options.outputs,
        providers: options.providers,
        changeDetection: options.changeDetection || ChangeDetectionStrategy.Default,
        templateUrl: options.templateUrl,
        template: options.template,
        styles: options.styles,
        directives: directives,
        pipes: pipes
      });

      return componentDecorator(target) || target;
    };
  }

  /**
   * Generic Component
   * @class
   */
  return {
    setters: [function (_3) {
      Component = _3.Component;
      ChangeDetectionStrategy = _3.ChangeDetectionStrategy;
    }, function (_4) {
      CORE_DIRECTIVES = _4.CORE_DIRECTIVES;
      JsonPipe = _4.JsonPipe;
      AsyncPipe = _4.AsyncPipe;
    }, function (_) {
      _createClass = _['default'];
    }, function (_6) {
      JsonPointer = _6['default'];
    }, function (_2) {
      _Object$assign = _2['default'];
    }, function (_5) {
      SchemaManager = _5['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_a3) {
      _toConsumableArray = _a3['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_aa) {
      _getIterator = _aa['default'];
    }, function (_f2) {
      MarkedPipe = _f2.MarkedPipe;
      JsonPointerEscapePipe = _f2.JsonPointerEscapePipe;
    }],
    execute: function () {
      'use strict';

      _export('RedocComponent', RedocComponent);

      _export('SchemaManager', SchemaManager);

      // common inputs for all components
      commonInputs = ['pointer'];

      BaseComponent = (function () {
        function BaseComponent(schemaMgr) {
          _classCallCheck(this, _BaseComponent);

          this.schemaMgr = schemaMgr;
          this.componentSchema = null;
        }

        /**
         * onInit method is run by angular2 after all component inputs are resolved
         */

        _createClass(BaseComponent, [{
          key: 'ngOnInit',
          value: function ngOnInit() {
            this.componentSchema = snapshot(this.schemaMgr.byPointer(this.pointer || ''));
            this.prepareModel();
            this.init();
          }
        }, {
          key: 'ngOnDestroy',
          value: function ngOnDestroy() {
            this.destroy();
          }

          /**
           * simple in-place schema dereferencing. Schema is already bundled so no need in global dereferencing.
           */
        }, {
          key: 'dereference',
          value: function dereference() {
            var _this = this;

            var schema = arguments.length <= 0 || arguments[0] === undefined ? _Object$assign({}, this.componentSchema) : arguments[0];

            var dereferencedCache = {};

            var resolve = function resolve(schema) {
              var resolvedRef = undefined;
              if (schema && schema.$ref) {
                resolvedRef = schema.$ref;
                var resolved = _this.schemaMgr.byPointer(schema.$ref);
                var baseName = JsonPointer.baseName(schema.$ref);
                if (!dereferencedCache[schema.$ref]) {
                  // if resolved schema doesn't have title use name from ref
                  resolved = _Object$assign({}, resolved);
                  resolved._pointer = schema.$ref;
                } else {
                  // for circular referenced save only title and type
                  resolved = {
                    title: resolved.title,
                    type: resolved.type
                  };
                }

                dereferencedCache[schema.$ref] = dereferencedCache[schema.$ref] ? dereferencedCache[schema.$ref] + 1 : 1;

                resolved.title = resolved.title || baseName;

                var keysCount = _Object$keys(schema).length;
                if (keysCount > 2 || keysCount === 2 && !schema.description) {
                  // allow only description field on the same level as $ref because it is
                  // common pattern over specs in the wild
                  console.warn('other properties defined at the same level as $ref at \'' + _this.pointer + '\'.\n            They are IGNORRED according to JsonSchema spec');
                }

                schema = schema.description ? {
                  description: schema.description
                } : {};
                _Object$assign(schema, resolved);
              }

              _Object$keys(schema).forEach(function (key) {
                var value = schema[key];
                if (value && typeof value === 'object') {
                  schema[key] = resolve(value);
                }
              });
              if (resolvedRef) dereferencedCache[resolvedRef] = dereferencedCache[resolvedRef] ? dereferencedCache[resolvedRef] - 1 : 0;
              return schema;
            };

            this.componentSchema = snapshot(resolve(schema, 1));
          }
        }, {
          key: 'prepareModel',

          /**
           * Used to prepare model based on component schema
           * @abstract
           */
          value: function prepareModel() {}

          /**
           * Used to initialize component. Run after prepareModel
           * @abstract
           */
        }, {
          key: 'init',
          value: function init() {}

          /**
           + Used to destroy component
           * @abstract
           */
        }, {
          key: 'destroy',
          value: function destroy() {}
        }], [{
          key: 'joinAllOf',
          value: function joinAllOf(schema, opts) {
            function merge(into, schemas) {
              var _iteratorNormalCompletion = true;
              var _didIteratorError = false;
              var _iteratorError = undefined;

              try {
                var _loop = function () {
                  var subSchema = _step.value;

                  if (opts && opts.omitParent && subSchema.discriminator) return 'continue';
                  // TODO: add support for merge array schemas
                  if (typeof subSchema !== 'object') {
                    var errMessage = 'Items of allOf should be Object: ' + typeof subSchema + ' found\n            ' + subSchema;
                    throw new Error(errMessage);
                  }

                  if (into.type && subSchema.type && into.type !== subSchema.type) {
                    var errMessage = 'allOf merging error: schemas with different types can\'t be merged';
                    throw new Error(errMessage);
                  }

                  if (into.type === 'array') {
                    console.warn('allOf: subschemas with type array are not supported yet');
                  }

                  // TODO: add check if can be merged correctly (no different properties with the same name)
                  into.type = into.type || subSchema.type;
                  if (into.type === 'object' && subSchema.properties) {
                    into.properties || (into.properties = {});
                    _Object$assign(into.properties, subSchema.properties);
                    _Object$keys(subSchema.properties).forEach(function (propName) {
                      if (!subSchema.properties[propName]._pointer) {
                        subSchema.properties[propName]._pointer = subSchema._pointer ? JsonPointer.join(subSchema._pointer, ['properties', propName]) : null;
                      }
                    });
                  }
                  if (into.type === 'object' && subSchema.required) {
                    var _into$required;

                    into.required || (into.required = []);
                    (_into$required = into.required).push.apply(_into$required, _toConsumableArray(subSchema.required));
                  }
                  // don't merge _pointer
                  subSchema._pointer = null;
                  defaults(into, subSchema);
                };

                for (var _iterator = _getIterator(schemas), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
                  var _ret = _loop();

                  if (_ret === 'continue') continue;
                }
              } catch (err) {
                _didIteratorError = true;
                _iteratorError = err;
              } finally {
                try {
                  if (!_iteratorNormalCompletion && _iterator['return']) {
                    _iterator['return']();
                  }
                } finally {
                  if (_didIteratorError) {
                    throw _iteratorError;
                  }
                }
              }

              into.allOf = null;
            }

            function traverse(obj) {
              if (obj === null || typeof obj !== 'object') {
                return;
              }

              for (var key in obj) {
                if (obj.hasOwnProperty(key)) {
                  traverse(obj[key]);
                }
              }

              if (obj.allOf) {
                merge(obj, obj.allOf);
              }
            }

            traverse(schema);
          }
        }]);

        var _BaseComponent = BaseComponent;
        BaseComponent = Reflect.metadata('parameters', [[SchemaManager]])(BaseComponent) || BaseComponent;
        return BaseComponent;
      })();

      _export('BaseComponent', BaseComponent);
    }
  };
});
$__System.register('ab', ['11', '85', '86', '87', '88', '89', '8a', '5e', '9c'], function (_export) {
  var ElementRef, ChangeDetectorRef, RedocComponent, BaseComponent, SchemaManager, ScrollService, Hash, MenuService, OptionsService, _get, _inherits, _createClass, _classCallCheck, BrowserDomAdapter, global, SideMenu;

  return {
    setters: [function (_4) {
      ElementRef = _4.ElementRef;
      ChangeDetectorRef = _4.ChangeDetectorRef;
    }, function (_5) {
      RedocComponent = _5.RedocComponent;
      BaseComponent = _5.BaseComponent;
      SchemaManager = _5.SchemaManager;
    }, function (_6) {
      ScrollService = _6.ScrollService;
      Hash = _6.Hash;
      MenuService = _6.MenuService;
      OptionsService = _6.OptionsService;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }, function (_c) {
      global = _c.global;
    }],
    execute: function () {
      'use strict';

      SideMenu = (function (_BaseComponent) {
        _inherits(SideMenu, _BaseComponent);

        function SideMenu(schemaMgr, elementRef, dom, scrollService, menuService, hash, optionsService, detectorRef) {
          var _this = this;

          _classCallCheck(this, _SideMenu);

          _get(Object.getPrototypeOf(_SideMenu.prototype), 'constructor', this).call(this, schemaMgr);
          this.$element = elementRef.nativeElement;
          this.dom = dom;
          this.scrollService = scrollService;
          this.menuService = menuService;
          this.hash = hash;

          this.activeCatCaption = '';
          this.activeItemCaption = '';

          this.options = optionsService.options;
          this.detectorRef = detectorRef;

          this.menuService.changed.subscribe(function (cat, item) {
            return _this.changed(cat, item);
          });
        }

        _createClass(SideMenu, [{
          key: 'changed',
          value: function changed(cat, item) {
            this.activeCatCaption = cat.name || '';
            this.activeItemCaption = item && item.summary || '';

            //safari doesn't update bindings if not run changeDetector manually :(
            this.detectorRef.detectChanges();
          }
        }, {
          key: 'activateAndScroll',
          value: function activateAndScroll(idx, methodIdx) {
            if (this.mobileMode()) {
              this.toggleMobileNav();
            }
            this.menuService.activate(idx, methodIdx);
            this.menuService.scrollToActive();
          }
        }, {
          key: 'init',
          value: function init() {
            var _this2 = this;

            this.$mobileNav = this.dom.querySelector(this.$element, '.mobile-nav');
            this.$resourcesNav = this.dom.querySelector(this.$element, '#resources-nav');

            //decorate option.scrollYOffset to account mobile nav
            var origOffset = this.options.scrollYOffset;
            this.options.scrollYOffset = function () {
              var mobileNavOffset = _this2.$mobileNav.clientHeight;
              return origOffset() + mobileNavOffset;
            };
          }
        }, {
          key: 'prepareModel',
          value: function prepareModel() {
            this.data = {};
            this.data.menu = this.menuService.categories;
          }
        }, {
          key: 'mobileMode',
          value: function mobileMode() {
            return this.$mobileNav.clientHeight > 0;
          }
        }, {
          key: 'toggleMobileNav',
          value: function toggleMobileNav() {
            var dom = this.dom;
            var $overflowParent = this.$scrollParent === global ? dom.defaultDoc().body : this.$scrollParent;
            if (dom.hasStyle(this.$resourcesNav, 'height')) {
              dom.removeStyle(this.$resourcesNav, 'height');
              dom.removeStyle($overflowParent, 'overflow-y');
            } else {
              var viewportHeight = this.$scrollParent.innerHeight || this.$scrollParent.clientHeight;
              var height = viewportHeight - this.$mobileNav.getBoundingClientRect().bottom;
              dom.setStyle($overflowParent, 'overflow-y', 'hidden');
              dom.setStyle(this.$resourcesNav, 'height', height + 'px');
            }
          }
        }, {
          key: 'destroy',
          value: function destroy() {
            this.scrollService.unbind();
            this.hash.unbind();
          }
        }]);

        var _SideMenu = SideMenu;
        SideMenu = Reflect.metadata('parameters', [[SchemaManager], [ElementRef], [BrowserDomAdapter], [ScrollService], [MenuService], [Hash], [OptionsService], [ChangeDetectorRef]])(SideMenu) || SideMenu;
        SideMenu = RedocComponent({
          selector: 'side-menu',
          template: '\n    <div #mobile class="mobile-nav" (click)="toggleMobileNav()">\n      <span class="menu-header"> API Reference: </span>\n      <span class="selected-item-info">\n        <span class="selected-tag"> {{activeCatCaption}} </span>\n        <span class="selected-endpoint">{{activeItemCaption}}</span>\n      </span>\n    </div>\n    <div #desktop id="resources-nav">\n      <h5 class="menu-header"> API reference </h5>\n      <div *ngFor="let cat of data.menu; let idx = index" class="menu-cat">\n\n        <label class="menu-cat-header" (click)="activateAndScroll(idx, -1)" [ngClass]="{active: cat.active}"> {{cat.name}}</label>\n        <ul class="menu-subitems" [ngClass]="{active: cat.active}">\n          <li *ngFor="let method of cat.methods; let methIdx = index"\n            [ngClass]="{active: method.active}"\n            (click)="activateAndScroll(idx, methIdx)">\n            {{method.summary}}\n          </li>\n        </ul>\n\n      </div>\n    </div>\n  ',
          providers: [ScrollService, MenuService, Hash],
          styles: ['\n    .menu-header{text-transform:uppercase;color:#0033a0;padding:0 20px;margin:10px 0}.menu-cat-header{font-size:0.929em;font-family:Montserrat,sans-serif;font-weight:300;cursor:pointer;color:rgba(38,50,56,0.6);text-transform:uppercase;background-color:#FAFAFA;-webkit-transition:all .15s ease-in-out;-moz-transition:all .15s ease-in-out;-ms-transition:all .15s ease-in-out;-o-transition:all .15s ease-in-out;transition:all .15s ease-in-out;display:block;padding:12.5px 20px}.menu-cat-header:hover,.menu-cat-header.active{color:#0033a0;background-color:#f0f0f0}.menu-subitems{margin:0;font-size:0.929em;line-height:1.2em;font-weight:300;color:rgba(38,50,56,0.9);padding:0;height:0;overflow:hidden}.menu-subitems.active{height:auto}.menu-subitems li{-webkit-transition:all .15s ease-in-out;-moz-transition:all .15s ease-in-out;-ms-transition:all .15s ease-in-out;-o-transition:all .15s ease-in-out;transition:all .15s ease-in-out;list-style:none inside none;cursor:pointer;background-color:#f0f0f0;padding:10px 40px;padding-left:40px;overflow:hidden;text-overflow:ellipsis}.menu-subitems li:hover,.menu-subitems li.active{background:#e1e1e1}.mobile-nav{display:none;height:3em;line-height:3em;box-sizing:border-box;border-bottom:1px solid #ccc;cursor:pointer}.mobile-nav:after{content:"";display:inline-block;width:3em;height:3em;background:url(\'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" enable-background="new 0 0 100 100" version="1.1" viewBox="0 0 100 100" xml:space="preserve"><polygon fill="#010101" points="23.1 34.1 51.5 61.7 80 34.1 81.5 35 51.5 64.1 21.5 35 23.1 34.1 "/></svg>\');background-size:70%;background-repeat:no-repeat;background-position:center;float:right;vertical-align:middle}.mobile-nav .menu-header{padding:0 10px 0 20px;font-size:0.95em}@media (max-width: 550px){.mobile-nav .menu-header{display:none}}@media (max-width: 1000px){.mobile-nav{display:block}#resources-nav{height:0;overflow-y:auto;transition:all 0.3s ease}#resources-nav .menu-header{display:none}.menu-subitems{height:auto}}.selected-tag{text-transform:capitalize}.selected-endpoint:before{content:"/";padding:0 2px;color:#ccc}.selected-endpoint:empty:before{display:none}.selected-item-info{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;box-sizing:border-box;max-width:350px}@media (max-width: 550px){.selected-item-info{display:inline-block;padding:0 20px;max-width:80%;max-width:calc(100% - 4em)}}\n  ']
        })(SideMenu) || SideMenu;
        return SideMenu;
      })(BaseComponent);

      _export('SideMenu', SideMenu);
    }
  };
});
$__System.registerDynamic("ac", [], false, function($__require, $__exports, $__module) {
  var _retrieveGlobal = $__System.get("@@global-helpers").prepareGlobal($__module.id, null, null);
  (function() {
    "format global";
    (function(factory) {
      var jQuery;
      if (typeof exports === "object") {
        try {
          jQuery = require("jquery");
        } catch (e) {}
        module.exports = factory(window, document, jQuery);
      } else {
        window.Dropkick = factory(window, document, window.jQuery);
      }
    }(function(window, document, jQuery, undefined) {
      var isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),
          isIframe = (window.parent !== window.self && location.host === parent.location.host),
          isIE = navigator.appVersion.indexOf("MSIE") !== -1,
          Dropkick = function(sel, opts) {
            var i,
                dk;
            if (this === window) {
              return new Dropkick(sel, opts);
            }
            if (typeof sel === "string" && sel[0] === "#") {
              sel = document.getElementById(sel.substr(1));
            }
            for (i = 0; i < Dropkick.uid; i++) {
              dk = Dropkick.cache[i];
              if (dk instanceof Dropkick && dk.data.select === sel) {
                _.extend(dk.data.settings, opts);
                return dk;
              }
            }
            if (!sel) {
              console.error("You must pass a select to DropKick");
              return false;
            }
            if (sel.nodeName === "SELECT") {
              return this.init(sel, opts);
            }
          },
          noop = function() {},
          _docListener,
          defaults = {
            initialize: noop,
            change: noop,
            open: noop,
            close: noop,
            search: "strict",
            bubble: true
          },
          _ = {
            hasClass: function(elem, classname) {
              var reg = new RegExp("(^|\\s+)" + classname + "(\\s+|$)");
              return elem && reg.test(elem.className);
            },
            addClass: function(elem, classname) {
              if (elem && !_.hasClass(elem, classname)) {
                elem.className += " " + classname;
              }
            },
            removeClass: function(elem, classname) {
              var reg = new RegExp("(^|\\s+)" + classname + "(\\s+|$)");
              elem && (elem.className = elem.className.replace(reg, " "));
            },
            toggleClass: function(elem, classname) {
              var fn = _.hasClass(elem, classname) ? "remove" : "add";
              _[fn + "Class"](elem, classname);
            },
            extend: function(obj) {
              Array.prototype.slice.call(arguments, 1).forEach(function(source) {
                if (source) {
                  for (var prop in source)
                    obj[prop] = source[prop];
                }
              });
              return obj;
            },
            offset: function(elem) {
              var box = elem.getBoundingClientRect() || {
                top: 0,
                left: 0
              },
                  docElem = document.documentElement,
                  offsetTop = isIE ? docElem.scrollTop : window.pageYOffset,
                  offsetLeft = isIE ? docElem.scrollLeft : window.pageXOffset;
              return {
                top: box.top + offsetTop - docElem.clientTop,
                left: box.left + offsetLeft - docElem.clientLeft
              };
            },
            position: function(elem, relative) {
              var pos = {
                top: 0,
                left: 0
              };
              while (elem && elem !== relative) {
                pos.top += elem.offsetTop;
                pos.left += elem.offsetLeft;
                elem = elem.parentNode;
              }
              return pos;
            },
            closest: function(child, ancestor) {
              while (child) {
                if (child === ancestor) {
                  return child;
                }
                child = child.parentNode;
              }
              return false;
            },
            create: function(name, attrs) {
              var a,
                  node = document.createElement(name);
              if (!attrs) {
                attrs = {};
              }
              for (a in attrs) {
                if (attrs.hasOwnProperty(a)) {
                  if (a === "innerHTML") {
                    node.innerHTML = attrs[a];
                  } else {
                    node.setAttribute(a, attrs[a]);
                  }
                }
              }
              return node;
            },
            deferred: function(fn) {
              return function() {
                var args = arguments,
                    ctx = this;
                window.setTimeout(function() {
                  fn.apply(ctx, args);
                }, 1);
              };
            }
          };
      Dropkick.cache = {};
      Dropkick.uid = 0;
      Dropkick.prototype = {
        add: function(elem, before) {
          var text,
              option,
              i;
          if (typeof elem === "string") {
            text = elem;
            elem = document.createElement("option");
            elem.text = text;
          }
          if (elem.nodeName === "OPTION") {
            option = _.create("li", {
              "class": "dk-option",
              "data-value": elem.value,
              "innerHTML": elem.text,
              "role": "option",
              "aria-selected": "false",
              "id": "dk" + this.data.cacheID + "-" + (elem.id || elem.value.replace(" ", "-"))
            });
            _.addClass(option, elem.className);
            this.length += 1;
            if (elem.disabled) {
              _.addClass(option, "dk-option-disabled");
              option.setAttribute("aria-disabled", "true");
            }
            this.data.select.add(elem, before);
            if (typeof before === "number") {
              before = this.item(before);
            }
            if (this.options.indexOf(before) > -1) {
              before.parentNode.insertBefore(option, before);
            } else {
              this.data.elem.lastChild.appendChild(option);
            }
            option.addEventListener("mouseover", this);
            i = this.options.indexOf(before);
            this.options.splice(i, 0, option);
            if (elem.selected) {
              this.select(i);
            }
          }
        },
        item: function(index) {
          index = index < 0 ? this.options.length + index : index;
          return this.options[index] || null;
        },
        remove: function(index) {
          var dkOption = this.item(index);
          dkOption.parentNode.removeChild(dkOption);
          this.options.splice(index, 1);
          this.data.select.remove(index);
          this.select(this.data.select.selectedIndex);
          this.length -= 1;
        },
        init: function(sel, opts) {
          var i,
              dk = Dropkick.build(sel, "dk" + Dropkick.uid);
          this.data = {};
          this.data.select = sel;
          this.data.elem = dk.elem;
          this.data.settings = _.extend({}, defaults, opts);
          this.disabled = sel.disabled;
          this.form = sel.form;
          this.length = sel.length;
          this.multiple = sel.multiple;
          this.options = dk.options.slice(0);
          this.selectedIndex = sel.selectedIndex;
          this.selectedOptions = dk.selected.slice(0);
          this.value = sel.value;
          this.data.cacheID = Dropkick.uid;
          Dropkick.cache[this.data.cacheID] = this;
          this.data.settings.initialize.call(this);
          Dropkick.uid += 1;
          if (!this._changeListener) {
            sel.addEventListener("change", this);
            this._changeListener = true;
          }
          if (!(isMobile && !this.data.settings.mobile)) {
            sel.parentNode.insertBefore(this.data.elem, sel);
            sel.setAttribute("data-dkCacheId", this.data.cacheID);
            this.data.elem.addEventListener("click", this);
            this.data.elem.addEventListener("keydown", this);
            this.data.elem.addEventListener("keypress", this);
            if (this.form) {
              this.form.addEventListener("reset", this);
            }
            if (!this.multiple) {
              for (i = 0; i < this.options.length; i++) {
                this.options[i].addEventListener("mouseover", this);
              }
            }
            if (!_docListener) {
              document.addEventListener("click", Dropkick.onDocClick);
              if (isIframe) {
                parent.document.addEventListener("click", Dropkick.onDocClick);
              }
              _docListener = true;
            }
          }
          return this;
        },
        close: function() {
          var i,
              dk = this.data.elem;
          if (!this.isOpen || this.multiple) {
            return false;
          }
          for (i = 0; i < this.options.length; i++) {
            _.removeClass(this.options[i], "dk-option-highlight");
          }
          dk.lastChild.setAttribute("aria-expanded", "false");
          _.removeClass(dk.lastChild, "dk-select-options-highlight");
          _.removeClass(dk, "dk-select-open-(up|down)");
          this.isOpen = false;
          this.data.settings.close.call(this);
        },
        open: _.deferred(function() {
          var dropHeight,
              above,
              below,
              direction,
              dkTop,
              dkBottom,
              dk = this.data.elem,
              dkOptsList = dk.lastChild;
          if (isIE) {
            dkTop = _.offset(dk).top - document.documentElement.scrollTop;
          } else {
            dkTop = _.offset(dk).top - window.scrollY;
          }
          dkBottom = window.innerHeight - (dkTop + dk.offsetHeight);
          if (this.isOpen || this.multiple) {
            return false;
          }
          dkOptsList.style.display = "block";
          dropHeight = dkOptsList.offsetHeight;
          dkOptsList.style.display = "";
          above = dkTop > dropHeight;
          below = dkBottom > dropHeight;
          direction = above && !below ? "-up" : "-down";
          this.isOpen = true;
          _.addClass(dk, "dk-select-open" + direction);
          dkOptsList.setAttribute("aria-expanded", "true");
          this._scrollTo(this.options.length - 1);
          this._scrollTo(this.selectedIndex);
          this.data.settings.open.call(this);
        }),
        disable: function(elem, disabled) {
          var disabledClass = "dk-option-disabled";
          if (arguments.length === 0 || typeof elem === "boolean") {
            disabled = elem === undefined ? true : false;
            elem = this.data.elem;
            disabledClass = "dk-select-disabled";
            this.disabled = disabled;
          }
          if (disabled === undefined) {
            disabled = true;
          }
          if (typeof elem === "number") {
            elem = this.item(elem);
          }
          _[disabled ? "addClass" : "removeClass"](elem, disabledClass);
        },
        select: function(elem, disabled) {
          var i,
              index,
              option,
              combobox,
              select = this.data.select;
          if (typeof elem === "number") {
            elem = this.item(elem);
          }
          if (typeof elem === "string") {
            for (i = 0; i < this.length; i++) {
              if (this.options[i].getAttribute("data-value") === elem) {
                elem = this.options[i];
              }
            }
          }
          if (!elem || typeof elem === "string" || (!disabled && _.hasClass(elem, "dk-option-disabled"))) {
            return false;
          }
          if (_.hasClass(elem, "dk-option")) {
            index = this.options.indexOf(elem);
            option = select.options[index];
            if (this.multiple) {
              _.toggleClass(elem, "dk-option-selected");
              option.selected = !option.selected;
              if (_.hasClass(elem, "dk-option-selected")) {
                elem.setAttribute("aria-selected", "true");
                this.selectedOptions.push(elem);
              } else {
                elem.setAttribute("aria-selected", "false");
                index = this.selectedOptions.indexOf(elem);
                this.selectedOptions.splice(index, 1);
              }
            } else {
              combobox = this.data.elem.firstChild;
              if (this.selectedOptions.length) {
                _.removeClass(this.selectedOptions[0], "dk-option-selected");
                this.selectedOptions[0].setAttribute("aria-selected", "false");
              }
              _.addClass(elem, "dk-option-selected");
              elem.setAttribute("aria-selected", "true");
              combobox.setAttribute("aria-activedescendant", elem.id);
              combobox.className = "dk-selected " + option.className;
              combobox.innerHTML = option.text;
              this.selectedOptions[0] = elem;
              option.selected = true;
            }
            this.selectedIndex = select.selectedIndex;
            this.value = select.value;
            if (!disabled) {
              this.data.select.dispatchEvent(new CustomEvent("change", {bubbles: this.data.settings.bubble}));
            }
            return elem;
          }
        },
        selectOne: function(elem, disabled) {
          this.reset(true);
          this._scrollTo(elem);
          return this.select(elem, disabled);
        },
        search: function(pattern, mode) {
          var i,
              tokens,
              str,
              tIndex,
              sIndex,
              cScore,
              tScore,
              reg,
              options = this.data.select.options,
              matches = [];
          if (!pattern) {
            return this.options;
          }
          mode = mode ? mode.toLowerCase() : "strict";
          mode = mode === "fuzzy" ? 2 : mode === "partial" ? 1 : 0;
          reg = new RegExp((mode ? "" : "^") + pattern, "i");
          for (i = 0; i < options.length; i++) {
            str = options[i].text.toLowerCase();
            if (mode == 2) {
              tokens = pattern.toLowerCase().split("");
              tIndex = sIndex = cScore = tScore = 0;
              while (sIndex < str.length) {
                if (str[sIndex] === tokens[tIndex]) {
                  cScore += 1 + cScore;
                  tIndex++;
                } else {
                  cScore = 0;
                }
                tScore += cScore;
                sIndex++;
              }
              if (tIndex === tokens.length) {
                matches.push({
                  e: this.options[i],
                  s: tScore,
                  i: i
                });
              }
            } else {
              reg.test(str) && matches.push(this.options[i]);
            }
          }
          if (mode === 2) {
            matches = matches.sort(function(a, b) {
              return (b.s - a.s) || a.i - b.i;
            }).reduce(function(p, o) {
              p[p.length] = o.e;
              return p;
            }, []);
          }
          return matches;
        },
        focus: function() {
          if (!this.disabled) {
            (this.multiple ? this.data.elem : this.data.elem.children[0]).focus();
          }
        },
        reset: function(clear) {
          var i,
              select = this.data.select;
          this.selectedOptions.length = 0;
          for (i = 0; i < select.options.length; i++) {
            select.options[i].selected = false;
            _.removeClass(this.options[i], "dk-option-selected");
            this.options[i].setAttribute("aria-selected", "false");
            if (!clear && select.options[i].defaultSelected) {
              this.select(i, true);
            }
          }
          if (!this.selectedOptions.length && !this.multiple) {
            this.select(0, true);
          }
        },
        refresh: function() {
          this.dispose().init(this.data.select, this.data.settings);
        },
        dispose: function() {
          delete Dropkick.cache[this.data.cacheID];
          this.data.elem.parentNode.removeChild(this.data.elem);
          this.data.select.removeAttribute("data-dkCacheId");
          return this;
        },
        handleEvent: function(event) {
          if (this.disabled) {
            return;
          }
          switch (event.type) {
            case "click":
              this._delegate(event);
              break;
            case "keydown":
              this._keyHandler(event);
              break;
            case "keypress":
              this._searchOptions(event);
              break;
            case "mouseover":
              this._highlight(event);
              break;
            case "reset":
              this.reset();
              break;
            case "change":
              this.data.settings.change.call(this);
              break;
          }
        },
        _delegate: function(event) {
          var selection,
              index,
              firstIndex,
              lastIndex,
              target = event.target;
          if (_.hasClass(target, "dk-option-disabled")) {
            return false;
          }
          if (!this.multiple) {
            this[this.isOpen ? "close" : "open"]();
            if (_.hasClass(target, "dk-option")) {
              this.select(target);
            }
          } else {
            if (_.hasClass(target, "dk-option")) {
              selection = window.getSelection();
              if (selection.type === "Range")
                selection.collapseToStart();
              if (event.shiftKey) {
                firstIndex = this.options.indexOf(this.selectedOptions[0]);
                lastIndex = this.options.indexOf(this.selectedOptions[this.selectedOptions.length - 1]);
                index = this.options.indexOf(target);
                if (index > firstIndex && index < lastIndex)
                  index = firstIndex;
                if (index > lastIndex && lastIndex > firstIndex)
                  lastIndex = firstIndex;
                this.reset(true);
                if (lastIndex > index) {
                  while (index < lastIndex + 1) {
                    this.select(index++);
                  }
                } else {
                  while (index > lastIndex - 1) {
                    this.select(index--);
                  }
                }
              } else if (event.ctrlKey || event.metaKey) {
                this.select(target);
              } else {
                this.reset(true);
                this.select(target);
              }
            }
          }
        },
        _highlight: function(event) {
          var i,
              option = event.target;
          if (!this.multiple) {
            for (i = 0; i < this.options.length; i++) {
              _.removeClass(this.options[i], "dk-option-highlight");
            }
            _.addClass(this.data.elem.lastChild, "dk-select-options-highlight");
            _.addClass(option, "dk-option-highlight");
          }
        },
        _keyHandler: function(event) {
          var lastSelected,
              j,
              selected = this.selectedOptions,
              options = this.options,
              i = 1,
              keys = {
                tab: 9,
                enter: 13,
                esc: 27,
                space: 32,
                up: 38,
                down: 40
              };
          switch (event.keyCode) {
            case keys.up:
              i = -1;
            case keys.down:
              event.preventDefault();
              lastSelected = selected[selected.length - 1];
              if (_.hasClass(this.data.elem.lastChild, "dk-select-options-highlight")) {
                _.removeClass(this.data.elem.lastChild, "dk-select-options-highlight");
                for (j = 0; j < options.length; j++) {
                  if (_.hasClass(options[j], "dk-option-highlight")) {
                    _.removeClass(options[j], "dk-option-highlight");
                    lastSelected = options[j];
                  }
                }
              }
              i = options.indexOf(lastSelected) + i;
              if (i > options.length - 1) {
                i = options.length - 1;
              } else if (i < 0) {
                i = 0;
              }
              if (!this.data.select.options[i].disabled) {
                this.reset(true);
                this.select(i);
                this._scrollTo(i);
              }
              break;
            case keys.space:
              if (!this.isOpen) {
                event.preventDefault();
                this.open();
                break;
              }
            case keys.tab:
            case keys.enter:
              for (i = 0; i < options.length; i++) {
                if (_.hasClass(options[i], "dk-option-highlight")) {
                  this.select(i);
                }
              }
            case keys.esc:
              if (this.isOpen) {
                event.preventDefault();
                this.close();
              }
              break;
          }
        },
        _searchOptions: function(event) {
          var results,
              self = this,
              keyChar = String.fromCharCode(event.keyCode || event.which),
              waitToReset = function() {
                if (self.data.searchTimeout) {
                  clearTimeout(self.data.searchTimeout);
                }
                self.data.searchTimeout = setTimeout(function() {
                  self.data.searchString = "";
                }, 1000);
              };
          if (this.data.searchString === undefined) {
            this.data.searchString = "";
          }
          waitToReset();
          this.data.searchString += keyChar;
          results = this.search(this.data.searchString, this.data.settings.search);
          if (results.length) {
            if (!_.hasClass(results[0], "dk-option-disabled")) {
              this.selectOne(results[0]);
            }
          }
        },
        _scrollTo: function(option) {
          var optPos,
              optTop,
              optBottom,
              dkOpts = this.data.elem.lastChild;
          if (option === -1 || (typeof option !== "number" && !option) || (!this.isOpen && !this.multiple)) {
            return false;
          }
          if (typeof option === "number") {
            option = this.item(option);
          }
          optPos = _.position(option, dkOpts).top;
          optTop = optPos - dkOpts.scrollTop;
          optBottom = optTop + option.offsetHeight;
          if (optBottom > dkOpts.offsetHeight) {
            optPos += option.offsetHeight;
            dkOpts.scrollTop = optPos - dkOpts.offsetHeight;
          } else if (optTop < 0) {
            dkOpts.scrollTop = optPos;
          }
        }
      };
      Dropkick.build = function(sel, idpre) {
        var selOpt,
            optList,
            i,
            options = [],
            ret = {
              elem: null,
              options: [],
              selected: []
            },
            addOption = function(node) {
              var option,
                  optgroup,
                  optgroupList,
                  i,
                  children = [];
              switch (node.nodeName) {
                case "OPTION":
                  option = _.create("li", {
                    "class": "dk-option ",
                    "data-value": node.value,
                    "innerHTML": node.text,
                    "role": "option",
                    "aria-selected": "false",
                    "id": idpre + "-" + (node.id || node.value.replace(" ", "-"))
                  });
                  _.addClass(option, node.className);
                  if (node.disabled) {
                    _.addClass(option, "dk-option-disabled");
                    option.setAttribute("aria-disabled", "true");
                  }
                  if (node.selected) {
                    _.addClass(option, "dk-option-selected");
                    option.setAttribute("aria-selected", "true");
                    ret.selected.push(option);
                  }
                  ret.options.push(this.appendChild(option));
                  break;
                case "OPTGROUP":
                  optgroup = _.create("li", {"class": "dk-optgroup"});
                  if (node.label) {
                    optgroup.appendChild(_.create("div", {
                      "class": "dk-optgroup-label",
                      "innerHTML": node.label
                    }));
                  }
                  optgroupList = _.create("ul", {"class": "dk-optgroup-options"});
                  for (i = node.children.length; i--; children.unshift(node.children[i]))
                    ;
                  children.forEach(addOption, optgroupList);
                  this.appendChild(optgroup).appendChild(optgroupList);
                  break;
              }
            };
        ret.elem = _.create("div", {"class": "dk-select" + (sel.multiple ? "-multi" : "")});
        optList = _.create("ul", {
          "class": "dk-select-options",
          "id": idpre + "-listbox",
          "role": "listbox"
        });
        sel.disabled && _.addClass(ret.elem, "dk-select-disabled");
        ret.elem.id = idpre + (sel.id ? "-" + sel.id : "");
        _.addClass(ret.elem, sel.className);
        if (!sel.multiple) {
          selOpt = sel.options[sel.selectedIndex];
          ret.elem.appendChild(_.create("div", {
            "class": "dk-selected " + selOpt.className,
            "tabindex": sel.tabindex || 0,
            "innerHTML": selOpt ? selOpt.text : '&nbsp;',
            "id": idpre + "-combobox",
            "aria-live": "assertive",
            "aria-owns": optList.id,
            "role": "combobox"
          }));
          optList.setAttribute("aria-expanded", "false");
        } else {
          ret.elem.setAttribute("tabindex", sel.getAttribute("tabindex") || "0");
          optList.setAttribute("aria-multiselectable", "true");
        }
        for (i = sel.children.length; i--; options.unshift(sel.children[i]))
          ;
        options.forEach(addOption, ret.elem.appendChild(optList));
        return ret;
      };
      Dropkick.onDocClick = function(event) {
        var tId,
            i;
        if (event.target.nodeType !== 1) {
          return false;
        }
        if ((tId = event.target.getAttribute("data-dkcacheid")) !== null) {
          Dropkick.cache[tId].focus();
        }
        for (i in Dropkick.cache) {
          if (!_.closest(event.target, Dropkick.cache[i].data.elem) && i !== tId) {
            Dropkick.cache[i].disabled || Dropkick.cache[i].close();
          }
        }
      };
      if (jQuery !== undefined) {
        jQuery.fn.dropkick = function() {
          var args = Array.prototype.slice.call(arguments);
          return jQuery(this).each(function() {
            if (!args[0] || typeof args[0] === 'object') {
              new Dropkick(this, args[0] || {});
            } else if (typeof args[0] === 'string') {
              Dropkick.prototype[args[0]].apply(new Dropkick(this), args.slice(1));
            }
          });
        };
      }
      return Dropkick;
    }));
  })();
  return _retrieveGlobal();
});

$__System.registerDynamic("ad", ["ac"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('ac');
  return module.exports;
});

$__System.register("ae", [], function() { return { setters: [], execute: function() {} } });

$__System.register('af', ['11', '76', '89', '8a', 'ad', 'ae'], function (_export) {
  var Component, EventEmitter, ElementRef, CORE_DIRECTIVES, _createClass, _classCallCheck, DropKick, DropDown;

  return {
    setters: [function (_2) {
      Component = _2.Component;
      EventEmitter = _2.EventEmitter;
      ElementRef = _2.ElementRef;
    }, function (_3) {
      CORE_DIRECTIVES = _3.CORE_DIRECTIVES;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_ad) {
      DropKick = _ad['default'];
    }, function (_ae) {}],
    execute: function () {
      'use strict';

      DropDown = (function () {
        function DropDown(elem) {
          _classCallCheck(this, _DropDown);

          this.change = new EventEmitter();
          this.elem = elem.nativeElement;
        }

        _createClass(DropDown, [{
          key: 'ngAfterContentInit',
          value: function ngAfterContentInit() {
            this.inst = new DropKick(this.elem.firstElementChild, { autoWidth: true });
          }
        }, {
          key: 'onChange',
          value: function onChange(value) {
            this.change.next(value);
          }
        }, {
          key: 'destroy',
          value: function destroy() {
            this.inst.dispose();
          }
        }]);

        var _DropDown = DropDown;
        DropDown = Reflect.metadata('parameters', [[ElementRef]])(DropDown) || DropDown;
        DropDown = Component({
          selector: 'dropdown',
          events: ['change'],
          template: '\n    <select (change)=onChange($event.target.value)>\n      <ng-content></ng-content>\n    </select>\n  ',
          directives: [CORE_DIRECTIVES],
          styles: ['\n    :host .dk-select{max-width:100%;font-family:Montserrat,sans-serif;font-size:.929em;min-width:100px;width:auto}:host .dk-selected:after{display:none}:host .dk-selected{color:#263238;border-color:rgba(38,50,56,0.5);padding:0.15em 0.6em 0.2em 0.5em;border-radius:2px}:host .dk-select-open-down .dk-selected,:host .dk-selected:focus,:host .dk-selected:hover{border-color:#0033a0;color:#0033a0}:host .dk-selected:before{border-top-color:#263238;border-width:.35em .35em 0}:host .dk-select-open-down .dk-selected:before,:host .dk-select-open-up .dk-selected:before{border-bottom-color:#0033a0}:host .dk-select-multi:focus .dk-select-options,:host .dk-select-open-down .dk-select-options,:host .dk-select-open-up .dk-select-options{border-color:rgba(38,50,56,0.2)}:host .dk-select-options .dk-option-highlight{background:#ffffff}:host .dk-select-options{margin-top:0.2em;padding:0;border-radius:2px;box-shadow:0px 2px 4px 0px rgba(34,36,38,0.12),0px 2px 10px 0px rgba(34,36,38,0.08) !important}:host .dk-option{color:#263238;padding:0.16em 0.6em 0.2em 0.5em}:host .dk-option:hover{background-color:rgba(38,50,56,0.12)}:host .dk-option:focus{background-color:rgba(38,50,56,0.12)}:host .dk-option-selected{background-color:rgba(0,0,0,0.05) !important}\n  ']
        })(DropDown) || DropDown;
        return DropDown;
      })();

      _export('DropDown', DropDown);
    }
  };
});
$__System.register('b0', ['11', '89', '8a', '5e'], function (_export) {
  var Directive, ElementRef, _createClass, _classCallCheck, BrowserDomAdapter, StickySidebar;

  return {
    setters: [function (_2) {
      Directive = _2.Directive;
      ElementRef = _2.ElementRef;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }],
    execute: function () {
      'use strict';

      StickySidebar = (function () {
        function StickySidebar(elementRef, dom) {
          _classCallCheck(this, _StickySidebar);

          this.$element = elementRef.nativeElement;
          this.dom = dom;

          // initial styling
          this.dom.setStyle(this.$element, 'position', 'absolute');
          this.dom.setStyle(this.$element, 'top', '0');
          this.dom.setStyle(this.$element, 'bottom', '0');
          this.dom.setStyle(this.$element, 'max-height', '100%');
        }

        _createClass(StickySidebar, [{
          key: 'bind',
          value: function bind() {
            var _this = this;

            this.cancelScrollBinding = this.dom.onAndCancel(this.scrollParent, 'scroll', function () {
              _this.updatePosition();
            });
            this.updatePosition();
          }
        }, {
          key: 'unbind',
          value: function unbind() {
            this.cancelScrollBinding && this.cancelScrollBinding();
          }
        }, {
          key: 'updatePosition',
          value: function updatePosition() {
            if (this.scrollY + this.scrollYOffset() >= this.$redocEl.offsetTop) {
              this.stick();
            } else {
              this.unstick();
            }
          }
        }, {
          key: 'stick',
          value: function stick() {
            this.dom.setStyle(this.$element, 'position', 'fixed');
            this.dom.setStyle(this.$element, 'top', this.scrollYOffset() + 'px');
          }
        }, {
          key: 'unstick',
          value: function unstick() {
            this.dom.setStyle(this.$element, 'position', 'absolute');
            this.dom.setStyle(this.$element, 'top', 0);
          }
        }, {
          key: 'ngOnInit',
          value: function ngOnInit() {
            // FIXME use more reliable code
            this.$redocEl = this.$element.offsetParent;
            this.bind();
          }
        }, {
          key: 'ngOnDestroy',
          value: function ngOnDestroy() {
            this.unbind();
          }
        }, {
          key: 'scrollY',
          get: function get() {
            return this.scrollParent.pageYOffset != null ? this.scrollParent.pageYOffset : this.scrollParent.scrollTop;
          }
        }]);

        var _StickySidebar = StickySidebar;
        StickySidebar = Reflect.metadata('parameters', [[ElementRef], [BrowserDomAdapter]])(StickySidebar) || StickySidebar;
        StickySidebar = Directive({
          selector: '[sticky-sidebar]',
          inputs: ['scrollParent', 'scrollYOffset']
        })(StickySidebar) || StickySidebar;
        return StickySidebar;
      })();

      _export('StickySidebar', StickySidebar);
    }
  };
});
$__System.register('b1', ['11', '76', '89', '8a'], function (_export) {
  var Component, EventEmitter, CORE_DIRECTIVES, _createClass, _classCallCheck, Tabs, Tab;

  return {
    setters: [function (_2) {
      Component = _2.Component;
      EventEmitter = _2.EventEmitter;
    }, function (_3) {
      CORE_DIRECTIVES = _3.CORE_DIRECTIVES;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {
      'use strict';

      Tabs = (function () {
        function Tabs() {
          _classCallCheck(this, _Tabs);

          this.tabs = [];
          this.change = new EventEmitter();
        }

        _createClass(Tabs, [{
          key: 'selectTab',
          value: function selectTab(tab) {
            var notify = arguments.length <= 1 || arguments[1] === undefined ? true : arguments[1];

            if (tab.active) return;
            this.tabs.forEach(function (tab) {
              tab.active = false;
            });
            tab.active = true;
            notify && this.change.next(tab.tabTitle);
          }
        }, {
          key: 'selectyByTitle',
          value: function selectyByTitle(tabTitle) {
            var notify = arguments.length <= 1 || arguments[1] === undefined ? false : arguments[1];

            var prevActive = undefined;
            var newActive = undefined;
            this.tabs.forEach(function (tab) {
              if (tab.active) prevActive = tab;
              tab.active = false;
              if (tab.tabTitle === tabTitle) {
                newActive = tab;
              }
            });
            if (newActive) {
              newActive.active = true;
            } else {
              prevActive.active = true;
            }
            notify && this.change.next(tabTitle);
          }
        }, {
          key: 'addTab',
          value: function addTab(tab) {
            if (this.tabs.length === 0) {
              tab.active = true;
            }
            this.tabs.push(tab);
          }
        }]);

        var _Tabs = Tabs;
        Tabs = Component({
          selector: 'tabs',
          events: ['change'],
          template: '\n    <ul>\n      <li *ngFor="let tab of tabs" [ngClass]="{active: tab.active}" (click)="selectTab(tab)"\n        class="tab-{{tab.tabStatus}}">{{tab.tabTitle}}</li>\n    </ul>\n    <ng-content></ng-content>\n  ',
          directives: [CORE_DIRECTIVES],
          styles: ['\n    ul{display:block;margin:0;padding:0}li{list-style:none;display:inline-block;cursor:pointer}.tab-success:before,.tab-error:before,.tab-redirect:before,.tab-info:before{content:"";display:inline-block;position:relative;top:-2px;height:4px;width:4px;border-radius:50%;margin-right:0.5em}.tab-success:before{box-shadow:0 0 3px 0 #00aa13;background-color:#00aa13}.tab-error:before{box-shadow:0 0 3px 0 #e53935;background-color:#e53935}.tab-redirect:before{box-shadow:0 0 3px 0 #f1c400;background-color:#f1c400}.tab-info:before{box-shadow:0 0 3px 0 #0033a0;background-color:#0033a0}\n  ']
        })(Tabs) || Tabs;
        return Tabs;
      })();

      _export('Tabs', Tabs);

      Tab = (function () {
        function Tab(tabs) {
          _classCallCheck(this, _Tab);

          this.active = false;
          tabs.addTab(this);
        }

        var _Tab = Tab;
        Tab = Reflect.metadata('parameters', [[Tabs]])(Tab) || Tab;
        Tab = Component({
          selector: 'tab',
          inputs: ['tabTitle', 'tabStatus'],
          template: '\n    <div class="tab-wrap" [ngClass]="{\'active\': active}">\n      <ng-content></ng-content>\n    </div>\n  ',
          directives: [CORE_DIRECTIVES],
          styles: ['\n    .tab-wrap {\n      display: none;\n    }\n\n    .tab-wrap.active {\n      display: block;\n    }']
        })(Tab) || Tab;
        return Tab;
      })();

      _export('Tab', Tab);
    }
  };
});
$__System.registerDynamic("b2", ["11", "b3", "b4", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var async_1 = $__require('b4');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var ObservableStrategy = (function() {
    function ObservableStrategy() {}
    ObservableStrategy.prototype.createSubscription = function(async, updateLatestValue) {
      return async_1.ObservableWrapper.subscribe(async, updateLatestValue, function(e) {
        throw e;
      });
    };
    ObservableStrategy.prototype.dispose = function(subscription) {
      async_1.ObservableWrapper.dispose(subscription);
    };
    ObservableStrategy.prototype.onDestroy = function(subscription) {
      async_1.ObservableWrapper.dispose(subscription);
    };
    return ObservableStrategy;
  }());
  var PromiseStrategy = (function() {
    function PromiseStrategy() {}
    PromiseStrategy.prototype.createSubscription = function(async, updateLatestValue) {
      return async.then(updateLatestValue);
    };
    PromiseStrategy.prototype.dispose = function(subscription) {};
    PromiseStrategy.prototype.onDestroy = function(subscription) {};
    return PromiseStrategy;
  }());
  var _promiseStrategy = new PromiseStrategy();
  var _observableStrategy = new ObservableStrategy();
  var __unused;
  var AsyncPipe = (function() {
    function AsyncPipe(_ref) {
      this._latestValue = null;
      this._latestReturnedValue = null;
      this._subscription = null;
      this._obj = null;
      this._strategy = null;
      this._ref = _ref;
    }
    AsyncPipe.prototype.ngOnDestroy = function() {
      if (lang_1.isPresent(this._subscription)) {
        this._dispose();
      }
    };
    AsyncPipe.prototype.transform = function(obj) {
      if (lang_1.isBlank(this._obj)) {
        if (lang_1.isPresent(obj)) {
          this._subscribe(obj);
        }
        this._latestReturnedValue = this._latestValue;
        return this._latestValue;
      }
      if (obj !== this._obj) {
        this._dispose();
        return this.transform(obj);
      }
      if (this._latestValue === this._latestReturnedValue) {
        return this._latestReturnedValue;
      } else {
        this._latestReturnedValue = this._latestValue;
        return core_1.WrappedValue.wrap(this._latestValue);
      }
    };
    AsyncPipe.prototype._subscribe = function(obj) {
      var _this = this;
      this._obj = obj;
      this._strategy = this._selectStrategy(obj);
      this._subscription = this._strategy.createSubscription(obj, function(value) {
        return _this._updateLatestValue(obj, value);
      });
    };
    AsyncPipe.prototype._selectStrategy = function(obj) {
      if (lang_1.isPromise(obj)) {
        return _promiseStrategy;
      } else if (async_1.ObservableWrapper.isObservable(obj)) {
        return _observableStrategy;
      } else {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(AsyncPipe, obj);
      }
    };
    AsyncPipe.prototype._dispose = function() {
      this._strategy.dispose(this._subscription);
      this._latestValue = null;
      this._latestReturnedValue = null;
      this._subscription = null;
      this._obj = null;
    };
    AsyncPipe.prototype._updateLatestValue = function(async, value) {
      if (async === this._obj) {
        this._latestValue = value;
        this._ref.markForCheck();
      }
    };
    AsyncPipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'async',
        pure: false
      }]
    }, {type: core_1.Injectable}];
    AsyncPipe.ctorParameters = [{type: core_1.ChangeDetectorRef}];
    return AsyncPipe;
  }());
  exports.AsyncPipe = AsyncPipe;
  return module.exports;
});

$__System.registerDynamic("b6", ["11", "b3", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var UpperCasePipe = (function() {
    function UpperCasePipe() {}
    UpperCasePipe.prototype.transform = function(value) {
      if (lang_1.isBlank(value))
        return value;
      if (!lang_1.isString(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(UpperCasePipe, value);
      }
      return value.toUpperCase();
    };
    UpperCasePipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'uppercase'}]
    }, {type: core_1.Injectable}];
    return UpperCasePipe;
  }());
  exports.UpperCasePipe = UpperCasePipe;
  return module.exports;
});

$__System.registerDynamic("b7", ["11", "b3", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var LowerCasePipe = (function() {
    function LowerCasePipe() {}
    LowerCasePipe.prototype.transform = function(value) {
      if (lang_1.isBlank(value))
        return value;
      if (!lang_1.isString(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(LowerCasePipe, value);
      }
      return value.toLowerCase();
    };
    LowerCasePipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'lowercase'}]
    }, {type: core_1.Injectable}];
    return LowerCasePipe;
  }());
  exports.LowerCasePipe = LowerCasePipe;
  return module.exports;
});

$__System.registerDynamic("b8", ["11", "b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var JsonPipe = (function() {
    function JsonPipe() {}
    JsonPipe.prototype.transform = function(value) {
      return lang_1.Json.stringify(value);
    };
    JsonPipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'json',
        pure: false
      }]
    }, {type: core_1.Injectable}];
    return JsonPipe;
  }());
  exports.JsonPipe = JsonPipe;
  return module.exports;
});

$__System.registerDynamic("b9", ["11", "b3", "ba", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var SlicePipe = (function() {
    function SlicePipe() {}
    SlicePipe.prototype.transform = function(value, start, end) {
      if (end === void 0) {
        end = null;
      }
      if (!this.supports(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(SlicePipe, value);
      }
      if (lang_1.isBlank(value))
        return value;
      if (lang_1.isString(value)) {
        return lang_1.StringWrapper.slice(value, start, end);
      }
      return collection_1.ListWrapper.slice(value, start, end);
    };
    SlicePipe.prototype.supports = function(obj) {
      return lang_1.isString(obj) || lang_1.isArray(obj);
    };
    SlicePipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'slice',
        pure: false
      }]
    }, {type: core_1.Injectable}];
    return SlicePipe;
  }());
  exports.SlicePipe = SlicePipe;
  return module.exports;
});

$__System.registerDynamic("bb", ["11", "b3", "bc", "ba", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var intl_1 = $__require('bc');
  var collection_1 = $__require('ba');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var defaultLocale = 'en-US';
  var DatePipe = (function() {
    function DatePipe() {}
    DatePipe.prototype.transform = function(value, pattern) {
      if (pattern === void 0) {
        pattern = 'mediumDate';
      }
      if (lang_1.isBlank(value))
        return null;
      if (!this.supports(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(DatePipe, value);
      }
      if (lang_1.isNumber(value)) {
        value = lang_1.DateWrapper.fromMillis(value);
      }
      if (collection_1.StringMapWrapper.contains(DatePipe._ALIASES, pattern)) {
        pattern = collection_1.StringMapWrapper.get(DatePipe._ALIASES, pattern);
      }
      return intl_1.DateFormatter.format(value, defaultLocale, pattern);
    };
    DatePipe.prototype.supports = function(obj) {
      return lang_1.isDate(obj) || lang_1.isNumber(obj);
    };
    DatePipe._ALIASES = {
      'medium': 'yMMMdjms',
      'short': 'yMdjm',
      'fullDate': 'yMMMMEEEEd',
      'longDate': 'yMMMMd',
      'mediumDate': 'yMMMd',
      'shortDate': 'yMd',
      'mediumTime': 'jms',
      'shortTime': 'jm'
    };
    DatePipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'date',
        pure: true
      }]
    }, {type: core_1.Injectable}];
    return DatePipe;
  }());
  exports.DatePipe = DatePipe;
  return module.exports;
});

$__System.registerDynamic("bc", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(NumberFormatStyle) {
    NumberFormatStyle[NumberFormatStyle["Decimal"] = 0] = "Decimal";
    NumberFormatStyle[NumberFormatStyle["Percent"] = 1] = "Percent";
    NumberFormatStyle[NumberFormatStyle["Currency"] = 2] = "Currency";
  })(exports.NumberFormatStyle || (exports.NumberFormatStyle = {}));
  var NumberFormatStyle = exports.NumberFormatStyle;
  var NumberFormatter = (function() {
    function NumberFormatter() {}
    NumberFormatter.format = function(num, locale, style, _a) {
      var _b = _a === void 0 ? {} : _a,
          _c = _b.minimumIntegerDigits,
          minimumIntegerDigits = _c === void 0 ? 1 : _c,
          _d = _b.minimumFractionDigits,
          minimumFractionDigits = _d === void 0 ? 0 : _d,
          _e = _b.maximumFractionDigits,
          maximumFractionDigits = _e === void 0 ? 3 : _e,
          currency = _b.currency,
          _f = _b.currencyAsSymbol,
          currencyAsSymbol = _f === void 0 ? false : _f;
      var intlOptions = {
        minimumIntegerDigits: minimumIntegerDigits,
        minimumFractionDigits: minimumFractionDigits,
        maximumFractionDigits: maximumFractionDigits
      };
      intlOptions.style = NumberFormatStyle[style].toLowerCase();
      if (style == NumberFormatStyle.Currency) {
        intlOptions.currency = currency;
        intlOptions.currencyDisplay = currencyAsSymbol ? 'symbol' : 'code';
      }
      return new Intl.NumberFormat(locale, intlOptions).format(num);
    };
    return NumberFormatter;
  }());
  exports.NumberFormatter = NumberFormatter;
  function digitCondition(len) {
    return len == 2 ? '2-digit' : 'numeric';
  }
  function nameCondition(len) {
    return len < 4 ? 'short' : 'long';
  }
  function extractComponents(pattern) {
    var ret = {};
    var i = 0,
        j;
    while (i < pattern.length) {
      j = i;
      while (j < pattern.length && pattern[j] == pattern[i])
        j++;
      var len = j - i;
      switch (pattern[i]) {
        case 'G':
          ret.era = nameCondition(len);
          break;
        case 'y':
          ret.year = digitCondition(len);
          break;
        case 'M':
          if (len >= 3)
            ret.month = nameCondition(len);
          else
            ret.month = digitCondition(len);
          break;
        case 'd':
          ret.day = digitCondition(len);
          break;
        case 'E':
          ret.weekday = nameCondition(len);
          break;
        case 'j':
          ret.hour = digitCondition(len);
          break;
        case 'h':
          ret.hour = digitCondition(len);
          ret.hour12 = true;
          break;
        case 'H':
          ret.hour = digitCondition(len);
          ret.hour12 = false;
          break;
        case 'm':
          ret.minute = digitCondition(len);
          break;
        case 's':
          ret.second = digitCondition(len);
          break;
        case 'z':
          ret.timeZoneName = 'long';
          break;
        case 'Z':
          ret.timeZoneName = 'short';
          break;
      }
      i = j;
    }
    return ret;
  }
  var dateFormatterCache = new Map();
  var DateFormatter = (function() {
    function DateFormatter() {}
    DateFormatter.format = function(date, locale, pattern) {
      var key = locale + pattern;
      if (dateFormatterCache.has(key)) {
        return dateFormatterCache.get(key).format(date);
      }
      var formatter = new Intl.DateTimeFormat(locale, extractComponents(pattern));
      dateFormatterCache.set(key, formatter);
      return formatter.format(date);
    };
    return DateFormatter;
  }());
  exports.DateFormatter = DateFormatter;
  return module.exports;
});

$__System.registerDynamic("bd", ["11", "b3", "be", "bc", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var intl_1 = $__require('bc');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var defaultLocale = 'en-US';
  var _re = lang_1.RegExpWrapper.create('^(\\d+)?\\.((\\d+)(\\-(\\d+))?)?$');
  var NumberPipe = (function() {
    function NumberPipe() {}
    NumberPipe._format = function(value, style, digits, currency, currencyAsSymbol) {
      if (currency === void 0) {
        currency = null;
      }
      if (currencyAsSymbol === void 0) {
        currencyAsSymbol = false;
      }
      if (lang_1.isBlank(value))
        return null;
      if (!lang_1.isNumber(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(NumberPipe, value);
      }
      var minInt = 1,
          minFraction = 0,
          maxFraction = 3;
      if (lang_1.isPresent(digits)) {
        var parts = lang_1.RegExpWrapper.firstMatch(_re, digits);
        if (lang_1.isBlank(parts)) {
          throw new exceptions_1.BaseException(digits + " is not a valid digit info for number pipes");
        }
        if (lang_1.isPresent(parts[1])) {
          minInt = lang_1.NumberWrapper.parseIntAutoRadix(parts[1]);
        }
        if (lang_1.isPresent(parts[3])) {
          minFraction = lang_1.NumberWrapper.parseIntAutoRadix(parts[3]);
        }
        if (lang_1.isPresent(parts[5])) {
          maxFraction = lang_1.NumberWrapper.parseIntAutoRadix(parts[5]);
        }
      }
      return intl_1.NumberFormatter.format(value, defaultLocale, style, {
        minimumIntegerDigits: minInt,
        minimumFractionDigits: minFraction,
        maximumFractionDigits: maxFraction,
        currency: currency,
        currencyAsSymbol: currencyAsSymbol
      });
    };
    NumberPipe.decorators = [{type: core_1.Injectable}];
    return NumberPipe;
  }());
  exports.NumberPipe = NumberPipe;
  var DecimalPipe = (function(_super) {
    __extends(DecimalPipe, _super);
    function DecimalPipe() {
      _super.apply(this, arguments);
    }
    DecimalPipe.prototype.transform = function(value, digits) {
      if (digits === void 0) {
        digits = null;
      }
      return NumberPipe._format(value, intl_1.NumberFormatStyle.Decimal, digits);
    };
    DecimalPipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'number'}]
    }, {type: core_1.Injectable}];
    return DecimalPipe;
  }(NumberPipe));
  exports.DecimalPipe = DecimalPipe;
  var PercentPipe = (function(_super) {
    __extends(PercentPipe, _super);
    function PercentPipe() {
      _super.apply(this, arguments);
    }
    PercentPipe.prototype.transform = function(value, digits) {
      if (digits === void 0) {
        digits = null;
      }
      return NumberPipe._format(value, intl_1.NumberFormatStyle.Percent, digits);
    };
    PercentPipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'percent'}]
    }, {type: core_1.Injectable}];
    return PercentPipe;
  }(NumberPipe));
  exports.PercentPipe = PercentPipe;
  var CurrencyPipe = (function(_super) {
    __extends(CurrencyPipe, _super);
    function CurrencyPipe() {
      _super.apply(this, arguments);
    }
    CurrencyPipe.prototype.transform = function(value, currencyCode, symbolDisplay, digits) {
      if (currencyCode === void 0) {
        currencyCode = 'USD';
      }
      if (symbolDisplay === void 0) {
        symbolDisplay = false;
      }
      if (digits === void 0) {
        digits = null;
      }
      return NumberPipe._format(value, intl_1.NumberFormatStyle.Currency, digits, currencyCode, symbolDisplay);
    };
    CurrencyPipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'currency'}]
    }, {type: core_1.Injectable}];
    return CurrencyPipe;
  }(NumberPipe));
  exports.CurrencyPipe = CurrencyPipe;
  return module.exports;
});

$__System.registerDynamic("bf", ["11", "b3", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var ReplacePipe = (function() {
    function ReplacePipe() {}
    ReplacePipe.prototype.transform = function(value, pattern, replacement) {
      if (lang_1.isBlank(value)) {
        return value;
      }
      if (!this._supportedInput(value)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(ReplacePipe, value);
      }
      var input = value.toString();
      if (!this._supportedPattern(pattern)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(ReplacePipe, pattern);
      }
      if (!this._supportedReplacement(replacement)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(ReplacePipe, replacement);
      }
      if (lang_1.isFunction(replacement)) {
        var rgxPattern = lang_1.isString(pattern) ? lang_1.RegExpWrapper.create(pattern) : pattern;
        return lang_1.StringWrapper.replaceAllMapped(input, rgxPattern, replacement);
      }
      if (pattern instanceof RegExp) {
        return lang_1.StringWrapper.replaceAll(input, pattern, replacement);
      }
      return lang_1.StringWrapper.replace(input, pattern, replacement);
    };
    ReplacePipe.prototype._supportedInput = function(input) {
      return lang_1.isString(input) || lang_1.isNumber(input);
    };
    ReplacePipe.prototype._supportedPattern = function(pattern) {
      return lang_1.isString(pattern) || pattern instanceof RegExp;
    };
    ReplacePipe.prototype._supportedReplacement = function(replacement) {
      return lang_1.isString(replacement) || lang_1.isFunction(replacement);
    };
    ReplacePipe.decorators = [{
      type: core_1.Pipe,
      args: [{name: 'replace'}]
    }, {type: core_1.Injectable}];
    return ReplacePipe;
  }());
  exports.ReplacePipe = ReplacePipe;
  return module.exports;
});

$__System.registerDynamic("c0", ["11", "b3", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var interpolationExp = lang_1.RegExpWrapper.create('#');
  var I18nPluralPipe = (function() {
    function I18nPluralPipe() {}
    I18nPluralPipe.prototype.transform = function(value, pluralMap) {
      var key;
      var valueStr;
      if (!lang_1.isStringMap(pluralMap)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(I18nPluralPipe, pluralMap);
      }
      key = value === 0 || value === 1 ? "=" + value : 'other';
      valueStr = lang_1.isPresent(value) ? value.toString() : '';
      return lang_1.StringWrapper.replaceAll(pluralMap[key], interpolationExp, valueStr);
    };
    I18nPluralPipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'i18nPlural',
        pure: true
      }]
    }, {type: core_1.Injectable}];
    return I18nPluralPipe;
  }());
  exports.I18nPluralPipe = I18nPluralPipe;
  return module.exports;
});

$__System.registerDynamic("b5", ["b3", "be"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var InvalidPipeArgumentException = (function(_super) {
    __extends(InvalidPipeArgumentException, _super);
    function InvalidPipeArgumentException(type, value) {
      _super.call(this, "Invalid argument '" + value + "' for pipe '" + lang_1.stringify(type) + "'");
    }
    return InvalidPipeArgumentException;
  }(exceptions_1.BaseException));
  exports.InvalidPipeArgumentException = InvalidPipeArgumentException;
  return module.exports;
});

$__System.registerDynamic("c1", ["11", "b3", "ba", "b5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var invalid_pipe_argument_exception_1 = $__require('b5');
  var I18nSelectPipe = (function() {
    function I18nSelectPipe() {}
    I18nSelectPipe.prototype.transform = function(value, mapping) {
      if (!lang_1.isStringMap(mapping)) {
        throw new invalid_pipe_argument_exception_1.InvalidPipeArgumentException(I18nSelectPipe, mapping);
      }
      return collection_1.StringMapWrapper.contains(mapping, value) ? mapping[value] : mapping['other'];
    };
    I18nSelectPipe.decorators = [{
      type: core_1.Pipe,
      args: [{
        name: 'i18nSelect',
        pure: true
      }]
    }, {type: core_1.Injectable}];
    return I18nSelectPipe;
  }());
  exports.I18nSelectPipe = I18nSelectPipe;
  return module.exports;
});

$__System.registerDynamic("c2", ["b2", "b6", "b7", "b8", "b9", "bb", "bd", "bf", "c0", "c1"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var async_pipe_1 = $__require('b2');
  var uppercase_pipe_1 = $__require('b6');
  var lowercase_pipe_1 = $__require('b7');
  var json_pipe_1 = $__require('b8');
  var slice_pipe_1 = $__require('b9');
  var date_pipe_1 = $__require('bb');
  var number_pipe_1 = $__require('bd');
  var replace_pipe_1 = $__require('bf');
  var i18n_plural_pipe_1 = $__require('c0');
  var i18n_select_pipe_1 = $__require('c1');
  exports.COMMON_PIPES = [async_pipe_1.AsyncPipe, uppercase_pipe_1.UpperCasePipe, lowercase_pipe_1.LowerCasePipe, json_pipe_1.JsonPipe, slice_pipe_1.SlicePipe, number_pipe_1.DecimalPipe, number_pipe_1.PercentPipe, number_pipe_1.CurrencyPipe, date_pipe_1.DatePipe, replace_pipe_1.ReplacePipe, i18n_plural_pipe_1.I18nPluralPipe, i18n_select_pipe_1.I18nSelectPipe];
  return module.exports;
});

$__System.registerDynamic("c3", ["b2", "bb", "b8", "b9", "b7", "bd", "b6", "bf", "c0", "c1", "c2"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var async_pipe_1 = $__require('b2');
  exports.AsyncPipe = async_pipe_1.AsyncPipe;
  var date_pipe_1 = $__require('bb');
  exports.DatePipe = date_pipe_1.DatePipe;
  var json_pipe_1 = $__require('b8');
  exports.JsonPipe = json_pipe_1.JsonPipe;
  var slice_pipe_1 = $__require('b9');
  exports.SlicePipe = slice_pipe_1.SlicePipe;
  var lowercase_pipe_1 = $__require('b7');
  exports.LowerCasePipe = lowercase_pipe_1.LowerCasePipe;
  var number_pipe_1 = $__require('bd');
  exports.NumberPipe = number_pipe_1.NumberPipe;
  exports.DecimalPipe = number_pipe_1.DecimalPipe;
  exports.PercentPipe = number_pipe_1.PercentPipe;
  exports.CurrencyPipe = number_pipe_1.CurrencyPipe;
  var uppercase_pipe_1 = $__require('b6');
  exports.UpperCasePipe = uppercase_pipe_1.UpperCasePipe;
  var replace_pipe_1 = $__require('bf');
  exports.ReplacePipe = replace_pipe_1.ReplacePipe;
  var i18n_plural_pipe_1 = $__require('c0');
  exports.I18nPluralPipe = i18n_plural_pipe_1.I18nPluralPipe;
  var i18n_select_pipe_1 = $__require('c1');
  exports.I18nSelectPipe = i18n_select_pipe_1.I18nSelectPipe;
  var common_pipes_1 = $__require('c2');
  exports.COMMON_PIPES = common_pipes_1.COMMON_PIPES;
  return module.exports;
});

$__System.registerDynamic("c4", ["11", "b4", "c5", "c6", "c7", "c8", "c9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var async_1 = $__require('b4');
  var control_container_1 = $__require('c5');
  var ng_control_1 = $__require('c6');
  var control_value_accessor_1 = $__require('c7');
  var shared_1 = $__require('c8');
  var validators_1 = $__require('c9');
  exports.controlNameBinding = {
    provide: ng_control_1.NgControl,
    useExisting: core_1.forwardRef(function() {
      return NgControlName;
    })
  };
  var NgControlName = (function(_super) {
    __extends(NgControlName, _super);
    function NgControlName(_parent, _validators, _asyncValidators, valueAccessors) {
      _super.call(this);
      this._parent = _parent;
      this._validators = _validators;
      this._asyncValidators = _asyncValidators;
      this.update = new async_1.EventEmitter();
      this._added = false;
      this.valueAccessor = shared_1.selectValueAccessor(this, valueAccessors);
    }
    NgControlName.prototype.ngOnChanges = function(changes) {
      if (!this._added) {
        this.formDirective.addControl(this);
        this._added = true;
      }
      if (shared_1.isPropertyUpdated(changes, this.viewModel)) {
        this.viewModel = this.model;
        this.formDirective.updateModel(this, this.model);
      }
    };
    NgControlName.prototype.ngOnDestroy = function() {
      this.formDirective.removeControl(this);
    };
    NgControlName.prototype.viewToModelUpdate = function(newValue) {
      this.viewModel = newValue;
      async_1.ObservableWrapper.callEmit(this.update, newValue);
    };
    Object.defineProperty(NgControlName.prototype, "path", {
      get: function() {
        return shared_1.controlPath(this.name, this._parent);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlName.prototype, "formDirective", {
      get: function() {
        return this._parent.formDirective;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlName.prototype, "validator", {
      get: function() {
        return shared_1.composeValidators(this._validators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlName.prototype, "asyncValidator", {
      get: function() {
        return shared_1.composeAsyncValidators(this._asyncValidators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlName.prototype, "control", {
      get: function() {
        return this.formDirective.getControl(this);
      },
      enumerable: true,
      configurable: true
    });
    NgControlName.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngControl]',
        bindings: [exports.controlNameBinding],
        inputs: ['name: ngControl', 'model: ngModel'],
        outputs: ['update: ngModelChange'],
        exportAs: 'ngForm'
      }]
    }];
    NgControlName.ctorParameters = [{
      type: control_container_1.ControlContainer,
      decorators: [{type: core_1.Host}, {type: core_1.SkipSelf}]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [control_value_accessor_1.NG_VALUE_ACCESSOR]
      }]
    }];
    return NgControlName;
  }(ng_control_1.NgControl));
  exports.NgControlName = NgControlName;
  return module.exports;
});

$__System.registerDynamic("ca", ["11", "ba", "b4", "c6", "c9", "c7", "c8"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var collection_1 = $__require('ba');
  var async_1 = $__require('b4');
  var ng_control_1 = $__require('c6');
  var validators_1 = $__require('c9');
  var control_value_accessor_1 = $__require('c7');
  var shared_1 = $__require('c8');
  exports.formControlBinding = {
    provide: ng_control_1.NgControl,
    useExisting: core_1.forwardRef(function() {
      return NgFormControl;
    })
  };
  var NgFormControl = (function(_super) {
    __extends(NgFormControl, _super);
    function NgFormControl(_validators, _asyncValidators, valueAccessors) {
      _super.call(this);
      this._validators = _validators;
      this._asyncValidators = _asyncValidators;
      this.update = new async_1.EventEmitter();
      this.valueAccessor = shared_1.selectValueAccessor(this, valueAccessors);
    }
    NgFormControl.prototype.ngOnChanges = function(changes) {
      if (this._isControlChanged(changes)) {
        shared_1.setUpControl(this.form, this);
        this.form.updateValueAndValidity({emitEvent: false});
      }
      if (shared_1.isPropertyUpdated(changes, this.viewModel)) {
        this.form.updateValue(this.model);
        this.viewModel = this.model;
      }
    };
    Object.defineProperty(NgFormControl.prototype, "path", {
      get: function() {
        return [];
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFormControl.prototype, "validator", {
      get: function() {
        return shared_1.composeValidators(this._validators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFormControl.prototype, "asyncValidator", {
      get: function() {
        return shared_1.composeAsyncValidators(this._asyncValidators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFormControl.prototype, "control", {
      get: function() {
        return this.form;
      },
      enumerable: true,
      configurable: true
    });
    NgFormControl.prototype.viewToModelUpdate = function(newValue) {
      this.viewModel = newValue;
      async_1.ObservableWrapper.callEmit(this.update, newValue);
    };
    NgFormControl.prototype._isControlChanged = function(changes) {
      return collection_1.StringMapWrapper.contains(changes, "form");
    };
    NgFormControl.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngFormControl]',
        bindings: [exports.formControlBinding],
        inputs: ['form: ngFormControl', 'model: ngModel'],
        outputs: ['update: ngModelChange'],
        exportAs: 'ngForm'
      }]
    }];
    NgFormControl.ctorParameters = [{
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [control_value_accessor_1.NG_VALUE_ACCESSOR]
      }]
    }];
    return NgFormControl;
  }(ng_control_1.NgControl));
  exports.NgFormControl = NgFormControl;
  return module.exports;
});

$__System.registerDynamic("cb", ["11", "b4", "c7", "c6", "cc", "c9", "c8"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var async_1 = $__require('b4');
  var control_value_accessor_1 = $__require('c7');
  var ng_control_1 = $__require('c6');
  var model_1 = $__require('cc');
  var validators_1 = $__require('c9');
  var shared_1 = $__require('c8');
  exports.formControlBinding = {
    provide: ng_control_1.NgControl,
    useExisting: core_1.forwardRef(function() {
      return NgModel;
    })
  };
  var NgModel = (function(_super) {
    __extends(NgModel, _super);
    function NgModel(_validators, _asyncValidators, valueAccessors) {
      _super.call(this);
      this._validators = _validators;
      this._asyncValidators = _asyncValidators;
      this._control = new model_1.Control();
      this._added = false;
      this.update = new async_1.EventEmitter();
      this.valueAccessor = shared_1.selectValueAccessor(this, valueAccessors);
    }
    NgModel.prototype.ngOnChanges = function(changes) {
      if (!this._added) {
        shared_1.setUpControl(this._control, this);
        this._control.updateValueAndValidity({emitEvent: false});
        this._added = true;
      }
      if (shared_1.isPropertyUpdated(changes, this.viewModel)) {
        this._control.updateValue(this.model);
        this.viewModel = this.model;
      }
    };
    Object.defineProperty(NgModel.prototype, "control", {
      get: function() {
        return this._control;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgModel.prototype, "path", {
      get: function() {
        return [];
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgModel.prototype, "validator", {
      get: function() {
        return shared_1.composeValidators(this._validators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgModel.prototype, "asyncValidator", {
      get: function() {
        return shared_1.composeAsyncValidators(this._asyncValidators);
      },
      enumerable: true,
      configurable: true
    });
    NgModel.prototype.viewToModelUpdate = function(newValue) {
      this.viewModel = newValue;
      async_1.ObservableWrapper.callEmit(this.update, newValue);
    };
    NgModel.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngModel]:not([ngControl]):not([ngFormControl])',
        bindings: [exports.formControlBinding],
        inputs: ['model: ngModel'],
        outputs: ['update: ngModelChange'],
        exportAs: 'ngForm'
      }]
    }];
    NgModel.ctorParameters = [{
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [control_value_accessor_1.NG_VALUE_ACCESSOR]
      }]
    }];
    return NgModel;
  }(ng_control_1.NgControl));
  exports.NgModel = NgModel;
  return module.exports;
});

$__System.registerDynamic("cd", ["11", "c5", "c8", "c9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var control_container_1 = $__require('c5');
  var shared_1 = $__require('c8');
  var validators_1 = $__require('c9');
  exports.controlGroupProvider = {
    provide: control_container_1.ControlContainer,
    useExisting: core_1.forwardRef(function() {
      return NgControlGroup;
    })
  };
  var NgControlGroup = (function(_super) {
    __extends(NgControlGroup, _super);
    function NgControlGroup(parent, _validators, _asyncValidators) {
      _super.call(this);
      this._validators = _validators;
      this._asyncValidators = _asyncValidators;
      this._parent = parent;
    }
    NgControlGroup.prototype.ngOnInit = function() {
      this.formDirective.addControlGroup(this);
    };
    NgControlGroup.prototype.ngOnDestroy = function() {
      this.formDirective.removeControlGroup(this);
    };
    Object.defineProperty(NgControlGroup.prototype, "control", {
      get: function() {
        return this.formDirective.getControlGroup(this);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlGroup.prototype, "path", {
      get: function() {
        return shared_1.controlPath(this.name, this._parent);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlGroup.prototype, "formDirective", {
      get: function() {
        return this._parent.formDirective;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlGroup.prototype, "validator", {
      get: function() {
        return shared_1.composeValidators(this._validators);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlGroup.prototype, "asyncValidator", {
      get: function() {
        return shared_1.composeAsyncValidators(this._asyncValidators);
      },
      enumerable: true,
      configurable: true
    });
    NgControlGroup.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngControlGroup]',
        providers: [exports.controlGroupProvider],
        inputs: ['name: ngControlGroup'],
        exportAs: 'ngForm'
      }]
    }];
    NgControlGroup.ctorParameters = [{
      type: control_container_1.ControlContainer,
      decorators: [{type: core_1.Host}, {type: core_1.SkipSelf}]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }];
    return NgControlGroup;
  }(control_container_1.ControlContainer));
  exports.NgControlGroup = NgControlGroup;
  return module.exports;
});

$__System.registerDynamic("ce", ["11", "b3", "ba", "be", "b4", "c5", "c8", "c9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var exceptions_1 = $__require('be');
  var async_1 = $__require('b4');
  var control_container_1 = $__require('c5');
  var shared_1 = $__require('c8');
  var validators_1 = $__require('c9');
  exports.formDirectiveProvider = {
    provide: control_container_1.ControlContainer,
    useExisting: core_1.forwardRef(function() {
      return NgFormModel;
    })
  };
  var NgFormModel = (function(_super) {
    __extends(NgFormModel, _super);
    function NgFormModel(_validators, _asyncValidators) {
      _super.call(this);
      this._validators = _validators;
      this._asyncValidators = _asyncValidators;
      this.form = null;
      this.directives = [];
      this.ngSubmit = new async_1.EventEmitter();
    }
    NgFormModel.prototype.ngOnChanges = function(changes) {
      this._checkFormPresent();
      if (collection_1.StringMapWrapper.contains(changes, "form")) {
        var sync = shared_1.composeValidators(this._validators);
        this.form.validator = validators_1.Validators.compose([this.form.validator, sync]);
        var async = shared_1.composeAsyncValidators(this._asyncValidators);
        this.form.asyncValidator = validators_1.Validators.composeAsync([this.form.asyncValidator, async]);
        this.form.updateValueAndValidity({
          onlySelf: true,
          emitEvent: false
        });
      }
      this._updateDomValue();
    };
    Object.defineProperty(NgFormModel.prototype, "formDirective", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFormModel.prototype, "control", {
      get: function() {
        return this.form;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFormModel.prototype, "path", {
      get: function() {
        return [];
      },
      enumerable: true,
      configurable: true
    });
    NgFormModel.prototype.addControl = function(dir) {
      var ctrl = this.form.find(dir.path);
      shared_1.setUpControl(ctrl, dir);
      ctrl.updateValueAndValidity({emitEvent: false});
      this.directives.push(dir);
    };
    NgFormModel.prototype.getControl = function(dir) {
      return this.form.find(dir.path);
    };
    NgFormModel.prototype.removeControl = function(dir) {
      collection_1.ListWrapper.remove(this.directives, dir);
    };
    NgFormModel.prototype.addControlGroup = function(dir) {
      var ctrl = this.form.find(dir.path);
      shared_1.setUpControlGroup(ctrl, dir);
      ctrl.updateValueAndValidity({emitEvent: false});
    };
    NgFormModel.prototype.removeControlGroup = function(dir) {};
    NgFormModel.prototype.getControlGroup = function(dir) {
      return this.form.find(dir.path);
    };
    NgFormModel.prototype.updateModel = function(dir, value) {
      var ctrl = this.form.find(dir.path);
      ctrl.updateValue(value);
    };
    NgFormModel.prototype.onSubmit = function() {
      async_1.ObservableWrapper.callEmit(this.ngSubmit, null);
      return false;
    };
    NgFormModel.prototype._updateDomValue = function() {
      var _this = this;
      this.directives.forEach(function(dir) {
        var ctrl = _this.form.find(dir.path);
        dir.valueAccessor.writeValue(ctrl.value);
      });
    };
    NgFormModel.prototype._checkFormPresent = function() {
      if (lang_1.isBlank(this.form)) {
        throw new exceptions_1.BaseException("ngFormModel expects a form. Please pass one in. Example: <form [ngFormModel]=\"myCoolForm\">");
      }
    };
    NgFormModel.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngFormModel]',
        bindings: [exports.formDirectiveProvider],
        inputs: ['form: ngFormModel'],
        host: {'(submit)': 'onSubmit()'},
        outputs: ['ngSubmit'],
        exportAs: 'ngForm'
      }]
    }];
    NgFormModel.ctorParameters = [{
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }];
    return NgFormModel;
  }(control_container_1.ControlContainer));
  exports.NgFormModel = NgFormModel;
  return module.exports;
});

$__System.registerDynamic("c5", ["cf"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var abstract_control_directive_1 = $__require('cf');
  var ControlContainer = (function(_super) {
    __extends(ControlContainer, _super);
    function ControlContainer() {
      _super.apply(this, arguments);
    }
    Object.defineProperty(ControlContainer.prototype, "formDirective", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ControlContainer.prototype, "path", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    return ControlContainer;
  }(abstract_control_directive_1.AbstractControlDirective));
  exports.ControlContainer = ControlContainer;
  return module.exports;
});

$__System.registerDynamic("d0", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function normalizeValidator(validator) {
    if (validator.validate !== undefined) {
      return function(c) {
        return validator.validate(c);
      };
    } else {
      return validator;
    }
  }
  exports.normalizeValidator = normalizeValidator;
  function normalizeAsyncValidator(validator) {
    if (validator.validate !== undefined) {
      return function(c) {
        return Promise.resolve(validator.validate(c));
      };
    } else {
      return validator;
    }
  }
  exports.normalizeAsyncValidator = normalizeAsyncValidator;
  return module.exports;
});

$__System.registerDynamic("c8", ["ba", "b3", "be", "c9", "d1", "d2", "d3", "d4", "d5", "d0"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('ba');
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var validators_1 = $__require('c9');
  var default_value_accessor_1 = $__require('d1');
  var number_value_accessor_1 = $__require('d2');
  var checkbox_value_accessor_1 = $__require('d3');
  var select_control_value_accessor_1 = $__require('d4');
  var radio_control_value_accessor_1 = $__require('d5');
  var normalize_validator_1 = $__require('d0');
  function controlPath(name, parent) {
    var p = collection_1.ListWrapper.clone(parent.path);
    p.push(name);
    return p;
  }
  exports.controlPath = controlPath;
  function setUpControl(control, dir) {
    if (lang_1.isBlank(control))
      _throwError(dir, "Cannot find control");
    if (lang_1.isBlank(dir.valueAccessor))
      _throwError(dir, "No value accessor for");
    control.validator = validators_1.Validators.compose([control.validator, dir.validator]);
    control.asyncValidator = validators_1.Validators.composeAsync([control.asyncValidator, dir.asyncValidator]);
    dir.valueAccessor.writeValue(control.value);
    dir.valueAccessor.registerOnChange(function(newValue) {
      dir.viewToModelUpdate(newValue);
      control.updateValue(newValue, {emitModelToViewChange: false});
      control.markAsDirty();
    });
    control.registerOnChange(function(newValue) {
      return dir.valueAccessor.writeValue(newValue);
    });
    dir.valueAccessor.registerOnTouched(function() {
      return control.markAsTouched();
    });
  }
  exports.setUpControl = setUpControl;
  function setUpControlGroup(control, dir) {
    if (lang_1.isBlank(control))
      _throwError(dir, "Cannot find control");
    control.validator = validators_1.Validators.compose([control.validator, dir.validator]);
    control.asyncValidator = validators_1.Validators.composeAsync([control.asyncValidator, dir.asyncValidator]);
  }
  exports.setUpControlGroup = setUpControlGroup;
  function _throwError(dir, message) {
    var path = dir.path.join(" -> ");
    throw new exceptions_1.BaseException(message + " '" + path + "'");
  }
  function composeValidators(validators) {
    return lang_1.isPresent(validators) ? validators_1.Validators.compose(validators.map(normalize_validator_1.normalizeValidator)) : null;
  }
  exports.composeValidators = composeValidators;
  function composeAsyncValidators(validators) {
    return lang_1.isPresent(validators) ? validators_1.Validators.composeAsync(validators.map(normalize_validator_1.normalizeAsyncValidator)) : null;
  }
  exports.composeAsyncValidators = composeAsyncValidators;
  function isPropertyUpdated(changes, viewModel) {
    if (!collection_1.StringMapWrapper.contains(changes, "model"))
      return false;
    var change = changes["model"];
    if (change.isFirstChange())
      return true;
    return !lang_1.looseIdentical(viewModel, change.currentValue);
  }
  exports.isPropertyUpdated = isPropertyUpdated;
  function selectValueAccessor(dir, valueAccessors) {
    if (lang_1.isBlank(valueAccessors))
      return null;
    var defaultAccessor;
    var builtinAccessor;
    var customAccessor;
    valueAccessors.forEach(function(v) {
      if (lang_1.hasConstructor(v, default_value_accessor_1.DefaultValueAccessor)) {
        defaultAccessor = v;
      } else if (lang_1.hasConstructor(v, checkbox_value_accessor_1.CheckboxControlValueAccessor) || lang_1.hasConstructor(v, number_value_accessor_1.NumberValueAccessor) || lang_1.hasConstructor(v, select_control_value_accessor_1.SelectControlValueAccessor) || lang_1.hasConstructor(v, radio_control_value_accessor_1.RadioControlValueAccessor)) {
        if (lang_1.isPresent(builtinAccessor))
          _throwError(dir, "More than one built-in value accessor matches");
        builtinAccessor = v;
      } else {
        if (lang_1.isPresent(customAccessor))
          _throwError(dir, "More than one custom value accessor matches");
        customAccessor = v;
      }
    });
    if (lang_1.isPresent(customAccessor))
      return customAccessor;
    if (lang_1.isPresent(builtinAccessor))
      return builtinAccessor;
    if (lang_1.isPresent(defaultAccessor))
      return defaultAccessor;
    _throwError(dir, "No valid value accessor for");
    return null;
  }
  exports.selectValueAccessor = selectValueAccessor;
  return module.exports;
});

$__System.registerDynamic("d6", ["11", "b4", "ba", "b3", "c5", "cc", "c8", "c9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var async_1 = $__require('b4');
  var collection_1 = $__require('ba');
  var lang_1 = $__require('b3');
  var control_container_1 = $__require('c5');
  var model_1 = $__require('cc');
  var shared_1 = $__require('c8');
  var validators_1 = $__require('c9');
  exports.formDirectiveProvider = {
    provide: control_container_1.ControlContainer,
    useExisting: core_1.forwardRef(function() {
      return NgForm;
    })
  };
  var NgForm = (function(_super) {
    __extends(NgForm, _super);
    function NgForm(validators, asyncValidators) {
      _super.call(this);
      this.ngSubmit = new async_1.EventEmitter();
      this.form = new model_1.ControlGroup({}, null, shared_1.composeValidators(validators), shared_1.composeAsyncValidators(asyncValidators));
    }
    Object.defineProperty(NgForm.prototype, "formDirective", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForm.prototype, "control", {
      get: function() {
        return this.form;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForm.prototype, "path", {
      get: function() {
        return [];
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForm.prototype, "controls", {
      get: function() {
        return this.form.controls;
      },
      enumerable: true,
      configurable: true
    });
    NgForm.prototype.addControl = function(dir) {
      var _this = this;
      async_1.PromiseWrapper.scheduleMicrotask(function() {
        var container = _this._findContainer(dir.path);
        var ctrl = new model_1.Control();
        shared_1.setUpControl(ctrl, dir);
        container.addControl(dir.name, ctrl);
        ctrl.updateValueAndValidity({emitEvent: false});
      });
    };
    NgForm.prototype.getControl = function(dir) {
      return this.form.find(dir.path);
    };
    NgForm.prototype.removeControl = function(dir) {
      var _this = this;
      async_1.PromiseWrapper.scheduleMicrotask(function() {
        var container = _this._findContainer(dir.path);
        if (lang_1.isPresent(container)) {
          container.removeControl(dir.name);
          container.updateValueAndValidity({emitEvent: false});
        }
      });
    };
    NgForm.prototype.addControlGroup = function(dir) {
      var _this = this;
      async_1.PromiseWrapper.scheduleMicrotask(function() {
        var container = _this._findContainer(dir.path);
        var group = new model_1.ControlGroup({});
        shared_1.setUpControlGroup(group, dir);
        container.addControl(dir.name, group);
        group.updateValueAndValidity({emitEvent: false});
      });
    };
    NgForm.prototype.removeControlGroup = function(dir) {
      var _this = this;
      async_1.PromiseWrapper.scheduleMicrotask(function() {
        var container = _this._findContainer(dir.path);
        if (lang_1.isPresent(container)) {
          container.removeControl(dir.name);
          container.updateValueAndValidity({emitEvent: false});
        }
      });
    };
    NgForm.prototype.getControlGroup = function(dir) {
      return this.form.find(dir.path);
    };
    NgForm.prototype.updateModel = function(dir, value) {
      var _this = this;
      async_1.PromiseWrapper.scheduleMicrotask(function() {
        var ctrl = _this.form.find(dir.path);
        ctrl.updateValue(value);
      });
    };
    NgForm.prototype.onSubmit = function() {
      async_1.ObservableWrapper.callEmit(this.ngSubmit, null);
      return false;
    };
    NgForm.prototype._findContainer = function(path) {
      path.pop();
      return collection_1.ListWrapper.isEmpty(path) ? this.form : this.form.find(path);
    };
    NgForm.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'form:not([ngNoForm]):not([ngFormModel]),ngForm,[ngForm]',
        bindings: [exports.formDirectiveProvider],
        host: {'(submit)': 'onSubmit()'},
        outputs: ['ngSubmit'],
        exportAs: 'ngForm'
      }]
    }];
    NgForm.ctorParameters = [{
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_VALIDATORS]
      }]
    }, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {type: core_1.Self}, {
        type: core_1.Inject,
        args: [validators_1.NG_ASYNC_VALIDATORS]
      }]
    }];
    return NgForm;
  }(control_container_1.ControlContainer));
  exports.NgForm = NgForm;
  return module.exports;
});

$__System.registerDynamic("d1", ["11", "b3", "c7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var control_value_accessor_1 = $__require('c7');
  exports.DEFAULT_VALUE_ACCESSOR = {
    provide: control_value_accessor_1.NG_VALUE_ACCESSOR,
    useExisting: core_1.forwardRef(function() {
      return DefaultValueAccessor;
    }),
    multi: true
  };
  var DefaultValueAccessor = (function() {
    function DefaultValueAccessor(_renderer, _elementRef) {
      this._renderer = _renderer;
      this._elementRef = _elementRef;
      this.onChange = function(_) {};
      this.onTouched = function() {};
    }
    DefaultValueAccessor.prototype.writeValue = function(value) {
      var normalizedValue = lang_1.isBlank(value) ? '' : value;
      this._renderer.setElementProperty(this._elementRef.nativeElement, 'value', normalizedValue);
    };
    DefaultValueAccessor.prototype.registerOnChange = function(fn) {
      this.onChange = fn;
    };
    DefaultValueAccessor.prototype.registerOnTouched = function(fn) {
      this.onTouched = fn;
    };
    DefaultValueAccessor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'input:not([type=checkbox])[ngControl],textarea[ngControl],input:not([type=checkbox])[ngFormControl],textarea[ngFormControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]',
        host: {
          '(input)': 'onChange($event.target.value)',
          '(blur)': 'onTouched()'
        },
        bindings: [exports.DEFAULT_VALUE_ACCESSOR]
      }]
    }];
    DefaultValueAccessor.ctorParameters = [{type: core_1.Renderer}, {type: core_1.ElementRef}];
    return DefaultValueAccessor;
  }());
  exports.DefaultValueAccessor = DefaultValueAccessor;
  return module.exports;
});

$__System.registerDynamic("d3", ["11", "c7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var control_value_accessor_1 = $__require('c7');
  exports.CHECKBOX_VALUE_ACCESSOR = {
    provide: control_value_accessor_1.NG_VALUE_ACCESSOR,
    useExisting: core_1.forwardRef(function() {
      return CheckboxControlValueAccessor;
    }),
    multi: true
  };
  var CheckboxControlValueAccessor = (function() {
    function CheckboxControlValueAccessor(_renderer, _elementRef) {
      this._renderer = _renderer;
      this._elementRef = _elementRef;
      this.onChange = function(_) {};
      this.onTouched = function() {};
    }
    CheckboxControlValueAccessor.prototype.writeValue = function(value) {
      this._renderer.setElementProperty(this._elementRef.nativeElement, 'checked', value);
    };
    CheckboxControlValueAccessor.prototype.registerOnChange = function(fn) {
      this.onChange = fn;
    };
    CheckboxControlValueAccessor.prototype.registerOnTouched = function(fn) {
      this.onTouched = fn;
    };
    CheckboxControlValueAccessor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'input[type=checkbox][ngControl],input[type=checkbox][ngFormControl],input[type=checkbox][ngModel]',
        host: {
          '(change)': 'onChange($event.target.checked)',
          '(blur)': 'onTouched()'
        },
        providers: [exports.CHECKBOX_VALUE_ACCESSOR]
      }]
    }];
    CheckboxControlValueAccessor.ctorParameters = [{type: core_1.Renderer}, {type: core_1.ElementRef}];
    return CheckboxControlValueAccessor;
  }());
  exports.CheckboxControlValueAccessor = CheckboxControlValueAccessor;
  return module.exports;
});

$__System.registerDynamic("d2", ["11", "b3", "c7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var control_value_accessor_1 = $__require('c7');
  exports.NUMBER_VALUE_ACCESSOR = {
    provide: control_value_accessor_1.NG_VALUE_ACCESSOR,
    useExisting: core_1.forwardRef(function() {
      return NumberValueAccessor;
    }),
    multi: true
  };
  var NumberValueAccessor = (function() {
    function NumberValueAccessor(_renderer, _elementRef) {
      this._renderer = _renderer;
      this._elementRef = _elementRef;
      this.onChange = function(_) {};
      this.onTouched = function() {};
    }
    NumberValueAccessor.prototype.writeValue = function(value) {
      this._renderer.setElementProperty(this._elementRef.nativeElement, 'value', value);
    };
    NumberValueAccessor.prototype.registerOnChange = function(fn) {
      this.onChange = function(value) {
        fn(value == '' ? null : lang_1.NumberWrapper.parseFloat(value));
      };
    };
    NumberValueAccessor.prototype.registerOnTouched = function(fn) {
      this.onTouched = fn;
    };
    NumberValueAccessor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'input[type=number][ngControl],input[type=number][ngFormControl],input[type=number][ngModel]',
        host: {
          '(change)': 'onChange($event.target.value)',
          '(input)': 'onChange($event.target.value)',
          '(blur)': 'onTouched()'
        },
        bindings: [exports.NUMBER_VALUE_ACCESSOR]
      }]
    }];
    NumberValueAccessor.ctorParameters = [{type: core_1.Renderer}, {type: core_1.ElementRef}];
    return NumberValueAccessor;
  }());
  exports.NumberValueAccessor = NumberValueAccessor;
  return module.exports;
});

$__System.registerDynamic("d7", ["11", "c6", "b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var ng_control_1 = $__require('c6');
  var lang_1 = $__require('b3');
  var NgControlStatus = (function() {
    function NgControlStatus(cd) {
      this._cd = cd;
    }
    Object.defineProperty(NgControlStatus.prototype, "ngClassUntouched", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? this._cd.control.untouched : false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlStatus.prototype, "ngClassTouched", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? this._cd.control.touched : false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlStatus.prototype, "ngClassPristine", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? this._cd.control.pristine : false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlStatus.prototype, "ngClassDirty", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? this._cd.control.dirty : false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlStatus.prototype, "ngClassValid", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? this._cd.control.valid : false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControlStatus.prototype, "ngClassInvalid", {
      get: function() {
        return lang_1.isPresent(this._cd.control) ? !this._cd.control.valid : false;
      },
      enumerable: true,
      configurable: true
    });
    NgControlStatus.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngControl],[ngModel],[ngFormControl]',
        host: {
          '[class.ng-untouched]': 'ngClassUntouched',
          '[class.ng-touched]': 'ngClassTouched',
          '[class.ng-pristine]': 'ngClassPristine',
          '[class.ng-dirty]': 'ngClassDirty',
          '[class.ng-valid]': 'ngClassValid',
          '[class.ng-invalid]': 'ngClassInvalid'
        }
      }]
    }];
    NgControlStatus.ctorParameters = [{
      type: ng_control_1.NgControl,
      decorators: [{type: core_1.Self}]
    }];
    return NgControlStatus;
  }());
  exports.NgControlStatus = NgControlStatus;
  return module.exports;
});

$__System.registerDynamic("d4", ["11", "b3", "ba", "c7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var control_value_accessor_1 = $__require('c7');
  exports.SELECT_VALUE_ACCESSOR = {
    provide: control_value_accessor_1.NG_VALUE_ACCESSOR,
    useExisting: core_1.forwardRef(function() {
      return SelectControlValueAccessor;
    }),
    multi: true
  };
  function _buildValueString(id, value) {
    if (lang_1.isBlank(id))
      return "" + value;
    if (!lang_1.isPrimitive(value))
      value = "Object";
    return lang_1.StringWrapper.slice(id + ": " + value, 0, 50);
  }
  function _extractId(valueString) {
    return valueString.split(":")[0];
  }
  var SelectControlValueAccessor = (function() {
    function SelectControlValueAccessor(_renderer, _elementRef) {
      this._renderer = _renderer;
      this._elementRef = _elementRef;
      this._optionMap = new Map();
      this._idCounter = 0;
      this.onChange = function(_) {};
      this.onTouched = function() {};
    }
    SelectControlValueAccessor.prototype.writeValue = function(value) {
      this.value = value;
      var valueString = _buildValueString(this._getOptionId(value), value);
      this._renderer.setElementProperty(this._elementRef.nativeElement, 'value', valueString);
    };
    SelectControlValueAccessor.prototype.registerOnChange = function(fn) {
      var _this = this;
      this.onChange = function(valueString) {
        fn(_this._getOptionValue(valueString));
      };
    };
    SelectControlValueAccessor.prototype.registerOnTouched = function(fn) {
      this.onTouched = fn;
    };
    SelectControlValueAccessor.prototype._registerOption = function() {
      return (this._idCounter++).toString();
    };
    SelectControlValueAccessor.prototype._getOptionId = function(value) {
      for (var _i = 0,
          _a = collection_1.MapWrapper.keys(this._optionMap); _i < _a.length; _i++) {
        var id = _a[_i];
        if (lang_1.looseIdentical(this._optionMap.get(id), value))
          return id;
      }
      return null;
    };
    SelectControlValueAccessor.prototype._getOptionValue = function(valueString) {
      var value = this._optionMap.get(_extractId(valueString));
      return lang_1.isPresent(value) ? value : valueString;
    };
    SelectControlValueAccessor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'select[ngControl],select[ngFormControl],select[ngModel]',
        host: {
          '(change)': 'onChange($event.target.value)',
          '(blur)': 'onTouched()'
        },
        providers: [exports.SELECT_VALUE_ACCESSOR]
      }]
    }];
    SelectControlValueAccessor.ctorParameters = [{type: core_1.Renderer}, {type: core_1.ElementRef}];
    return SelectControlValueAccessor;
  }());
  exports.SelectControlValueAccessor = SelectControlValueAccessor;
  var NgSelectOption = (function() {
    function NgSelectOption(_element, _renderer, _select) {
      this._element = _element;
      this._renderer = _renderer;
      this._select = _select;
      if (lang_1.isPresent(this._select))
        this.id = this._select._registerOption();
    }
    Object.defineProperty(NgSelectOption.prototype, "ngValue", {
      set: function(value) {
        if (this._select == null)
          return;
        this._select._optionMap.set(this.id, value);
        this._setElementValue(_buildValueString(this.id, value));
        this._select.writeValue(this._select.value);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgSelectOption.prototype, "value", {
      set: function(value) {
        this._setElementValue(value);
        if (lang_1.isPresent(this._select))
          this._select.writeValue(this._select.value);
      },
      enumerable: true,
      configurable: true
    });
    NgSelectOption.prototype._setElementValue = function(value) {
      this._renderer.setElementProperty(this._element.nativeElement, 'value', value);
    };
    NgSelectOption.prototype.ngOnDestroy = function() {
      if (lang_1.isPresent(this._select)) {
        this._select._optionMap.delete(this.id);
        this._select.writeValue(this._select.value);
      }
    };
    NgSelectOption.decorators = [{
      type: core_1.Directive,
      args: [{selector: 'option'}]
    }];
    NgSelectOption.ctorParameters = [{type: core_1.ElementRef}, {type: core_1.Renderer}, {
      type: SelectControlValueAccessor,
      decorators: [{type: core_1.Optional}, {type: core_1.Host}]
    }];
    NgSelectOption.propDecorators = {
      'ngValue': [{
        type: core_1.Input,
        args: ['ngValue']
      }],
      'value': [{
        type: core_1.Input,
        args: ['value']
      }]
    };
    return NgSelectOption;
  }());
  exports.NgSelectOption = NgSelectOption;
  return module.exports;
});

$__System.registerDynamic("d8", ["c4", "ca", "cb", "cd", "ce", "d6", "d1", "d3", "d2", "d5", "d7", "d4", "d9", "c6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ng_control_name_1 = $__require('c4');
  var ng_form_control_1 = $__require('ca');
  var ng_model_1 = $__require('cb');
  var ng_control_group_1 = $__require('cd');
  var ng_form_model_1 = $__require('ce');
  var ng_form_1 = $__require('d6');
  var default_value_accessor_1 = $__require('d1');
  var checkbox_value_accessor_1 = $__require('d3');
  var number_value_accessor_1 = $__require('d2');
  var radio_control_value_accessor_1 = $__require('d5');
  var ng_control_status_1 = $__require('d7');
  var select_control_value_accessor_1 = $__require('d4');
  var validators_1 = $__require('d9');
  var ng_control_name_2 = $__require('c4');
  exports.NgControlName = ng_control_name_2.NgControlName;
  var ng_form_control_2 = $__require('ca');
  exports.NgFormControl = ng_form_control_2.NgFormControl;
  var ng_model_2 = $__require('cb');
  exports.NgModel = ng_model_2.NgModel;
  var ng_control_group_2 = $__require('cd');
  exports.NgControlGroup = ng_control_group_2.NgControlGroup;
  var ng_form_model_2 = $__require('ce');
  exports.NgFormModel = ng_form_model_2.NgFormModel;
  var ng_form_2 = $__require('d6');
  exports.NgForm = ng_form_2.NgForm;
  var default_value_accessor_2 = $__require('d1');
  exports.DefaultValueAccessor = default_value_accessor_2.DefaultValueAccessor;
  var checkbox_value_accessor_2 = $__require('d3');
  exports.CheckboxControlValueAccessor = checkbox_value_accessor_2.CheckboxControlValueAccessor;
  var radio_control_value_accessor_2 = $__require('d5');
  exports.RadioControlValueAccessor = radio_control_value_accessor_2.RadioControlValueAccessor;
  exports.RadioButtonState = radio_control_value_accessor_2.RadioButtonState;
  var number_value_accessor_2 = $__require('d2');
  exports.NumberValueAccessor = number_value_accessor_2.NumberValueAccessor;
  var ng_control_status_2 = $__require('d7');
  exports.NgControlStatus = ng_control_status_2.NgControlStatus;
  var select_control_value_accessor_2 = $__require('d4');
  exports.SelectControlValueAccessor = select_control_value_accessor_2.SelectControlValueAccessor;
  exports.NgSelectOption = select_control_value_accessor_2.NgSelectOption;
  var validators_2 = $__require('d9');
  exports.RequiredValidator = validators_2.RequiredValidator;
  exports.MinLengthValidator = validators_2.MinLengthValidator;
  exports.MaxLengthValidator = validators_2.MaxLengthValidator;
  exports.PatternValidator = validators_2.PatternValidator;
  var ng_control_1 = $__require('c6');
  exports.NgControl = ng_control_1.NgControl;
  exports.FORM_DIRECTIVES = [ng_control_name_1.NgControlName, ng_control_group_1.NgControlGroup, ng_form_control_1.NgFormControl, ng_model_1.NgModel, ng_form_model_1.NgFormModel, ng_form_1.NgForm, select_control_value_accessor_1.NgSelectOption, default_value_accessor_1.DefaultValueAccessor, number_value_accessor_1.NumberValueAccessor, checkbox_value_accessor_1.CheckboxControlValueAccessor, select_control_value_accessor_1.SelectControlValueAccessor, radio_control_value_accessor_1.RadioControlValueAccessor, ng_control_status_1.NgControlStatus, validators_1.RequiredValidator, validators_1.MinLengthValidator, validators_1.MaxLengthValidator, validators_1.PatternValidator];
  return module.exports;
});

$__System.registerDynamic("c9", ["11", "b3", "da", "b4", "ba", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var core_1 = $__require('11');
    var lang_1 = $__require('b3');
    var promise_1 = $__require('da');
    var async_1 = $__require('b4');
    var collection_1 = $__require('ba');
    exports.NG_VALIDATORS = new core_1.OpaqueToken("NgValidators");
    exports.NG_ASYNC_VALIDATORS = new core_1.OpaqueToken("NgAsyncValidators");
    var Validators = (function() {
      function Validators() {}
      Validators.required = function(control) {
        return lang_1.isBlank(control.value) || (lang_1.isString(control.value) && control.value == "") ? {"required": true} : null;
      };
      Validators.minLength = function(minLength) {
        return function(control) {
          if (lang_1.isPresent(Validators.required(control)))
            return null;
          var v = control.value;
          return v.length < minLength ? {"minlength": {
              "requiredLength": minLength,
              "actualLength": v.length
            }} : null;
        };
      };
      Validators.maxLength = function(maxLength) {
        return function(control) {
          if (lang_1.isPresent(Validators.required(control)))
            return null;
          var v = control.value;
          return v.length > maxLength ? {"maxlength": {
              "requiredLength": maxLength,
              "actualLength": v.length
            }} : null;
        };
      };
      Validators.pattern = function(pattern) {
        return function(control) {
          if (lang_1.isPresent(Validators.required(control)))
            return null;
          var regex = new RegExp("^" + pattern + "$");
          var v = control.value;
          return regex.test(v) ? null : {"pattern": {
              "requiredPattern": "^" + pattern + "$",
              "actualValue": v
            }};
        };
      };
      Validators.nullValidator = function(c) {
        return null;
      };
      Validators.compose = function(validators) {
        if (lang_1.isBlank(validators))
          return null;
        var presentValidators = validators.filter(lang_1.isPresent);
        if (presentValidators.length == 0)
          return null;
        return function(control) {
          return _mergeErrors(_executeValidators(control, presentValidators));
        };
      };
      Validators.composeAsync = function(validators) {
        if (lang_1.isBlank(validators))
          return null;
        var presentValidators = validators.filter(lang_1.isPresent);
        if (presentValidators.length == 0)
          return null;
        return function(control) {
          var promises = _executeAsyncValidators(control, presentValidators).map(_convertToPromise);
          return promise_1.PromiseWrapper.all(promises).then(_mergeErrors);
        };
      };
      return Validators;
    }());
    exports.Validators = Validators;
    function _convertToPromise(obj) {
      return promise_1.PromiseWrapper.isPromise(obj) ? obj : async_1.ObservableWrapper.toPromise(obj);
    }
    function _executeValidators(control, validators) {
      return validators.map(function(v) {
        return v(control);
      });
    }
    function _executeAsyncValidators(control, validators) {
      return validators.map(function(v) {
        return v(control);
      });
    }
    function _mergeErrors(arrayOfErrors) {
      var res = arrayOfErrors.reduce(function(res, errors) {
        return lang_1.isPresent(errors) ? collection_1.StringMapWrapper.merge(res, errors) : res;
      }, {});
      return collection_1.StringMapWrapper.isEmpty(res) ? null : res;
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("d9", ["11", "b3", "c9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var validators_1 = $__require('c9');
  var REQUIRED = validators_1.Validators.required;
  exports.REQUIRED_VALIDATOR = {
    provide: validators_1.NG_VALIDATORS,
    useValue: REQUIRED,
    multi: true
  };
  var RequiredValidator = (function() {
    function RequiredValidator() {}
    RequiredValidator.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[required][ngControl],[required][ngFormControl],[required][ngModel]',
        providers: [exports.REQUIRED_VALIDATOR]
      }]
    }];
    return RequiredValidator;
  }());
  exports.RequiredValidator = RequiredValidator;
  exports.MIN_LENGTH_VALIDATOR = {
    provide: validators_1.NG_VALIDATORS,
    useExisting: core_1.forwardRef(function() {
      return MinLengthValidator;
    }),
    multi: true
  };
  var MinLengthValidator = (function() {
    function MinLengthValidator(minLength) {
      this._validator = validators_1.Validators.minLength(lang_1.NumberWrapper.parseInt(minLength, 10));
    }
    MinLengthValidator.prototype.validate = function(c) {
      return this._validator(c);
    };
    MinLengthValidator.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[minlength][ngControl],[minlength][ngFormControl],[minlength][ngModel]',
        providers: [exports.MIN_LENGTH_VALIDATOR]
      }]
    }];
    MinLengthValidator.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Attribute,
        args: ["minlength"]
      }]
    }];
    return MinLengthValidator;
  }());
  exports.MinLengthValidator = MinLengthValidator;
  exports.MAX_LENGTH_VALIDATOR = {
    provide: validators_1.NG_VALIDATORS,
    useExisting: core_1.forwardRef(function() {
      return MaxLengthValidator;
    }),
    multi: true
  };
  var MaxLengthValidator = (function() {
    function MaxLengthValidator(maxLength) {
      this._validator = validators_1.Validators.maxLength(lang_1.NumberWrapper.parseInt(maxLength, 10));
    }
    MaxLengthValidator.prototype.validate = function(c) {
      return this._validator(c);
    };
    MaxLengthValidator.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[maxlength][ngControl],[maxlength][ngFormControl],[maxlength][ngModel]',
        providers: [exports.MAX_LENGTH_VALIDATOR]
      }]
    }];
    MaxLengthValidator.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Attribute,
        args: ["maxlength"]
      }]
    }];
    return MaxLengthValidator;
  }());
  exports.MaxLengthValidator = MaxLengthValidator;
  exports.PATTERN_VALIDATOR = {
    provide: validators_1.NG_VALIDATORS,
    useExisting: core_1.forwardRef(function() {
      return PatternValidator;
    }),
    multi: true
  };
  var PatternValidator = (function() {
    function PatternValidator(pattern) {
      this._validator = validators_1.Validators.pattern(pattern);
    }
    PatternValidator.prototype.validate = function(c) {
      return this._validator(c);
    };
    PatternValidator.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[pattern][ngControl],[pattern][ngFormControl],[pattern][ngModel]',
        providers: [exports.PATTERN_VALIDATOR]
      }]
    }];
    PatternValidator.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Attribute,
        args: ["pattern"]
      }]
    }];
    return PatternValidator;
  }());
  exports.PatternValidator = PatternValidator;
  return module.exports;
});

$__System.registerDynamic("cc", ["b3", "b4", "da", "ba"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('b3');
  var async_1 = $__require('b4');
  var promise_1 = $__require('da');
  var collection_1 = $__require('ba');
  exports.VALID = "VALID";
  exports.INVALID = "INVALID";
  exports.PENDING = "PENDING";
  function isControl(control) {
    return control instanceof AbstractControl;
  }
  exports.isControl = isControl;
  function _find(control, path) {
    if (lang_1.isBlank(path))
      return null;
    if (!(path instanceof Array)) {
      path = path.split("/");
    }
    if (path instanceof Array && collection_1.ListWrapper.isEmpty(path))
      return null;
    return path.reduce(function(v, name) {
      if (v instanceof ControlGroup) {
        return lang_1.isPresent(v.controls[name]) ? v.controls[name] : null;
      } else if (v instanceof ControlArray) {
        var index = name;
        return lang_1.isPresent(v.at(index)) ? v.at(index) : null;
      } else {
        return null;
      }
    }, control);
  }
  function toObservable(r) {
    return promise_1.PromiseWrapper.isPromise(r) ? async_1.ObservableWrapper.fromPromise(r) : r;
  }
  var AbstractControl = (function() {
    function AbstractControl(validator, asyncValidator) {
      this.validator = validator;
      this.asyncValidator = asyncValidator;
      this._pristine = true;
      this._touched = false;
    }
    Object.defineProperty(AbstractControl.prototype, "value", {
      get: function() {
        return this._value;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "status", {
      get: function() {
        return this._status;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "valid", {
      get: function() {
        return this._status === exports.VALID;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "errors", {
      get: function() {
        return this._errors;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "pristine", {
      get: function() {
        return this._pristine;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "dirty", {
      get: function() {
        return !this.pristine;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "touched", {
      get: function() {
        return this._touched;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "untouched", {
      get: function() {
        return !this._touched;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "valueChanges", {
      get: function() {
        return this._valueChanges;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "statusChanges", {
      get: function() {
        return this._statusChanges;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControl.prototype, "pending", {
      get: function() {
        return this._status == exports.PENDING;
      },
      enumerable: true,
      configurable: true
    });
    AbstractControl.prototype.markAsTouched = function() {
      this._touched = true;
    };
    AbstractControl.prototype.markAsDirty = function(_a) {
      var onlySelf = (_a === void 0 ? {} : _a).onlySelf;
      onlySelf = lang_1.normalizeBool(onlySelf);
      this._pristine = false;
      if (lang_1.isPresent(this._parent) && !onlySelf) {
        this._parent.markAsDirty({onlySelf: onlySelf});
      }
    };
    AbstractControl.prototype.markAsPending = function(_a) {
      var onlySelf = (_a === void 0 ? {} : _a).onlySelf;
      onlySelf = lang_1.normalizeBool(onlySelf);
      this._status = exports.PENDING;
      if (lang_1.isPresent(this._parent) && !onlySelf) {
        this._parent.markAsPending({onlySelf: onlySelf});
      }
    };
    AbstractControl.prototype.setParent = function(parent) {
      this._parent = parent;
    };
    AbstractControl.prototype.updateValueAndValidity = function(_a) {
      var _b = _a === void 0 ? {} : _a,
          onlySelf = _b.onlySelf,
          emitEvent = _b.emitEvent;
      onlySelf = lang_1.normalizeBool(onlySelf);
      emitEvent = lang_1.isPresent(emitEvent) ? emitEvent : true;
      this._updateValue();
      this._errors = this._runValidator();
      this._status = this._calculateStatus();
      if (this._status == exports.VALID || this._status == exports.PENDING) {
        this._runAsyncValidator(emitEvent);
      }
      if (emitEvent) {
        async_1.ObservableWrapper.callEmit(this._valueChanges, this._value);
        async_1.ObservableWrapper.callEmit(this._statusChanges, this._status);
      }
      if (lang_1.isPresent(this._parent) && !onlySelf) {
        this._parent.updateValueAndValidity({
          onlySelf: onlySelf,
          emitEvent: emitEvent
        });
      }
    };
    AbstractControl.prototype._runValidator = function() {
      return lang_1.isPresent(this.validator) ? this.validator(this) : null;
    };
    AbstractControl.prototype._runAsyncValidator = function(emitEvent) {
      var _this = this;
      if (lang_1.isPresent(this.asyncValidator)) {
        this._status = exports.PENDING;
        this._cancelExistingSubscription();
        var obs = toObservable(this.asyncValidator(this));
        this._asyncValidationSubscription = async_1.ObservableWrapper.subscribe(obs, function(res) {
          return _this.setErrors(res, {emitEvent: emitEvent});
        });
      }
    };
    AbstractControl.prototype._cancelExistingSubscription = function() {
      if (lang_1.isPresent(this._asyncValidationSubscription)) {
        async_1.ObservableWrapper.dispose(this._asyncValidationSubscription);
      }
    };
    AbstractControl.prototype.setErrors = function(errors, _a) {
      var emitEvent = (_a === void 0 ? {} : _a).emitEvent;
      emitEvent = lang_1.isPresent(emitEvent) ? emitEvent : true;
      this._errors = errors;
      this._status = this._calculateStatus();
      if (emitEvent) {
        async_1.ObservableWrapper.callEmit(this._statusChanges, this._status);
      }
      if (lang_1.isPresent(this._parent)) {
        this._parent._updateControlsErrors();
      }
    };
    AbstractControl.prototype.find = function(path) {
      return _find(this, path);
    };
    AbstractControl.prototype.getError = function(errorCode, path) {
      if (path === void 0) {
        path = null;
      }
      var control = lang_1.isPresent(path) && !collection_1.ListWrapper.isEmpty(path) ? this.find(path) : this;
      if (lang_1.isPresent(control) && lang_1.isPresent(control._errors)) {
        return collection_1.StringMapWrapper.get(control._errors, errorCode);
      } else {
        return null;
      }
    };
    AbstractControl.prototype.hasError = function(errorCode, path) {
      if (path === void 0) {
        path = null;
      }
      return lang_1.isPresent(this.getError(errorCode, path));
    };
    Object.defineProperty(AbstractControl.prototype, "root", {
      get: function() {
        var x = this;
        while (lang_1.isPresent(x._parent)) {
          x = x._parent;
        }
        return x;
      },
      enumerable: true,
      configurable: true
    });
    AbstractControl.prototype._updateControlsErrors = function() {
      this._status = this._calculateStatus();
      if (lang_1.isPresent(this._parent)) {
        this._parent._updateControlsErrors();
      }
    };
    AbstractControl.prototype._initObservables = function() {
      this._valueChanges = new async_1.EventEmitter();
      this._statusChanges = new async_1.EventEmitter();
    };
    AbstractControl.prototype._calculateStatus = function() {
      if (lang_1.isPresent(this._errors))
        return exports.INVALID;
      if (this._anyControlsHaveStatus(exports.PENDING))
        return exports.PENDING;
      if (this._anyControlsHaveStatus(exports.INVALID))
        return exports.INVALID;
      return exports.VALID;
    };
    return AbstractControl;
  }());
  exports.AbstractControl = AbstractControl;
  var Control = (function(_super) {
    __extends(Control, _super);
    function Control(value, validator, asyncValidator) {
      if (value === void 0) {
        value = null;
      }
      if (validator === void 0) {
        validator = null;
      }
      if (asyncValidator === void 0) {
        asyncValidator = null;
      }
      _super.call(this, validator, asyncValidator);
      this._value = value;
      this.updateValueAndValidity({
        onlySelf: true,
        emitEvent: false
      });
      this._initObservables();
    }
    Control.prototype.updateValue = function(value, _a) {
      var _b = _a === void 0 ? {} : _a,
          onlySelf = _b.onlySelf,
          emitEvent = _b.emitEvent,
          emitModelToViewChange = _b.emitModelToViewChange;
      emitModelToViewChange = lang_1.isPresent(emitModelToViewChange) ? emitModelToViewChange : true;
      this._value = value;
      if (lang_1.isPresent(this._onChange) && emitModelToViewChange)
        this._onChange(this._value);
      this.updateValueAndValidity({
        onlySelf: onlySelf,
        emitEvent: emitEvent
      });
    };
    Control.prototype._updateValue = function() {};
    Control.prototype._anyControlsHaveStatus = function(status) {
      return false;
    };
    Control.prototype.registerOnChange = function(fn) {
      this._onChange = fn;
    };
    return Control;
  }(AbstractControl));
  exports.Control = Control;
  var ControlGroup = (function(_super) {
    __extends(ControlGroup, _super);
    function ControlGroup(controls, optionals, validator, asyncValidator) {
      if (optionals === void 0) {
        optionals = null;
      }
      if (validator === void 0) {
        validator = null;
      }
      if (asyncValidator === void 0) {
        asyncValidator = null;
      }
      _super.call(this, validator, asyncValidator);
      this.controls = controls;
      this._optionals = lang_1.isPresent(optionals) ? optionals : {};
      this._initObservables();
      this._setParentForControls();
      this.updateValueAndValidity({
        onlySelf: true,
        emitEvent: false
      });
    }
    ControlGroup.prototype.addControl = function(name, control) {
      this.controls[name] = control;
      control.setParent(this);
    };
    ControlGroup.prototype.removeControl = function(name) {
      collection_1.StringMapWrapper.delete(this.controls, name);
    };
    ControlGroup.prototype.include = function(controlName) {
      collection_1.StringMapWrapper.set(this._optionals, controlName, true);
      this.updateValueAndValidity();
    };
    ControlGroup.prototype.exclude = function(controlName) {
      collection_1.StringMapWrapper.set(this._optionals, controlName, false);
      this.updateValueAndValidity();
    };
    ControlGroup.prototype.contains = function(controlName) {
      var c = collection_1.StringMapWrapper.contains(this.controls, controlName);
      return c && this._included(controlName);
    };
    ControlGroup.prototype._setParentForControls = function() {
      var _this = this;
      collection_1.StringMapWrapper.forEach(this.controls, function(control, name) {
        control.setParent(_this);
      });
    };
    ControlGroup.prototype._updateValue = function() {
      this._value = this._reduceValue();
    };
    ControlGroup.prototype._anyControlsHaveStatus = function(status) {
      var _this = this;
      var res = false;
      collection_1.StringMapWrapper.forEach(this.controls, function(control, name) {
        res = res || (_this.contains(name) && control.status == status);
      });
      return res;
    };
    ControlGroup.prototype._reduceValue = function() {
      return this._reduceChildren({}, function(acc, control, name) {
        acc[name] = control.value;
        return acc;
      });
    };
    ControlGroup.prototype._reduceChildren = function(initValue, fn) {
      var _this = this;
      var res = initValue;
      collection_1.StringMapWrapper.forEach(this.controls, function(control, name) {
        if (_this._included(name)) {
          res = fn(res, control, name);
        }
      });
      return res;
    };
    ControlGroup.prototype._included = function(controlName) {
      var isOptional = collection_1.StringMapWrapper.contains(this._optionals, controlName);
      return !isOptional || collection_1.StringMapWrapper.get(this._optionals, controlName);
    };
    return ControlGroup;
  }(AbstractControl));
  exports.ControlGroup = ControlGroup;
  var ControlArray = (function(_super) {
    __extends(ControlArray, _super);
    function ControlArray(controls, validator, asyncValidator) {
      if (validator === void 0) {
        validator = null;
      }
      if (asyncValidator === void 0) {
        asyncValidator = null;
      }
      _super.call(this, validator, asyncValidator);
      this.controls = controls;
      this._initObservables();
      this._setParentForControls();
      this.updateValueAndValidity({
        onlySelf: true,
        emitEvent: false
      });
    }
    ControlArray.prototype.at = function(index) {
      return this.controls[index];
    };
    ControlArray.prototype.push = function(control) {
      this.controls.push(control);
      control.setParent(this);
      this.updateValueAndValidity();
    };
    ControlArray.prototype.insert = function(index, control) {
      collection_1.ListWrapper.insert(this.controls, index, control);
      control.setParent(this);
      this.updateValueAndValidity();
    };
    ControlArray.prototype.removeAt = function(index) {
      collection_1.ListWrapper.removeAt(this.controls, index);
      this.updateValueAndValidity();
    };
    Object.defineProperty(ControlArray.prototype, "length", {
      get: function() {
        return this.controls.length;
      },
      enumerable: true,
      configurable: true
    });
    ControlArray.prototype._updateValue = function() {
      this._value = this.controls.map(function(control) {
        return control.value;
      });
    };
    ControlArray.prototype._anyControlsHaveStatus = function(status) {
      return this.controls.some(function(c) {
        return c.status == status;
      });
    };
    ControlArray.prototype._setParentForControls = function() {
      var _this = this;
      this.controls.forEach(function(control) {
        control.setParent(_this);
      });
    };
    return ControlArray;
  }(AbstractControl));
  exports.ControlArray = ControlArray;
  return module.exports;
});

$__System.registerDynamic("db", ["11", "ba", "b3", "cc"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var collection_1 = $__require('ba');
  var lang_1 = $__require('b3');
  var modelModule = $__require('cc');
  var FormBuilder = (function() {
    function FormBuilder() {}
    FormBuilder.prototype.group = function(controlsConfig, extra) {
      if (extra === void 0) {
        extra = null;
      }
      var controls = this._reduceControls(controlsConfig);
      var optionals = (lang_1.isPresent(extra) ? collection_1.StringMapWrapper.get(extra, "optionals") : null);
      var validator = lang_1.isPresent(extra) ? collection_1.StringMapWrapper.get(extra, "validator") : null;
      var asyncValidator = lang_1.isPresent(extra) ? collection_1.StringMapWrapper.get(extra, "asyncValidator") : null;
      return new modelModule.ControlGroup(controls, optionals, validator, asyncValidator);
    };
    FormBuilder.prototype.control = function(value, validator, asyncValidator) {
      if (validator === void 0) {
        validator = null;
      }
      if (asyncValidator === void 0) {
        asyncValidator = null;
      }
      return new modelModule.Control(value, validator, asyncValidator);
    };
    FormBuilder.prototype.array = function(controlsConfig, validator, asyncValidator) {
      var _this = this;
      if (validator === void 0) {
        validator = null;
      }
      if (asyncValidator === void 0) {
        asyncValidator = null;
      }
      var controls = controlsConfig.map(function(c) {
        return _this._createControl(c);
      });
      return new modelModule.ControlArray(controls, validator, asyncValidator);
    };
    FormBuilder.prototype._reduceControls = function(controlsConfig) {
      var _this = this;
      var controls = {};
      collection_1.StringMapWrapper.forEach(controlsConfig, function(controlConfig, controlName) {
        controls[controlName] = _this._createControl(controlConfig);
      });
      return controls;
    };
    FormBuilder.prototype._createControl = function(controlConfig) {
      if (controlConfig instanceof modelModule.Control || controlConfig instanceof modelModule.ControlGroup || controlConfig instanceof modelModule.ControlArray) {
        return controlConfig;
      } else if (lang_1.isArray(controlConfig)) {
        var value = controlConfig[0];
        var validator = controlConfig.length > 1 ? controlConfig[1] : null;
        var asyncValidator = controlConfig.length > 2 ? controlConfig[2] : null;
        return this.control(value, validator, asyncValidator);
      } else {
        return this.control(controlConfig);
      }
    };
    FormBuilder.decorators = [{type: core_1.Injectable}];
    return FormBuilder;
  }());
  exports.FormBuilder = FormBuilder;
  return module.exports;
});

$__System.registerDynamic("c7", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  exports.NG_VALUE_ACCESSOR = new core_1.OpaqueToken("NgValueAccessor");
  return module.exports;
});

$__System.registerDynamic("cf", ["b3", "be"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var AbstractControlDirective = (function() {
    function AbstractControlDirective() {}
    Object.defineProperty(AbstractControlDirective.prototype, "control", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "value", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.value : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "valid", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.valid : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "errors", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.errors : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "pristine", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.pristine : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "dirty", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.dirty : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "touched", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.touched : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "untouched", {
      get: function() {
        return lang_1.isPresent(this.control) ? this.control.untouched : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AbstractControlDirective.prototype, "path", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    return AbstractControlDirective;
  }());
  exports.AbstractControlDirective = AbstractControlDirective;
  return module.exports;
});

$__System.registerDynamic("c6", ["be", "cf"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var exceptions_1 = $__require('be');
  var abstract_control_directive_1 = $__require('cf');
  var NgControl = (function(_super) {
    __extends(NgControl, _super);
    function NgControl() {
      _super.apply(this, arguments);
      this.name = null;
      this.valueAccessor = null;
    }
    Object.defineProperty(NgControl.prototype, "validator", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgControl.prototype, "asyncValidator", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return NgControl;
  }(abstract_control_directive_1.AbstractControlDirective));
  exports.NgControl = NgControl;
  return module.exports;
});

$__System.registerDynamic("d5", ["11", "b3", "ba", "c7", "c6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var control_value_accessor_1 = $__require('c7');
  var ng_control_1 = $__require('c6');
  exports.RADIO_VALUE_ACCESSOR = {
    provide: control_value_accessor_1.NG_VALUE_ACCESSOR,
    useExisting: core_1.forwardRef(function() {
      return RadioControlValueAccessor;
    }),
    multi: true
  };
  var RadioControlRegistry = (function() {
    function RadioControlRegistry() {
      this._accessors = [];
    }
    RadioControlRegistry.prototype.add = function(control, accessor) {
      this._accessors.push([control, accessor]);
    };
    RadioControlRegistry.prototype.remove = function(accessor) {
      var indexToRemove = -1;
      for (var i = 0; i < this._accessors.length; ++i) {
        if (this._accessors[i][1] === accessor) {
          indexToRemove = i;
        }
      }
      collection_1.ListWrapper.removeAt(this._accessors, indexToRemove);
    };
    RadioControlRegistry.prototype.select = function(accessor) {
      this._accessors.forEach(function(c) {
        if (c[0].control.root === accessor._control.control.root && c[1] !== accessor) {
          c[1].fireUncheck();
        }
      });
    };
    RadioControlRegistry.decorators = [{type: core_1.Injectable}];
    return RadioControlRegistry;
  }());
  exports.RadioControlRegistry = RadioControlRegistry;
  var RadioButtonState = (function() {
    function RadioButtonState(checked, value) {
      this.checked = checked;
      this.value = value;
    }
    return RadioButtonState;
  }());
  exports.RadioButtonState = RadioButtonState;
  var RadioControlValueAccessor = (function() {
    function RadioControlValueAccessor(_renderer, _elementRef, _registry, _injector) {
      this._renderer = _renderer;
      this._elementRef = _elementRef;
      this._registry = _registry;
      this._injector = _injector;
      this.onChange = function() {};
      this.onTouched = function() {};
    }
    RadioControlValueAccessor.prototype.ngOnInit = function() {
      this._control = this._injector.get(ng_control_1.NgControl);
      this._registry.add(this._control, this);
    };
    RadioControlValueAccessor.prototype.ngOnDestroy = function() {
      this._registry.remove(this);
    };
    RadioControlValueAccessor.prototype.writeValue = function(value) {
      this._state = value;
      if (lang_1.isPresent(value) && value.checked) {
        this._renderer.setElementProperty(this._elementRef.nativeElement, 'checked', true);
      }
    };
    RadioControlValueAccessor.prototype.registerOnChange = function(fn) {
      var _this = this;
      this._fn = fn;
      this.onChange = function() {
        fn(new RadioButtonState(true, _this._state.value));
        _this._registry.select(_this);
      };
    };
    RadioControlValueAccessor.prototype.fireUncheck = function() {
      this._fn(new RadioButtonState(false, this._state.value));
    };
    RadioControlValueAccessor.prototype.registerOnTouched = function(fn) {
      this.onTouched = fn;
    };
    RadioControlValueAccessor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: 'input[type=radio][ngControl],input[type=radio][ngFormControl],input[type=radio][ngModel]',
        host: {
          '(change)': 'onChange()',
          '(blur)': 'onTouched()'
        },
        providers: [exports.RADIO_VALUE_ACCESSOR]
      }]
    }];
    RadioControlValueAccessor.ctorParameters = [{type: core_1.Renderer}, {type: core_1.ElementRef}, {type: RadioControlRegistry}, {type: core_1.Injector}];
    RadioControlValueAccessor.propDecorators = {'name': [{type: core_1.Input}]};
    return RadioControlValueAccessor;
  }());
  exports.RadioControlValueAccessor = RadioControlValueAccessor;
  return module.exports;
});

$__System.registerDynamic("dc", ["cc", "cf", "c5", "c4", "ca", "cb", "c6", "cd", "ce", "d6", "c7", "d1", "d7", "d3", "d4", "d8", "c9", "d9", "db", "d5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var model_1 = $__require('cc');
  exports.AbstractControl = model_1.AbstractControl;
  exports.Control = model_1.Control;
  exports.ControlGroup = model_1.ControlGroup;
  exports.ControlArray = model_1.ControlArray;
  var abstract_control_directive_1 = $__require('cf');
  exports.AbstractControlDirective = abstract_control_directive_1.AbstractControlDirective;
  var control_container_1 = $__require('c5');
  exports.ControlContainer = control_container_1.ControlContainer;
  var ng_control_name_1 = $__require('c4');
  exports.NgControlName = ng_control_name_1.NgControlName;
  var ng_form_control_1 = $__require('ca');
  exports.NgFormControl = ng_form_control_1.NgFormControl;
  var ng_model_1 = $__require('cb');
  exports.NgModel = ng_model_1.NgModel;
  var ng_control_1 = $__require('c6');
  exports.NgControl = ng_control_1.NgControl;
  var ng_control_group_1 = $__require('cd');
  exports.NgControlGroup = ng_control_group_1.NgControlGroup;
  var ng_form_model_1 = $__require('ce');
  exports.NgFormModel = ng_form_model_1.NgFormModel;
  var ng_form_1 = $__require('d6');
  exports.NgForm = ng_form_1.NgForm;
  var control_value_accessor_1 = $__require('c7');
  exports.NG_VALUE_ACCESSOR = control_value_accessor_1.NG_VALUE_ACCESSOR;
  var default_value_accessor_1 = $__require('d1');
  exports.DefaultValueAccessor = default_value_accessor_1.DefaultValueAccessor;
  var ng_control_status_1 = $__require('d7');
  exports.NgControlStatus = ng_control_status_1.NgControlStatus;
  var checkbox_value_accessor_1 = $__require('d3');
  exports.CheckboxControlValueAccessor = checkbox_value_accessor_1.CheckboxControlValueAccessor;
  var select_control_value_accessor_1 = $__require('d4');
  exports.NgSelectOption = select_control_value_accessor_1.NgSelectOption;
  exports.SelectControlValueAccessor = select_control_value_accessor_1.SelectControlValueAccessor;
  var directives_1 = $__require('d8');
  exports.FORM_DIRECTIVES = directives_1.FORM_DIRECTIVES;
  exports.RadioButtonState = directives_1.RadioButtonState;
  var validators_1 = $__require('c9');
  exports.NG_VALIDATORS = validators_1.NG_VALIDATORS;
  exports.NG_ASYNC_VALIDATORS = validators_1.NG_ASYNC_VALIDATORS;
  exports.Validators = validators_1.Validators;
  var validators_2 = $__require('d9');
  exports.RequiredValidator = validators_2.RequiredValidator;
  exports.MinLengthValidator = validators_2.MinLengthValidator;
  exports.MaxLengthValidator = validators_2.MaxLengthValidator;
  exports.PatternValidator = validators_2.PatternValidator;
  var form_builder_1 = $__require('db');
  exports.FormBuilder = form_builder_1.FormBuilder;
  var form_builder_2 = $__require('db');
  var radio_control_value_accessor_1 = $__require('d5');
  exports.FORM_PROVIDERS = [form_builder_2.FormBuilder, radio_control_value_accessor_1.RadioControlRegistry];
  exports.FORM_BINDINGS = exports.FORM_PROVIDERS;
  return module.exports;
});

$__System.registerDynamic("dd", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  return module.exports;
});

$__System.registerDynamic("de", ["11", "b3", "ba"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var NgClass = (function() {
    function NgClass(_iterableDiffers, _keyValueDiffers, _ngEl, _renderer) {
      this._iterableDiffers = _iterableDiffers;
      this._keyValueDiffers = _keyValueDiffers;
      this._ngEl = _ngEl;
      this._renderer = _renderer;
      this._initialClasses = [];
    }
    Object.defineProperty(NgClass.prototype, "initialClasses", {
      set: function(v) {
        this._applyInitialClasses(true);
        this._initialClasses = lang_1.isPresent(v) && lang_1.isString(v) ? v.split(' ') : [];
        this._applyInitialClasses(false);
        this._applyClasses(this._rawClass, false);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgClass.prototype, "rawClass", {
      set: function(v) {
        this._cleanupClasses(this._rawClass);
        if (lang_1.isString(v)) {
          v = v.split(' ');
        }
        this._rawClass = v;
        this._iterableDiffer = null;
        this._keyValueDiffer = null;
        if (lang_1.isPresent(v)) {
          if (collection_1.isListLikeIterable(v)) {
            this._iterableDiffer = this._iterableDiffers.find(v).create(null);
          } else {
            this._keyValueDiffer = this._keyValueDiffers.find(v).create(null);
          }
        }
      },
      enumerable: true,
      configurable: true
    });
    NgClass.prototype.ngDoCheck = function() {
      if (lang_1.isPresent(this._iterableDiffer)) {
        var changes = this._iterableDiffer.diff(this._rawClass);
        if (lang_1.isPresent(changes)) {
          this._applyIterableChanges(changes);
        }
      }
      if (lang_1.isPresent(this._keyValueDiffer)) {
        var changes = this._keyValueDiffer.diff(this._rawClass);
        if (lang_1.isPresent(changes)) {
          this._applyKeyValueChanges(changes);
        }
      }
    };
    NgClass.prototype.ngOnDestroy = function() {
      this._cleanupClasses(this._rawClass);
    };
    NgClass.prototype._cleanupClasses = function(rawClassVal) {
      this._applyClasses(rawClassVal, true);
      this._applyInitialClasses(false);
    };
    NgClass.prototype._applyKeyValueChanges = function(changes) {
      var _this = this;
      changes.forEachAddedItem(function(record) {
        _this._toggleClass(record.key, record.currentValue);
      });
      changes.forEachChangedItem(function(record) {
        _this._toggleClass(record.key, record.currentValue);
      });
      changes.forEachRemovedItem(function(record) {
        if (record.previousValue) {
          _this._toggleClass(record.key, false);
        }
      });
    };
    NgClass.prototype._applyIterableChanges = function(changes) {
      var _this = this;
      changes.forEachAddedItem(function(record) {
        _this._toggleClass(record.item, true);
      });
      changes.forEachRemovedItem(function(record) {
        _this._toggleClass(record.item, false);
      });
    };
    NgClass.prototype._applyInitialClasses = function(isCleanup) {
      var _this = this;
      this._initialClasses.forEach(function(className) {
        return _this._toggleClass(className, !isCleanup);
      });
    };
    NgClass.prototype._applyClasses = function(rawClassVal, isCleanup) {
      var _this = this;
      if (lang_1.isPresent(rawClassVal)) {
        if (lang_1.isArray(rawClassVal)) {
          rawClassVal.forEach(function(className) {
            return _this._toggleClass(className, !isCleanup);
          });
        } else if (rawClassVal instanceof Set) {
          rawClassVal.forEach(function(className) {
            return _this._toggleClass(className, !isCleanup);
          });
        } else {
          collection_1.StringMapWrapper.forEach(rawClassVal, function(expVal, className) {
            if (lang_1.isPresent(expVal))
              _this._toggleClass(className, !isCleanup);
          });
        }
      }
    };
    NgClass.prototype._toggleClass = function(className, enabled) {
      className = className.trim();
      if (className.length > 0) {
        if (className.indexOf(' ') > -1) {
          var classes = className.split(/\s+/g);
          for (var i = 0,
              len = classes.length; i < len; i++) {
            this._renderer.setElementClass(this._ngEl.nativeElement, classes[i], enabled);
          }
        } else {
          this._renderer.setElementClass(this._ngEl.nativeElement, className, enabled);
        }
      }
    };
    NgClass.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngClass]',
        inputs: ['rawClass: ngClass', 'initialClasses: class']
      }]
    }];
    NgClass.ctorParameters = [{type: core_1.IterableDiffers}, {type: core_1.KeyValueDiffers}, {type: core_1.ElementRef}, {type: core_1.Renderer}];
    return NgClass;
  }());
  exports.NgClass = NgClass;
  return module.exports;
});

$__System.registerDynamic("df", ["11", "b3", "be"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var NgForRow = (function() {
    function NgForRow($implicit, index, count) {
      this.$implicit = $implicit;
      this.index = index;
      this.count = count;
    }
    Object.defineProperty(NgForRow.prototype, "first", {
      get: function() {
        return this.index === 0;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForRow.prototype, "last", {
      get: function() {
        return this.index === this.count - 1;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForRow.prototype, "even", {
      get: function() {
        return this.index % 2 === 0;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgForRow.prototype, "odd", {
      get: function() {
        return !this.even;
      },
      enumerable: true,
      configurable: true
    });
    return NgForRow;
  }());
  exports.NgForRow = NgForRow;
  var NgFor = (function() {
    function NgFor(_viewContainer, _templateRef, _iterableDiffers, _cdr) {
      this._viewContainer = _viewContainer;
      this._templateRef = _templateRef;
      this._iterableDiffers = _iterableDiffers;
      this._cdr = _cdr;
    }
    Object.defineProperty(NgFor.prototype, "ngForOf", {
      set: function(value) {
        this._ngForOf = value;
        if (lang_1.isBlank(this._differ) && lang_1.isPresent(value)) {
          try {
            this._differ = this._iterableDiffers.find(value).create(this._cdr, this._ngForTrackBy);
          } catch (e) {
            throw new exceptions_1.BaseException("Cannot find a differ supporting object '" + value + "' of type '" + lang_1.getTypeNameForDebugging(value) + "'. NgFor only supports binding to Iterables such as Arrays.");
          }
        }
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFor.prototype, "ngForTemplate", {
      set: function(value) {
        if (lang_1.isPresent(value)) {
          this._templateRef = value;
        }
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(NgFor.prototype, "ngForTrackBy", {
      set: function(value) {
        this._ngForTrackBy = value;
      },
      enumerable: true,
      configurable: true
    });
    NgFor.prototype.ngDoCheck = function() {
      if (lang_1.isPresent(this._differ)) {
        var changes = this._differ.diff(this._ngForOf);
        if (lang_1.isPresent(changes))
          this._applyChanges(changes);
      }
    };
    NgFor.prototype._applyChanges = function(changes) {
      var _this = this;
      var recordViewTuples = [];
      changes.forEachRemovedItem(function(removedRecord) {
        return recordViewTuples.push(new RecordViewTuple(removedRecord, null));
      });
      changes.forEachMovedItem(function(movedRecord) {
        return recordViewTuples.push(new RecordViewTuple(movedRecord, null));
      });
      var insertTuples = this._bulkRemove(recordViewTuples);
      changes.forEachAddedItem(function(addedRecord) {
        return insertTuples.push(new RecordViewTuple(addedRecord, null));
      });
      this._bulkInsert(insertTuples);
      for (var i = 0; i < insertTuples.length; i++) {
        this._perViewChange(insertTuples[i].view, insertTuples[i].record);
      }
      for (var i = 0,
          ilen = this._viewContainer.length; i < ilen; i++) {
        var viewRef = this._viewContainer.get(i);
        viewRef.context.index = i;
        viewRef.context.count = ilen;
      }
      changes.forEachIdentityChange(function(record) {
        var viewRef = _this._viewContainer.get(record.currentIndex);
        viewRef.context.$implicit = record.item;
      });
    };
    NgFor.prototype._perViewChange = function(view, record) {
      view.context.$implicit = record.item;
    };
    NgFor.prototype._bulkRemove = function(tuples) {
      tuples.sort(function(a, b) {
        return a.record.previousIndex - b.record.previousIndex;
      });
      var movedTuples = [];
      for (var i = tuples.length - 1; i >= 0; i--) {
        var tuple = tuples[i];
        if (lang_1.isPresent(tuple.record.currentIndex)) {
          tuple.view = this._viewContainer.detach(tuple.record.previousIndex);
          movedTuples.push(tuple);
        } else {
          this._viewContainer.remove(tuple.record.previousIndex);
        }
      }
      return movedTuples;
    };
    NgFor.prototype._bulkInsert = function(tuples) {
      tuples.sort(function(a, b) {
        return a.record.currentIndex - b.record.currentIndex;
      });
      for (var i = 0; i < tuples.length; i++) {
        var tuple = tuples[i];
        if (lang_1.isPresent(tuple.view)) {
          this._viewContainer.insert(tuple.view, tuple.record.currentIndex);
        } else {
          tuple.view = this._viewContainer.createEmbeddedView(this._templateRef, new NgForRow(null, null, null), tuple.record.currentIndex);
        }
      }
      return tuples;
    };
    NgFor.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngFor][ngForOf]',
        inputs: ['ngForTrackBy', 'ngForOf', 'ngForTemplate']
      }]
    }];
    NgFor.ctorParameters = [{type: core_1.ViewContainerRef}, {type: core_1.TemplateRef}, {type: core_1.IterableDiffers}, {type: core_1.ChangeDetectorRef}];
    return NgFor;
  }());
  exports.NgFor = NgFor;
  var RecordViewTuple = (function() {
    function RecordViewTuple(record, view) {
      this.record = record;
      this.view = view;
    }
    return RecordViewTuple;
  }());
  return module.exports;
});

$__System.registerDynamic("e0", ["11", "b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var NgIf = (function() {
    function NgIf(_viewContainer, _templateRef) {
      this._viewContainer = _viewContainer;
      this._templateRef = _templateRef;
      this._prevCondition = null;
    }
    Object.defineProperty(NgIf.prototype, "ngIf", {
      set: function(newCondition) {
        if (newCondition && (lang_1.isBlank(this._prevCondition) || !this._prevCondition)) {
          this._prevCondition = true;
          this._viewContainer.createEmbeddedView(this._templateRef);
        } else if (!newCondition && (lang_1.isBlank(this._prevCondition) || this._prevCondition)) {
          this._prevCondition = false;
          this._viewContainer.clear();
        }
      },
      enumerable: true,
      configurable: true
    });
    NgIf.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngIf]',
        inputs: ['ngIf']
      }]
    }];
    NgIf.ctorParameters = [{type: core_1.ViewContainerRef}, {type: core_1.TemplateRef}];
    return NgIf;
  }());
  exports.NgIf = NgIf;
  return module.exports;
});

$__System.registerDynamic("e1", ["11", "b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var NgTemplateOutlet = (function() {
    function NgTemplateOutlet(_viewContainerRef) {
      this._viewContainerRef = _viewContainerRef;
    }
    Object.defineProperty(NgTemplateOutlet.prototype, "ngTemplateOutlet", {
      set: function(templateRef) {
        if (lang_1.isPresent(this._insertedViewRef)) {
          this._viewContainerRef.remove(this._viewContainerRef.indexOf(this._insertedViewRef));
        }
        if (lang_1.isPresent(templateRef)) {
          this._insertedViewRef = this._viewContainerRef.createEmbeddedView(templateRef);
        }
      },
      enumerable: true,
      configurable: true
    });
    NgTemplateOutlet.decorators = [{
      type: core_1.Directive,
      args: [{selector: '[ngTemplateOutlet]'}]
    }];
    NgTemplateOutlet.ctorParameters = [{type: core_1.ViewContainerRef}];
    NgTemplateOutlet.propDecorators = {'ngTemplateOutlet': [{type: core_1.Input}]};
    return NgTemplateOutlet;
  }());
  exports.NgTemplateOutlet = NgTemplateOutlet;
  return module.exports;
});

$__System.registerDynamic("e2", ["11", "b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var NgStyle = (function() {
    function NgStyle(_differs, _ngEl, _renderer) {
      this._differs = _differs;
      this._ngEl = _ngEl;
      this._renderer = _renderer;
    }
    Object.defineProperty(NgStyle.prototype, "rawStyle", {
      set: function(v) {
        this._rawStyle = v;
        if (lang_1.isBlank(this._differ) && lang_1.isPresent(v)) {
          this._differ = this._differs.find(this._rawStyle).create(null);
        }
      },
      enumerable: true,
      configurable: true
    });
    NgStyle.prototype.ngDoCheck = function() {
      if (lang_1.isPresent(this._differ)) {
        var changes = this._differ.diff(this._rawStyle);
        if (lang_1.isPresent(changes)) {
          this._applyChanges(changes);
        }
      }
    };
    NgStyle.prototype._applyChanges = function(changes) {
      var _this = this;
      changes.forEachAddedItem(function(record) {
        _this._setStyle(record.key, record.currentValue);
      });
      changes.forEachChangedItem(function(record) {
        _this._setStyle(record.key, record.currentValue);
      });
      changes.forEachRemovedItem(function(record) {
        _this._setStyle(record.key, null);
      });
    };
    NgStyle.prototype._setStyle = function(name, val) {
      this._renderer.setElementStyle(this._ngEl.nativeElement, name, val);
    };
    NgStyle.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngStyle]',
        inputs: ['rawStyle: ngStyle']
      }]
    }];
    NgStyle.ctorParameters = [{type: core_1.KeyValueDiffers}, {type: core_1.ElementRef}, {type: core_1.Renderer}];
    return NgStyle;
  }());
  exports.NgStyle = NgStyle;
  return module.exports;
});

$__System.registerDynamic("e3", ["11", "b3", "ba"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var _WHEN_DEFAULT = new Object();
  var SwitchView = (function() {
    function SwitchView(_viewContainerRef, _templateRef) {
      this._viewContainerRef = _viewContainerRef;
      this._templateRef = _templateRef;
    }
    SwitchView.prototype.create = function() {
      this._viewContainerRef.createEmbeddedView(this._templateRef);
    };
    SwitchView.prototype.destroy = function() {
      this._viewContainerRef.clear();
    };
    return SwitchView;
  }());
  exports.SwitchView = SwitchView;
  var NgSwitch = (function() {
    function NgSwitch() {
      this._useDefault = false;
      this._valueViews = new collection_1.Map();
      this._activeViews = [];
    }
    Object.defineProperty(NgSwitch.prototype, "ngSwitch", {
      set: function(value) {
        this._emptyAllActiveViews();
        this._useDefault = false;
        var views = this._valueViews.get(value);
        if (lang_1.isBlank(views)) {
          this._useDefault = true;
          views = lang_1.normalizeBlank(this._valueViews.get(_WHEN_DEFAULT));
        }
        this._activateViews(views);
        this._switchValue = value;
      },
      enumerable: true,
      configurable: true
    });
    NgSwitch.prototype._onWhenValueChanged = function(oldWhen, newWhen, view) {
      this._deregisterView(oldWhen, view);
      this._registerView(newWhen, view);
      if (oldWhen === this._switchValue) {
        view.destroy();
        collection_1.ListWrapper.remove(this._activeViews, view);
      } else if (newWhen === this._switchValue) {
        if (this._useDefault) {
          this._useDefault = false;
          this._emptyAllActiveViews();
        }
        view.create();
        this._activeViews.push(view);
      }
      if (this._activeViews.length === 0 && !this._useDefault) {
        this._useDefault = true;
        this._activateViews(this._valueViews.get(_WHEN_DEFAULT));
      }
    };
    NgSwitch.prototype._emptyAllActiveViews = function() {
      var activeContainers = this._activeViews;
      for (var i = 0; i < activeContainers.length; i++) {
        activeContainers[i].destroy();
      }
      this._activeViews = [];
    };
    NgSwitch.prototype._activateViews = function(views) {
      if (lang_1.isPresent(views)) {
        for (var i = 0; i < views.length; i++) {
          views[i].create();
        }
        this._activeViews = views;
      }
    };
    NgSwitch.prototype._registerView = function(value, view) {
      var views = this._valueViews.get(value);
      if (lang_1.isBlank(views)) {
        views = [];
        this._valueViews.set(value, views);
      }
      views.push(view);
    };
    NgSwitch.prototype._deregisterView = function(value, view) {
      if (value === _WHEN_DEFAULT)
        return;
      var views = this._valueViews.get(value);
      if (views.length == 1) {
        this._valueViews.delete(value);
      } else {
        collection_1.ListWrapper.remove(views, view);
      }
    };
    NgSwitch.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngSwitch]',
        inputs: ['ngSwitch']
      }]
    }];
    return NgSwitch;
  }());
  exports.NgSwitch = NgSwitch;
  var NgSwitchWhen = (function() {
    function NgSwitchWhen(viewContainer, templateRef, ngSwitch) {
      this._value = _WHEN_DEFAULT;
      this._switch = ngSwitch;
      this._view = new SwitchView(viewContainer, templateRef);
    }
    Object.defineProperty(NgSwitchWhen.prototype, "ngSwitchWhen", {
      set: function(value) {
        this._switch._onWhenValueChanged(this._value, value, this._view);
        this._value = value;
      },
      enumerable: true,
      configurable: true
    });
    NgSwitchWhen.decorators = [{
      type: core_1.Directive,
      args: [{
        selector: '[ngSwitchWhen]',
        inputs: ['ngSwitchWhen']
      }]
    }];
    NgSwitchWhen.ctorParameters = [{type: core_1.ViewContainerRef}, {type: core_1.TemplateRef}, {
      type: NgSwitch,
      decorators: [{type: core_1.Host}]
    }];
    return NgSwitchWhen;
  }());
  exports.NgSwitchWhen = NgSwitchWhen;
  var NgSwitchDefault = (function() {
    function NgSwitchDefault(viewContainer, templateRef, sswitch) {
      sswitch._registerView(_WHEN_DEFAULT, new SwitchView(viewContainer, templateRef));
    }
    NgSwitchDefault.decorators = [{
      type: core_1.Directive,
      args: [{selector: '[ngSwitchDefault]'}]
    }];
    NgSwitchDefault.ctorParameters = [{type: core_1.ViewContainerRef}, {type: core_1.TemplateRef}, {
      type: NgSwitch,
      decorators: [{type: core_1.Host}]
    }];
    return NgSwitchDefault;
  }());
  exports.NgSwitchDefault = NgSwitchDefault;
  return module.exports;
});

$__System.registerDynamic("e4", ["11", "b3", "ba", "e3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var collection_1 = $__require('ba');
  var ng_switch_1 = $__require('e3');
  var _CATEGORY_DEFAULT = 'other';
  var NgLocalization = (function() {
    function NgLocalization() {}
    return NgLocalization;
  }());
  exports.NgLocalization = NgLocalization;
  var NgPluralCase = (function() {
    function NgPluralCase(value, template, viewContainer) {
      this.value = value;
      this._view = new ng_switch_1.SwitchView(viewContainer, template);
    }
    NgPluralCase.decorators = [{
      type: core_1.Directive,
      args: [{selector: '[ngPluralCase]'}]
    }];
    NgPluralCase.ctorParameters = [{
      type: undefined,
      decorators: [{
        type: core_1.Attribute,
        args: ['ngPluralCase']
      }]
    }, {type: core_1.TemplateRef}, {type: core_1.ViewContainerRef}];
    return NgPluralCase;
  }());
  exports.NgPluralCase = NgPluralCase;
  var NgPlural = (function() {
    function NgPlural(_localization) {
      this._localization = _localization;
      this._caseViews = new collection_1.Map();
      this.cases = null;
    }
    Object.defineProperty(NgPlural.prototype, "ngPlural", {
      set: function(value) {
        this._switchValue = value;
        this._updateView();
      },
      enumerable: true,
      configurable: true
    });
    NgPlural.prototype.ngAfterContentInit = function() {
      var _this = this;
      this.cases.forEach(function(pluralCase) {
        _this._caseViews.set(_this._formatValue(pluralCase), pluralCase._view);
      });
      this._updateView();
    };
    NgPlural.prototype._updateView = function() {
      this._clearViews();
      var view = this._caseViews.get(this._switchValue);
      if (!lang_1.isPresent(view))
        view = this._getCategoryView(this._switchValue);
      this._activateView(view);
    };
    NgPlural.prototype._clearViews = function() {
      if (lang_1.isPresent(this._activeView))
        this._activeView.destroy();
    };
    NgPlural.prototype._activateView = function(view) {
      if (!lang_1.isPresent(view))
        return;
      this._activeView = view;
      this._activeView.create();
    };
    NgPlural.prototype._getCategoryView = function(value) {
      var category = this._localization.getPluralCategory(value);
      var categoryView = this._caseViews.get(category);
      return lang_1.isPresent(categoryView) ? categoryView : this._caseViews.get(_CATEGORY_DEFAULT);
    };
    NgPlural.prototype._isValueView = function(pluralCase) {
      return pluralCase.value[0] === "=";
    };
    NgPlural.prototype._formatValue = function(pluralCase) {
      return this._isValueView(pluralCase) ? this._stripValue(pluralCase.value) : pluralCase.value;
    };
    NgPlural.prototype._stripValue = function(value) {
      return lang_1.NumberWrapper.parseInt(value.substring(1), 10);
    };
    NgPlural.decorators = [{
      type: core_1.Directive,
      args: [{selector: '[ngPlural]'}]
    }];
    NgPlural.ctorParameters = [{type: NgLocalization}];
    NgPlural.propDecorators = {
      'cases': [{
        type: core_1.ContentChildren,
        args: [NgPluralCase]
      }],
      'ngPlural': [{type: core_1.Input}]
    };
    return NgPlural;
  }());
  exports.NgPlural = NgPlural;
  return module.exports;
});

$__System.registerDynamic("e5", ["de", "df", "e0", "e1", "e2", "e3", "e4"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ng_class_1 = $__require('de');
  var ng_for_1 = $__require('df');
  var ng_if_1 = $__require('e0');
  var ng_template_outlet_1 = $__require('e1');
  var ng_style_1 = $__require('e2');
  var ng_switch_1 = $__require('e3');
  var ng_plural_1 = $__require('e4');
  exports.CORE_DIRECTIVES = [ng_class_1.NgClass, ng_for_1.NgFor, ng_if_1.NgIf, ng_template_outlet_1.NgTemplateOutlet, ng_style_1.NgStyle, ng_switch_1.NgSwitch, ng_switch_1.NgSwitchWhen, ng_switch_1.NgSwitchDefault, ng_plural_1.NgPlural, ng_plural_1.NgPluralCase];
  return module.exports;
});

$__System.registerDynamic("e6", ["de", "df", "e0", "e1", "e2", "e3", "e4", "dd", "e5"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  var ng_class_1 = $__require('de');
  exports.NgClass = ng_class_1.NgClass;
  var ng_for_1 = $__require('df');
  exports.NgFor = ng_for_1.NgFor;
  var ng_if_1 = $__require('e0');
  exports.NgIf = ng_if_1.NgIf;
  var ng_template_outlet_1 = $__require('e1');
  exports.NgTemplateOutlet = ng_template_outlet_1.NgTemplateOutlet;
  var ng_style_1 = $__require('e2');
  exports.NgStyle = ng_style_1.NgStyle;
  var ng_switch_1 = $__require('e3');
  exports.NgSwitch = ng_switch_1.NgSwitch;
  exports.NgSwitchWhen = ng_switch_1.NgSwitchWhen;
  exports.NgSwitchDefault = ng_switch_1.NgSwitchDefault;
  var ng_plural_1 = $__require('e4');
  exports.NgPlural = ng_plural_1.NgPlural;
  exports.NgPluralCase = ng_plural_1.NgPluralCase;
  exports.NgLocalization = ng_plural_1.NgLocalization;
  __export($__require('dd'));
  var core_directives_1 = $__require('e5');
  exports.CORE_DIRECTIVES = core_directives_1.CORE_DIRECTIVES;
  return module.exports;
});

$__System.registerDynamic("e7", ["dc", "e6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var forms_1 = $__require('dc');
  var directives_1 = $__require('e6');
  exports.COMMON_DIRECTIVES = [directives_1.CORE_DIRECTIVES, forms_1.FORM_DIRECTIVES];
  return module.exports;
});

$__System.registerDynamic("e8", ["11", "b3", "e9", "ea", "eb"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var location_strategy_1 = $__require('e9');
  var location_1 = $__require('ea');
  var platform_location_1 = $__require('eb');
  var HashLocationStrategy = (function(_super) {
    __extends(HashLocationStrategy, _super);
    function HashLocationStrategy(_platformLocation, _baseHref) {
      _super.call(this);
      this._platformLocation = _platformLocation;
      this._baseHref = '';
      if (lang_1.isPresent(_baseHref)) {
        this._baseHref = _baseHref;
      }
    }
    HashLocationStrategy.prototype.onPopState = function(fn) {
      this._platformLocation.onPopState(fn);
      this._platformLocation.onHashChange(fn);
    };
    HashLocationStrategy.prototype.getBaseHref = function() {
      return this._baseHref;
    };
    HashLocationStrategy.prototype.path = function() {
      var path = this._platformLocation.hash;
      if (!lang_1.isPresent(path))
        path = '#';
      return (path.length > 0 ? path.substring(1) : path);
    };
    HashLocationStrategy.prototype.prepareExternalUrl = function(internal) {
      var url = location_1.Location.joinWithSlash(this._baseHref, internal);
      return url.length > 0 ? ('#' + url) : url;
    };
    HashLocationStrategy.prototype.pushState = function(state, title, path, queryParams) {
      var url = this.prepareExternalUrl(path + location_1.Location.normalizeQueryParams(queryParams));
      if (url.length == 0) {
        url = this._platformLocation.pathname;
      }
      this._platformLocation.pushState(state, title, url);
    };
    HashLocationStrategy.prototype.replaceState = function(state, title, path, queryParams) {
      var url = this.prepareExternalUrl(path + location_1.Location.normalizeQueryParams(queryParams));
      if (url.length == 0) {
        url = this._platformLocation.pathname;
      }
      this._platformLocation.replaceState(state, title, url);
    };
    HashLocationStrategy.prototype.forward = function() {
      this._platformLocation.forward();
    };
    HashLocationStrategy.prototype.back = function() {
      this._platformLocation.back();
    };
    HashLocationStrategy.decorators = [{type: core_1.Injectable}];
    HashLocationStrategy.ctorParameters = [{type: platform_location_1.PlatformLocation}, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {
        type: core_1.Inject,
        args: [location_strategy_1.APP_BASE_HREF]
      }]
    }];
    return HashLocationStrategy;
  }(location_strategy_1.LocationStrategy));
  exports.HashLocationStrategy = HashLocationStrategy;
  return module.exports;
});

$__System.registerDynamic("ec", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var BaseWrappedException = (function(_super) {
    __extends(BaseWrappedException, _super);
    function BaseWrappedException(message) {
      _super.call(this, message);
    }
    Object.defineProperty(BaseWrappedException.prototype, "wrapperMessage", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "wrapperStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalException", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "context", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "message", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    return BaseWrappedException;
  }(Error));
  exports.BaseWrappedException = BaseWrappedException;
  return module.exports;
});

$__System.registerDynamic("ba", ["b3"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('b3');
  exports.Map = lang_1.global.Map;
  exports.Set = lang_1.global.Set;
  var createMapFromPairs = (function() {
    try {
      if (new exports.Map([[1, 2]]).size === 1) {
        return function createMapFromPairs(pairs) {
          return new exports.Map(pairs);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromPairs(pairs) {
      var map = new exports.Map();
      for (var i = 0; i < pairs.length; i++) {
        var pair = pairs[i];
        map.set(pair[0], pair[1]);
      }
      return map;
    };
  })();
  var createMapFromMap = (function() {
    try {
      if (new exports.Map(new exports.Map())) {
        return function createMapFromMap(m) {
          return new exports.Map(m);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromMap(m) {
      var map = new exports.Map();
      m.forEach(function(v, k) {
        map.set(k, v);
      });
      return map;
    };
  })();
  var _clearValues = (function() {
    if ((new exports.Map()).keys().next) {
      return function _clearValues(m) {
        var keyIterator = m.keys();
        var k;
        while (!((k = keyIterator.next()).done)) {
          m.set(k.value, null);
        }
      };
    } else {
      return function _clearValuesWithForeEach(m) {
        m.forEach(function(v, k) {
          m.set(k, null);
        });
      };
    }
  })();
  var _arrayFromMap = (function() {
    try {
      if ((new exports.Map()).values().next) {
        return function createArrayFromMap(m, getValues) {
          return getValues ? Array.from(m.values()) : Array.from(m.keys());
        };
      }
    } catch (e) {}
    return function createArrayFromMapWithForeach(m, getValues) {
      var res = ListWrapper.createFixedSize(m.size),
          i = 0;
      m.forEach(function(v, k) {
        res[i] = getValues ? v : k;
        i++;
      });
      return res;
    };
  })();
  var MapWrapper = (function() {
    function MapWrapper() {}
    MapWrapper.clone = function(m) {
      return createMapFromMap(m);
    };
    MapWrapper.createFromStringMap = function(stringMap) {
      var result = new exports.Map();
      for (var prop in stringMap) {
        result.set(prop, stringMap[prop]);
      }
      return result;
    };
    MapWrapper.toStringMap = function(m) {
      var r = {};
      m.forEach(function(v, k) {
        return r[k] = v;
      });
      return r;
    };
    MapWrapper.createFromPairs = function(pairs) {
      return createMapFromPairs(pairs);
    };
    MapWrapper.clearValues = function(m) {
      _clearValues(m);
    };
    MapWrapper.iterable = function(m) {
      return m;
    };
    MapWrapper.keys = function(m) {
      return _arrayFromMap(m, false);
    };
    MapWrapper.values = function(m) {
      return _arrayFromMap(m, true);
    };
    return MapWrapper;
  }());
  exports.MapWrapper = MapWrapper;
  var StringMapWrapper = (function() {
    function StringMapWrapper() {}
    StringMapWrapper.create = function() {
      return {};
    };
    StringMapWrapper.contains = function(map, key) {
      return map.hasOwnProperty(key);
    };
    StringMapWrapper.get = function(map, key) {
      return map.hasOwnProperty(key) ? map[key] : undefined;
    };
    StringMapWrapper.set = function(map, key, value) {
      map[key] = value;
    };
    StringMapWrapper.keys = function(map) {
      return Object.keys(map);
    };
    StringMapWrapper.values = function(map) {
      return Object.keys(map).reduce(function(r, a) {
        r.push(map[a]);
        return r;
      }, []);
    };
    StringMapWrapper.isEmpty = function(map) {
      for (var prop in map) {
        return false;
      }
      return true;
    };
    StringMapWrapper.delete = function(map, key) {
      delete map[key];
    };
    StringMapWrapper.forEach = function(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    };
    StringMapWrapper.merge = function(m1, m2) {
      var m = {};
      for (var attr in m1) {
        if (m1.hasOwnProperty(attr)) {
          m[attr] = m1[attr];
        }
      }
      for (var attr in m2) {
        if (m2.hasOwnProperty(attr)) {
          m[attr] = m2[attr];
        }
      }
      return m;
    };
    StringMapWrapper.equals = function(m1, m2) {
      var k1 = Object.keys(m1);
      var k2 = Object.keys(m2);
      if (k1.length != k2.length) {
        return false;
      }
      var key;
      for (var i = 0; i < k1.length; i++) {
        key = k1[i];
        if (m1[key] !== m2[key]) {
          return false;
        }
      }
      return true;
    };
    return StringMapWrapper;
  }());
  exports.StringMapWrapper = StringMapWrapper;
  var ListWrapper = (function() {
    function ListWrapper() {}
    ListWrapper.createFixedSize = function(size) {
      return new Array(size);
    };
    ListWrapper.createGrowableSize = function(size) {
      return new Array(size);
    };
    ListWrapper.clone = function(array) {
      return array.slice(0);
    };
    ListWrapper.forEachWithIndex = function(array, fn) {
      for (var i = 0; i < array.length; i++) {
        fn(array[i], i);
      }
    };
    ListWrapper.first = function(array) {
      if (!array)
        return null;
      return array[0];
    };
    ListWrapper.last = function(array) {
      if (!array || array.length == 0)
        return null;
      return array[array.length - 1];
    };
    ListWrapper.indexOf = function(array, value, startIndex) {
      if (startIndex === void 0) {
        startIndex = 0;
      }
      return array.indexOf(value, startIndex);
    };
    ListWrapper.contains = function(list, el) {
      return list.indexOf(el) !== -1;
    };
    ListWrapper.reversed = function(array) {
      var a = ListWrapper.clone(array);
      return a.reverse();
    };
    ListWrapper.concat = function(a, b) {
      return a.concat(b);
    };
    ListWrapper.insert = function(list, index, value) {
      list.splice(index, 0, value);
    };
    ListWrapper.removeAt = function(list, index) {
      var res = list[index];
      list.splice(index, 1);
      return res;
    };
    ListWrapper.removeAll = function(list, items) {
      for (var i = 0; i < items.length; ++i) {
        var index = list.indexOf(items[i]);
        list.splice(index, 1);
      }
    };
    ListWrapper.remove = function(list, el) {
      var index = list.indexOf(el);
      if (index > -1) {
        list.splice(index, 1);
        return true;
      }
      return false;
    };
    ListWrapper.clear = function(list) {
      list.length = 0;
    };
    ListWrapper.isEmpty = function(list) {
      return list.length == 0;
    };
    ListWrapper.fill = function(list, value, start, end) {
      if (start === void 0) {
        start = 0;
      }
      if (end === void 0) {
        end = null;
      }
      list.fill(value, start, end === null ? list.length : end);
    };
    ListWrapper.equals = function(a, b) {
      if (a.length != b.length)
        return false;
      for (var i = 0; i < a.length; ++i) {
        if (a[i] !== b[i])
          return false;
      }
      return true;
    };
    ListWrapper.slice = function(l, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return l.slice(from, to === null ? undefined : to);
    };
    ListWrapper.splice = function(l, from, length) {
      return l.splice(from, length);
    };
    ListWrapper.sort = function(l, compareFn) {
      if (lang_1.isPresent(compareFn)) {
        l.sort(compareFn);
      } else {
        l.sort();
      }
    };
    ListWrapper.toString = function(l) {
      return l.toString();
    };
    ListWrapper.toJSON = function(l) {
      return JSON.stringify(l);
    };
    ListWrapper.maximum = function(list, predicate) {
      if (list.length == 0) {
        return null;
      }
      var solution = null;
      var maxValue = -Infinity;
      for (var index = 0; index < list.length; index++) {
        var candidate = list[index];
        if (lang_1.isBlank(candidate)) {
          continue;
        }
        var candidateValue = predicate(candidate);
        if (candidateValue > maxValue) {
          solution = candidate;
          maxValue = candidateValue;
        }
      }
      return solution;
    };
    ListWrapper.flatten = function(list) {
      var target = [];
      _flattenArray(list, target);
      return target;
    };
    ListWrapper.addAll = function(list, source) {
      for (var i = 0; i < source.length; i++) {
        list.push(source[i]);
      }
    };
    return ListWrapper;
  }());
  exports.ListWrapper = ListWrapper;
  function _flattenArray(source, target) {
    if (lang_1.isPresent(source)) {
      for (var i = 0; i < source.length; i++) {
        var item = source[i];
        if (lang_1.isArray(item)) {
          _flattenArray(item, target);
        } else {
          target.push(item);
        }
      }
    }
    return target;
  }
  function isListLikeIterable(obj) {
    if (!lang_1.isJsObject(obj))
      return false;
    return lang_1.isArray(obj) || (!(obj instanceof exports.Map) && lang_1.getSymbolIterator() in obj);
  }
  exports.isListLikeIterable = isListLikeIterable;
  function areIterablesEqual(a, b, comparator) {
    var iterator1 = a[lang_1.getSymbolIterator()]();
    var iterator2 = b[lang_1.getSymbolIterator()]();
    while (true) {
      var item1 = iterator1.next();
      var item2 = iterator2.next();
      if (item1.done && item2.done)
        return true;
      if (item1.done || item2.done)
        return false;
      if (!comparator(item1.value, item2.value))
        return false;
    }
  }
  exports.areIterablesEqual = areIterablesEqual;
  function iterateListLike(obj, fn) {
    if (lang_1.isArray(obj)) {
      for (var i = 0; i < obj.length; i++) {
        fn(obj[i]);
      }
    } else {
      var iterator = obj[lang_1.getSymbolIterator()]();
      var item;
      while (!((item = iterator.next()).done)) {
        fn(item.value);
      }
    }
  }
  exports.iterateListLike = iterateListLike;
  var createSetFromList = (function() {
    var test = new exports.Set([1, 2, 3]);
    if (test.size === 3) {
      return function createSetFromList(lst) {
        return new exports.Set(lst);
      };
    } else {
      return function createSetAndPopulateFromList(lst) {
        var res = new exports.Set(lst);
        if (res.size !== lst.length) {
          for (var i = 0; i < lst.length; i++) {
            res.add(lst[i]);
          }
        }
        return res;
      };
    }
  })();
  var SetWrapper = (function() {
    function SetWrapper() {}
    SetWrapper.createFromList = function(lst) {
      return createSetFromList(lst);
    };
    SetWrapper.has = function(s, key) {
      return s.has(key);
    };
    SetWrapper.delete = function(m, k) {
      m.delete(k);
    };
    return SetWrapper;
  }());
  exports.SetWrapper = SetWrapper;
  return module.exports;
});

$__System.registerDynamic("ed", ["b3", "ec", "ba"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('b3');
  var base_wrapped_exception_1 = $__require('ec');
  var collection_1 = $__require('ba');
  var _ArrayLogger = (function() {
    function _ArrayLogger() {
      this.res = [];
    }
    _ArrayLogger.prototype.log = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logError = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroup = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroupEnd = function() {};
    ;
    return _ArrayLogger;
  }());
  var ExceptionHandler = (function() {
    function ExceptionHandler(_logger, _rethrowException) {
      if (_rethrowException === void 0) {
        _rethrowException = true;
      }
      this._logger = _logger;
      this._rethrowException = _rethrowException;
    }
    ExceptionHandler.exceptionToString = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var l = new _ArrayLogger();
      var e = new ExceptionHandler(l, false);
      e.call(exception, stackTrace, reason);
      return l.res.join("\n");
    };
    ExceptionHandler.prototype.call = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var originalException = this._findOriginalException(exception);
      var originalStack = this._findOriginalStack(exception);
      var context = this._findContext(exception);
      this._logger.logGroup("EXCEPTION: " + this._extractMessage(exception));
      if (lang_1.isPresent(stackTrace) && lang_1.isBlank(originalStack)) {
        this._logger.logError("STACKTRACE:");
        this._logger.logError(this._longStackTrace(stackTrace));
      }
      if (lang_1.isPresent(reason)) {
        this._logger.logError("REASON: " + reason);
      }
      if (lang_1.isPresent(originalException)) {
        this._logger.logError("ORIGINAL EXCEPTION: " + this._extractMessage(originalException));
      }
      if (lang_1.isPresent(originalStack)) {
        this._logger.logError("ORIGINAL STACKTRACE:");
        this._logger.logError(this._longStackTrace(originalStack));
      }
      if (lang_1.isPresent(context)) {
        this._logger.logError("ERROR CONTEXT:");
        this._logger.logError(context);
      }
      this._logger.logGroupEnd();
      if (this._rethrowException)
        throw exception;
    };
    ExceptionHandler.prototype._extractMessage = function(exception) {
      return exception instanceof base_wrapped_exception_1.BaseWrappedException ? exception.wrapperMessage : exception.toString();
    };
    ExceptionHandler.prototype._longStackTrace = function(stackTrace) {
      return collection_1.isListLikeIterable(stackTrace) ? stackTrace.join("\n\n-----async gap-----\n") : stackTrace.toString();
    };
    ExceptionHandler.prototype._findContext = function(exception) {
      try {
        if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
          return null;
        return lang_1.isPresent(exception.context) ? exception.context : this._findContext(exception.originalException);
      } catch (e) {
        return null;
      }
    };
    ExceptionHandler.prototype._findOriginalException = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception.originalException;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
      }
      return e;
    };
    ExceptionHandler.prototype._findOriginalStack = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception;
      var stack = exception.originalStack;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
        if (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
          stack = e.originalStack;
        }
      }
      return stack;
    };
    return ExceptionHandler;
  }());
  exports.ExceptionHandler = ExceptionHandler;
  return module.exports;
});

$__System.registerDynamic("be", ["ec", "ed"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var base_wrapped_exception_1 = $__require('ec');
  var exception_handler_1 = $__require('ed');
  var exception_handler_2 = $__require('ed');
  exports.ExceptionHandler = exception_handler_2.ExceptionHandler;
  var BaseException = (function(_super) {
    __extends(BaseException, _super);
    function BaseException(message) {
      if (message === void 0) {
        message = "--";
      }
      _super.call(this, message);
      this.message = message;
      this.stack = (new Error(message)).stack;
    }
    BaseException.prototype.toString = function() {
      return this.message;
    };
    return BaseException;
  }(Error));
  exports.BaseException = BaseException;
  var WrappedException = (function(_super) {
    __extends(WrappedException, _super);
    function WrappedException(_wrapperMessage, _originalException, _originalStack, _context) {
      _super.call(this, _wrapperMessage);
      this._wrapperMessage = _wrapperMessage;
      this._originalException = _originalException;
      this._originalStack = _originalStack;
      this._context = _context;
      this._wrapperStack = (new Error(_wrapperMessage)).stack;
    }
    Object.defineProperty(WrappedException.prototype, "wrapperMessage", {
      get: function() {
        return this._wrapperMessage;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "wrapperStack", {
      get: function() {
        return this._wrapperStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalException", {
      get: function() {
        return this._originalException;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalStack", {
      get: function() {
        return this._originalStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "context", {
      get: function() {
        return this._context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "message", {
      get: function() {
        return exception_handler_1.ExceptionHandler.exceptionToString(this);
      },
      enumerable: true,
      configurable: true
    });
    WrappedException.prototype.toString = function() {
      return this.message;
    };
    return WrappedException;
  }(base_wrapped_exception_1.BaseWrappedException));
  exports.WrappedException = WrappedException;
  function makeTypeError(message) {
    return new TypeError(message);
  }
  exports.makeTypeError = makeTypeError;
  function unimplemented() {
    throw new BaseException('unimplemented');
  }
  exports.unimplemented = unimplemented;
  return module.exports;
});

$__System.registerDynamic("eb", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var PlatformLocation = (function() {
    function PlatformLocation() {}
    Object.defineProperty(PlatformLocation.prototype, "pathname", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(PlatformLocation.prototype, "search", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(PlatformLocation.prototype, "hash", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    return PlatformLocation;
  }());
  exports.PlatformLocation = PlatformLocation;
  return module.exports;
});

$__System.registerDynamic("ee", ["11", "b3", "be", "eb", "e9", "ea"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var core_1 = $__require('11');
  var lang_1 = $__require('b3');
  var exceptions_1 = $__require('be');
  var platform_location_1 = $__require('eb');
  var location_strategy_1 = $__require('e9');
  var location_1 = $__require('ea');
  var PathLocationStrategy = (function(_super) {
    __extends(PathLocationStrategy, _super);
    function PathLocationStrategy(_platformLocation, href) {
      _super.call(this);
      this._platformLocation = _platformLocation;
      if (lang_1.isBlank(href)) {
        href = this._platformLocation.getBaseHrefFromDOM();
      }
      if (lang_1.isBlank(href)) {
        throw new exceptions_1.BaseException("No base href set. Please provide a value for the APP_BASE_HREF token or add a base element to the document.");
      }
      this._baseHref = href;
    }
    PathLocationStrategy.prototype.onPopState = function(fn) {
      this._platformLocation.onPopState(fn);
      this._platformLocation.onHashChange(fn);
    };
    PathLocationStrategy.prototype.getBaseHref = function() {
      return this._baseHref;
    };
    PathLocationStrategy.prototype.prepareExternalUrl = function(internal) {
      return location_1.Location.joinWithSlash(this._baseHref, internal);
    };
    PathLocationStrategy.prototype.path = function() {
      return this._platformLocation.pathname + location_1.Location.normalizeQueryParams(this._platformLocation.search);
    };
    PathLocationStrategy.prototype.pushState = function(state, title, url, queryParams) {
      var externalUrl = this.prepareExternalUrl(url + location_1.Location.normalizeQueryParams(queryParams));
      this._platformLocation.pushState(state, title, externalUrl);
    };
    PathLocationStrategy.prototype.replaceState = function(state, title, url, queryParams) {
      var externalUrl = this.prepareExternalUrl(url + location_1.Location.normalizeQueryParams(queryParams));
      this._platformLocation.replaceState(state, title, externalUrl);
    };
    PathLocationStrategy.prototype.forward = function() {
      this._platformLocation.forward();
    };
    PathLocationStrategy.prototype.back = function() {
      this._platformLocation.back();
    };
    PathLocationStrategy.decorators = [{type: core_1.Injectable}];
    PathLocationStrategy.ctorParameters = [{type: platform_location_1.PlatformLocation}, {
      type: undefined,
      decorators: [{type: core_1.Optional}, {
        type: core_1.Inject,
        args: [location_strategy_1.APP_BASE_HREF]
      }]
    }];
    return PathLocationStrategy;
  }(location_strategy_1.LocationStrategy));
  exports.PathLocationStrategy = PathLocationStrategy;
  return module.exports;
});

$__System.registerDynamic("b3", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var globalScope;
  if (typeof window === 'undefined') {
    if (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) {
      globalScope = self;
    } else {
      globalScope = global;
    }
  } else {
    globalScope = window;
  }
  function scheduleMicroTask(fn) {
    Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
  }
  exports.scheduleMicroTask = scheduleMicroTask;
  exports.IS_DART = false;
  var _global = globalScope;
  exports.global = _global;
  exports.Type = Function;
  function getTypeNameForDebugging(type) {
    if (type['name']) {
      return type['name'];
    }
    return typeof type;
  }
  exports.getTypeNameForDebugging = getTypeNameForDebugging;
  exports.Math = _global.Math;
  exports.Date = _global.Date;
  var _devMode = true;
  var _modeLocked = false;
  function lockMode() {
    _modeLocked = true;
  }
  exports.lockMode = lockMode;
  function enableProdMode() {
    if (_modeLocked) {
      throw 'Cannot enable prod mode after platform setup.';
    }
    _devMode = false;
  }
  exports.enableProdMode = enableProdMode;
  function assertionsEnabled() {
    return _devMode;
  }
  exports.assertionsEnabled = assertionsEnabled;
  _global.assert = function assert(condition) {};
  function isPresent(obj) {
    return obj !== undefined && obj !== null;
  }
  exports.isPresent = isPresent;
  function isBlank(obj) {
    return obj === undefined || obj === null;
  }
  exports.isBlank = isBlank;
  function isBoolean(obj) {
    return typeof obj === "boolean";
  }
  exports.isBoolean = isBoolean;
  function isNumber(obj) {
    return typeof obj === "number";
  }
  exports.isNumber = isNumber;
  function isString(obj) {
    return typeof obj === "string";
  }
  exports.isString = isString;
  function isFunction(obj) {
    return typeof obj === "function";
  }
  exports.isFunction = isFunction;
  function isType(obj) {
    return isFunction(obj);
  }
  exports.isType = isType;
  function isStringMap(obj) {
    return typeof obj === 'object' && obj !== null;
  }
  exports.isStringMap = isStringMap;
  var STRING_MAP_PROTO = Object.getPrototypeOf({});
  function isStrictStringMap(obj) {
    return isStringMap(obj) && Object.getPrototypeOf(obj) === STRING_MAP_PROTO;
  }
  exports.isStrictStringMap = isStrictStringMap;
  function isPromise(obj) {
    return obj instanceof _global.Promise;
  }
  exports.isPromise = isPromise;
  function isArray(obj) {
    return Array.isArray(obj);
  }
  exports.isArray = isArray;
  function isDate(obj) {
    return obj instanceof exports.Date && !isNaN(obj.valueOf());
  }
  exports.isDate = isDate;
  function noop() {}
  exports.noop = noop;
  function stringify(token) {
    if (typeof token === 'string') {
      return token;
    }
    if (token === undefined || token === null) {
      return '' + token;
    }
    if (token.name) {
      return token.name;
    }
    if (token.overriddenName) {
      return token.overriddenName;
    }
    var res = token.toString();
    var newLineIndex = res.indexOf("\n");
    return (newLineIndex === -1) ? res : res.substring(0, newLineIndex);
  }
  exports.stringify = stringify;
  function serializeEnum(val) {
    return val;
  }
  exports.serializeEnum = serializeEnum;
  function deserializeEnum(val, values) {
    return val;
  }
  exports.deserializeEnum = deserializeEnum;
  function resolveEnumToken(enumValue, val) {
    return enumValue[val];
  }
  exports.resolveEnumToken = resolveEnumToken;
  var StringWrapper = (function() {
    function StringWrapper() {}
    StringWrapper.fromCharCode = function(code) {
      return String.fromCharCode(code);
    };
    StringWrapper.charCodeAt = function(s, index) {
      return s.charCodeAt(index);
    };
    StringWrapper.split = function(s, regExp) {
      return s.split(regExp);
    };
    StringWrapper.equals = function(s, s2) {
      return s === s2;
    };
    StringWrapper.stripLeft = function(s, charVal) {
      if (s && s.length) {
        var pos = 0;
        for (var i = 0; i < s.length; i++) {
          if (s[i] != charVal)
            break;
          pos++;
        }
        s = s.substring(pos);
      }
      return s;
    };
    StringWrapper.stripRight = function(s, charVal) {
      if (s && s.length) {
        var pos = s.length;
        for (var i = s.length - 1; i >= 0; i--) {
          if (s[i] != charVal)
            break;
          pos--;
        }
        s = s.substring(0, pos);
      }
      return s;
    };
    StringWrapper.replace = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.replaceAll = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.slice = function(s, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return s.slice(from, to === null ? undefined : to);
    };
    StringWrapper.replaceAllMapped = function(s, from, cb) {
      return s.replace(from, function() {
        var matches = [];
        for (var _i = 0; _i < arguments.length; _i++) {
          matches[_i - 0] = arguments[_i];
        }
        matches.splice(-2, 2);
        return cb(matches);
      });
    };
    StringWrapper.contains = function(s, substr) {
      return s.indexOf(substr) != -1;
    };
    StringWrapper.compare = function(a, b) {
      if (a < b) {
        return -1;
      } else if (a > b) {
        return 1;
      } else {
        return 0;
      }
    };
    return StringWrapper;
  }());
  exports.StringWrapper = StringWrapper;
  var StringJoiner = (function() {
    function StringJoiner(parts) {
      if (parts === void 0) {
        parts = [];
      }
      this.parts = parts;
    }
    StringJoiner.prototype.add = function(part) {
      this.parts.push(part);
    };
    StringJoiner.prototype.toString = function() {
      return this.parts.join("");
    };
    return StringJoiner;
  }());
  exports.StringJoiner = StringJoiner;
  var NumberParseError = (function(_super) {
    __extends(NumberParseError, _super);
    function NumberParseError(message) {
      _super.call(this);
      this.message = message;
    }
    NumberParseError.prototype.toString = function() {
      return this.message;
    };
    return NumberParseError;
  }(Error));
  exports.NumberParseError = NumberParseError;
  var NumberWrapper = (function() {
    function NumberWrapper() {}
    NumberWrapper.toFixed = function(n, fractionDigits) {
      return n.toFixed(fractionDigits);
    };
    NumberWrapper.equal = function(a, b) {
      return a === b;
    };
    NumberWrapper.parseIntAutoRadix = function(text) {
      var result = parseInt(text);
      if (isNaN(result)) {
        throw new NumberParseError("Invalid integer literal when parsing " + text);
      }
      return result;
    };
    NumberWrapper.parseInt = function(text, radix) {
      if (radix == 10) {
        if (/^(\-|\+)?[0-9]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else if (radix == 16) {
        if (/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else {
        var result = parseInt(text, radix);
        if (!isNaN(result)) {
          return result;
        }
      }
      throw new NumberParseError("Invalid integer literal when parsing " + text + " in base " + radix);
    };
    NumberWrapper.parseFloat = function(text) {
      return parseFloat(text);
    };
    Object.defineProperty(NumberWrapper, "NaN", {
      get: function() {
        return NaN;
      },
      enumerable: true,
      configurable: true
    });
    NumberWrapper.isNaN = function(value) {
      return isNaN(value);
    };
    NumberWrapper.isInteger = function(value) {
      return Number.isInteger(value);
    };
    return NumberWrapper;
  }());
  exports.NumberWrapper = NumberWrapper;
  exports.RegExp = _global.RegExp;
  var RegExpWrapper = (function() {
    function RegExpWrapper() {}
    RegExpWrapper.create = function(regExpStr, flags) {
      if (flags === void 0) {
        flags = '';
      }
      flags = flags.replace(/g/g, '');
      return new _global.RegExp(regExpStr, flags + 'g');
    };
    RegExpWrapper.firstMatch = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.exec(input);
    };
    RegExpWrapper.test = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.test(input);
    };
    RegExpWrapper.matcher = function(regExp, input) {
      regExp.lastIndex = 0;
      return {
        re: regExp,
        input: input
      };
    };
    RegExpWrapper.replaceAll = function(regExp, input, replace) {
      var c = regExp.exec(input);
      var res = '';
      regExp.lastIndex = 0;
      var prev = 0;
      while (c) {
        res += input.substring(prev, c.index);
        res += replace(c);
        prev = c.index + c[0].length;
        regExp.lastIndex = prev;
        c = regExp.exec(input);
      }
      res += input.substring(prev);
      return res;
    };
    return RegExpWrapper;
  }());
  exports.RegExpWrapper = RegExpWrapper;
  var RegExpMatcherWrapper = (function() {
    function RegExpMatcherWrapper() {}
    RegExpMatcherWrapper.next = function(matcher) {
      return matcher.re.exec(matcher.input);
    };
    return RegExpMatcherWrapper;
  }());
  exports.RegExpMatcherWrapper = RegExpMatcherWrapper;
  var FunctionWrapper = (function() {
    function FunctionWrapper() {}
    FunctionWrapper.apply = function(fn, posArgs) {
      return fn.apply(null, posArgs);
    };
    return FunctionWrapper;
  }());
  exports.FunctionWrapper = FunctionWrapper;
  function looseIdentical(a, b) {
    return a === b || typeof a === "number" && typeof b === "number" && isNaN(a) && isNaN(b);
  }
  exports.looseIdentical = looseIdentical;
  function getMapKey(value) {
    return value;
  }
  exports.getMapKey = getMapKey;
  function normalizeBlank(obj) {
    return isBlank(obj) ? null : obj;
  }
  exports.normalizeBlank = normalizeBlank;
  function normalizeBool(obj) {
    return isBlank(obj) ? false : obj;
  }
  exports.normalizeBool = normalizeBool;
  function isJsObject(o) {
    return o !== null && (typeof o === "function" || typeof o === "object");
  }
  exports.isJsObject = isJsObject;
  function print(obj) {
    console.log(obj);
  }
  exports.print = print;
  function warn(obj) {
    console.warn(obj);
  }
  exports.warn = warn;
  var Json = (function() {
    function Json() {}
    Json.parse = function(s) {
      return _global.JSON.parse(s);
    };
    Json.stringify = function(data) {
      return _global.JSON.stringify(data, null, 2);
    };
    return Json;
  }());
  exports.Json = Json;
  var DateWrapper = (function() {
    function DateWrapper() {}
    DateWrapper.create = function(year, month, day, hour, minutes, seconds, milliseconds) {
      if (month === void 0) {
        month = 1;
      }
      if (day === void 0) {
        day = 1;
      }
      if (hour === void 0) {
        hour = 0;
      }
      if (minutes === void 0) {
        minutes = 0;
      }
      if (seconds === void 0) {
        seconds = 0;
      }
      if (milliseconds === void 0) {
        milliseconds = 0;
      }
      return new exports.Date(year, month - 1, day, hour, minutes, seconds, milliseconds);
    };
    DateWrapper.fromISOString = function(str) {
      return new exports.Date(str);
    };
    DateWrapper.fromMillis = function(ms) {
      return new exports.Date(ms);
    };
    DateWrapper.toMillis = function(date) {
      return date.getTime();
    };
    DateWrapper.now = function() {
      return new exports.Date();
    };
    DateWrapper.toJson = function(date) {
      return date.toJSON();
    };
    return DateWrapper;
  }());
  exports.DateWrapper = DateWrapper;
  function setValueOnPath(global, path, value) {
    var parts = path.split('.');
    var obj = global;
    while (parts.length > 1) {
      var name = parts.shift();
      if (obj.hasOwnProperty(name) && isPresent(obj[name])) {
        obj = obj[name];
      } else {
        obj = obj[name] = {};
      }
    }
    if (obj === undefined || obj === null) {
      obj = {};
    }
    obj[parts.shift()] = value;
  }
  exports.setValueOnPath = setValueOnPath;
  var _symbolIterator = null;
  function getSymbolIterator() {
    if (isBlank(_symbolIterator)) {
      if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
        _symbolIterator = Symbol.iterator;
      } else {
        var keys = Object.getOwnPropertyNames(Map.prototype);
        for (var i = 0; i < keys.length; ++i) {
          var key = keys[i];
          if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
            _symbolIterator = key;
          }
        }
      }
    }
    return _symbolIterator;
  }
  exports.getSymbolIterator = getSymbolIterator;
  function evalExpression(sourceUrl, expr, declarations, vars) {
    var fnBody = declarations + "\nreturn " + expr + "\n//# sourceURL=" + sourceUrl;
    var fnArgNames = [];
    var fnArgValues = [];
    for (var argName in vars) {
      fnArgNames.push(argName);
      fnArgValues.push(vars[argName]);
    }
    return new (Function.bind.apply(Function, [void 0].concat(fnArgNames.concat(fnBody))))().apply(void 0, fnArgValues);
  }
  exports.evalExpression = evalExpression;
  function isPrimitive(obj) {
    return !isJsObject(obj);
  }
  exports.isPrimitive = isPrimitive;
  function hasConstructor(value, type) {
    return value.constructor === type;
  }
  exports.hasConstructor = hasConstructor;
  function bitWiseOr(values) {
    return values.reduce(function(a, b) {
      return a | b;
    });
  }
  exports.bitWiseOr = bitWiseOr;
  function bitWiseAnd(values) {
    return values.reduce(function(a, b) {
      return a & b;
    });
  }
  exports.bitWiseAnd = bitWiseAnd;
  function escape(s) {
    return _global.encodeURI(s);
  }
  exports.escape = escape;
  return module.exports;
});

$__System.registerDynamic("da", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var PromiseCompleter = (function() {
    function PromiseCompleter() {
      var _this = this;
      this.promise = new Promise(function(res, rej) {
        _this.resolve = res;
        _this.reject = rej;
      });
    }
    return PromiseCompleter;
  }());
  exports.PromiseCompleter = PromiseCompleter;
  var PromiseWrapper = (function() {
    function PromiseWrapper() {}
    PromiseWrapper.resolve = function(obj) {
      return Promise.resolve(obj);
    };
    PromiseWrapper.reject = function(obj, _) {
      return Promise.reject(obj);
    };
    PromiseWrapper.catchError = function(promise, onError) {
      return promise.catch(onError);
    };
    PromiseWrapper.all = function(promises) {
      if (promises.length == 0)
        return Promise.resolve([]);
      return Promise.all(promises);
    };
    PromiseWrapper.then = function(promise, success, rejection) {
      return promise.then(success, rejection);
    };
    PromiseWrapper.wrap = function(computation) {
      return new Promise(function(res, rej) {
        try {
          res(computation());
        } catch (e) {
          rej(e);
        }
      });
    };
    PromiseWrapper.scheduleMicrotask = function(computation) {
      PromiseWrapper.then(PromiseWrapper.resolve(null), computation, function(_) {});
    };
    PromiseWrapper.isPromise = function(obj) {
      return obj instanceof Promise;
    };
    PromiseWrapper.completer = function() {
      return new PromiseCompleter();
    };
    return PromiseWrapper;
  }());
  exports.PromiseWrapper = PromiseWrapper;
  return module.exports;
});

$__System.registerDynamic("b4", ["b3", "da", "33", "34", "35", "36"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('b3');
  var promise_1 = $__require('da');
  exports.PromiseWrapper = promise_1.PromiseWrapper;
  exports.PromiseCompleter = promise_1.PromiseCompleter;
  var Subject_1 = $__require('33');
  var PromiseObservable_1 = $__require('34');
  var toPromise_1 = $__require('35');
  var Observable_1 = $__require('36');
  exports.Observable = Observable_1.Observable;
  var Subject_2 = $__require('33');
  exports.Subject = Subject_2.Subject;
  var TimerWrapper = (function() {
    function TimerWrapper() {}
    TimerWrapper.setTimeout = function(fn, millis) {
      return lang_1.global.setTimeout(fn, millis);
    };
    TimerWrapper.clearTimeout = function(id) {
      lang_1.global.clearTimeout(id);
    };
    TimerWrapper.setInterval = function(fn, millis) {
      return lang_1.global.setInterval(fn, millis);
    };
    TimerWrapper.clearInterval = function(id) {
      lang_1.global.clearInterval(id);
    };
    return TimerWrapper;
  }());
  exports.TimerWrapper = TimerWrapper;
  var ObservableWrapper = (function() {
    function ObservableWrapper() {}
    ObservableWrapper.subscribe = function(emitter, onNext, onError, onComplete) {
      if (onComplete === void 0) {
        onComplete = function() {};
      }
      onError = (typeof onError === "function") && onError || lang_1.noop;
      onComplete = (typeof onComplete === "function") && onComplete || lang_1.noop;
      return emitter.subscribe({
        next: onNext,
        error: onError,
        complete: onComplete
      });
    };
    ObservableWrapper.isObservable = function(obs) {
      return !!obs.subscribe;
    };
    ObservableWrapper.hasSubscribers = function(obs) {
      return obs.observers.length > 0;
    };
    ObservableWrapper.dispose = function(subscription) {
      subscription.unsubscribe();
    };
    ObservableWrapper.callNext = function(emitter, value) {
      emitter.next(value);
    };
    ObservableWrapper.callEmit = function(emitter, value) {
      emitter.emit(value);
    };
    ObservableWrapper.callError = function(emitter, error) {
      emitter.error(error);
    };
    ObservableWrapper.callComplete = function(emitter) {
      emitter.complete();
    };
    ObservableWrapper.fromPromise = function(promise) {
      return PromiseObservable_1.PromiseObservable.create(promise);
    };
    ObservableWrapper.toPromise = function(obj) {
      return toPromise_1.toPromise.call(obj);
    };
    return ObservableWrapper;
  }());
  exports.ObservableWrapper = ObservableWrapper;
  var EventEmitter = (function(_super) {
    __extends(EventEmitter, _super);
    function EventEmitter(isAsync) {
      if (isAsync === void 0) {
        isAsync = true;
      }
      _super.call(this);
      this._isAsync = isAsync;
    }
    EventEmitter.prototype.emit = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.next = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.subscribe = function(generatorOrNext, error, complete) {
      var schedulerFn;
      var errorFn = function(err) {
        return null;
      };
      var completeFn = function() {
        return null;
      };
      if (generatorOrNext && typeof generatorOrNext === 'object') {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext.next(value);
          });
        } : function(value) {
          generatorOrNext.next(value);
        };
        if (generatorOrNext.error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return generatorOrNext.error(err);
            });
          } : function(err) {
            generatorOrNext.error(err);
          };
        }
        if (generatorOrNext.complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return generatorOrNext.complete();
            });
          } : function() {
            generatorOrNext.complete();
          };
        }
      } else {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext(value);
          });
        } : function(value) {
          generatorOrNext(value);
        };
        if (error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return error(err);
            });
          } : function(err) {
            error(err);
          };
        }
        if (complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return complete();
            });
          } : function() {
            complete();
          };
        }
      }
      return _super.prototype.subscribe.call(this, schedulerFn, errorFn, completeFn);
    };
    return EventEmitter;
  }(Subject_1.Subject));
  exports.EventEmitter = EventEmitter;
  return module.exports;
});

$__System.registerDynamic("e9", ["11"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var LocationStrategy = (function() {
    function LocationStrategy() {}
    return LocationStrategy;
  }());
  exports.LocationStrategy = LocationStrategy;
  exports.APP_BASE_HREF = new core_1.OpaqueToken('appBaseHref');
  return module.exports;
});

$__System.registerDynamic("ea", ["11", "b4", "e9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core_1 = $__require('11');
  var async_1 = $__require('b4');
  var location_strategy_1 = $__require('e9');
  var Location = (function() {
    function Location(platformStrategy) {
      var _this = this;
      this.platformStrategy = platformStrategy;
      this._subject = new async_1.EventEmitter();
      var browserBaseHref = this.platformStrategy.getBaseHref();
      this._baseHref = Location.stripTrailingSlash(_stripIndexHtml(browserBaseHref));
      this.platformStrategy.onPopState(function(ev) {
        async_1.ObservableWrapper.callEmit(_this._subject, {
          'url': _this.path(),
          'pop': true,
          'type': ev.type
        });
      });
    }
    Location.prototype.path = function() {
      return this.normalize(this.platformStrategy.path());
    };
    Location.prototype.normalize = function(url) {
      return Location.stripTrailingSlash(_stripBaseHref(this._baseHref, _stripIndexHtml(url)));
    };
    Location.prototype.prepareExternalUrl = function(url) {
      if (url.length > 0 && !url.startsWith('/')) {
        url = '/' + url;
      }
      return this.platformStrategy.prepareExternalUrl(url);
    };
    Location.prototype.go = function(path, query) {
      if (query === void 0) {
        query = '';
      }
      this.platformStrategy.pushState(null, '', path, query);
    };
    Location.prototype.replaceState = function(path, query) {
      if (query === void 0) {
        query = '';
      }
      this.platformStrategy.replaceState(null, '', path, query);
    };
    Location.prototype.forward = function() {
      this.platformStrategy.forward();
    };
    Location.prototype.back = function() {
      this.platformStrategy.back();
    };
    Location.prototype.subscribe = function(onNext, onThrow, onReturn) {
      if (onThrow === void 0) {
        onThrow = null;
      }
      if (onReturn === void 0) {
        onReturn = null;
      }
      return async_1.ObservableWrapper.subscribe(this._subject, onNext, onThrow, onReturn);
    };
    Location.normalizeQueryParams = function(params) {
      return (params.length > 0 && params.substring(0, 1) != '?') ? ('?' + params) : params;
    };
    Location.joinWithSlash = function(start, end) {
      if (start.length == 0) {
        return end;
      }
      if (end.length == 0) {
        return start;
      }
      var slashes = 0;
      if (start.endsWith('/')) {
        slashes++;
      }
      if (end.startsWith('/')) {
        slashes++;
      }
      if (slashes == 2) {
        return start + end.substring(1);
      }
      if (slashes == 1) {
        return start + end;
      }
      return start + '/' + end;
    };
    Location.stripTrailingSlash = function(url) {
      if (/\/$/g.test(url)) {
        url = url.substring(0, url.length - 1);
      }
      return url;
    };
    Location.decorators = [{type: core_1.Injectable}];
    Location.ctorParameters = [{type: location_strategy_1.LocationStrategy}];
    return Location;
  }());
  exports.Location = Location;
  function _stripBaseHref(baseHref, url) {
    if (baseHref.length > 0 && url.startsWith(baseHref)) {
      return url.substring(baseHref.length);
    }
    return url;
  }
  function _stripIndexHtml(url) {
    if (/\/index.html$/g.test(url)) {
      return url.substring(0, url.length - 11);
    }
    return url;
  }
  return module.exports;
});

$__System.registerDynamic("ef", ["eb", "e9", "e8", "ee", "ea"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('eb'));
  __export($__require('e9'));
  __export($__require('e8'));
  __export($__require('ee'));
  __export($__require('ea'));
  return module.exports;
});

$__System.registerDynamic("f0", ["c3", "e6", "dc", "e7", "ef"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('c3'));
  __export($__require('e6'));
  __export($__require('dc'));
  __export($__require('e7'));
  __export($__require('ef'));
  return module.exports;
});

$__System.registerDynamic("76", ["f0"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('f0');
  return module.exports;
});

$__System.register('f1', ['11', '76', '89', '8a'], function (_export) {
  var Component, EventEmitter, CORE_DIRECTIVES, _createClass, _classCallCheck, Zippy;

  return {
    setters: [function (_2) {
      Component = _2.Component;
      EventEmitter = _2.EventEmitter;
    }, function (_3) {
      CORE_DIRECTIVES = _3.CORE_DIRECTIVES;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {
      'use strict';

      Zippy = (function () {
        function Zippy() {
          _classCallCheck(this, _Zippy);

          this.type = 'general';
          this.visible = false;
          this.empty = false;
          this.open = new EventEmitter();
          this.close = new EventEmitter();
        }

        _createClass(Zippy, [{
          key: 'toggle',
          value: function toggle() {
            this.visible = !this.visible;
            if (this.empty) return;
            this.visible ? this.open.next() : this.close.next();
          }
        }]);

        var _Zippy = Zippy;
        Zippy = Component({
          selector: 'zippy',
          events: ['open', 'close'],
          inputs: ['title', 'visible', 'type', 'empty'],
          template: '\n    <div class="zippy zippy-{{type}}" [ngClass]="{\'zippy-empty\': empty}">\n      <div class="zippy-title" (click)="toggle()">\n        <span class="zippy-indicator">{{ visible ? \'&#9662;\' : \'&#9656;\' }}</span>\n        {{title}}\n      </div>\n      <div class="zippy-content" [ngClass]="{\'zippy-hidden\': !visible}">\n        <ng-content></ng-content>\n      </div>\n    </div>\n  ',
          styles: ['\n    .zippy-title{padding:10px;border-radius:2px;margin:2px 0;line-height:1.5em;background-color:#f2f2f2;cursor:pointer}.zippy-success>.zippy-title{color:#00aa13;background-color:rgba(0,170,19,0.08)}.zippy-error>.zippy-title{color:#e53935;background-color:rgba(229,57,53,0.06)}.zippy-redirect>.zippy-title{color:#263238;background-color:rgba(38,50,56,0.08)}.zippy-info>.zippy-title{color:#0033a0;background-color:rgba(0,51,160,0.08)}span.zippy-indicator{font-size:1.2em;margin-right:0.2em;position:relative;top:0}.zippy-content{padding:15px 0}.zippy-empty .zippy-title{cursor:default}.zippy-empty .zippy-indicator{display:none}.zippy-empty .zippy-content{display:none}.zippy-hidden{overflow:hidden;visibility:hidden;height:0;padding:0}\n  '],
          directives: [CORE_DIRECTIVES]
        })(Zippy) || Zippy;
        return Zippy;
      })();

      _export('Zippy', Zippy);
    }
  };
});
$__System.register('90', ['af', 'b0', 'b1', 'f1'], function (_export) {
  'use strict';
  return {
    setters: [function (_af) {
      var _exportObj = {};

      for (var _key in _af) {
        if (_key !== 'default') _exportObj[_key] = _af[_key];
      }

      _export(_exportObj);
    }, function (_b0) {
      var _exportObj2 = {};

      for (var _key2 in _b0) {
        if (_key2 !== 'default') _exportObj2[_key2] = _b0[_key2];
      }

      _export(_exportObj2);
    }, function (_b1) {
      var _exportObj3 = {};

      for (var _key3 in _b1) {
        if (_key3 !== 'default') _exportObj3[_key3] = _b1[_key3];
      }

      _export(_exportObj3);
    }, function (_f1) {
      var _exportObj4 = {};

      for (var _key4 in _f1) {
        if (_key4 !== 'default') _exportObj4[_key4] = _f1[_key4];
      }

      _export(_exportObj4);
    }],
    execute: function () {}
  };
});
$__System.registerDynamic("f2", ["f3", "f4", "f5", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var classof = $__require('f3'),
      ITERATOR = $__require('f4')('iterator'),
      Iterators = $__require('f5');
  module.exports = $__require('f6').isIterable = function(it) {
    var O = Object(it);
    return O[ITERATOR] !== undefined || '@@iterator' in O || Iterators.hasOwnProperty(classof(O));
  };
  return module.exports;
});

$__System.registerDynamic("f7", ["f8", "f9", "f2"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('f8');
  $__require('f9');
  module.exports = $__require('f2');
  return module.exports;
});

$__System.registerDynamic("fa", ["f7"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('f7'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("a1", ["aa", "fa"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _getIterator = $__require('aa')["default"];
  var _isIterable = $__require('fa')["default"];
  exports["default"] = (function() {
    function sliceIterator(arr, i) {
      var _arr = [];
      var _n = true;
      var _d = false;
      var _e = undefined;
      try {
        for (var _i = _getIterator(arr),
            _s; !(_n = (_s = _i.next()).done); _n = true) {
          _arr.push(_s.value);
          if (i && _arr.length === i)
            break;
        }
      } catch (err) {
        _d = true;
        _e = err;
      } finally {
        try {
          if (!_n && _i["return"])
            _i["return"]();
        } finally {
          if (_d)
            throw _e;
        }
      }
      return _arr;
    }
    return function(arr, i) {
      if (Array.isArray(arr)) {
        return arr;
      } else if (_isIterable(Object(arr))) {
        return sliceIterator(arr, i);
      } else {
        throw new TypeError("Invalid attempt to destructure non-iterable instance");
      }
    };
  })();
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("fb", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = Object.is || function is(x, y) {
    return x === y ? x !== 0 || 1 / x === 1 / y : x != x && y != y;
  };
  return module.exports;
});

$__System.registerDynamic("fc", ["fd", "fe", "f4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var anObject = $__require('fd'),
      aFunction = $__require('fe'),
      SPECIES = $__require('f4')('species');
  module.exports = function(O, D) {
    var C = anObject(O).constructor,
        S;
    return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? D : aFunction(S);
  };
  return module.exports;
});

$__System.registerDynamic("ff", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(fn, args, that) {
    var un = that === undefined;
    switch (args.length) {
      case 0:
        return un ? fn() : fn.call(that);
      case 1:
        return un ? fn(args[0]) : fn.call(that, args[0]);
      case 2:
        return un ? fn(args[0], args[1]) : fn.call(that, args[0], args[1]);
      case 3:
        return un ? fn(args[0], args[1], args[2]) : fn.call(that, args[0], args[1], args[2]);
      case 4:
        return un ? fn(args[0], args[1], args[2], args[3]) : fn.call(that, args[0], args[1], args[2], args[3]);
    }
    return fn.apply(that, args);
  };
  return module.exports;
});

$__System.registerDynamic("100", ["101"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('101').document && document.documentElement;
  return module.exports;
});

$__System.registerDynamic("102", ["103", "101"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var isObject = $__require('103'),
      document = $__require('101').document,
      is = isObject(document) && isObject(document.createElement);
  module.exports = function(it) {
    return is ? document.createElement(it) : {};
  };
  return module.exports;
});

$__System.registerDynamic("104", ["105", "ff", "100", "102", "101", "106", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    var ctx = $__require('105'),
        invoke = $__require('ff'),
        html = $__require('100'),
        cel = $__require('102'),
        global = $__require('101'),
        process = global.process,
        setTask = global.setImmediate,
        clearTask = global.clearImmediate,
        MessageChannel = global.MessageChannel,
        counter = 0,
        queue = {},
        ONREADYSTATECHANGE = 'onreadystatechange',
        defer,
        channel,
        port;
    var run = function() {
      var id = +this;
      if (queue.hasOwnProperty(id)) {
        var fn = queue[id];
        delete queue[id];
        fn();
      }
    };
    var listner = function(event) {
      run.call(event.data);
    };
    if (!setTask || !clearTask) {
      setTask = function setImmediate(fn) {
        var args = [],
            i = 1;
        while (arguments.length > i)
          args.push(arguments[i++]);
        queue[++counter] = function() {
          invoke(typeof fn == 'function' ? fn : Function(fn), args);
        };
        defer(counter);
        return counter;
      };
      clearTask = function clearImmediate(id) {
        delete queue[id];
      };
      if ($__require('106')(process) == 'process') {
        defer = function(id) {
          process.nextTick(ctx(run, id, 1));
        };
      } else if (MessageChannel) {
        channel = new MessageChannel;
        port = channel.port2;
        channel.port1.onmessage = listner;
        defer = ctx(port.postMessage, port, 1);
      } else if (global.addEventListener && typeof postMessage == 'function' && !global.importScripts) {
        defer = function(id) {
          global.postMessage(id + '', '*');
        };
        global.addEventListener('message', listner, false);
      } else if (ONREADYSTATECHANGE in cel('script')) {
        defer = function(id) {
          html.appendChild(cel('script'))[ONREADYSTATECHANGE] = function() {
            html.removeChild(this);
            run.call(id);
          };
        };
      } else {
        defer = function(id) {
          setTimeout(ctx(run, id, 1), 0);
        };
      }
    }
    module.exports = {
      set: setTask,
      clear: clearTask
    };
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("107", ["101", "104", "106", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    var global = $__require('101'),
        macrotask = $__require('104').set,
        Observer = global.MutationObserver || global.WebKitMutationObserver,
        process = global.process,
        Promise = global.Promise,
        isNode = $__require('106')(process) == 'process',
        head,
        last,
        notify;
    var flush = function() {
      var parent,
          domain,
          fn;
      if (isNode && (parent = process.domain)) {
        process.domain = null;
        parent.exit();
      }
      while (head) {
        domain = head.domain;
        fn = head.fn;
        if (domain)
          domain.enter();
        fn();
        if (domain)
          domain.exit();
        head = head.next;
      }
      last = undefined;
      if (parent)
        parent.enter();
    };
    if (isNode) {
      notify = function() {
        process.nextTick(flush);
      };
    } else if (Observer) {
      var toggle = 1,
          node = document.createTextNode('');
      new Observer(flush).observe(node, {characterData: true});
      notify = function() {
        node.data = toggle = -toggle;
      };
    } else if (Promise && Promise.resolve) {
      notify = function() {
        Promise.resolve().then(flush);
      };
    } else {
      notify = function() {
        macrotask.call(global, flush);
      };
    }
    module.exports = function asap(fn) {
      var task = {
        fn: fn,
        next: undefined,
        domain: isNode && process.domain
      };
      if (last)
        last.next = task;
      if (!head) {
        head = task;
        notify();
      }
      last = task;
    };
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("108", ["109", "10a", "101", "105", "f3", "10b", "103", "fd", "fe", "10c", "10d", "10e", "fb", "f4", "fc", "107", "10f", "110", "111", "112", "f6", "113", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    var $ = $__require('109'),
        LIBRARY = $__require('10a'),
        global = $__require('101'),
        ctx = $__require('105'),
        classof = $__require('f3'),
        $export = $__require('10b'),
        isObject = $__require('103'),
        anObject = $__require('fd'),
        aFunction = $__require('fe'),
        strictNew = $__require('10c'),
        forOf = $__require('10d'),
        setProto = $__require('10e').set,
        same = $__require('fb'),
        SPECIES = $__require('f4')('species'),
        speciesConstructor = $__require('fc'),
        asap = $__require('107'),
        PROMISE = 'Promise',
        process = global.process,
        isNode = classof(process) == 'process',
        P = global[PROMISE],
        Wrapper;
    var testResolve = function(sub) {
      var test = new P(function() {});
      if (sub)
        test.constructor = Object;
      return P.resolve(test) === test;
    };
    var USE_NATIVE = function() {
      var works = false;
      function P2(x) {
        var self = new P(x);
        setProto(self, P2.prototype);
        return self;
      }
      try {
        works = P && P.resolve && testResolve();
        setProto(P2, P);
        P2.prototype = $.create(P.prototype, {constructor: {value: P2}});
        if (!(P2.resolve(5).then(function() {}) instanceof P2)) {
          works = false;
        }
        if (works && $__require('10f')) {
          var thenableThenGotten = false;
          P.resolve($.setDesc({}, 'then', {get: function() {
              thenableThenGotten = true;
            }}));
          works = thenableThenGotten;
        }
      } catch (e) {
        works = false;
      }
      return works;
    }();
    var sameConstructor = function(a, b) {
      if (LIBRARY && a === P && b === Wrapper)
        return true;
      return same(a, b);
    };
    var getConstructor = function(C) {
      var S = anObject(C)[SPECIES];
      return S != undefined ? S : C;
    };
    var isThenable = function(it) {
      var then;
      return isObject(it) && typeof(then = it.then) == 'function' ? then : false;
    };
    var PromiseCapability = function(C) {
      var resolve,
          reject;
      this.promise = new C(function($$resolve, $$reject) {
        if (resolve !== undefined || reject !== undefined)
          throw TypeError('Bad Promise constructor');
        resolve = $$resolve;
        reject = $$reject;
      });
      this.resolve = aFunction(resolve), this.reject = aFunction(reject);
    };
    var perform = function(exec) {
      try {
        exec();
      } catch (e) {
        return {error: e};
      }
    };
    var notify = function(record, isReject) {
      if (record.n)
        return;
      record.n = true;
      var chain = record.c;
      asap(function() {
        var value = record.v,
            ok = record.s == 1,
            i = 0;
        var run = function(reaction) {
          var handler = ok ? reaction.ok : reaction.fail,
              resolve = reaction.resolve,
              reject = reaction.reject,
              result,
              then;
          try {
            if (handler) {
              if (!ok)
                record.h = true;
              result = handler === true ? value : handler(value);
              if (result === reaction.promise) {
                reject(TypeError('Promise-chain cycle'));
              } else if (then = isThenable(result)) {
                then.call(result, resolve, reject);
              } else
                resolve(result);
            } else
              reject(value);
          } catch (e) {
            reject(e);
          }
        };
        while (chain.length > i)
          run(chain[i++]);
        chain.length = 0;
        record.n = false;
        if (isReject)
          setTimeout(function() {
            var promise = record.p,
                handler,
                console;
            if (isUnhandled(promise)) {
              if (isNode) {
                process.emit('unhandledRejection', value, promise);
              } else if (handler = global.onunhandledrejection) {
                handler({
                  promise: promise,
                  reason: value
                });
              } else if ((console = global.console) && console.error) {
                console.error('Unhandled promise rejection', value);
              }
            }
            record.a = undefined;
          }, 1);
      });
    };
    var isUnhandled = function(promise) {
      var record = promise._d,
          chain = record.a || record.c,
          i = 0,
          reaction;
      if (record.h)
        return false;
      while (chain.length > i) {
        reaction = chain[i++];
        if (reaction.fail || !isUnhandled(reaction.promise))
          return false;
      }
      return true;
    };
    var $reject = function(value) {
      var record = this;
      if (record.d)
        return;
      record.d = true;
      record = record.r || record;
      record.v = value;
      record.s = 2;
      record.a = record.c.slice();
      notify(record, true);
    };
    var $resolve = function(value) {
      var record = this,
          then;
      if (record.d)
        return;
      record.d = true;
      record = record.r || record;
      try {
        if (record.p === value)
          throw TypeError("Promise can't be resolved itself");
        if (then = isThenable(value)) {
          asap(function() {
            var wrapper = {
              r: record,
              d: false
            };
            try {
              then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1));
            } catch (e) {
              $reject.call(wrapper, e);
            }
          });
        } else {
          record.v = value;
          record.s = 1;
          notify(record, false);
        }
      } catch (e) {
        $reject.call({
          r: record,
          d: false
        }, e);
      }
    };
    if (!USE_NATIVE) {
      P = function Promise(executor) {
        aFunction(executor);
        var record = this._d = {
          p: strictNew(this, P, PROMISE),
          c: [],
          a: undefined,
          s: 0,
          d: false,
          v: undefined,
          h: false,
          n: false
        };
        try {
          executor(ctx($resolve, record, 1), ctx($reject, record, 1));
        } catch (err) {
          $reject.call(record, err);
        }
      };
      $__require('110')(P.prototype, {
        then: function then(onFulfilled, onRejected) {
          var reaction = new PromiseCapability(speciesConstructor(this, P)),
              promise = reaction.promise,
              record = this._d;
          reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true;
          reaction.fail = typeof onRejected == 'function' && onRejected;
          record.c.push(reaction);
          if (record.a)
            record.a.push(reaction);
          if (record.s)
            notify(record, false);
          return promise;
        },
        'catch': function(onRejected) {
          return this.then(undefined, onRejected);
        }
      });
    }
    $export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: P});
    $__require('111')(P, PROMISE);
    $__require('112')(PROMISE);
    Wrapper = $__require('f6')[PROMISE];
    $export($export.S + $export.F * !USE_NATIVE, PROMISE, {reject: function reject(r) {
        var capability = new PromiseCapability(this),
            $$reject = capability.reject;
        $$reject(r);
        return capability.promise;
      }});
    $export($export.S + $export.F * (!USE_NATIVE || testResolve(true)), PROMISE, {resolve: function resolve(x) {
        if (x instanceof P && sameConstructor(x.constructor, this))
          return x;
        var capability = new PromiseCapability(this),
            $$resolve = capability.resolve;
        $$resolve(x);
        return capability.promise;
      }});
    $export($export.S + $export.F * !(USE_NATIVE && $__require('113')(function(iter) {
      P.all(iter)['catch'](function() {});
    })), PROMISE, {
      all: function all(iterable) {
        var C = getConstructor(this),
            capability = new PromiseCapability(C),
            resolve = capability.resolve,
            reject = capability.reject,
            values = [];
        var abrupt = perform(function() {
          forOf(iterable, false, values.push, values);
          var remaining = values.length,
              results = Array(remaining);
          if (remaining)
            $.each.call(values, function(promise, index) {
              var alreadyCalled = false;
              C.resolve(promise).then(function(value) {
                if (alreadyCalled)
                  return;
                alreadyCalled = true;
                results[index] = value;
                --remaining || resolve(results);
              }, reject);
            });
          else
            resolve(results);
        });
        if (abrupt)
          reject(abrupt.error);
        return capability.promise;
      },
      race: function race(iterable) {
        var C = getConstructor(this),
            capability = new PromiseCapability(C),
            reject = capability.reject;
        var abrupt = perform(function() {
          forOf(iterable, false, function(promise) {
            C.resolve(promise).then(capability.resolve, reject);
          });
        });
        if (abrupt)
          reject(abrupt.error);
        return capability.promise;
      }
    });
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("114", ["115", "f9", "f8", "108", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('115');
  $__require('f9');
  $__require('f8');
  $__require('108');
  module.exports = $__require('f6').Promise;
  return module.exports;
});

$__System.registerDynamic("116", ["114"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('114'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("117", ["118", "119"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toObject = $__require('118');
  $__require('119')('keys', function($keys) {
    return function keys(it) {
      return $keys(toObject(it));
    };
  });
  return module.exports;
});

$__System.registerDynamic("11a", ["117", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('117');
  module.exports = $__require('f6').Object.keys;
  return module.exports;
});

$__System.registerDynamic("8f", ["11a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('11a'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("11b", ["fd", "11c", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var anObject = $__require('fd'),
      get = $__require('11c');
  module.exports = $__require('f6').getIterator = function(it) {
    var iterFn = get(it);
    if (typeof iterFn != 'function')
      throw TypeError(it + ' is not iterable!');
    return anObject(iterFn.call(it));
  };
  return module.exports;
});

$__System.registerDynamic("11d", ["f8", "f9", "11b"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('f8');
  $__require('f9');
  module.exports = $__require('11b');
  return module.exports;
});

$__System.registerDynamic("aa", ["11d"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('11d'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("11e", ["11f", "120"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var strong = $__require('11f');
  $__require('120')('Map', function(get) {
    return function Map() {
      return get(this, arguments.length > 0 ? arguments[0] : undefined);
    };
  }, {
    get: function get(key) {
      var entry = strong.getEntry(this, key);
      return entry && entry.v;
    },
    set: function set(key, value) {
      return strong.def(this, key === 0 ? 0 : key, value);
    }
  }, strong, true);
  return module.exports;
});

$__System.registerDynamic("121", ["10b", "122"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $export = $__require('10b');
  $export($export.P, 'Map', {toJSON: $__require('122')('Map')});
  return module.exports;
});

$__System.registerDynamic("123", ["115", "f9", "f8", "11e", "121", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('115');
  $__require('f9');
  $__require('f8');
  $__require('11e');
  $__require('121');
  module.exports = $__require('f6').Map;
  return module.exports;
});

$__System.registerDynamic("124", ["123"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('123'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("125", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  if (typeof Number.isFinite !== "function") {
    Number.isFinite = function isFinite(value) {
      if (typeof value !== "number") {
        return false;
      }
      if (value !== value || value === Infinity || value === -Infinity) {
        return false;
      }
      return true;
    };
  }
  return module.exports;
});

$__System.registerDynamic("126", ["127", "128", "129", "12a", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var Report = $__require('127');
    var SchemaCompilation = $__require('128');
    var SchemaValidation = $__require('129');
    var Utils = $__require('12a');
    function decodeJSONPointer(str) {
      return decodeURIComponent(str).replace(/~[0-1]/g, function(x) {
        return x === "~1" ? "/" : "~";
      });
    }
    function getRemotePath(uri) {
      var io = uri.indexOf("#");
      return io === -1 ? uri : uri.slice(0, io);
    }
    function getQueryPath(uri) {
      var io = uri.indexOf("#");
      var res = io === -1 ? undefined : uri.slice(io + 1);
      return res;
    }
    function findId(schema, id) {
      if (typeof schema !== "object" || schema === null) {
        return;
      }
      if (!id) {
        return schema;
      }
      if (schema.id) {
        if (schema.id === id || schema.id[0] === "#" && schema.id.substring(1) === id) {
          return schema;
        }
      }
      var idx,
          result;
      if (Array.isArray(schema)) {
        idx = schema.length;
        while (idx--) {
          result = findId(schema[idx], id);
          if (result) {
            return result;
          }
        }
      } else {
        var keys = Object.keys(schema);
        idx = keys.length;
        while (idx--) {
          var k = keys[idx];
          if (k.indexOf("__$") === 0) {
            continue;
          }
          result = findId(schema[k], id);
          if (result) {
            return result;
          }
        }
      }
    }
    exports.cacheSchemaByUri = function(uri, schema) {
      var remotePath = getRemotePath(uri);
      if (remotePath) {
        this.cache[remotePath] = schema;
      }
    };
    exports.removeFromCacheByUri = function(uri) {
      var remotePath = getRemotePath(uri);
      if (remotePath) {
        delete this.cache[remotePath];
      }
    };
    exports.checkCacheForUri = function(uri) {
      var remotePath = getRemotePath(uri);
      return remotePath ? this.cache[remotePath] != null : false;
    };
    exports.getSchema = function(report, schema) {
      if (typeof schema === "object") {
        schema = exports.getSchemaByReference.call(this, report, schema);
      }
      if (typeof schema === "string") {
        schema = exports.getSchemaByUri.call(this, report, schema);
      }
      return schema;
    };
    exports.getSchemaByReference = function(report, key) {
      var i = this.referenceCache.length;
      while (i--) {
        if (this.referenceCache[i][0] === key) {
          return this.referenceCache[i][1];
        }
      }
      var schema = Utils.cloneDeep(key);
      this.referenceCache.push([key, schema]);
      return schema;
    };
    exports.getSchemaByUri = function(report, uri, root) {
      var remotePath = getRemotePath(uri),
          queryPath = getQueryPath(uri),
          result = remotePath ? this.cache[remotePath] : root;
      if (result && remotePath) {
        var compileRemote = result !== root;
        if (compileRemote) {
          report.path.push(remotePath);
          var remoteReport = new Report(report);
          if (SchemaCompilation.compileSchema.call(this, remoteReport, result)) {
            SchemaValidation.validateSchema.call(this, remoteReport, result);
          }
          var remoteReportIsValid = remoteReport.isValid();
          if (!remoteReportIsValid) {
            report.addError("REMOTE_NOT_VALID", [uri], remoteReport);
          }
          report.path.pop();
          if (!remoteReportIsValid) {
            return undefined;
          }
        }
      }
      if (result && queryPath) {
        var parts = queryPath.split("/");
        for (var idx = 0,
            lim = parts.length; result && idx < lim; idx++) {
          var key = decodeJSONPointer(parts[idx]);
          if (idx === 0) {
            result = findId(result, key);
          } else {
            result = result[key];
          }
        }
      }
      return result;
    };
    exports.getRemotePath = getRemotePath;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("128", ["127", "126", "12a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Report = $__require('127');
  var SchemaCache = $__require('126');
  var Utils = $__require('12a');
  function mergeReference(scope, ref) {
    if (Utils.isAbsoluteUri(ref)) {
      return ref;
    }
    var joinedScope = scope.join(""),
        isScopeAbsolute = Utils.isAbsoluteUri(joinedScope),
        isScopeRelative = Utils.isRelativeUri(joinedScope),
        isRefRelative = Utils.isRelativeUri(ref),
        toRemove;
    if (isScopeAbsolute && isRefRelative) {
      toRemove = joinedScope.match(/\/[^\/]*$/);
      if (toRemove) {
        joinedScope = joinedScope.slice(0, toRemove.index + 1);
      }
    } else if (isScopeRelative && isRefRelative) {
      joinedScope = "";
    } else {
      toRemove = joinedScope.match(/[^#/]+$/);
      if (toRemove) {
        joinedScope = joinedScope.slice(0, toRemove.index);
      }
    }
    var res = joinedScope + ref;
    res = res.replace(/##/, "#");
    return res;
  }
  function collectReferences(obj, results, scope, path) {
    results = results || [];
    scope = scope || [];
    path = path || [];
    if (typeof obj !== "object" || obj === null) {
      return results;
    }
    if (typeof obj.id === "string") {
      scope.push(obj.id);
    }
    if (typeof obj.$ref === "string" && typeof obj.__$refResolved === "undefined") {
      results.push({
        ref: mergeReference(scope, obj.$ref),
        key: "$ref",
        obj: obj,
        path: path.slice(0)
      });
    }
    if (typeof obj.$schema === "string" && typeof obj.__$schemaResolved === "undefined") {
      results.push({
        ref: mergeReference(scope, obj.$schema),
        key: "$schema",
        obj: obj,
        path: path.slice(0)
      });
    }
    var idx;
    if (Array.isArray(obj)) {
      idx = obj.length;
      while (idx--) {
        path.push(idx.toString());
        collectReferences(obj[idx], results, scope, path);
        path.pop();
      }
    } else {
      var keys = Object.keys(obj);
      idx = keys.length;
      while (idx--) {
        if (keys[idx].indexOf("__$") === 0) {
          continue;
        }
        path.push(keys[idx]);
        collectReferences(obj[keys[idx]], results, scope, path);
        path.pop();
      }
    }
    if (typeof obj.id === "string") {
      scope.pop();
    }
    return results;
  }
  var compileArrayOfSchemasLoop = function(mainReport, arr) {
    var idx = arr.length,
        compiledCount = 0;
    while (idx--) {
      var report = new Report(mainReport);
      var isValid = exports.compileSchema.call(this, report, arr[idx]);
      if (isValid) {
        compiledCount++;
      }
      mainReport.errors = mainReport.errors.concat(report.errors);
    }
    return compiledCount;
  };
  function findId(arr, id) {
    var idx = arr.length;
    while (idx--) {
      if (arr[idx].id === id) {
        return arr[idx];
      }
    }
    return null;
  }
  var compileArrayOfSchemas = function(report, arr) {
    var compiled = 0,
        lastLoopCompiled;
    do {
      var idx = report.errors.length;
      while (idx--) {
        if (report.errors[idx].code === "UNRESOLVABLE_REFERENCE") {
          report.errors.splice(idx, 1);
        }
      }
      lastLoopCompiled = compiled;
      compiled = compileArrayOfSchemasLoop.call(this, report, arr);
      idx = arr.length;
      while (idx--) {
        var sch = arr[idx];
        if (sch.__$missingReferences) {
          var idx2 = sch.__$missingReferences.length;
          while (idx2--) {
            var refObj = sch.__$missingReferences[idx2];
            var response = findId(arr, refObj.ref);
            if (response) {
              refObj.obj["__" + refObj.key + "Resolved"] = response;
              sch.__$missingReferences.splice(idx2, 1);
            }
          }
          if (sch.__$missingReferences.length === 0) {
            delete sch.__$missingReferences;
          }
        }
      }
    } while (compiled !== arr.length && compiled !== lastLoopCompiled);
    return report.isValid();
  };
  exports.compileSchema = function(report, schema) {
    report.commonErrorMessage = "SCHEMA_COMPILATION_FAILED";
    if (typeof schema === "string") {
      var loadedSchema = SchemaCache.getSchemaByUri.call(this, report, schema);
      if (!loadedSchema) {
        report.addError("SCHEMA_NOT_REACHABLE", [schema]);
        return false;
      }
      schema = loadedSchema;
    }
    if (Array.isArray(schema)) {
      return compileArrayOfSchemas.call(this, report, schema);
    }
    if (schema.__$compiled && schema.id && SchemaCache.checkCacheForUri.call(this, schema.id) === false) {
      schema.__$compiled = undefined;
    }
    if (schema.__$compiled) {
      return true;
    }
    if (schema.id && typeof schema.id === "string") {
      SchemaCache.cacheSchemaByUri.call(this, schema.id, schema);
    }
    var isRoot = false;
    if (!report.rootSchema) {
      report.rootSchema = schema;
      isRoot = true;
    }
    var isValidExceptReferences = report.isValid();
    delete schema.__$missingReferences;
    var refs = collectReferences.call(this, schema),
        idx = refs.length;
    while (idx--) {
      var refObj = refs[idx];
      var response = SchemaCache.getSchemaByUri.call(this, report, refObj.ref, schema);
      if (!response) {
        var schemaReader = this.getSchemaReader();
        if (schemaReader) {
          var s = schemaReader(refObj.ref);
          if (s) {
            s.id = refObj.ref;
            var subreport = new Report(report);
            if (!exports.compileSchema.call(this, subreport, s)) {
              report.errors = report.errors.concat(subreport.errors);
            } else {
              response = SchemaCache.getSchemaByUri.call(this, report, refObj.ref, schema);
            }
          }
        }
      }
      if (!response) {
        var hasNotValid = report.hasError("REMOTE_NOT_VALID", [refObj.ref]);
        var isAbsolute = Utils.isAbsoluteUri(refObj.ref);
        var isDownloaded = false;
        var ignoreUnresolvableRemotes = this.options.ignoreUnresolvableReferences === true;
        if (isAbsolute) {
          isDownloaded = SchemaCache.checkCacheForUri.call(this, refObj.ref);
        }
        if (hasNotValid) {} else if (ignoreUnresolvableRemotes && isAbsolute) {} else if (isDownloaded) {} else {
          Array.prototype.push.apply(report.path, refObj.path);
          report.addError("UNRESOLVABLE_REFERENCE", [refObj.ref]);
          report.path = report.path.slice(0, -refObj.path.length);
          if (isValidExceptReferences) {
            schema.__$missingReferences = schema.__$missingReferences || [];
            schema.__$missingReferences.push(refObj);
          }
        }
      }
      refObj.obj["__" + refObj.key + "Resolved"] = response;
    }
    var isValid = report.isValid();
    if (isValid) {
      schema.__$compiled = true;
    } else {
      if (schema.id && typeof schema.id === "string") {
        SchemaCache.removeFromCacheByUri.call(this, schema.id);
      }
    }
    if (isRoot) {
      report.rootSchema = undefined;
    }
    return isValid;
  };
  return module.exports;
});

$__System.registerDynamic("12b", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = toInt;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function toInt(str, radix) {
    (0, _assertString2.default)(str);
    return parseInt(str, radix || 10);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("12d", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = toBoolean;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function toBoolean(str, strict) {
    (0, _assertString2.default)(str);
    if (strict) {
      return str === '1' || str === 'true';
    }
    return str !== '0' && str !== 'false' && str !== '';
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("12e", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = equals;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function equals(str, comparison) {
    (0, _assertString2.default)(str);
    return str === comparison;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("12f", ["12c", "130"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = contains;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _toString = $__require('130');
  var _toString2 = _interopRequireDefault(_toString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function contains(str, elem) {
    (0, _assertString2.default)(str);
    return str.indexOf((0, _toString2.default)(elem)) >= 0;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("131", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = matches;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function matches(str, pattern, modifiers) {
    (0, _assertString2.default)(str);
    if (Object.prototype.toString.call(pattern) !== '[object RegExp]') {
      pattern = new RegExp(pattern, modifiers);
    }
    return pattern.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("132", ["12c", "133", "134", "135"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isURL;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _isFQDN = $__require('133');
  var _isFQDN2 = _interopRequireDefault(_isFQDN);
  var _isIP = $__require('134');
  var _isIP2 = _interopRequireDefault(_isIP);
  var _merge = $__require('135');
  var _merge2 = _interopRequireDefault(_merge);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var default_url_options = {
    protocols: ['http', 'https', 'ftp'],
    require_tld: true,
    require_protocol: false,
    require_valid_protocol: true,
    allow_underscores: false,
    allow_trailing_dot: false,
    allow_protocol_relative_urls: false
  };
  function isURL(url, options) {
    (0, _assertString2.default)(url);
    if (!url || url.length >= 2083 || /\s/.test(url)) {
      return false;
    }
    if (url.indexOf('mailto:') === 0) {
      return false;
    }
    options = (0, _merge2.default)(options, default_url_options);
    var protocol = void 0,
        auth = void 0,
        host = void 0,
        hostname = void 0,
        port = void 0,
        port_str = void 0,
        split = void 0;
    split = url.split('#');
    url = split.shift();
    split = url.split('?');
    url = split.shift();
    split = url.split('://');
    if (split.length > 1) {
      protocol = split.shift();
      if (options.require_valid_protocol && options.protocols.indexOf(protocol) === -1) {
        return false;
      }
    } else if (options.require_protocol) {
      return false;
    } else if (options.allow_protocol_relative_urls && url.substr(0, 2) === '//') {
      split[0] = url.substr(2);
    }
    url = split.join('://');
    split = url.split('/');
    url = split.shift();
    split = url.split('@');
    if (split.length > 1) {
      auth = split.shift();
      if (auth.indexOf(':') >= 0 && auth.split(':').length > 2) {
        return false;
      }
    }
    hostname = split.join('@');
    split = hostname.split(':');
    host = split.shift();
    if (split.length) {
      port_str = split.join(':');
      port = parseInt(port_str, 10);
      if (!/^[0-9]+$/.test(port_str) || port <= 0 || port > 65535) {
        return false;
      }
    }
    if (!(0, _isIP2.default)(host) && !(0, _isFQDN2.default)(host, options) && host !== 'localhost') {
      return false;
    }
    if (options.host_whitelist && options.host_whitelist.indexOf(host) === -1) {
      return false;
    }
    if (options.host_blacklist && options.host_blacklist.indexOf(host) !== -1) {
      return false;
    }
    return true;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("136", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isMACAddress;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var macAddress = /^([0-9a-fA-F][0-9a-fA-F]:){5}([0-9a-fA-F][0-9a-fA-F])$/;
  function isMACAddress(str) {
    (0, _assertString2.default)(str);
    return macAddress.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("134", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isIP;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var ipv4Maybe = /^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})$/;
  var ipv6Block = /^[0-9A-F]{1,4}$/i;
  function isIP(str) {
    var version = arguments.length <= 1 || arguments[1] === undefined ? '' : arguments[1];
    (0, _assertString2.default)(str);
    version = String(version);
    if (!version) {
      return isIP(str, 4) || isIP(str, 6);
    } else if (version === '4') {
      if (!ipv4Maybe.test(str)) {
        return false;
      }
      var parts = str.split('.').sort(function(a, b) {
        return a - b;
      });
      return parts[3] <= 255;
    } else if (version === '6') {
      var blocks = str.split(':');
      var foundOmissionBlock = false;
      var foundIPv4TransitionBlock = isIP(blocks[blocks.length - 1], 4);
      var expectedNumberOfBlocks = foundIPv4TransitionBlock ? 7 : 8;
      if (blocks.length > expectedNumberOfBlocks) {
        return false;
      }
      if (str === '::') {
        return true;
      } else if (str.substr(0, 2) === '::') {
        blocks.shift();
        blocks.shift();
        foundOmissionBlock = true;
      } else if (str.substr(str.length - 2) === '::') {
        blocks.pop();
        blocks.pop();
        foundOmissionBlock = true;
      }
      for (var i = 0; i < blocks.length; ++i) {
        if (blocks[i] === '' && i > 0 && i < blocks.length - 1) {
          if (foundOmissionBlock) {
            return false;
          }
          foundOmissionBlock = true;
        } else if (foundIPv4TransitionBlock && i === blocks.length - 1) {} else if (!ipv6Block.test(blocks[i])) {
          return false;
        }
      }
      if (foundOmissionBlock) {
        return blocks.length >= 1;
      }
      return blocks.length === expectedNumberOfBlocks;
    }
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("137", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isBoolean;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isBoolean(str) {
    (0, _assertString2.default)(str);
    return ['true', 'false', '1', '0'].indexOf(str) >= 0;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("138", ["12c", "139"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isAlpha;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _alpha = $__require('139');
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isAlpha(str) {
    var locale = arguments.length <= 1 || arguments[1] === undefined ? 'en-US' : arguments[1];
    (0, _assertString2.default)(str);
    if (locale in _alpha.alpha) {
      return _alpha.alpha[locale].test(str);
    }
    throw new Error('Invalid locale \'' + locale + '\'');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("139", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var alpha = exports.alpha = {
    'en-US': /^[A-Z]+$/i,
    'cs-CZ': /^[A-ZÁČĎÉĚÍŇÓŘŠŤÚŮÝŽ]+$/i,
    'de-DE': /^[A-ZÄÖÜß]+$/i,
    'es-ES': /^[A-ZÁÉÍÑÓÚÜ]+$/i,
    'fr-FR': /^[A-ZÀÂÆÇÉÈÊËÏÎÔŒÙÛÜŸ]+$/i,
    'nl-NL': /^[A-ZÉËÏÓÖÜ]+$/i,
    'pl-PL': /^[A-ZĄĆĘŚŁŃÓŻŹ]+$/i,
    'pt-PT': /^[A-ZÃÁÀÂÇÉÊÍÕÓÔÚÜ]+$/i,
    'ru-RU': /^[А-ЯЁа-яё]+$/i,
    'tr-TR': /^[A-ZÇĞİıÖŞÜ]+$/i,
    ar: /^[ءآأؤإئابةتثجحخدذرزسشصضطظعغفقكلمنهوىيًٌٍَُِّْٰ]+$/
  };
  var alphanumeric = exports.alphanumeric = {
    'en-US': /^[0-9A-Z]+$/i,
    'cs-CZ': /^[0-9A-ZÁČĎÉĚÍŇÓŘŠŤÚŮÝŽ]+$/i,
    'de-DE': /^[0-9A-ZÄÖÜß]+$/i,
    'es-ES': /^[0-9A-ZÁÉÍÑÓÚÜ]+$/i,
    'fr-FR': /^[0-9A-ZÀÂÆÇÉÈÊËÏÎÔŒÙÛÜŸ]+$/i,
    'nl-NL': /^[0-9A-ZÉËÏÓÖÜ]+$/i,
    'pl-PL': /^[0-9A-ZĄĆĘŚŁŃÓŻŹ]+$/i,
    'pt-PT': /^[0-9A-ZÃÁÀÂÇÉÊÍÕÓÔÚÜ]+$/i,
    'ru-RU': /^[0-9А-ЯЁа-яё]+$/i,
    'tr-TR': /^[0-9A-ZÇĞİıÖŞÜ]+$/i,
    ar: /^[٠١٢٣٤٥٦٧٨٩0-9ءآأؤإئابةتثجحخدذرزسشصضطظعغفقكلمنهوىيًٌٍَُِّْٰ]+$/
  };
  var englishLocales = exports.englishLocales = ['AU', 'GB', 'HK', 'IN', 'NZ', 'ZA', 'ZM'];
  for (var locale,
      i = 0; i < englishLocales.length; i++) {
    locale = 'en-' + englishLocales[i];
    alpha[locale] = alpha['en-US'];
    alphanumeric[locale] = alphanumeric['en-US'];
  }
  var arabicLocales = exports.arabicLocales = ['AE', 'BH', 'DZ', 'EG', 'IQ', 'JO', 'KW', 'LB', 'LY', 'MA', 'QM', 'QA', 'SA', 'SD', 'SY', 'TN', 'YE'];
  for (var _locale,
      _i = 0; _i < arabicLocales.length; _i++) {
    _locale = 'ar-' + arabicLocales[_i];
    alpha[_locale] = alpha.ar;
    alphanumeric[_locale] = alphanumeric.ar;
  }
  return module.exports;
});

$__System.registerDynamic("13a", ["12c", "139"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isAlphanumeric;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _alpha = $__require('139');
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isAlphanumeric(str) {
    var locale = arguments.length <= 1 || arguments[1] === undefined ? 'en-US' : arguments[1];
    (0, _assertString2.default)(str);
    if (locale in _alpha.alphanumeric) {
      return _alpha.alphanumeric[locale].test(str);
    }
    throw new Error('Invalid locale \'' + locale + '\'');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("13b", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isNumeric;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var numeric = /^[-+]?[0-9]+$/;
  function isNumeric(str) {
    (0, _assertString2.default)(str);
    return numeric.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("13c", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isLowercase;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isLowercase(str) {
    (0, _assertString2.default)(str);
    return str === str.toLowerCase();
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("13d", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isUppercase;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isUppercase(str) {
    (0, _assertString2.default)(str);
    return str === str.toUpperCase();
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("13e", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isAscii;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var ascii = /^[\x00-\x7F]+$/;
  function isAscii(str) {
    (0, _assertString2.default)(str);
    return ascii.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("13f", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.fullWidth = undefined;
  exports.default = isFullWidth;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var fullWidth = exports.fullWidth = /[^\u0020-\u007E\uFF61-\uFF9F\uFFA0-\uFFDC\uFFE8-\uFFEE0-9a-zA-Z]/;
  function isFullWidth(str) {
    (0, _assertString2.default)(str);
    return fullWidth.test(str);
  }
  return module.exports;
});

$__System.registerDynamic("140", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.halfWidth = undefined;
  exports.default = isHalfWidth;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var halfWidth = exports.halfWidth = /[\u0020-\u007E\uFF61-\uFF9F\uFFA0-\uFFDC\uFFE8-\uFFEE0-9a-zA-Z]/;
  function isHalfWidth(str) {
    (0, _assertString2.default)(str);
    return halfWidth.test(str);
  }
  return module.exports;
});

$__System.registerDynamic("141", ["12c", "13f", "140"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isVariableWidth;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _isFullWidth = $__require('13f');
  var _isHalfWidth = $__require('140');
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isVariableWidth(str) {
    (0, _assertString2.default)(str);
    return _isFullWidth.fullWidth.test(str) && _isHalfWidth.halfWidth.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("142", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isMultibyte;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var multibyte = /[^\x00-\x7F]/;
  function isMultibyte(str) {
    (0, _assertString2.default)(str);
    return multibyte.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("143", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isSurrogatePair;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var surrogatePair = /[\uD800-\uDBFF][\uDC00-\uDFFF]/;
  function isSurrogatePair(str) {
    (0, _assertString2.default)(str);
    return surrogatePair.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("144", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isInt;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var int = /^(?:[-+]?(?:0|[1-9][0-9]*))$/;
  function isInt(str, options) {
    (0, _assertString2.default)(str);
    options = options || {};
    return int.test(str) && (!options.hasOwnProperty('min') || str >= options.min) && (!options.hasOwnProperty('max') || str <= options.max);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("145", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isFloat;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var float = /^(?:[-+]?(?:[0-9]+))?(?:\.[0-9]*)?(?:[eE][\+\-]?(?:[0-9]+))?$/;
  function isFloat(str, options) {
    (0, _assertString2.default)(str);
    options = options || {};
    if (str === '' || str === '.') {
      return false;
    }
    return float.test(str) && (!options.hasOwnProperty('min') || str >= options.min) && (!options.hasOwnProperty('max') || str <= options.max);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("146", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isDecimal;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var decimal = /^[-+]?([0-9]+|\.[0-9]+|[0-9]+\.[0-9]+)$/;
  function isDecimal(str) {
    (0, _assertString2.default)(str);
    return str !== '' && decimal.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("147", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = toFloat;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function toFloat(str) {
    (0, _assertString2.default)(str);
    return parseFloat(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("148", ["12c", "147"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isDivisibleBy;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _toFloat = $__require('147');
  var _toFloat2 = _interopRequireDefault(_toFloat);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isDivisibleBy(str, num) {
    (0, _assertString2.default)(str);
    return (0, _toFloat2.default)(str) % parseInt(num, 10) === 0;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("149", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isHexColor;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var hexcolor = /^#?([0-9A-F]{3}|[0-9A-F]{6})$/i;
  function isHexColor(str) {
    (0, _assertString2.default)(str);
    return hexcolor.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14a", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
    return typeof obj;
  } : function(obj) {
    return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
  };
  exports.default = isJSON;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isJSON(str) {
    (0, _assertString2.default)(str);
    try {
      var obj = JSON.parse(str);
      return !!obj && (typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) === 'object';
    } catch (e) {}
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14b", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isNull;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isNull(str) {
    (0, _assertString2.default)(str);
    return str.length === 0;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14c", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
    return typeof obj;
  } : function(obj) {
    return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
  };
  exports.default = isLength;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isLength(str, options) {
    (0, _assertString2.default)(str);
    var min = void 0;
    var max = void 0;
    if ((typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') {
      min = options.min || 0;
      max = options.max;
    } else {
      min = arguments[1];
      max = arguments[2];
    }
    var surrogatePairs = str.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g) || [];
    var len = str.length - surrogatePairs.length;
    return len >= min && (typeof max === 'undefined' || len <= max);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14d", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isUUID;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var uuid = {
    3: /^[0-9A-F]{8}-[0-9A-F]{4}-3[0-9A-F]{3}-[0-9A-F]{4}-[0-9A-F]{12}$/i,
    4: /^[0-9A-F]{8}-[0-9A-F]{4}-4[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,
    5: /^[0-9A-F]{8}-[0-9A-F]{4}-5[0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}$/i,
    all: /^[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}$/i
  };
  function isUUID(str) {
    var version = arguments.length <= 1 || arguments[1] === undefined ? 'all' : arguments[1];
    (0, _assertString2.default)(str);
    var pattern = uuid[version];
    return pattern && pattern.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14e", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isHexadecimal;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var hexadecimal = /^[0-9A-F]+$/i;
  function isHexadecimal(str) {
    (0, _assertString2.default)(str);
    return hexadecimal.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("14f", ["12c", "14e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isMongoId;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _isHexadecimal = $__require('14e');
  var _isHexadecimal2 = _interopRequireDefault(_isHexadecimal);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isMongoId(str) {
    (0, _assertString2.default)(str);
    return (0, _isHexadecimal2.default)(str) && str.length === 24;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("150", ["12c", "151"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isDate;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _isISO = $__require('151');
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function getTimezoneOffset(str) {
    var iso8601Parts = str.match(_isISO.iso8601);
    var timezone = void 0,
        sign = void 0,
        hours = void 0,
        minutes = void 0;
    if (!iso8601Parts) {
      str = str.toLowerCase();
      timezone = str.match(/(?:\s|gmt\s*)(-|\+)(\d{1,4})(\s|$)/);
      if (!timezone) {
        return str.indexOf('gmt') !== -1 ? 0 : null;
      }
      sign = timezone[1];
      var offset = timezone[2];
      if (offset.length === 3) {
        offset = '0' + offset;
      }
      if (offset.length <= 2) {
        hours = 0;
        minutes = parseInt(offset, 10);
      } else {
        hours = parseInt(offset.slice(0, 2), 10);
        minutes = parseInt(offset.slice(2, 4), 10);
      }
    } else {
      timezone = iso8601Parts[21];
      if (!timezone) {
        return !iso8601Parts[12] ? 0 : null;
      }
      if (timezone === 'z' || timezone === 'Z') {
        return 0;
      }
      sign = iso8601Parts[22];
      if (timezone.indexOf(':') !== -1) {
        hours = parseInt(iso8601Parts[23], 10);
        minutes = parseInt(iso8601Parts[24], 10);
      } else {
        hours = 0;
        minutes = parseInt(iso8601Parts[23], 10);
      }
    }
    return (hours * 60 + minutes) * (sign === '-' ? 1 : -1);
  }
  function isDate(str) {
    (0, _assertString2.default)(str);
    var normalizedDate = new Date(Date.parse(str));
    if (isNaN(normalizedDate)) {
      return false;
    }
    var timezoneOffset = getTimezoneOffset(str);
    if (timezoneOffset !== null) {
      var timezoneDifference = normalizedDate.getTimezoneOffset() - timezoneOffset;
      normalizedDate = new Date(normalizedDate.getTime() + 60000 * timezoneDifference);
    }
    var day = String(normalizedDate.getDate());
    var dayOrYear = void 0,
        dayOrYearMatches = void 0,
        year = void 0;
    dayOrYearMatches = str.match(/(^|[^:\d])[23]\d([^:\d]|$)/g);
    if (!dayOrYearMatches) {
      return true;
    }
    dayOrYear = dayOrYearMatches.map(function(digitString) {
      return digitString.match(/\d+/g)[0];
    }).join('/');
    year = String(normalizedDate.getFullYear()).slice(-2);
    if (dayOrYear === day || dayOrYear === year) {
      return true;
    } else if (dayOrYear === '' + day / year || dayOrYear === '' + year / day) {
      return true;
    }
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("152", ["12c", "153"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isAfter;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _toDate = $__require('153');
  var _toDate2 = _interopRequireDefault(_toDate);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isAfter(str) {
    var date = arguments.length <= 1 || arguments[1] === undefined ? String(new Date()) : arguments[1];
    (0, _assertString2.default)(str);
    var comparison = (0, _toDate2.default)(date);
    var original = (0, _toDate2.default)(str);
    return !!(original && comparison && original > comparison);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("153", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = toDate;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function toDate(date) {
    (0, _assertString2.default)(date);
    date = Date.parse(date);
    return !isNaN(date) ? new Date(date) : null;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("154", ["12c", "153"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isBefore;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _toDate = $__require('153');
  var _toDate2 = _interopRequireDefault(_toDate);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isBefore(str) {
    var date = arguments.length <= 1 || arguments[1] === undefined ? String(new Date()) : arguments[1];
    (0, _assertString2.default)(str);
    var comparison = (0, _toDate2.default)(date);
    var original = (0, _toDate2.default)(str);
    return !!(original && comparison && original < comparison);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("155", ["12c", "130"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
    return typeof obj;
  } : function(obj) {
    return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
  };
  exports.default = isIn;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _toString = $__require('130');
  var _toString2 = _interopRequireDefault(_toString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isIn(str, options) {
    (0, _assertString2.default)(str);
    var i = void 0;
    if (Object.prototype.toString.call(options) === '[object Array]') {
      var array = [];
      for (i in options) {
        if ({}.hasOwnProperty.call(options, i)) {
          array[i] = (0, _toString2.default)(options[i]);
        }
      }
      return array.indexOf(str) >= 0;
    } else if ((typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') {
      return options.hasOwnProperty(str);
    } else if (options && typeof options.indexOf === 'function') {
      return options.indexOf(str) >= 0;
    }
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("156", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isCreditCard;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var creditCard = /^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/;
  function isCreditCard(str) {
    (0, _assertString2.default)(str);
    var sanitized = str.replace(/[^0-9]+/g, '');
    if (!creditCard.test(sanitized)) {
      return false;
    }
    var sum = 0;
    var digit = void 0;
    var tmpNum = void 0;
    var shouldDouble = void 0;
    for (var i = sanitized.length - 1; i >= 0; i--) {
      digit = sanitized.substring(i, i + 1);
      tmpNum = parseInt(digit, 10);
      if (shouldDouble) {
        tmpNum *= 2;
        if (tmpNum >= 10) {
          sum += tmpNum % 10 + 1;
        } else {
          sum += tmpNum;
        }
      } else {
        sum += tmpNum;
      }
      shouldDouble = !shouldDouble;
    }
    return !!(sum % 10 === 0 ? sanitized : false);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("157", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isISIN;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var isin = /^[A-Z]{2}[0-9A-Z]{9}[0-9]$/;
  function isISIN(str) {
    (0, _assertString2.default)(str);
    if (!isin.test(str)) {
      return false;
    }
    var checksumStr = str.replace(/[A-Z]/g, function(character) {
      return parseInt(character, 36);
    });
    var sum = 0;
    var digit = void 0;
    var tmpNum = void 0;
    var shouldDouble = true;
    for (var i = checksumStr.length - 2; i >= 0; i--) {
      digit = checksumStr.substring(i, i + 1);
      tmpNum = parseInt(digit, 10);
      if (shouldDouble) {
        tmpNum *= 2;
        if (tmpNum >= 10) {
          sum += tmpNum + 1;
        } else {
          sum += tmpNum;
        }
      } else {
        sum += tmpNum;
      }
      shouldDouble = !shouldDouble;
    }
    return parseInt(str.substr(str.length - 1), 10) === (10000 - sum) % 10;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("158", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isISBN;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var isbn10Maybe = /^(?:[0-9]{9}X|[0-9]{10})$/;
  var isbn13Maybe = /^(?:[0-9]{13})$/;
  var factor = [1, 3];
  function isISBN(str) {
    var version = arguments.length <= 1 || arguments[1] === undefined ? '' : arguments[1];
    (0, _assertString2.default)(str);
    version = String(version);
    if (!version) {
      return isISBN(str, 10) || isISBN(str, 13);
    }
    var sanitized = str.replace(/[\s-]+/g, '');
    var checksum = 0;
    var i = void 0;
    if (version === '10') {
      if (!isbn10Maybe.test(sanitized)) {
        return false;
      }
      for (i = 0; i < 9; i++) {
        checksum += (i + 1) * sanitized.charAt(i);
      }
      if (sanitized.charAt(9) === 'X') {
        checksum += 10 * 10;
      } else {
        checksum += 10 * sanitized.charAt(9);
      }
      if (checksum % 11 === 0) {
        return !!sanitized;
      }
    } else if (version === '13') {
      if (!isbn13Maybe.test(sanitized)) {
        return false;
      }
      for (i = 0; i < 12; i++) {
        checksum += factor[i % 2] * sanitized.charAt(i);
      }
      if (sanitized.charAt(12) - (10 - checksum % 10) % 10 === 0) {
        return !!sanitized;
      }
    }
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("159", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isMobilePhone;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var phones = {
    'ar-SY': /^(!?(\+?963)|0)?9\d{8}$/,
    'en-US': /^(\+?1)?[2-9]\d{2}[2-9](?!11)\d{6}$/,
    'cs-CZ': /^(\+?420)? ?[1-9][0-9]{2} ?[0-9]{3} ?[0-9]{3}$/,
    'de-DE': /^(\+?49[ \.\-])?([\(]{1}[0-9]{1,6}[\)])?([0-9 \.\-\/]{3,20})((x|ext|extension)[ ]?[0-9]{1,4})?$/,
    'el-GR': /^(\+?30)?(69\d{8})$/,
    'en-AU': /^(\+?61|0)4\d{8}$/,
    'en-GB': /^(\+?44|0)7\d{9}$/,
    'en-HK': /^(\+?852\-?)?[569]\d{3}\-?\d{4}$/,
    'en-IN': /^(\+?91|0)?[789]\d{9}$/,
    'en-NZ': /^(\+?64|0)2\d{7,9}$/,
    'en-ZA': /^(\+?27|0)\d{9}$/,
    'en-ZM': /^(\+?26)?09[567]\d{7}$/,
    'es-ES': /^(\+?34)?(6\d{1}|7[1234])\d{7}$/,
    'fi-FI': /^(\+?358|0)\s?(4(0|1|2|4|5)?|50)\s?(\d\s?){4,8}\d$/,
    'fr-FR': /^(\+?33|0)[67]\d{8}$/,
    'ms-MY': /^(\+?6?01){1}(([145]{1}(\-|\s)?\d{7,8})|([236789]{1}(\s|\-)?\d{7}))$/,
    'nb-NO': /^(\+?47)?[49]\d{7}$/,
    'nn-NO': /^(\+?47)?[49]\d{7}$/,
    'pt-BR': /^(\+?55|0)\-?[1-9]{2}\-?[2-9]{1}\d{3,4}\-?\d{4}$/,
    'pt-PT': /^(\+?351)?9[1236]\d{7}$/,
    'ru-RU': /^(\+?7|8)?9\d{9}$/,
    'tr-TR': /^(\+?90|0)?5\d{9}$/,
    'vi-VN': /^(\+?84|0)?((1(2([0-9])|6([2-9])|88|99))|(9((?!5)[0-9])))([0-9]{7})$/,
    'zh-CN': /^(\+?0?86\-?)?((13\d|14[57]|15[^4,\D]|17[678]|18\d)\d{8}|170[059]\d{7})$/,
    'zh-TW': /^(\+?886\-?|0)?9\d{8}$/
  };
  function isMobilePhone(str, locale) {
    (0, _assertString2.default)(str);
    if (locale in phones) {
      return phones[locale].test(str);
    }
    return false;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("15a", ["135", "12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isCurrency;
  var _merge = $__require('135');
  var _merge2 = _interopRequireDefault(_merge);
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function currencyRegex(options) {
    var symbol = '(\\' + options.symbol.replace(/\./g, '\\.') + ')' + (options.require_symbol ? '' : '?'),
        negative = '-?',
        whole_dollar_amount_without_sep = '[1-9]\\d*',
        whole_dollar_amount_with_sep = '[1-9]\\d{0,2}(\\' + options.thousands_separator + '\\d{3})*',
        valid_whole_dollar_amounts = ['0', whole_dollar_amount_without_sep, whole_dollar_amount_with_sep],
        whole_dollar_amount = '(' + valid_whole_dollar_amounts.join('|') + ')?',
        decimal_amount = '(\\' + options.decimal_separator + '\\d{2})?';
    var pattern = whole_dollar_amount + decimal_amount;
    if (options.allow_negatives && !options.parens_for_negatives) {
      if (options.negative_sign_after_digits) {
        pattern += negative;
      } else if (options.negative_sign_before_digits) {
        pattern = negative + pattern;
      }
    }
    if (options.allow_negative_sign_placeholder) {
      pattern = '( (?!\\-))?' + pattern;
    } else if (options.allow_space_after_symbol) {
      pattern = ' ?' + pattern;
    } else if (options.allow_space_after_digits) {
      pattern += '( (?!$))?';
    }
    if (options.symbol_after_digits) {
      pattern += symbol;
    } else {
      pattern = symbol + pattern;
    }
    if (options.allow_negatives) {
      if (options.parens_for_negatives) {
        pattern = '(\\(' + pattern + '\\)|' + pattern + ')';
      } else if (!(options.negative_sign_before_digits || options.negative_sign_after_digits)) {
        pattern = negative + pattern;
      }
    }
    return new RegExp('^' + '(?!-? )(?=.*\\d)' + pattern + '$');
  }
  var default_currency_options = {
    symbol: '$',
    require_symbol: false,
    allow_space_after_symbol: false,
    symbol_after_digits: false,
    allow_negatives: true,
    parens_for_negatives: false,
    negative_sign_before_digits: false,
    negative_sign_after_digits: false,
    allow_negative_sign_placeholder: false,
    thousands_separator: ',',
    decimal_separator: '.',
    allow_space_after_digits: false
  };
  function isCurrency(str, options) {
    (0, _assertString2.default)(str);
    options = (0, _merge2.default)(options, default_currency_options);
    return currencyRegex(options).test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("151", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.iso8601 = undefined;
  exports.default = function(str) {
    (0, _assertString2.default)(str);
    return iso8601.test(str);
  };
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var iso8601 = exports.iso8601 = /^([\+-]?\d{4}(?!\d{2}\b))((-?)((0[1-9]|1[0-2])(\3([12]\d|0[1-9]|3[01]))?|W([0-4]\d|5[0-2])(-?[1-7])?|(00[1-9]|0[1-9]\d|[12]\d{2}|3([0-5]\d|6[1-6])))([T\s]((([01]\d|2[0-3])((:?)[0-5]\d)?|24\:?00)([\.,]\d+(?!:))?)?(\17[0-5]\d([\.,]\d+)?)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?)?)?$/;
  return module.exports;
});

$__System.registerDynamic("15b", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isBase64;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var notBase64 = /[^A-Z0-9+\/=]/i;
  function isBase64(str) {
    (0, _assertString2.default)(str);
    var len = str.length;
    if (!len || len % 4 !== 0 || notBase64.test(str)) {
      return false;
    }
    var firstPaddingChar = str.indexOf('=');
    return firstPaddingChar === -1 || firstPaddingChar === len - 1 || firstPaddingChar === len - 2 && str[len - 1] === '=';
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("15c", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isDataURI;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var dataURI = /^\s*data:([a-z]+\/[a-z0-9\-\+]+(;[a-z\-]+\=[a-z0-9\-]+)?)?(;base64)?,[a-z0-9\!\$\&\'\,\(\)\*\+\,\;\=\-\.\_\~\:\@\/\?\%\s]*\s*$/i;
  function isDataURI(str) {
    (0, _assertString2.default)(str);
    return dataURI.test(str);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("15d", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = ltrim;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function ltrim(str, chars) {
    (0, _assertString2.default)(str);
    var pattern = chars ? new RegExp('^[' + chars + ']+', 'g') : /^\s+/g;
    return str.replace(pattern, '');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("15e", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = rtrim;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function rtrim(str, chars) {
    (0, _assertString2.default)(str);
    var pattern = chars ? new RegExp('[' + chars + ']+$', 'g') : /\s+$/g;
    return str.replace(pattern, '');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("15f", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = trim;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function trim(str, chars) {
    (0, _assertString2.default)(str);
    var pattern = chars ? new RegExp('^[' + chars + ']+|[' + chars + ']+$', 'g') : /^\s+|\s+$/g;
    return str.replace(pattern, '');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("160", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = escape;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function escape(str) {
    (0, _assertString2.default)(str);
    return str.replace(/&/g, '&amp;').replace(/"/g, '&quot;').replace(/'/g, '&#x27;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/\//g, '&#x2F;').replace(/\`/g, '&#96;');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("161", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = unescape;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function unescape(str) {
    (0, _assertString2.default)(str);
    return str.replace(/&amp;/g, '&').replace(/&quot;/g, '"').replace(/&#x27;/g, "'").replace(/&lt;/g, '<').replace(/&gt;/g, '>').replace(/&#x2F;/g, '\/').replace(/&#96;/g, '\`');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("162", ["12c", "163"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = stripLow;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _blacklist = $__require('163');
  var _blacklist2 = _interopRequireDefault(_blacklist);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function stripLow(str, keep_new_lines) {
    (0, _assertString2.default)(str);
    var chars = keep_new_lines ? '\\x00-\\x09\\x0B\\x0C\\x0E-\\x1F\\x7F' : '\\x00-\\x1F\\x7F';
    return (0, _blacklist2.default)(str, chars);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("164", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = whitelist;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function whitelist(str, chars) {
    (0, _assertString2.default)(str);
    return str.replace(new RegExp('[^' + chars + ']+', 'g'), '');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("163", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = blacklist;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function blacklist(str, chars) {
    (0, _assertString2.default)(str);
    return str.replace(new RegExp('[' + chars + ']+', 'g'), '');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("165", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isWhitelisted;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isWhitelisted(str, chars) {
    (0, _assertString2.default)(str);
    for (var i = str.length - 1; i >= 0; i--) {
      if (chars.indexOf(str[i]) === -1) {
        return false;
      }
    }
    return true;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("166", ["12c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
    return typeof obj;
  } : function(obj) {
    return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
  };
  exports.default = isByteLength;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  function isByteLength(str, options) {
    (0, _assertString2.default)(str);
    var min = void 0;
    var max = void 0;
    if ((typeof options === 'undefined' ? 'undefined' : _typeof(options)) === 'object') {
      min = options.min || 0;
      max = options.max;
    } else {
      min = arguments[1];
      max = arguments[2];
    }
    var len = encodeURI(str).split(/%..|./).length - 1;
    return len >= min && (typeof max === 'undefined' || len <= max);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("12c", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = assertString;
  function assertString(input) {
    if (typeof input !== 'string') {
      throw new TypeError('This library (validator.js) validates strings only');
    }
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("133", ["12c", "135"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isFDQN;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _merge = $__require('135');
  var _merge2 = _interopRequireDefault(_merge);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var default_fqdn_options = {
    require_tld: true,
    allow_underscores: false,
    allow_trailing_dot: false
  };
  function isFDQN(str, options) {
    (0, _assertString2.default)(str);
    options = (0, _merge2.default)(options, default_fqdn_options);
    if (options.allow_trailing_dot && str[str.length - 1] === '.') {
      str = str.substring(0, str.length - 1);
    }
    var parts = str.split('.');
    if (options.require_tld) {
      var tld = parts.pop();
      if (!parts.length || !/^([a-z\u00a1-\uffff]{2,}|xn[a-z0-9-]{2,})$/i.test(tld)) {
        return false;
      }
    }
    for (var part,
        i = 0; i < parts.length; i++) {
      part = parts[i];
      if (options.allow_underscores) {
        part = part.replace(/_/g, '');
      }
      if (!/^[a-z\u00a1-\uffff0-9-]+$/i.test(part)) {
        return false;
      }
      if (/[\uff01-\uff5e]/.test(part)) {
        return false;
      }
      if (part[0] === '-' || part[part.length - 1] === '-') {
        return false;
      }
    }
    return true;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("167", ["12c", "135", "166", "133"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = isEmail;
  var _assertString = $__require('12c');
  var _assertString2 = _interopRequireDefault(_assertString);
  var _merge = $__require('135');
  var _merge2 = _interopRequireDefault(_merge);
  var _isByteLength = $__require('166');
  var _isByteLength2 = _interopRequireDefault(_isByteLength);
  var _isFQDN = $__require('133');
  var _isFQDN2 = _interopRequireDefault(_isFQDN);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var default_email_options = {
    allow_display_name: false,
    allow_utf8_local_part: true,
    require_tld: true
  };
  var displayName = /^[a-z\d!#\$%&'\*\+\-\/=\?\^_`{\|}~\.\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+[a-z\d!#\$%&'\*\+\-\/=\?\^_`{\|}~\.\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF\s]*<(.+)>$/i;
  var emailUserPart = /^[a-z\d!#\$%&'\*\+\-\/=\?\^_`{\|}~]+$/i;
  var quotedEmailUser = /^([\s\x01-\x08\x0b\x0c\x0e-\x1f\x7f\x21\x23-\x5b\x5d-\x7e]|(\\[\x01-\x09\x0b\x0c\x0d-\x7f]))*$/i;
  var emailUserUtf8Part = /^[a-z\d!#\$%&'\*\+\-\/=\?\^_`{\|}~\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+$/i;
  var quotedEmailUserUtf8 = /^([\s\x01-\x08\x0b\x0c\x0e-\x1f\x7f\x21\x23-\x5b\x5d-\x7e\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]|(\\[\x01-\x09\x0b\x0c\x0d-\x7f\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))*$/i;
  function isEmail(str, options) {
    (0, _assertString2.default)(str);
    options = (0, _merge2.default)(options, default_email_options);
    if (options.allow_display_name) {
      var display_email = str.match(displayName);
      if (display_email) {
        str = display_email[1];
      }
    }
    var parts = str.split('@');
    var domain = parts.pop();
    var user = parts.join('@');
    var lower_domain = domain.toLowerCase();
    if (lower_domain === 'gmail.com' || lower_domain === 'googlemail.com') {
      user = user.replace(/\./g, '').toLowerCase();
    }
    if (!(0, _isByteLength2.default)(user, {max: 64}) || !(0, _isByteLength2.default)(domain, {max: 256})) {
      return false;
    }
    if (!(0, _isFQDN2.default)(domain, {require_tld: options.require_tld})) {
      return false;
    }
    if (user[0] === '"') {
      user = user.slice(1, user.length - 1);
      return options.allow_utf8_local_part ? quotedEmailUserUtf8.test(user) : quotedEmailUser.test(user);
    }
    var pattern = options.allow_utf8_local_part ? emailUserUtf8Part : emailUserPart;
    var user_parts = user.split('.');
    for (var i = 0; i < user_parts.length; i++) {
      if (!pattern.test(user_parts[i])) {
        return false;
      }
    }
    return true;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("135", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = merge;
  function merge() {
    var obj = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];
    var defaults = arguments[1];
    for (var key in defaults) {
      if (typeof obj[key] === 'undefined') {
        obj[key] = defaults[key];
      }
    }
    return obj;
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("168", ["167", "135"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  exports.default = normalizeEmail;
  var _isEmail = $__require('167');
  var _isEmail2 = _interopRequireDefault(_isEmail);
  var _merge = $__require('135');
  var _merge2 = _interopRequireDefault(_merge);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var default_normalize_email_options = {
    lowercase: true,
    remove_dots: true,
    remove_extension: true
  };
  function normalizeEmail(email, options) {
    options = (0, _merge2.default)(options, default_normalize_email_options);
    if (!(0, _isEmail2.default)(email)) {
      return false;
    }
    var parts = email.split('@', 2);
    parts[1] = parts[1].toLowerCase();
    if (parts[1] === 'gmail.com' || parts[1] === 'googlemail.com') {
      if (options.remove_extension) {
        parts[0] = parts[0].split('+')[0];
      }
      if (options.remove_dots) {
        parts[0] = parts[0].replace(/\./g, '');
      }
      if (!parts[0].length) {
        return false;
      }
      parts[0] = parts[0].toLowerCase();
      parts[1] = 'gmail.com';
    } else if (options.lowercase) {
      parts[0] = parts[0].toLowerCase();
    }
    return parts.join('@');
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("130", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function(obj) {
    return typeof obj;
  } : function(obj) {
    return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
  };
  exports.default = toString;
  function toString(input) {
    if ((typeof input === 'undefined' ? 'undefined' : _typeof(input)) === 'object' && input !== null) {
      if (typeof input.toString === 'function') {
        input = input.toString();
      } else {
        input = '[object Object]';
      }
    } else if (input === null || typeof input === 'undefined' || isNaN(input) && !input.length) {
      input = '';
    }
    return String(input);
  }
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("169", ["153", "147", "12b", "12d", "12e", "12f", "131", "167", "132", "136", "134", "133", "137", "138", "13a", "13b", "13c", "13d", "13e", "13f", "140", "141", "142", "143", "144", "145", "146", "14e", "148", "149", "14a", "14b", "14c", "166", "14d", "14f", "150", "152", "154", "155", "156", "157", "158", "159", "15a", "151", "15b", "15c", "15d", "15e", "15f", "160", "161", "162", "164", "163", "165", "168", "130"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  Object.defineProperty(exports, "__esModule", {value: true});
  var _toDate = $__require('153');
  var _toDate2 = _interopRequireDefault(_toDate);
  var _toFloat = $__require('147');
  var _toFloat2 = _interopRequireDefault(_toFloat);
  var _toInt = $__require('12b');
  var _toInt2 = _interopRequireDefault(_toInt);
  var _toBoolean = $__require('12d');
  var _toBoolean2 = _interopRequireDefault(_toBoolean);
  var _equals = $__require('12e');
  var _equals2 = _interopRequireDefault(_equals);
  var _contains = $__require('12f');
  var _contains2 = _interopRequireDefault(_contains);
  var _matches = $__require('131');
  var _matches2 = _interopRequireDefault(_matches);
  var _isEmail = $__require('167');
  var _isEmail2 = _interopRequireDefault(_isEmail);
  var _isURL = $__require('132');
  var _isURL2 = _interopRequireDefault(_isURL);
  var _isMACAddress = $__require('136');
  var _isMACAddress2 = _interopRequireDefault(_isMACAddress);
  var _isIP = $__require('134');
  var _isIP2 = _interopRequireDefault(_isIP);
  var _isFQDN = $__require('133');
  var _isFQDN2 = _interopRequireDefault(_isFQDN);
  var _isBoolean = $__require('137');
  var _isBoolean2 = _interopRequireDefault(_isBoolean);
  var _isAlpha = $__require('138');
  var _isAlpha2 = _interopRequireDefault(_isAlpha);
  var _isAlphanumeric = $__require('13a');
  var _isAlphanumeric2 = _interopRequireDefault(_isAlphanumeric);
  var _isNumeric = $__require('13b');
  var _isNumeric2 = _interopRequireDefault(_isNumeric);
  var _isLowercase = $__require('13c');
  var _isLowercase2 = _interopRequireDefault(_isLowercase);
  var _isUppercase = $__require('13d');
  var _isUppercase2 = _interopRequireDefault(_isUppercase);
  var _isAscii = $__require('13e');
  var _isAscii2 = _interopRequireDefault(_isAscii);
  var _isFullWidth = $__require('13f');
  var _isFullWidth2 = _interopRequireDefault(_isFullWidth);
  var _isHalfWidth = $__require('140');
  var _isHalfWidth2 = _interopRequireDefault(_isHalfWidth);
  var _isVariableWidth = $__require('141');
  var _isVariableWidth2 = _interopRequireDefault(_isVariableWidth);
  var _isMultibyte = $__require('142');
  var _isMultibyte2 = _interopRequireDefault(_isMultibyte);
  var _isSurrogatePair = $__require('143');
  var _isSurrogatePair2 = _interopRequireDefault(_isSurrogatePair);
  var _isInt = $__require('144');
  var _isInt2 = _interopRequireDefault(_isInt);
  var _isFloat = $__require('145');
  var _isFloat2 = _interopRequireDefault(_isFloat);
  var _isDecimal = $__require('146');
  var _isDecimal2 = _interopRequireDefault(_isDecimal);
  var _isHexadecimal = $__require('14e');
  var _isHexadecimal2 = _interopRequireDefault(_isHexadecimal);
  var _isDivisibleBy = $__require('148');
  var _isDivisibleBy2 = _interopRequireDefault(_isDivisibleBy);
  var _isHexColor = $__require('149');
  var _isHexColor2 = _interopRequireDefault(_isHexColor);
  var _isJSON = $__require('14a');
  var _isJSON2 = _interopRequireDefault(_isJSON);
  var _isNull = $__require('14b');
  var _isNull2 = _interopRequireDefault(_isNull);
  var _isLength = $__require('14c');
  var _isLength2 = _interopRequireDefault(_isLength);
  var _isByteLength = $__require('166');
  var _isByteLength2 = _interopRequireDefault(_isByteLength);
  var _isUUID = $__require('14d');
  var _isUUID2 = _interopRequireDefault(_isUUID);
  var _isMongoId = $__require('14f');
  var _isMongoId2 = _interopRequireDefault(_isMongoId);
  var _isDate = $__require('150');
  var _isDate2 = _interopRequireDefault(_isDate);
  var _isAfter = $__require('152');
  var _isAfter2 = _interopRequireDefault(_isAfter);
  var _isBefore = $__require('154');
  var _isBefore2 = _interopRequireDefault(_isBefore);
  var _isIn = $__require('155');
  var _isIn2 = _interopRequireDefault(_isIn);
  var _isCreditCard = $__require('156');
  var _isCreditCard2 = _interopRequireDefault(_isCreditCard);
  var _isISIN = $__require('157');
  var _isISIN2 = _interopRequireDefault(_isISIN);
  var _isISBN = $__require('158');
  var _isISBN2 = _interopRequireDefault(_isISBN);
  var _isMobilePhone = $__require('159');
  var _isMobilePhone2 = _interopRequireDefault(_isMobilePhone);
  var _isCurrency = $__require('15a');
  var _isCurrency2 = _interopRequireDefault(_isCurrency);
  var _isISO = $__require('151');
  var _isISO2 = _interopRequireDefault(_isISO);
  var _isBase = $__require('15b');
  var _isBase2 = _interopRequireDefault(_isBase);
  var _isDataURI = $__require('15c');
  var _isDataURI2 = _interopRequireDefault(_isDataURI);
  var _ltrim = $__require('15d');
  var _ltrim2 = _interopRequireDefault(_ltrim);
  var _rtrim = $__require('15e');
  var _rtrim2 = _interopRequireDefault(_rtrim);
  var _trim = $__require('15f');
  var _trim2 = _interopRequireDefault(_trim);
  var _escape = $__require('160');
  var _escape2 = _interopRequireDefault(_escape);
  var _unescape = $__require('161');
  var _unescape2 = _interopRequireDefault(_unescape);
  var _stripLow = $__require('162');
  var _stripLow2 = _interopRequireDefault(_stripLow);
  var _whitelist = $__require('164');
  var _whitelist2 = _interopRequireDefault(_whitelist);
  var _blacklist = $__require('163');
  var _blacklist2 = _interopRequireDefault(_blacklist);
  var _isWhitelisted = $__require('165');
  var _isWhitelisted2 = _interopRequireDefault(_isWhitelisted);
  var _normalizeEmail = $__require('168');
  var _normalizeEmail2 = _interopRequireDefault(_normalizeEmail);
  var _toString = $__require('130');
  var _toString2 = _interopRequireDefault(_toString);
  function _interopRequireDefault(obj) {
    return obj && obj.__esModule ? obj : {default: obj};
  }
  var version = '5.2.0';
  var validator = {
    version: version,
    toDate: _toDate2.default,
    toFloat: _toFloat2.default,
    toInt: _toInt2.default,
    toBoolean: _toBoolean2.default,
    equals: _equals2.default,
    contains: _contains2.default,
    matches: _matches2.default,
    isEmail: _isEmail2.default,
    isURL: _isURL2.default,
    isMACAddress: _isMACAddress2.default,
    isIP: _isIP2.default,
    isFQDN: _isFQDN2.default,
    isBoolean: _isBoolean2.default,
    isAlpha: _isAlpha2.default,
    isAlphanumeric: _isAlphanumeric2.default,
    isNumeric: _isNumeric2.default,
    isLowercase: _isLowercase2.default,
    isUppercase: _isUppercase2.default,
    isAscii: _isAscii2.default,
    isFullWidth: _isFullWidth2.default,
    isHalfWidth: _isHalfWidth2.default,
    isVariableWidth: _isVariableWidth2.default,
    isMultibyte: _isMultibyte2.default,
    isSurrogatePair: _isSurrogatePair2.default,
    isInt: _isInt2.default,
    isFloat: _isFloat2.default,
    isDecimal: _isDecimal2.default,
    isHexadecimal: _isHexadecimal2.default,
    isDivisibleBy: _isDivisibleBy2.default,
    isHexColor: _isHexColor2.default,
    isJSON: _isJSON2.default,
    isNull: _isNull2.default,
    isLength: _isLength2.default,
    isByteLength: _isByteLength2.default,
    isUUID: _isUUID2.default,
    isMongoId: _isMongoId2.default,
    isDate: _isDate2.default,
    isAfter: _isAfter2.default,
    isBefore: _isBefore2.default,
    isIn: _isIn2.default,
    isCreditCard: _isCreditCard2.default,
    isISIN: _isISIN2.default,
    isISBN: _isISBN2.default,
    isMobilePhone: _isMobilePhone2.default,
    isCurrency: _isCurrency2.default,
    isISO8601: _isISO2.default,
    isBase64: _isBase2.default,
    isDataURI: _isDataURI2.default,
    ltrim: _ltrim2.default,
    rtrim: _rtrim2.default,
    trim: _trim2.default,
    escape: _escape2.default,
    unescape: _unescape2.default,
    stripLow: _stripLow2.default,
    whitelist: _whitelist2.default,
    blacklist: _blacklist2.default,
    isWhitelisted: _isWhitelisted2.default,
    normalizeEmail: _normalizeEmail2.default,
    toString: _toString2.default
  };
  exports.default = validator;
  module.exports = exports['default'];
  return module.exports;
});

$__System.registerDynamic("16a", ["169"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('169');
  return module.exports;
});

$__System.registerDynamic("16b", ["16a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var validator = $__require('16a');
  var FormatValidators = {
    "date": function(date) {
      if (typeof date !== "string") {
        return true;
      }
      var matches = /^([0-9]{4})-([0-9]{2})-([0-9]{2})$/.exec(date);
      if (matches === null) {
        return false;
      }
      if (matches[2] < "01" || matches[2] > "12" || matches[3] < "01" || matches[3] > "31") {
        return false;
      }
      return true;
    },
    "date-time": function(dateTime) {
      if (typeof dateTime !== "string") {
        return true;
      }
      var s = dateTime.toLowerCase().split("t");
      if (!FormatValidators.date(s[0])) {
        return false;
      }
      var matches = /^([0-9]{2}):([0-9]{2}):([0-9]{2})(.[0-9]+)?(z|([+-][0-9]{2}:[0-9]{2}))$/.exec(s[1]);
      if (matches === null) {
        return false;
      }
      if (matches[1] > "23" || matches[2] > "59" || matches[3] > "59") {
        return false;
      }
      return true;
    },
    "email": function(email) {
      if (typeof email !== "string") {
        return true;
      }
      return validator.isEmail(email, {"require_tld": true});
    },
    "hostname": function(hostname) {
      if (typeof hostname !== "string") {
        return true;
      }
      var valid = /^[a-zA-Z](([-0-9a-zA-Z]+)?[0-9a-zA-Z])?(\.[a-zA-Z](([-0-9a-zA-Z]+)?[0-9a-zA-Z])?)*$/.test(hostname);
      if (valid) {
        if (hostname.length > 255) {
          return false;
        }
        var labels = hostname.split(".");
        for (var i = 0; i < labels.length; i++) {
          if (labels[i].length > 63) {
            return false;
          }
        }
      }
      return valid;
    },
    "host-name": function(hostname) {
      return FormatValidators.hostname.call(this, hostname);
    },
    "ipv4": function(ipv4) {
      if (typeof ipv4 !== "string") {
        return true;
      }
      return validator.isIP(ipv4, 4);
    },
    "ipv6": function(ipv6) {
      if (typeof ipv6 !== "string") {
        return true;
      }
      return validator.isIP(ipv6, 6);
    },
    "regex": function(str) {
      try {
        RegExp(str);
        return true;
      } catch (e) {
        return false;
      }
    },
    "uri": function(uri) {
      if (this.options.strictUris) {
        return FormatValidators["strict-uri"].apply(this, arguments);
      }
      return typeof uri !== "string" || RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?").test(uri);
    },
    "strict-uri": function(uri) {
      return typeof uri !== "string" || validator.isURL(uri);
    }
  };
  module.exports = FormatValidators;
  return module.exports;
});

$__System.registerDynamic("16c", ["16b", "127", "12a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var FormatValidators = $__require('16b'),
      Report = $__require('127'),
      Utils = $__require('12a');
  var JsonValidators = {
    multipleOf: function(report, schema, json) {
      if (typeof json !== "number") {
        return;
      }
      if (Utils.whatIs(json / schema.multipleOf) !== "integer") {
        report.addError("MULTIPLE_OF", [json, schema.multipleOf], null, schema.description);
      }
    },
    maximum: function(report, schema, json) {
      if (typeof json !== "number") {
        return;
      }
      if (schema.exclusiveMaximum !== true) {
        if (json > schema.maximum) {
          report.addError("MAXIMUM", [json, schema.maximum], null, schema.description);
        }
      } else {
        if (json >= schema.maximum) {
          report.addError("MAXIMUM_EXCLUSIVE", [json, schema.maximum], null, schema.description);
        }
      }
    },
    exclusiveMaximum: function() {},
    minimum: function(report, schema, json) {
      if (typeof json !== "number") {
        return;
      }
      if (schema.exclusiveMinimum !== true) {
        if (json < schema.minimum) {
          report.addError("MINIMUM", [json, schema.minimum], null, schema.description);
        }
      } else {
        if (json <= schema.minimum) {
          report.addError("MINIMUM_EXCLUSIVE", [json, schema.minimum], null, schema.description);
        }
      }
    },
    exclusiveMinimum: function() {},
    maxLength: function(report, schema, json) {
      if (typeof json !== "string") {
        return;
      }
      if (Utils.ucs2decode(json).length > schema.maxLength) {
        report.addError("MAX_LENGTH", [json.length, schema.maxLength], null, schema.description);
      }
    },
    minLength: function(report, schema, json) {
      if (typeof json !== "string") {
        return;
      }
      if (Utils.ucs2decode(json).length < schema.minLength) {
        report.addError("MIN_LENGTH", [json.length, schema.minLength], null, schema.description);
      }
    },
    pattern: function(report, schema, json) {
      if (typeof json !== "string") {
        return;
      }
      if (RegExp(schema.pattern).test(json) === false) {
        report.addError("PATTERN", [schema.pattern, json], null, schema.description);
      }
    },
    additionalItems: function(report, schema, json) {
      if (!Array.isArray(json)) {
        return;
      }
      if (schema.additionalItems === false && Array.isArray(schema.items)) {
        if (json.length > schema.items.length) {
          report.addError("ARRAY_ADDITIONAL_ITEMS", null, null, schema.description);
        }
      }
    },
    items: function() {},
    maxItems: function(report, schema, json) {
      if (!Array.isArray(json)) {
        return;
      }
      if (json.length > schema.maxItems) {
        report.addError("ARRAY_LENGTH_LONG", [json.length, schema.maxItems], null, schema.description);
      }
    },
    minItems: function(report, schema, json) {
      if (!Array.isArray(json)) {
        return;
      }
      if (json.length < schema.minItems) {
        report.addError("ARRAY_LENGTH_SHORT", [json.length, schema.minItems], null, schema.description);
      }
    },
    uniqueItems: function(report, schema, json) {
      if (!Array.isArray(json)) {
        return;
      }
      if (schema.uniqueItems === true) {
        var matches = [];
        if (Utils.isUniqueArray(json, matches) === false) {
          report.addError("ARRAY_UNIQUE", matches, null, schema.description);
        }
      }
    },
    maxProperties: function(report, schema, json) {
      if (Utils.whatIs(json) !== "object") {
        return;
      }
      var keysCount = Object.keys(json).length;
      if (keysCount > schema.maxProperties) {
        report.addError("OBJECT_PROPERTIES_MAXIMUM", [keysCount, schema.maxProperties], null, schema.description);
      }
    },
    minProperties: function(report, schema, json) {
      if (Utils.whatIs(json) !== "object") {
        return;
      }
      var keysCount = Object.keys(json).length;
      if (keysCount < schema.minProperties) {
        report.addError("OBJECT_PROPERTIES_MINIMUM", [keysCount, schema.minProperties], null, schema.description);
      }
    },
    required: function(report, schema, json) {
      if (Utils.whatIs(json) !== "object") {
        return;
      }
      var idx = schema.required.length;
      while (idx--) {
        var requiredPropertyName = schema.required[idx];
        if (json[requiredPropertyName] === undefined) {
          report.addError("OBJECT_MISSING_REQUIRED_PROPERTY", [requiredPropertyName], null, schema.description);
        }
      }
    },
    additionalProperties: function(report, schema, json) {
      if (schema.properties === undefined && schema.patternProperties === undefined) {
        return JsonValidators.properties.call(this, report, schema, json);
      }
    },
    patternProperties: function(report, schema, json) {
      if (schema.properties === undefined) {
        return JsonValidators.properties.call(this, report, schema, json);
      }
    },
    properties: function(report, schema, json) {
      if (Utils.whatIs(json) !== "object") {
        return;
      }
      var properties = schema.properties !== undefined ? schema.properties : {};
      var patternProperties = schema.patternProperties !== undefined ? schema.patternProperties : {};
      if (schema.additionalProperties === false) {
        var s = Object.keys(json);
        var p = Object.keys(properties);
        var pp = Object.keys(patternProperties);
        s = Utils.difference(s, p);
        var idx = pp.length;
        while (idx--) {
          var regExp = RegExp(pp[idx]),
              idx2 = s.length;
          while (idx2--) {
            if (regExp.test(s[idx2]) === true) {
              s.splice(idx2, 1);
            }
          }
        }
        if (s.length > 0) {
          var idx3 = this.options.assumeAdditional.length;
          if (idx3) {
            while (idx3--) {
              var io = s.indexOf(this.options.assumeAdditional[idx3]);
              if (io !== -1) {
                s.splice(io, 1);
              }
            }
          }
          if (s.length > 0) {
            report.addError("OBJECT_ADDITIONAL_PROPERTIES", [s], null, schema.description);
          }
        }
      }
    },
    dependencies: function(report, schema, json) {
      if (Utils.whatIs(json) !== "object") {
        return;
      }
      var keys = Object.keys(schema.dependencies),
          idx = keys.length;
      while (idx--) {
        var dependencyName = keys[idx];
        if (json[dependencyName]) {
          var dependencyDefinition = schema.dependencies[dependencyName];
          if (Utils.whatIs(dependencyDefinition) === "object") {
            exports.validate.call(this, report, dependencyDefinition, json);
          } else {
            var idx2 = dependencyDefinition.length;
            while (idx2--) {
              var requiredPropertyName = dependencyDefinition[idx2];
              if (json[requiredPropertyName] === undefined) {
                report.addError("OBJECT_DEPENDENCY_KEY", [requiredPropertyName, dependencyName], null, schema.description);
              }
            }
          }
        }
      }
    },
    enum: function(report, schema, json) {
      var match = false,
          idx = schema.enum.length;
      while (idx--) {
        if (Utils.areEqual(json, schema.enum[idx])) {
          match = true;
          break;
        }
      }
      if (match === false) {
        report.addError("ENUM_MISMATCH", [json], null, schema.description);
      }
    },
    allOf: function(report, schema, json) {
      var idx = schema.allOf.length;
      while (idx--) {
        var validateResult = exports.validate.call(this, report, schema.allOf[idx], json);
        if (this.options.breakOnFirstError && validateResult === false) {
          break;
        }
      }
    },
    anyOf: function(report, schema, json) {
      var subReports = [],
          passed = false,
          idx = schema.anyOf.length;
      while (idx-- && passed === false) {
        var subReport = new Report(report);
        subReports.push(subReport);
        passed = exports.validate.call(this, subReport, schema.anyOf[idx], json);
      }
      if (passed === false) {
        report.addError("ANY_OF_MISSING", undefined, subReports, schema.description);
      }
    },
    oneOf: function(report, schema, json) {
      var passes = 0,
          subReports = [],
          idx = schema.oneOf.length;
      while (idx--) {
        var subReport = new Report(report, {maxErrors: 1});
        subReports.push(subReport);
        if (exports.validate.call(this, subReport, schema.oneOf[idx], json) === true) {
          passes++;
        }
      }
      if (passes === 0) {
        report.addError("ONE_OF_MISSING", undefined, subReports, schema.description);
      } else if (passes > 1) {
        report.addError("ONE_OF_MULTIPLE", null, null, schema.description);
      }
    },
    not: function(report, schema, json) {
      var subReport = new Report(report);
      if (exports.validate.call(this, subReport, schema.not, json) === true) {
        report.addError("NOT_PASSED", null, null, schema.description);
      }
    },
    definitions: function() {},
    format: function(report, schema, json) {
      var formatValidatorFn = FormatValidators[schema.format];
      if (typeof formatValidatorFn === "function") {
        if (formatValidatorFn.length === 2) {
          report.addAsyncTask(formatValidatorFn, [json], function(result) {
            if (result !== true) {
              report.addError("INVALID_FORMAT", [schema.format, json], null, schema.description);
            }
          });
        } else {
          if (formatValidatorFn.call(this, json) !== true) {
            report.addError("INVALID_FORMAT", [schema.format, json], null, schema.description);
          }
        }
      } else if (this.options.ignoreUnknownFormats !== true) {
        report.addError("UNKNOWN_FORMAT", [schema.format], null, schema.description);
      }
    }
  };
  var recurseArray = function(report, schema, json) {
    var idx = json.length;
    if (Array.isArray(schema.items)) {
      while (idx--) {
        if (idx < schema.items.length) {
          report.path.push(idx.toString());
          exports.validate.call(this, report, schema.items[idx], json[idx]);
          report.path.pop();
        } else {
          if (typeof schema.additionalItems === "object") {
            report.path.push(idx.toString());
            exports.validate.call(this, report, schema.additionalItems, json[idx]);
            report.path.pop();
          }
        }
      }
    } else if (typeof schema.items === "object") {
      while (idx--) {
        report.path.push(idx.toString());
        exports.validate.call(this, report, schema.items, json[idx]);
        report.path.pop();
      }
    }
  };
  var recurseObject = function(report, schema, json) {
    var additionalProperties = schema.additionalProperties;
    if (additionalProperties === true || additionalProperties === undefined) {
      additionalProperties = {};
    }
    var p = schema.properties ? Object.keys(schema.properties) : [];
    var pp = schema.patternProperties ? Object.keys(schema.patternProperties) : [];
    var keys = Object.keys(json),
        idx = keys.length;
    while (idx--) {
      var m = keys[idx],
          propertyValue = json[m];
      var s = [];
      if (p.indexOf(m) !== -1) {
        s.push(schema.properties[m]);
      }
      var idx2 = pp.length;
      while (idx2--) {
        var regexString = pp[idx2];
        if (RegExp(regexString).test(m) === true) {
          s.push(schema.patternProperties[regexString]);
        }
      }
      if (s.length === 0 && additionalProperties !== false) {
        s.push(additionalProperties);
      }
      idx2 = s.length;
      while (idx2--) {
        report.path.push(m);
        exports.validate.call(this, report, s[idx2], propertyValue);
        report.path.pop();
      }
    }
  };
  exports.validate = function(report, schema, json) {
    report.commonErrorMessage = "JSON_OBJECT_VALIDATION_FAILED";
    var to = Utils.whatIs(schema);
    if (to !== "object") {
      report.addError("SCHEMA_NOT_AN_OBJECT", [to], null, schema.description);
      return false;
    }
    var keys = Object.keys(schema);
    if (keys.length === 0) {
      return true;
    }
    var isRoot = false;
    if (!report.rootSchema) {
      report.rootSchema = schema;
      isRoot = true;
    }
    if (schema.$ref !== undefined) {
      var maxRefs = 99;
      while (schema.$ref && maxRefs > 0) {
        if (!schema.__$refResolved) {
          report.addError("REF_UNRESOLVED", [schema.$ref], null, schema.description);
          break;
        } else if (schema.__$refResolved === schema) {
          break;
        } else {
          schema = schema.__$refResolved;
          keys = Object.keys(schema);
        }
        maxRefs--;
      }
      if (maxRefs === 0) {
        throw new Error("Circular dependency by $ref references!");
      }
    }
    var jsonType = Utils.whatIs(json);
    if (schema.type) {
      if (typeof schema.type === "string") {
        if (jsonType !== schema.type && (jsonType !== "integer" || schema.type !== "number")) {
          report.addError("INVALID_TYPE", [schema.type, jsonType], null, schema.description);
          if (this.options.breakOnFirstError) {
            return false;
          }
        }
      } else {
        if (schema.type.indexOf(jsonType) === -1 && (jsonType !== "integer" || schema.type.indexOf("number") === -1)) {
          report.addError("INVALID_TYPE", [schema.type, jsonType], null, schema.description);
          if (this.options.breakOnFirstError) {
            return false;
          }
        }
      }
    }
    var idx = keys.length;
    while (idx--) {
      if (JsonValidators[keys[idx]]) {
        JsonValidators[keys[idx]].call(this, report, schema, json);
        if (report.errors.length && this.options.breakOnFirstError) {
          break;
        }
      }
    }
    if (report.errors.length === 0 || this.options.breakOnFirstError === false) {
      if (jsonType === "array") {
        recurseArray.call(this, report, schema, json);
      } else if (jsonType === "object") {
        recurseObject.call(this, report, schema, json);
      }
    }
    if (typeof this.options.customValidator === "function") {
      this.options.customValidator(report, schema, json);
    }
    if (isRoot) {
      report.rootSchema = undefined;
    }
    return report.errors.length === 0;
  };
  return module.exports;
});

$__System.registerDynamic("16d", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    var FUNC_ERROR_TEXT = 'Expected a function';
    var HASH_UNDEFINED = '__lodash_hash_undefined__';
    var INFINITY = 1 / 0;
    var funcTag = '[object Function]',
        genTag = '[object GeneratorFunction]',
        symbolTag = '[object Symbol]';
    var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]/g;
    var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
    var reEscapeChar = /\\(\\)?/g;
    var reIsHostCtor = /^\[object .+?Constructor\]$/;
    var objectTypes = {
      'function': true,
      'object': true
    };
    var freeExports = (objectTypes[typeof exports] && exports && !exports.nodeType) ? exports : undefined;
    var freeModule = (objectTypes[typeof module] && module && !module.nodeType) ? module : undefined;
    var freeGlobal = checkGlobal(freeExports && freeModule && typeof global == 'object' && global);
    var freeSelf = checkGlobal(objectTypes[typeof self] && self);
    var freeWindow = checkGlobal(objectTypes[typeof window] && window);
    var thisGlobal = checkGlobal(objectTypes[typeof this] && this);
    var root = freeGlobal || ((freeWindow !== (thisGlobal && thisGlobal.window)) && freeWindow) || freeSelf || thisGlobal || Function('return this')();
    function checkGlobal(value) {
      return (value && value.Object === Object) ? value : null;
    }
    function isHostObject(value) {
      var result = false;
      if (value != null && typeof value.toString != 'function') {
        try {
          result = !!(value + '');
        } catch (e) {}
      }
      return result;
    }
    var arrayProto = Array.prototype,
        objectProto = Object.prototype;
    var funcToString = Function.prototype.toString;
    var hasOwnProperty = objectProto.hasOwnProperty;
    var objectToString = objectProto.toString;
    var reIsNative = RegExp('^' + funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\$&').replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$');
    var Symbol = root.Symbol,
        splice = arrayProto.splice;
    var Map = getNative(root, 'Map'),
        nativeCreate = getNative(Object, 'create');
    var symbolProto = Symbol ? Symbol.prototype : undefined,
        symbolToString = symbolProto ? symbolProto.toString : undefined;
    function Hash() {}
    function hashDelete(hash, key) {
      return hashHas(hash, key) && delete hash[key];
    }
    function hashGet(hash, key) {
      if (nativeCreate) {
        var result = hash[key];
        return result === HASH_UNDEFINED ? undefined : result;
      }
      return hasOwnProperty.call(hash, key) ? hash[key] : undefined;
    }
    function hashHas(hash, key) {
      return nativeCreate ? hash[key] !== undefined : hasOwnProperty.call(hash, key);
    }
    function hashSet(hash, key, value) {
      hash[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;
    }
    Hash.prototype = nativeCreate ? nativeCreate(null) : objectProto;
    function MapCache(values) {
      var index = -1,
          length = values ? values.length : 0;
      this.clear();
      while (++index < length) {
        var entry = values[index];
        this.set(entry[0], entry[1]);
      }
    }
    function mapClear() {
      this.__data__ = {
        'hash': new Hash,
        'map': Map ? new Map : [],
        'string': new Hash
      };
    }
    function mapDelete(key) {
      var data = this.__data__;
      if (isKeyable(key)) {
        return hashDelete(typeof key == 'string' ? data.string : data.hash, key);
      }
      return Map ? data.map['delete'](key) : assocDelete(data.map, key);
    }
    function mapGet(key) {
      var data = this.__data__;
      if (isKeyable(key)) {
        return hashGet(typeof key == 'string' ? data.string : data.hash, key);
      }
      return Map ? data.map.get(key) : assocGet(data.map, key);
    }
    function mapHas(key) {
      var data = this.__data__;
      if (isKeyable(key)) {
        return hashHas(typeof key == 'string' ? data.string : data.hash, key);
      }
      return Map ? data.map.has(key) : assocHas(data.map, key);
    }
    function mapSet(key, value) {
      var data = this.__data__;
      if (isKeyable(key)) {
        hashSet(typeof key == 'string' ? data.string : data.hash, key, value);
      } else if (Map) {
        data.map.set(key, value);
      } else {
        assocSet(data.map, key, value);
      }
      return this;
    }
    MapCache.prototype.clear = mapClear;
    MapCache.prototype['delete'] = mapDelete;
    MapCache.prototype.get = mapGet;
    MapCache.prototype.has = mapHas;
    MapCache.prototype.set = mapSet;
    function assocDelete(array, key) {
      var index = assocIndexOf(array, key);
      if (index < 0) {
        return false;
      }
      var lastIndex = array.length - 1;
      if (index == lastIndex) {
        array.pop();
      } else {
        splice.call(array, index, 1);
      }
      return true;
    }
    function assocGet(array, key) {
      var index = assocIndexOf(array, key);
      return index < 0 ? undefined : array[index][1];
    }
    function assocHas(array, key) {
      return assocIndexOf(array, key) > -1;
    }
    function assocIndexOf(array, key) {
      var length = array.length;
      while (length--) {
        if (eq(array[length][0], key)) {
          return length;
        }
      }
      return -1;
    }
    function assocSet(array, key, value) {
      var index = assocIndexOf(array, key);
      if (index < 0) {
        array.push([key, value]);
      } else {
        array[index][1] = value;
      }
    }
    function getNative(object, key) {
      var value = object[key];
      return isNative(value) ? value : undefined;
    }
    function isKeyable(value) {
      var type = typeof value;
      return type == 'number' || type == 'boolean' || (type == 'string' && value != '__proto__') || value == null;
    }
    var stringToPath = memoize(function(string) {
      var result = [];
      toString(string).replace(rePropName, function(match, number, quote, string) {
        result.push(quote ? string.replace(reEscapeChar, '$1') : (number || match));
      });
      return result;
    });
    function toSource(func) {
      if (func != null) {
        try {
          return funcToString.call(func);
        } catch (e) {}
        try {
          return (func + '');
        } catch (e) {}
      }
      return '';
    }
    function memoize(func, resolver) {
      if (typeof func != 'function' || (resolver && typeof resolver != 'function')) {
        throw new TypeError(FUNC_ERROR_TEXT);
      }
      var memoized = function() {
        var args = arguments,
            key = resolver ? resolver.apply(this, args) : args[0],
            cache = memoized.cache;
        if (cache.has(key)) {
          return cache.get(key);
        }
        var result = func.apply(this, args);
        memoized.cache = cache.set(key, result);
        return result;
      };
      memoized.cache = new (memoize.Cache || MapCache);
      return memoized;
    }
    memoize.Cache = MapCache;
    function eq(value, other) {
      return value === other || (value !== value && other !== other);
    }
    function isFunction(value) {
      var tag = isObject(value) ? objectToString.call(value) : '';
      return tag == funcTag || tag == genTag;
    }
    function isObject(value) {
      var type = typeof value;
      return !!value && (type == 'object' || type == 'function');
    }
    function isObjectLike(value) {
      return !!value && typeof value == 'object';
    }
    function isNative(value) {
      if (!isObject(value)) {
        return false;
      }
      var pattern = (isFunction(value) || isHostObject(value)) ? reIsNative : reIsHostCtor;
      return pattern.test(toSource(value));
    }
    function isSymbol(value) {
      return typeof value == 'symbol' || (isObjectLike(value) && objectToString.call(value) == symbolTag);
    }
    function toString(value) {
      if (typeof value == 'string') {
        return value;
      }
      if (value == null) {
        return '';
      }
      if (isSymbol(value)) {
        return symbolToString ? symbolToString.call(value) : '';
      }
      var result = (value + '');
      return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;
    }
    module.exports = stringToPath;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("16e", ["16d"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('16d');
  return module.exports;
});

$__System.registerDynamic("16f", ["16e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var stringToPath = $__require('16e');
  var symbolTag = '[object Symbol]';
  var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,
      reIsPlainProp = /^\w*$/;
  var objectProto = Object.prototype;
  var objectToString = objectProto.toString;
  function baseGet(object, path) {
    path = isKey(path, object) ? [path] : castPath(path);
    var index = 0,
        length = path.length;
    while (object != null && index < length) {
      object = object[path[index++]];
    }
    return (index && index == length) ? object : undefined;
  }
  function castPath(value) {
    return isArray(value) ? value : stringToPath(value);
  }
  function isKey(value, object) {
    var type = typeof value;
    if (type == 'number' || type == 'symbol') {
      return true;
    }
    return !isArray(value) && (isSymbol(value) || reIsPlainProp.test(value) || !reIsDeepProp.test(value) || (object != null && value in Object(object)));
  }
  var isArray = Array.isArray;
  function isObjectLike(value) {
    return !!value && typeof value == 'object';
  }
  function isSymbol(value) {
    return typeof value == 'symbol' || (isObjectLike(value) && objectToString.call(value) == symbolTag);
  }
  function get(object, path, defaultValue) {
    var result = object == null ? undefined : baseGet(object, path);
    return result === undefined ? defaultValue : result;
  }
  module.exports = get;
  return module.exports;
});

$__System.registerDynamic("170", ["16f"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('16f');
  return module.exports;
});

$__System.registerDynamic("171", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    INVALID_TYPE: "Expected type {0} but found type {1}",
    INVALID_FORMAT: "Object didn't pass validation for format {0}: {1}",
    ENUM_MISMATCH: "No enum match for: {0}",
    ANY_OF_MISSING: "Data does not match any schemas from 'anyOf'",
    ONE_OF_MISSING: "Data does not match any schemas from 'oneOf'",
    ONE_OF_MULTIPLE: "Data is valid against more than one schema from 'oneOf'",
    NOT_PASSED: "Data matches schema from 'not'",
    ARRAY_LENGTH_SHORT: "Array is too short ({0}), minimum {1}",
    ARRAY_LENGTH_LONG: "Array is too long ({0}), maximum {1}",
    ARRAY_UNIQUE: "Array items are not unique (indexes {0} and {1})",
    ARRAY_ADDITIONAL_ITEMS: "Additional items not allowed",
    MULTIPLE_OF: "Value {0} is not a multiple of {1}",
    MINIMUM: "Value {0} is less than minimum {1}",
    MINIMUM_EXCLUSIVE: "Value {0} is equal or less than exclusive minimum {1}",
    MAXIMUM: "Value {0} is greater than maximum {1}",
    MAXIMUM_EXCLUSIVE: "Value {0} is equal or greater than exclusive maximum {1}",
    OBJECT_PROPERTIES_MINIMUM: "Too few properties defined ({0}), minimum {1}",
    OBJECT_PROPERTIES_MAXIMUM: "Too many properties defined ({0}), maximum {1}",
    OBJECT_MISSING_REQUIRED_PROPERTY: "Missing required property: {0}",
    OBJECT_ADDITIONAL_PROPERTIES: "Additional properties not allowed: {0}",
    OBJECT_DEPENDENCY_KEY: "Dependency failed - key must exist: {0} (due to key: {1})",
    MIN_LENGTH: "String is too short ({0} chars), minimum {1}",
    MAX_LENGTH: "String is too long ({0} chars), maximum {1}",
    PATTERN: "String does not match pattern {0}: {1}",
    KEYWORD_TYPE_EXPECTED: "Keyword '{0}' is expected to be of type '{1}'",
    KEYWORD_UNDEFINED_STRICT: "Keyword '{0}' must be defined in strict mode",
    KEYWORD_UNEXPECTED: "Keyword '{0}' is not expected to appear in the schema",
    KEYWORD_MUST_BE: "Keyword '{0}' must be {1}",
    KEYWORD_DEPENDENCY: "Keyword '{0}' requires keyword '{1}'",
    KEYWORD_PATTERN: "Keyword '{0}' is not a valid RegExp pattern: {1}",
    KEYWORD_VALUE_TYPE: "Each element of keyword '{0}' array must be a '{1}'",
    UNKNOWN_FORMAT: "There is no validation function for format '{0}'",
    CUSTOM_MODE_FORCE_PROPERTIES: "{0} must define at least one property if present",
    REF_UNRESOLVED: "Reference has not been resolved during compilation: {0}",
    UNRESOLVABLE_REFERENCE: "Reference could not be resolved: {0}",
    SCHEMA_NOT_REACHABLE: "Validator was not able to read schema with uri: {0}",
    SCHEMA_TYPE_EXPECTED: "Schema is expected to be of type 'object'",
    SCHEMA_NOT_AN_OBJECT: "Schema is not an object: {0}",
    ASYNC_TIMEOUT: "{0} asynchronous task(s) have timed out after {1} ms",
    PARENT_SCHEMA_VALIDATION_FAILED: "Schema failed to validate against its parent schema, see inner errors for details.",
    REMOTE_NOT_VALID: "Remote reference didn't compile successfully: {0}"
  };
  return module.exports;
});

$__System.registerDynamic("127", ["170", "171", "12a", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var get = $__require('170');
    var Errors = $__require('171');
    var Utils = $__require('12a');
    function Report(parentOrOptions, reportOptions) {
      this.parentReport = parentOrOptions instanceof Report ? parentOrOptions : undefined;
      this.options = parentOrOptions instanceof Report ? parentOrOptions.options : parentOrOptions || {};
      this.reportOptions = reportOptions || {};
      this.errors = [];
      this.path = [];
      this.asyncTasks = [];
    }
    Report.prototype.isValid = function() {
      if (this.asyncTasks.length > 0) {
        throw new Error("Async tasks pending, can't answer isValid");
      }
      return this.errors.length === 0;
    };
    Report.prototype.addAsyncTask = function(fn, args, asyncTaskResultProcessFn) {
      this.asyncTasks.push([fn, args, asyncTaskResultProcessFn]);
    };
    Report.prototype.processAsyncTasks = function(timeout, callback) {
      var validationTimeout = timeout || 2000,
          tasksCount = this.asyncTasks.length,
          idx = tasksCount,
          timedOut = false,
          self = this;
      function finish() {
        process.nextTick(function() {
          var valid = self.errors.length === 0,
              err = valid ? undefined : self.errors;
          callback(err, valid);
        });
      }
      function respond(asyncTaskResultProcessFn) {
        return function(asyncTaskResult) {
          if (timedOut) {
            return;
          }
          asyncTaskResultProcessFn(asyncTaskResult);
          if (--tasksCount === 0) {
            finish();
          }
        };
      }
      if (tasksCount === 0 || this.errors.length > 0) {
        finish();
        return;
      }
      while (idx--) {
        var task = this.asyncTasks[idx];
        task[0].apply(null, task[1].concat(respond(task[2])));
      }
      setTimeout(function() {
        if (tasksCount > 0) {
          timedOut = true;
          self.addError("ASYNC_TIMEOUT", [tasksCount, validationTimeout]);
          callback(self.errors, false);
        }
      }, validationTimeout);
    };
    Report.prototype.getPath = function(returnPathAsString) {
      var path = [];
      if (this.parentReport) {
        path = path.concat(this.parentReport.path);
      }
      path = path.concat(this.path);
      if (returnPathAsString !== true) {
        path = "#/" + path.map(function(segment) {
          if (Utils.isAbsoluteUri(segment)) {
            return "uri(" + segment + ")";
          }
          return segment.replace(/\~/g, "~0").replace(/\//g, "~1");
        }).join("/");
      }
      return path;
    };
    Report.prototype.getSchemaId = function() {
      if (!this.rootSchema) {
        return null;
      }
      var path = [];
      if (this.parentReport) {
        path = path.concat(this.parentReport.path);
      }
      path = path.concat(this.path);
      while (path.length > 0) {
        var obj = get(this.rootSchema, path);
        if (obj && obj.id) {
          return obj.id;
        }
        path.pop();
      }
      return this.rootSchema.id;
    };
    Report.prototype.hasError = function(errorCode, params) {
      var idx = this.errors.length;
      while (idx--) {
        if (this.errors[idx].code === errorCode) {
          var match = true;
          var idx2 = this.errors[idx].params.length;
          while (idx2--) {
            if (this.errors[idx].params[idx2] !== params[idx2]) {
              match = false;
            }
          }
          if (match) {
            return match;
          }
        }
      }
      return false;
    };
    Report.prototype.addError = function(errorCode, params, subReports, schemaDescription) {
      if (!errorCode) {
        throw new Error("No errorCode passed into addError()");
      }
      this.addCustomError(errorCode, Errors[errorCode], params, subReports, schemaDescription);
    };
    Report.prototype.addCustomError = function(errorCode, errorMessage, params, subReports, schemaDescription) {
      if (this.errors.length >= this.reportOptions.maxErrors) {
        return;
      }
      if (!errorMessage) {
        throw new Error("No errorMessage known for code " + errorCode);
      }
      params = params || [];
      var idx = params.length;
      while (idx--) {
        var whatIs = Utils.whatIs(params[idx]);
        var param = (whatIs === "object" || whatIs === "null") ? JSON.stringify(params[idx]) : params[idx];
        errorMessage = errorMessage.replace("{" + idx + "}", param);
      }
      var err = {
        code: errorCode,
        params: params,
        message: errorMessage,
        path: this.getPath(this.options.reportPathAsArray),
        schemaId: this.getSchemaId()
      };
      if (schemaDescription) {
        err.description = schemaDescription;
      }
      if (subReports != null) {
        if (!Array.isArray(subReports)) {
          subReports = [subReports];
        }
        err.inner = [];
        idx = subReports.length;
        while (idx--) {
          var subReport = subReports[idx],
              idx2 = subReport.errors.length;
          while (idx2--) {
            err.inner.push(subReport.errors[idx2]);
          }
        }
        if (err.inner.length === 0) {
          err.inner = undefined;
        }
      }
      this.errors.push(err);
    };
    module.exports = Report;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("129", ["16b", "16c", "127", "12a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var FormatValidators = $__require('16b'),
      JsonValidation = $__require('16c'),
      Report = $__require('127'),
      Utils = $__require('12a');
  var SchemaValidators = {
    $ref: function(report, schema) {
      if (typeof schema.$ref !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["$ref", "string"]);
      }
    },
    $schema: function(report, schema) {
      if (typeof schema.$schema !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["$schema", "string"]);
      }
    },
    multipleOf: function(report, schema) {
      if (typeof schema.multipleOf !== "number") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["multipleOf", "number"]);
      } else if (schema.multipleOf <= 0) {
        report.addError("KEYWORD_MUST_BE", ["multipleOf", "strictly greater than 0"]);
      }
    },
    maximum: function(report, schema) {
      if (typeof schema.maximum !== "number") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["maximum", "number"]);
      }
    },
    exclusiveMaximum: function(report, schema) {
      if (typeof schema.exclusiveMaximum !== "boolean") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["exclusiveMaximum", "boolean"]);
      } else if (schema.maximum === undefined) {
        report.addError("KEYWORD_DEPENDENCY", ["exclusiveMaximum", "maximum"]);
      }
    },
    minimum: function(report, schema) {
      if (typeof schema.minimum !== "number") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["minimum", "number"]);
      }
    },
    exclusiveMinimum: function(report, schema) {
      if (typeof schema.exclusiveMinimum !== "boolean") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["exclusiveMinimum", "boolean"]);
      } else if (schema.minimum === undefined) {
        report.addError("KEYWORD_DEPENDENCY", ["exclusiveMinimum", "minimum"]);
      }
    },
    maxLength: function(report, schema) {
      if (Utils.whatIs(schema.maxLength) !== "integer") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["maxLength", "integer"]);
      } else if (schema.maxLength < 0) {
        report.addError("KEYWORD_MUST_BE", ["maxLength", "greater than, or equal to 0"]);
      }
    },
    minLength: function(report, schema) {
      if (Utils.whatIs(schema.minLength) !== "integer") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["minLength", "integer"]);
      } else if (schema.minLength < 0) {
        report.addError("KEYWORD_MUST_BE", ["minLength", "greater than, or equal to 0"]);
      }
    },
    pattern: function(report, schema) {
      if (typeof schema.pattern !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["pattern", "string"]);
      } else {
        try {
          RegExp(schema.pattern);
        } catch (e) {
          report.addError("KEYWORD_PATTERN", ["pattern", schema.pattern]);
        }
      }
    },
    additionalItems: function(report, schema) {
      var type = Utils.whatIs(schema.additionalItems);
      if (type !== "boolean" && type !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["additionalItems", ["boolean", "object"]]);
      } else if (type === "object") {
        report.path.push("additionalItems");
        exports.validateSchema.call(this, report, schema.additionalItems);
        report.path.pop();
      }
    },
    items: function(report, schema) {
      var type = Utils.whatIs(schema.items);
      if (type === "object") {
        report.path.push("items");
        exports.validateSchema.call(this, report, schema.items);
        report.path.pop();
      } else if (type === "array") {
        var idx = schema.items.length;
        while (idx--) {
          report.path.push("items");
          report.path.push(idx.toString());
          exports.validateSchema.call(this, report, schema.items[idx]);
          report.path.pop();
          report.path.pop();
        }
      } else {
        report.addError("KEYWORD_TYPE_EXPECTED", ["items", ["array", "object"]]);
      }
      if (this.options.forceAdditional === true && schema.additionalItems === undefined && Array.isArray(schema.items)) {
        report.addError("KEYWORD_UNDEFINED_STRICT", ["additionalItems"]);
      }
      if (this.options.assumeAdditional && schema.additionalItems === undefined && Array.isArray(schema.items)) {
        schema.additionalItems = false;
      }
    },
    maxItems: function(report, schema) {
      if (typeof schema.maxItems !== "number") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["maxItems", "integer"]);
      } else if (schema.maxItems < 0) {
        report.addError("KEYWORD_MUST_BE", ["maxItems", "greater than, or equal to 0"]);
      }
    },
    minItems: function(report, schema) {
      if (Utils.whatIs(schema.minItems) !== "integer") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["minItems", "integer"]);
      } else if (schema.minItems < 0) {
        report.addError("KEYWORD_MUST_BE", ["minItems", "greater than, or equal to 0"]);
      }
    },
    uniqueItems: function(report, schema) {
      if (typeof schema.uniqueItems !== "boolean") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["uniqueItems", "boolean"]);
      }
    },
    maxProperties: function(report, schema) {
      if (Utils.whatIs(schema.maxProperties) !== "integer") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["maxProperties", "integer"]);
      } else if (schema.maxProperties < 0) {
        report.addError("KEYWORD_MUST_BE", ["maxProperties", "greater than, or equal to 0"]);
      }
    },
    minProperties: function(report, schema) {
      if (Utils.whatIs(schema.minProperties) !== "integer") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["minProperties", "integer"]);
      } else if (schema.minProperties < 0) {
        report.addError("KEYWORD_MUST_BE", ["minProperties", "greater than, or equal to 0"]);
      }
    },
    required: function(report, schema) {
      if (Utils.whatIs(schema.required) !== "array") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["required", "array"]);
      } else if (schema.required.length === 0) {
        report.addError("KEYWORD_MUST_BE", ["required", "an array with at least one element"]);
      } else {
        var idx = schema.required.length;
        while (idx--) {
          if (typeof schema.required[idx] !== "string") {
            report.addError("KEYWORD_VALUE_TYPE", ["required", "string"]);
          }
        }
        if (Utils.isUniqueArray(schema.required) === false) {
          report.addError("KEYWORD_MUST_BE", ["required", "an array with unique items"]);
        }
      }
    },
    additionalProperties: function(report, schema) {
      var type = Utils.whatIs(schema.additionalProperties);
      if (type !== "boolean" && type !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["additionalProperties", ["boolean", "object"]]);
      } else if (type === "object") {
        report.path.push("additionalProperties");
        exports.validateSchema.call(this, report, schema.additionalProperties);
        report.path.pop();
      }
    },
    properties: function(report, schema) {
      if (Utils.whatIs(schema.properties) !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["properties", "object"]);
        return;
      }
      var keys = Object.keys(schema.properties),
          idx = keys.length;
      while (idx--) {
        var key = keys[idx],
            val = schema.properties[key];
        report.path.push("properties");
        report.path.push(key);
        exports.validateSchema.call(this, report, val);
        report.path.pop();
        report.path.pop();
      }
      if (this.options.forceAdditional === true && schema.additionalProperties === undefined) {
        report.addError("KEYWORD_UNDEFINED_STRICT", ["additionalProperties"]);
      }
      if (this.options.assumeAdditional && schema.additionalProperties === undefined) {
        schema.additionalProperties = false;
      }
      if (this.options.forceProperties === true && keys.length === 0) {
        report.addError("CUSTOM_MODE_FORCE_PROPERTIES", ["properties"]);
      }
    },
    patternProperties: function(report, schema) {
      if (Utils.whatIs(schema.patternProperties) !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["patternProperties", "object"]);
        return;
      }
      var keys = Object.keys(schema.patternProperties),
          idx = keys.length;
      while (idx--) {
        var key = keys[idx],
            val = schema.patternProperties[key];
        try {
          RegExp(key);
        } catch (e) {
          report.addError("KEYWORD_PATTERN", ["patternProperties", key]);
        }
        report.path.push("patternProperties");
        report.path.push(key.toString());
        exports.validateSchema.call(this, report, val);
        report.path.pop();
        report.path.pop();
      }
      if (this.options.forceProperties === true && keys.length === 0) {
        report.addError("CUSTOM_MODE_FORCE_PROPERTIES", ["patternProperties"]);
      }
    },
    dependencies: function(report, schema) {
      if (Utils.whatIs(schema.dependencies) !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["dependencies", "object"]);
      } else {
        var keys = Object.keys(schema.dependencies),
            idx = keys.length;
        while (idx--) {
          var schemaKey = keys[idx],
              schemaDependency = schema.dependencies[schemaKey],
              type = Utils.whatIs(schemaDependency);
          if (type === "object") {
            report.path.push("dependencies");
            report.path.push(schemaKey);
            exports.validateSchema.call(this, report, schemaDependency);
            report.path.pop();
            report.path.pop();
          } else if (type === "array") {
            var idx2 = schemaDependency.length;
            if (idx2 === 0) {
              report.addError("KEYWORD_MUST_BE", ["dependencies", "not empty array"]);
            }
            while (idx2--) {
              if (typeof schemaDependency[idx2] !== "string") {
                report.addError("KEYWORD_VALUE_TYPE", ["dependensices", "string"]);
              }
            }
            if (Utils.isUniqueArray(schemaDependency) === false) {
              report.addError("KEYWORD_MUST_BE", ["dependencies", "an array with unique items"]);
            }
          } else {
            report.addError("KEYWORD_VALUE_TYPE", ["dependencies", "object or array"]);
          }
        }
      }
    },
    enum: function(report, schema) {
      if (Array.isArray(schema.enum) === false) {
        report.addError("KEYWORD_TYPE_EXPECTED", ["enum", "array"]);
      } else if (schema.enum.length === 0) {
        report.addError("KEYWORD_MUST_BE", ["enum", "an array with at least one element"]);
      } else if (Utils.isUniqueArray(schema.enum) === false) {
        report.addError("KEYWORD_MUST_BE", ["enum", "an array with unique elements"]);
      }
    },
    type: function(report, schema) {
      var primitiveTypes = ["array", "boolean", "integer", "number", "null", "object", "string"],
          primitiveTypeStr = primitiveTypes.join(","),
          isArray = Array.isArray(schema.type);
      if (isArray) {
        var idx = schema.type.length;
        while (idx--) {
          if (primitiveTypes.indexOf(schema.type[idx]) === -1) {
            report.addError("KEYWORD_TYPE_EXPECTED", ["type", primitiveTypeStr]);
          }
        }
        if (Utils.isUniqueArray(schema.type) === false) {
          report.addError("KEYWORD_MUST_BE", ["type", "an object with unique properties"]);
        }
      } else if (typeof schema.type === "string") {
        if (primitiveTypes.indexOf(schema.type) === -1) {
          report.addError("KEYWORD_TYPE_EXPECTED", ["type", primitiveTypeStr]);
        }
      } else {
        report.addError("KEYWORD_TYPE_EXPECTED", ["type", ["string", "array"]]);
      }
      if (this.options.noEmptyStrings === true) {
        if (schema.type === "string" || isArray && schema.type.indexOf("string") !== -1) {
          if (schema.minLength === undefined && schema.enum === undefined && schema.format === undefined) {
            schema.minLength = 1;
          }
        }
      }
      if (this.options.noEmptyArrays === true) {
        if (schema.type === "array" || isArray && schema.type.indexOf("array") !== -1) {
          if (schema.minItems === undefined) {
            schema.minItems = 1;
          }
        }
      }
      if (this.options.forceProperties === true) {
        if (schema.type === "object" || isArray && schema.type.indexOf("object") !== -1) {
          if (schema.properties === undefined && schema.patternProperties === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["properties"]);
          }
        }
      }
      if (this.options.forceItems === true) {
        if (schema.type === "array" || isArray && schema.type.indexOf("array") !== -1) {
          if (schema.items === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["items"]);
          }
        }
      }
      if (this.options.forceMinItems === true) {
        if (schema.type === "array" || isArray && schema.type.indexOf("array") !== -1) {
          if (schema.minItems === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["minItems"]);
          }
        }
      }
      if (this.options.forceMaxItems === true) {
        if (schema.type === "array" || isArray && schema.type.indexOf("array") !== -1) {
          if (schema.maxItems === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["maxItems"]);
          }
        }
      }
      if (this.options.forceMinLength === true) {
        if (schema.type === "string" || isArray && schema.type.indexOf("string") !== -1) {
          if (schema.minLength === undefined && schema.format === undefined && schema.enum === undefined && schema.pattern === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["minLength"]);
          }
        }
      }
      if (this.options.forceMaxLength === true) {
        if (schema.type === "string" || isArray && schema.type.indexOf("string") !== -1) {
          if (schema.maxLength === undefined && schema.format === undefined && schema.enum === undefined && schema.pattern === undefined) {
            report.addError("KEYWORD_UNDEFINED_STRICT", ["maxLength"]);
          }
        }
      }
    },
    allOf: function(report, schema) {
      if (Array.isArray(schema.allOf) === false) {
        report.addError("KEYWORD_TYPE_EXPECTED", ["allOf", "array"]);
      } else if (schema.allOf.length === 0) {
        report.addError("KEYWORD_MUST_BE", ["allOf", "an array with at least one element"]);
      } else {
        var idx = schema.allOf.length;
        while (idx--) {
          report.path.push("allOf");
          report.path.push(idx.toString());
          exports.validateSchema.call(this, report, schema.allOf[idx]);
          report.path.pop();
          report.path.pop();
        }
      }
    },
    anyOf: function(report, schema) {
      if (Array.isArray(schema.anyOf) === false) {
        report.addError("KEYWORD_TYPE_EXPECTED", ["anyOf", "array"]);
      } else if (schema.anyOf.length === 0) {
        report.addError("KEYWORD_MUST_BE", ["anyOf", "an array with at least one element"]);
      } else {
        var idx = schema.anyOf.length;
        while (idx--) {
          report.path.push("anyOf");
          report.path.push(idx.toString());
          exports.validateSchema.call(this, report, schema.anyOf[idx]);
          report.path.pop();
          report.path.pop();
        }
      }
    },
    oneOf: function(report, schema) {
      if (Array.isArray(schema.oneOf) === false) {
        report.addError("KEYWORD_TYPE_EXPECTED", ["oneOf", "array"]);
      } else if (schema.oneOf.length === 0) {
        report.addError("KEYWORD_MUST_BE", ["oneOf", "an array with at least one element"]);
      } else {
        var idx = schema.oneOf.length;
        while (idx--) {
          report.path.push("oneOf");
          report.path.push(idx.toString());
          exports.validateSchema.call(this, report, schema.oneOf[idx]);
          report.path.pop();
          report.path.pop();
        }
      }
    },
    not: function(report, schema) {
      if (Utils.whatIs(schema.not) !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["not", "object"]);
      } else {
        report.path.push("not");
        exports.validateSchema.call(this, report, schema.not);
        report.path.pop();
      }
    },
    definitions: function(report, schema) {
      if (Utils.whatIs(schema.definitions) !== "object") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["definitions", "object"]);
      } else {
        var keys = Object.keys(schema.definitions),
            idx = keys.length;
        while (idx--) {
          var key = keys[idx],
              val = schema.definitions[key];
          report.path.push("definitions");
          report.path.push(key);
          exports.validateSchema.call(this, report, val);
          report.path.pop();
          report.path.pop();
        }
      }
    },
    format: function(report, schema) {
      if (typeof schema.format !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["format", "string"]);
      } else {
        if (FormatValidators[schema.format] === undefined && this.options.ignoreUnknownFormats !== true) {
          report.addError("UNKNOWN_FORMAT", [schema.format]);
        }
      }
    },
    id: function(report, schema) {
      if (typeof schema.id !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["id", "string"]);
      }
    },
    title: function(report, schema) {
      if (typeof schema.title !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["title", "string"]);
      }
    },
    description: function(report, schema) {
      if (typeof schema.description !== "string") {
        report.addError("KEYWORD_TYPE_EXPECTED", ["description", "string"]);
      }
    },
    "default": function() {}
  };
  var validateArrayOfSchemas = function(report, arr) {
    var idx = arr.length;
    while (idx--) {
      exports.validateSchema.call(this, report, arr[idx]);
    }
    return report.isValid();
  };
  exports.validateSchema = function(report, schema) {
    report.commonErrorMessage = "SCHEMA_VALIDATION_FAILED";
    if (Array.isArray(schema)) {
      return validateArrayOfSchemas.call(this, report, schema);
    }
    if (schema.__$validated) {
      return true;
    }
    var hasParentSchema = schema.$schema && schema.id !== schema.$schema;
    if (hasParentSchema) {
      if (schema.__$schemaResolved && schema.__$schemaResolved !== schema) {
        var subReport = new Report(report);
        var valid = JsonValidation.validate.call(this, subReport, schema.__$schemaResolved, schema);
        if (valid === false) {
          report.addError("PARENT_SCHEMA_VALIDATION_FAILED", null, subReport);
        }
      } else {
        if (this.options.ignoreUnresolvableReferences !== true) {
          report.addError("REF_UNRESOLVED", [schema.$schema]);
        }
      }
    }
    if (this.options.noTypeless === true) {
      if (schema.type !== undefined) {
        var schemas = [];
        if (Array.isArray(schema.anyOf)) {
          schemas = schemas.concat(schema.anyOf);
        }
        if (Array.isArray(schema.oneOf)) {
          schemas = schemas.concat(schema.oneOf);
        }
        if (Array.isArray(schema.allOf)) {
          schemas = schemas.concat(schema.allOf);
        }
        schemas.forEach(function(sch) {
          if (!sch.type) {
            sch.type = schema.type;
          }
        });
      }
      if (schema.enum === undefined && schema.type === undefined && schema.anyOf === undefined && schema.oneOf === undefined && schema.not === undefined && schema.$ref === undefined) {
        report.addError("KEYWORD_UNDEFINED_STRICT", ["type"]);
      }
    }
    var keys = Object.keys(schema),
        idx = keys.length;
    while (idx--) {
      var key = keys[idx];
      if (key.indexOf("__") === 0) {
        continue;
      }
      if (SchemaValidators[key] !== undefined) {
        SchemaValidators[key].call(this, report, schema);
      } else if (!hasParentSchema) {
        if (this.options.noExtraKeywords === true) {
          report.addError("KEYWORD_UNEXPECTED", [key]);
        }
      }
    }
    if (this.options.pedanticCheck === true) {
      if (schema.enum) {
        var tmpSchema = Utils.clone(schema);
        delete tmpSchema.enum;
        delete tmpSchema.default;
        report.path.push("enum");
        idx = schema.enum.length;
        while (idx--) {
          report.path.push(idx.toString());
          JsonValidation.validate.call(this, report, tmpSchema, schema.enum[idx]);
          report.path.pop();
        }
        report.path.pop();
      }
      if (schema.default) {
        report.path.push("default");
        JsonValidation.validate.call(this, report, schema, schema.default);
        report.path.pop();
      }
    }
    var isValid = report.isValid();
    if (isValid) {
      schema.__$validated = true;
    }
    return isValid;
  };
  return module.exports;
});

$__System.registerDynamic("12a", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.isAbsoluteUri = function(uri) {
    return /^https?:\/\//.test(uri);
  };
  exports.isRelativeUri = function(uri) {
    return /.+#/.test(uri);
  };
  exports.whatIs = function(what) {
    var to = typeof what;
    if (to === "object") {
      if (what === null) {
        return "null";
      }
      if (Array.isArray(what)) {
        return "array";
      }
      return "object";
    }
    if (to === "number") {
      if (Number.isFinite(what)) {
        if (what % 1 === 0) {
          return "integer";
        } else {
          return "number";
        }
      }
      if (Number.isNaN(what)) {
        return "not-a-number";
      }
      return "unknown-number";
    }
    return to;
  };
  exports.areEqual = function areEqual(json1, json2) {
    if (json1 === json2) {
      return true;
    }
    var i,
        len;
    if (Array.isArray(json1) && Array.isArray(json2)) {
      if (json1.length !== json2.length) {
        return false;
      }
      len = json1.length;
      for (i = 0; i < len; i++) {
        if (!areEqual(json1[i], json2[i])) {
          return false;
        }
      }
      return true;
    }
    if (exports.whatIs(json1) === "object" && exports.whatIs(json2) === "object") {
      var keys1 = Object.keys(json1);
      var keys2 = Object.keys(json2);
      if (!areEqual(keys1, keys2)) {
        return false;
      }
      len = keys1.length;
      for (i = 0; i < len; i++) {
        if (!areEqual(json1[keys1[i]], json2[keys1[i]])) {
          return false;
        }
      }
      return true;
    }
    return false;
  };
  exports.isUniqueArray = function(arr, indexes) {
    var i,
        j,
        l = arr.length;
    for (i = 0; i < l; i++) {
      for (j = i + 1; j < l; j++) {
        if (exports.areEqual(arr[i], arr[j])) {
          if (indexes) {
            indexes.push(i, j);
          }
          return false;
        }
      }
    }
    return true;
  };
  exports.difference = function(bigSet, subSet) {
    var arr = [],
        idx = bigSet.length;
    while (idx--) {
      if (subSet.indexOf(bigSet[idx]) === -1) {
        arr.push(bigSet[idx]);
      }
    }
    return arr;
  };
  exports.clone = function(src) {
    if (typeof src === "undefined") {
      return void 0;
    }
    if (typeof src !== "object" || src === null) {
      return src;
    }
    var res,
        idx;
    if (Array.isArray(src)) {
      res = [];
      idx = src.length;
      while (idx--) {
        res[idx] = src[idx];
      }
    } else {
      res = {};
      var keys = Object.keys(src);
      idx = keys.length;
      while (idx--) {
        var key = keys[idx];
        res[key] = src[key];
      }
    }
    return res;
  };
  exports.cloneDeep = function(src) {
    var visited = [],
        cloned = [];
    function cloneDeep(src) {
      if (typeof src !== "object" || src === null) {
        return src;
      }
      var res,
          idx,
          cidx;
      cidx = visited.indexOf(src);
      if (cidx !== -1) {
        return cloned[cidx];
      }
      visited.push(src);
      if (Array.isArray(src)) {
        res = [];
        cloned.push(res);
        idx = src.length;
        while (idx--) {
          res[idx] = cloneDeep(src[idx]);
        }
      } else {
        res = {};
        cloned.push(res);
        var keys = Object.keys(src);
        idx = keys.length;
        while (idx--) {
          var key = keys[idx];
          res[key] = cloneDeep(src[key]);
        }
      }
      return res;
    }
    return cloneDeep(src);
  };
  exports.ucs2decode = function(string) {
    var output = [],
        counter = 0,
        length = string.length,
        value,
        extra;
    while (counter < length) {
      value = string.charCodeAt(counter++);
      if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
        extra = string.charCodeAt(counter++);
        if ((extra & 0xFC00) == 0xDC00) {
          output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
        } else {
          output.push(value);
          counter--;
        }
      } else {
        output.push(value);
      }
    }
    return output;
  };
  return module.exports;
});

$__System.registerDynamic("172", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "id": "http://json-schema.org/draft-04/schema#",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "description": "Core schema meta-schema",
    "definitions": {
      "schemaArray": {
        "type": "array",
        "minItems": 1,
        "items": {"$ref": "#"}
      },
      "positiveInteger": {
        "type": "integer",
        "minimum": 0
      },
      "positiveIntegerDefault0": {"allOf": [{"$ref": "#/definitions/positiveInteger"}, {"default": 0}]},
      "simpleTypes": {"enum": ["array", "boolean", "integer", "null", "number", "object", "string"]},
      "stringArray": {
        "type": "array",
        "items": {"type": "string"},
        "minItems": 1,
        "uniqueItems": true
      }
    },
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "format": "uri"
      },
      "$schema": {
        "type": "string",
        "format": "uri"
      },
      "title": {"type": "string"},
      "description": {"type": "string"},
      "default": {},
      "multipleOf": {
        "type": "number",
        "minimum": 0,
        "exclusiveMinimum": true
      },
      "maximum": {"type": "number"},
      "exclusiveMaximum": {
        "type": "boolean",
        "default": false
      },
      "minimum": {"type": "number"},
      "exclusiveMinimum": {
        "type": "boolean",
        "default": false
      },
      "maxLength": {"$ref": "#/definitions/positiveInteger"},
      "minLength": {"$ref": "#/definitions/positiveIntegerDefault0"},
      "pattern": {
        "type": "string",
        "format": "regex"
      },
      "additionalItems": {
        "anyOf": [{"type": "boolean"}, {"$ref": "#"}],
        "default": {}
      },
      "items": {
        "anyOf": [{"$ref": "#"}, {"$ref": "#/definitions/schemaArray"}],
        "default": {}
      },
      "maxItems": {"$ref": "#/definitions/positiveInteger"},
      "minItems": {"$ref": "#/definitions/positiveIntegerDefault0"},
      "uniqueItems": {
        "type": "boolean",
        "default": false
      },
      "maxProperties": {"$ref": "#/definitions/positiveInteger"},
      "minProperties": {"$ref": "#/definitions/positiveIntegerDefault0"},
      "required": {"$ref": "#/definitions/stringArray"},
      "additionalProperties": {
        "anyOf": [{"type": "boolean"}, {"$ref": "#"}],
        "default": {}
      },
      "definitions": {
        "type": "object",
        "additionalProperties": {"$ref": "#"},
        "default": {}
      },
      "properties": {
        "type": "object",
        "additionalProperties": {"$ref": "#"},
        "default": {}
      },
      "patternProperties": {
        "type": "object",
        "additionalProperties": {"$ref": "#"},
        "default": {}
      },
      "dependencies": {
        "type": "object",
        "additionalProperties": {"anyOf": [{"$ref": "#"}, {"$ref": "#/definitions/stringArray"}]}
      },
      "enum": {
        "type": "array",
        "minItems": 1,
        "uniqueItems": true
      },
      "type": {"anyOf": [{"$ref": "#/definitions/simpleTypes"}, {
          "type": "array",
          "items": {"$ref": "#/definitions/simpleTypes"},
          "minItems": 1,
          "uniqueItems": true
        }]},
      "format": {"type": "string"},
      "allOf": {"$ref": "#/definitions/schemaArray"},
      "anyOf": {"$ref": "#/definitions/schemaArray"},
      "oneOf": {"$ref": "#/definitions/schemaArray"},
      "not": {"$ref": "#"}
    },
    "dependencies": {
      "exclusiveMaximum": ["maximum"],
      "exclusiveMinimum": ["minimum"]
    },
    "default": {}
  };
  return module.exports;
});

$__System.registerDynamic("173", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "$schema": "http://json-schema.org/draft-04/hyper-schema#",
    "id": "http://json-schema.org/draft-04/hyper-schema#",
    "title": "JSON Hyper-Schema",
    "allOf": [{"$ref": "http://json-schema.org/draft-04/schema#"}],
    "properties": {
      "additionalItems": {"anyOf": [{"type": "boolean"}, {"$ref": "#"}]},
      "additionalProperties": {"anyOf": [{"type": "boolean"}, {"$ref": "#"}]},
      "dependencies": {"additionalProperties": {"anyOf": [{"$ref": "#"}, {"type": "array"}]}},
      "items": {"anyOf": [{"$ref": "#"}, {"$ref": "#/definitions/schemaArray"}]},
      "definitions": {"additionalProperties": {"$ref": "#"}},
      "patternProperties": {"additionalProperties": {"$ref": "#"}},
      "properties": {"additionalProperties": {"$ref": "#"}},
      "allOf": {"$ref": "#/definitions/schemaArray"},
      "anyOf": {"$ref": "#/definitions/schemaArray"},
      "oneOf": {"$ref": "#/definitions/schemaArray"},
      "not": {"$ref": "#"},
      "links": {
        "type": "array",
        "items": {"$ref": "#/definitions/linkDescription"}
      },
      "fragmentResolution": {"type": "string"},
      "media": {
        "type": "object",
        "properties": {
          "type": {
            "description": "A media type, as described in RFC 2046",
            "type": "string"
          },
          "binaryEncoding": {
            "description": "A content encoding scheme, as described in RFC 2045",
            "type": "string"
          }
        }
      },
      "pathStart": {
        "description": "Instances' URIs must start with this value for this schema to apply to them",
        "type": "string",
        "format": "uri"
      }
    },
    "definitions": {
      "schemaArray": {
        "type": "array",
        "items": {"$ref": "#"}
      },
      "linkDescription": {
        "title": "Link Description Object",
        "type": "object",
        "required": ["href", "rel"],
        "properties": {
          "href": {
            "description": "a URI template, as defined by RFC 6570, with the addition of the $, ( and ) characters for pre-processing",
            "type": "string"
          },
          "rel": {
            "description": "relation to the target resource of the link",
            "type": "string"
          },
          "title": {
            "description": "a title for the link",
            "type": "string"
          },
          "targetSchema": {
            "description": "JSON Schema describing the link target",
            "$ref": "#"
          },
          "mediaType": {
            "description": "media type (as defined by RFC 2046) describing the link target",
            "type": "string"
          },
          "method": {
            "description": "method for requesting the target of the link (e.g. for HTTP this might be \"GET\" or \"DELETE\")",
            "type": "string"
          },
          "encType": {
            "description": "The media type in which to submit data along with the request",
            "type": "string",
            "default": "application/json"
          },
          "schema": {
            "description": "Schema describing the data to submit along with the request",
            "$ref": "#"
          }
        }
      }
    }
  };
  return module.exports;
});

$__System.registerDynamic("174", ["125", "170", "127", "16b", "16c", "126", "128", "129", "12a", "172", "173", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    $__require('125');
    var get = $__require('170');
    var Report = $__require('127');
    var FormatValidators = $__require('16b');
    var JsonValidation = $__require('16c');
    var SchemaCache = $__require('126');
    var SchemaCompilation = $__require('128');
    var SchemaValidation = $__require('129');
    var Utils = $__require('12a');
    var Draft4Schema = $__require('172');
    var Draft4HyperSchema = $__require('173');
    var defaultOptions = {
      asyncTimeout: 2000,
      forceAdditional: false,
      assumeAdditional: false,
      forceItems: false,
      forceMinItems: false,
      forceMaxItems: false,
      forceMinLength: false,
      forceMaxLength: false,
      forceProperties: false,
      ignoreUnresolvableReferences: false,
      noExtraKeywords: false,
      noTypeless: false,
      noEmptyStrings: false,
      noEmptyArrays: false,
      strictUris: false,
      strictMode: false,
      reportPathAsArray: false,
      breakOnFirstError: true,
      pedanticCheck: false,
      ignoreUnknownFormats: false,
      customValidator: null
    };
    function ZSchema(options) {
      this.cache = {};
      this.referenceCache = [];
      this.setRemoteReference("http://json-schema.org/draft-04/schema", Draft4Schema);
      this.setRemoteReference("http://json-schema.org/draft-04/hyper-schema", Draft4HyperSchema);
      if (typeof options === "object") {
        var keys = Object.keys(options),
            idx = keys.length,
            key;
        while (idx--) {
          key = keys[idx];
          if (defaultOptions[key] === undefined) {
            throw new Error("Unexpected option passed to constructor: " + key);
          }
        }
        keys = Object.keys(defaultOptions);
        idx = keys.length;
        while (idx--) {
          key = keys[idx];
          if (options[key] === undefined) {
            options[key] = Utils.clone(defaultOptions[key]);
          }
        }
        this.options = options;
      } else {
        this.options = Utils.clone(defaultOptions);
      }
      if (this.options.strictMode === true) {
        this.options.forceAdditional = true;
        this.options.forceItems = true;
        this.options.forceMaxLength = true;
        this.options.forceProperties = true;
        this.options.noExtraKeywords = true;
        this.options.noTypeless = true;
        this.options.noEmptyStrings = true;
        this.options.noEmptyArrays = true;
      }
    }
    ZSchema.prototype.compileSchema = function(schema) {
      var report = new Report(this.options);
      schema = SchemaCache.getSchema.call(this, report, schema);
      SchemaCompilation.compileSchema.call(this, report, schema);
      this.lastReport = report;
      return report.isValid();
    };
    ZSchema.prototype.validateSchema = function(schema) {
      if (Array.isArray(schema) && schema.length === 0) {
        throw new Error(".validateSchema was called with an empty array");
      }
      var report = new Report(this.options);
      schema = SchemaCache.getSchema.call(this, report, schema);
      var compiled = SchemaCompilation.compileSchema.call(this, report, schema);
      if (compiled) {
        SchemaValidation.validateSchema.call(this, report, schema);
      }
      this.lastReport = report;
      return report.isValid();
    };
    ZSchema.prototype.validate = function(json, schema, options, callback) {
      if (Utils.whatIs(options) === "function") {
        callback = options;
        options = {};
      }
      if (!options) {
        options = {};
      }
      var whatIs = Utils.whatIs(schema);
      if (whatIs !== "string" && whatIs !== "object") {
        var e = new Error("Invalid .validate call - schema must be an string or object but " + whatIs + " was passed!");
        if (callback) {
          process.nextTick(function() {
            callback(e, false);
          });
          return;
        }
        throw e;
      }
      var foundError = false;
      var report = new Report(this.options);
      if (typeof schema === "string") {
        var schemaName = schema;
        schema = SchemaCache.getSchema.call(this, report, schemaName);
        if (!schema) {
          throw new Error("Schema with id '" + schemaName + "' wasn't found in the validator cache!");
        }
      } else {
        schema = SchemaCache.getSchema.call(this, report, schema);
      }
      var compiled = false;
      if (!foundError) {
        compiled = SchemaCompilation.compileSchema.call(this, report, schema);
      }
      if (!compiled) {
        this.lastReport = report;
        foundError = true;
      }
      var validated = false;
      if (!foundError) {
        validated = SchemaValidation.validateSchema.call(this, report, schema);
      }
      if (!validated) {
        this.lastReport = report;
        foundError = true;
      }
      if (options.schemaPath) {
        report.rootSchema = schema;
        schema = get(schema, options.schemaPath);
        if (!schema) {
          throw new Error("Schema path '" + options.schemaPath + "' wasn't found in the schema!");
        }
      }
      if (!foundError) {
        JsonValidation.validate.call(this, report, schema, json);
      }
      if (callback) {
        report.processAsyncTasks(this.options.asyncTimeout, callback);
        return;
      } else if (report.asyncTasks.length > 0) {
        throw new Error("This validation has async tasks and cannot be done in sync mode, please provide callback argument.");
      }
      this.lastReport = report;
      return report.isValid();
    };
    ZSchema.prototype.getLastError = function() {
      if (this.lastReport.errors.length === 0) {
        return null;
      }
      var e = new Error();
      e.name = "z-schema validation error";
      e.message = this.lastReport.commonErrorMessage;
      e.details = this.lastReport.errors;
      return e;
    };
    ZSchema.prototype.getLastErrors = function() {
      return this.lastReport && this.lastReport.errors.length > 0 ? this.lastReport.errors : undefined;
    };
    ZSchema.prototype.getMissingReferences = function(arr) {
      arr = arr || this.lastReport.errors;
      var res = [],
          idx = arr.length;
      while (idx--) {
        var error = arr[idx];
        if (error.code === "UNRESOLVABLE_REFERENCE") {
          var reference = error.params[0];
          if (res.indexOf(reference) === -1) {
            res.push(reference);
          }
        }
        if (error.inner) {
          res = res.concat(this.getMissingReferences(error.inner));
        }
      }
      return res;
    };
    ZSchema.prototype.getMissingRemoteReferences = function() {
      var missingReferences = this.getMissingReferences(),
          missingRemoteReferences = [],
          idx = missingReferences.length;
      while (idx--) {
        var remoteReference = SchemaCache.getRemotePath(missingReferences[idx]);
        if (remoteReference && missingRemoteReferences.indexOf(remoteReference) === -1) {
          missingRemoteReferences.push(remoteReference);
        }
      }
      return missingRemoteReferences;
    };
    ZSchema.prototype.setRemoteReference = function(uri, schema) {
      if (typeof schema === "string") {
        schema = JSON.parse(schema);
      } else {
        schema = Utils.cloneDeep(schema);
      }
      SchemaCache.cacheSchemaByUri.call(this, uri, schema);
    };
    ZSchema.prototype.getResolvedSchema = function(schema) {
      var report = new Report(this.options);
      schema = SchemaCache.getSchema.call(this, report, schema);
      schema = Utils.cloneDeep(schema);
      var visited = [];
      var cleanup = function(schema) {
        var key,
            typeOf = Utils.whatIs(schema);
        if (typeOf !== "object" && typeOf !== "array") {
          return;
        }
        if (schema.___$visited) {
          return;
        }
        schema.___$visited = true;
        visited.push(schema);
        if (schema.$ref && schema.__$refResolved) {
          var from = schema.__$refResolved;
          var to = schema;
          delete schema.$ref;
          delete schema.__$refResolved;
          for (key in from) {
            if (from.hasOwnProperty(key)) {
              to[key] = from[key];
            }
          }
        }
        for (key in schema) {
          if (schema.hasOwnProperty(key)) {
            if (key.indexOf("__$") === 0) {
              delete schema[key];
            } else {
              cleanup(schema[key]);
            }
          }
        }
      };
      cleanup(schema);
      visited.forEach(function(s) {
        delete s.___$visited;
      });
      this.lastReport = report;
      if (report.isValid()) {
        return schema;
      } else {
        throw this.getLastError();
      }
    };
    ZSchema.prototype.setSchemaReader = function(schemaReader) {
      return ZSchema.setSchemaReader(schemaReader);
    };
    ZSchema.prototype.getSchemaReader = function() {
      return ZSchema.schemaReader;
    };
    ZSchema.setSchemaReader = function(schemaReader) {
      ZSchema.schemaReader = schemaReader;
    };
    ZSchema.registerFormat = function(formatName, validatorFunction) {
      FormatValidators[formatName] = validatorFunction;
    };
    ZSchema.unregisterFormat = function(formatName) {
      delete FormatValidators[formatName];
    };
    ZSchema.getRegisteredFormats = function() {
      return Object.keys(FormatValidators);
    };
    ZSchema.getDefaultOptions = function() {
      return Utils.cloneDeep(defaultOptions);
    };
    module.exports = ZSchema;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("175", ["174"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('174');
  return module.exports;
});

$__System.registerDynamic("176", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "title": "A JSON Schema for Swagger 2.0 API.",
    "id": "http://swagger.io/v2/schema.json#",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "required": ["swagger", "info", "paths"],
    "additionalProperties": false,
    "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
    "properties": {
      "swagger": {
        "type": "string",
        "enum": ["2.0"],
        "description": "The Swagger version of this document."
      },
      "info": {"$ref": "#/definitions/info"},
      "host": {
        "type": "string",
        "pattern": "^[^{}/ :\\\\]+(?::\\d+)?$",
        "description": "The host (name or ip) of the API. Example: 'swagger.io'"
      },
      "basePath": {
        "type": "string",
        "pattern": "^/",
        "description": "The base path to the API. Example: '/api'."
      },
      "schemes": {"$ref": "#/definitions/schemesList"},
      "consumes": {
        "description": "A list of MIME types accepted by the API.",
        "$ref": "#/definitions/mediaTypeList"
      },
      "produces": {
        "description": "A list of MIME types the API can produce.",
        "$ref": "#/definitions/mediaTypeList"
      },
      "paths": {"$ref": "#/definitions/paths"},
      "definitions": {"$ref": "#/definitions/definitions"},
      "parameters": {"$ref": "#/definitions/parameterDefinitions"},
      "responses": {"$ref": "#/definitions/responseDefinitions"},
      "security": {"$ref": "#/definitions/security"},
      "securityDefinitions": {"$ref": "#/definitions/securityDefinitions"},
      "tags": {
        "type": "array",
        "items": {"$ref": "#/definitions/tag"},
        "uniqueItems": true
      },
      "externalDocs": {"$ref": "#/definitions/externalDocs"}
    },
    "definitions": {
      "info": {
        "type": "object",
        "description": "General information about the API.",
        "required": ["version", "title"],
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "title": {
            "type": "string",
            "description": "A unique and precise title of the API."
          },
          "version": {
            "type": "string",
            "description": "A semantic version number of the API."
          },
          "description": {
            "type": "string",
            "description": "A longer description of the API. Should be different from the title.  GitHub Flavored Markdown is allowed."
          },
          "termsOfService": {
            "type": "string",
            "description": "The terms of service for the API."
          },
          "contact": {"$ref": "#/definitions/contact"},
          "license": {"$ref": "#/definitions/license"}
        }
      },
      "contact": {
        "type": "object",
        "description": "Contact information for the owners of the API.",
        "additionalProperties": false,
        "properties": {
          "name": {
            "type": "string",
            "description": "The identifying name of the contact person/organization."
          },
          "url": {
            "type": "string",
            "description": "The URL pointing to the contact information.",
            "format": "uri"
          },
          "email": {
            "type": "string",
            "description": "The email address of the contact person/organization.",
            "format": "email"
          }
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "license": {
        "type": "object",
        "required": ["name"],
        "additionalProperties": false,
        "properties": {
          "name": {
            "type": "string",
            "description": "The name of the license type. It's encouraged to use an OSI compatible license."
          },
          "url": {
            "type": "string",
            "description": "The URL pointing to the license.",
            "format": "uri"
          }
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "paths": {
        "type": "object",
        "description": "Relative paths to the individual endpoints. They must be relative to the 'basePath'.",
        "patternProperties": {
          "^x-": {"$ref": "#/definitions/vendorExtension"},
          "^/": {"$ref": "#/definitions/pathItem"}
        },
        "additionalProperties": false
      },
      "definitions": {
        "type": "object",
        "additionalProperties": {"$ref": "#/definitions/schema"},
        "description": "One or more JSON objects describing the schemas being consumed and produced by the API."
      },
      "parameterDefinitions": {
        "type": "object",
        "additionalProperties": {"$ref": "#/definitions/parameter"},
        "description": "One or more JSON representations for parameters"
      },
      "responseDefinitions": {
        "type": "object",
        "additionalProperties": {"$ref": "#/definitions/response"},
        "description": "One or more JSON representations for parameters"
      },
      "externalDocs": {
        "type": "object",
        "additionalProperties": false,
        "description": "information about external documentation",
        "required": ["url"],
        "properties": {
          "description": {"type": "string"},
          "url": {
            "type": "string",
            "format": "uri"
          }
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "examples": {
        "type": "object",
        "additionalProperties": true
      },
      "mimeType": {
        "type": "string",
        "description": "The MIME type of the HTTP message."
      },
      "operation": {
        "type": "object",
        "required": ["responses"],
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "tags": {
            "type": "array",
            "items": {"type": "string"},
            "uniqueItems": true
          },
          "summary": {
            "type": "string",
            "description": "A brief summary of the operation."
          },
          "description": {
            "type": "string",
            "description": "A longer description of the operation, GitHub Flavored Markdown is allowed."
          },
          "externalDocs": {"$ref": "#/definitions/externalDocs"},
          "operationId": {
            "type": "string",
            "description": "A unique identifier of the operation."
          },
          "produces": {
            "description": "A list of MIME types the API can produce.",
            "$ref": "#/definitions/mediaTypeList"
          },
          "consumes": {
            "description": "A list of MIME types the API can consume.",
            "$ref": "#/definitions/mediaTypeList"
          },
          "parameters": {"$ref": "#/definitions/parametersList"},
          "responses": {"$ref": "#/definitions/responses"},
          "schemes": {"$ref": "#/definitions/schemesList"},
          "deprecated": {
            "type": "boolean",
            "default": false
          },
          "security": {"$ref": "#/definitions/security"}
        }
      },
      "pathItem": {
        "type": "object",
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "$ref": {"type": "string"},
          "get": {"$ref": "#/definitions/operation"},
          "put": {"$ref": "#/definitions/operation"},
          "post": {"$ref": "#/definitions/operation"},
          "delete": {"$ref": "#/definitions/operation"},
          "options": {"$ref": "#/definitions/operation"},
          "head": {"$ref": "#/definitions/operation"},
          "patch": {"$ref": "#/definitions/operation"},
          "parameters": {"$ref": "#/definitions/parametersList"}
        }
      },
      "responses": {
        "type": "object",
        "description": "Response objects names can either be any valid HTTP status code or 'default'.",
        "minProperties": 1,
        "additionalProperties": false,
        "patternProperties": {
          "^([0-9]{3})$|^(default)$": {"$ref": "#/definitions/responseValue"},
          "^x-": {"$ref": "#/definitions/vendorExtension"}
        },
        "not": {
          "type": "object",
          "additionalProperties": false,
          "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
        }
      },
      "responseValue": {"oneOf": [{"$ref": "#/definitions/response"}, {"$ref": "#/definitions/jsonReference"}]},
      "response": {
        "type": "object",
        "required": ["description"],
        "properties": {
          "description": {"type": "string"},
          "schema": {"oneOf": [{"$ref": "#/definitions/schema"}, {"$ref": "#/definitions/fileSchema"}]},
          "headers": {"$ref": "#/definitions/headers"},
          "examples": {"$ref": "#/definitions/examples"}
        },
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "headers": {
        "type": "object",
        "additionalProperties": {"$ref": "#/definitions/header"}
      },
      "header": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["string", "number", "integer", "boolean", "array"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormat"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"},
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "vendorExtension": {
        "description": "Any property starting with x- is valid.",
        "additionalProperties": true,
        "additionalItems": true
      },
      "bodyParameter": {
        "type": "object",
        "required": ["name", "in", "schema"],
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "description": {
            "type": "string",
            "description": "A brief description of the parameter. This could contain examples of use.  GitHub Flavored Markdown is allowed."
          },
          "name": {
            "type": "string",
            "description": "The name of the parameter."
          },
          "in": {
            "type": "string",
            "description": "Determines the location of the parameter.",
            "enum": ["body"]
          },
          "required": {
            "type": "boolean",
            "description": "Determines whether or not this parameter is required or optional.",
            "default": false
          },
          "schema": {"$ref": "#/definitions/schema"}
        },
        "additionalProperties": false
      },
      "headerParameterSubSchema": {
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "required": {
            "type": "boolean",
            "description": "Determines whether or not this parameter is required or optional.",
            "default": false
          },
          "in": {
            "type": "string",
            "description": "Determines the location of the parameter.",
            "enum": ["header"]
          },
          "description": {
            "type": "string",
            "description": "A brief description of the parameter. This could contain examples of use.  GitHub Flavored Markdown is allowed."
          },
          "name": {
            "type": "string",
            "description": "The name of the parameter."
          },
          "type": {
            "type": "string",
            "enum": ["string", "number", "boolean", "integer", "array"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormat"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"}
        }
      },
      "queryParameterSubSchema": {
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "required": {
            "type": "boolean",
            "description": "Determines whether or not this parameter is required or optional.",
            "default": false
          },
          "in": {
            "type": "string",
            "description": "Determines the location of the parameter.",
            "enum": ["query"]
          },
          "description": {
            "type": "string",
            "description": "A brief description of the parameter. This could contain examples of use.  GitHub Flavored Markdown is allowed."
          },
          "name": {
            "type": "string",
            "description": "The name of the parameter."
          },
          "allowEmptyValue": {
            "type": "boolean",
            "default": false,
            "description": "allows sending a parameter by name only or with an empty value."
          },
          "type": {
            "type": "string",
            "enum": ["string", "number", "boolean", "integer", "array"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormatWithMulti"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"}
        }
      },
      "formDataParameterSubSchema": {
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "required": {
            "type": "boolean",
            "description": "Determines whether or not this parameter is required or optional.",
            "default": false
          },
          "in": {
            "type": "string",
            "description": "Determines the location of the parameter.",
            "enum": ["formData"]
          },
          "description": {
            "type": "string",
            "description": "A brief description of the parameter. This could contain examples of use.  GitHub Flavored Markdown is allowed."
          },
          "name": {
            "type": "string",
            "description": "The name of the parameter."
          },
          "allowEmptyValue": {
            "type": "boolean",
            "default": false,
            "description": "allows sending a parameter by name only or with an empty value."
          },
          "type": {
            "type": "string",
            "enum": ["string", "number", "boolean", "integer", "array", "file"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormatWithMulti"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"}
        }
      },
      "pathParameterSubSchema": {
        "additionalProperties": false,
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "required": ["required"],
        "properties": {
          "required": {
            "type": "boolean",
            "enum": [true],
            "description": "Determines whether or not this parameter is required or optional."
          },
          "in": {
            "type": "string",
            "description": "Determines the location of the parameter.",
            "enum": ["path"]
          },
          "description": {
            "type": "string",
            "description": "A brief description of the parameter. This could contain examples of use.  GitHub Flavored Markdown is allowed."
          },
          "name": {
            "type": "string",
            "description": "The name of the parameter."
          },
          "type": {
            "type": "string",
            "enum": ["string", "number", "boolean", "integer", "array"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormat"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"}
        }
      },
      "nonBodyParameter": {
        "type": "object",
        "required": ["name", "in", "type"],
        "oneOf": [{"$ref": "#/definitions/headerParameterSubSchema"}, {"$ref": "#/definitions/formDataParameterSubSchema"}, {"$ref": "#/definitions/queryParameterSubSchema"}, {"$ref": "#/definitions/pathParameterSubSchema"}]
      },
      "parameter": {"oneOf": [{"$ref": "#/definitions/bodyParameter"}, {"$ref": "#/definitions/nonBodyParameter"}]},
      "schema": {
        "type": "object",
        "description": "A deterministic version of a JSON Schema object.",
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "properties": {
          "$ref": {"type": "string"},
          "format": {"type": "string"},
          "title": {"$ref": "http://json-schema.org/draft-04/schema#/properties/title"},
          "description": {"$ref": "http://json-schema.org/draft-04/schema#/properties/description"},
          "default": {"$ref": "http://json-schema.org/draft-04/schema#/properties/default"},
          "multipleOf": {"$ref": "http://json-schema.org/draft-04/schema#/properties/multipleOf"},
          "maximum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/maximum"},
          "exclusiveMaximum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},
          "minimum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/minimum"},
          "exclusiveMinimum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},
          "maxLength": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},
          "minLength": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},
          "pattern": {"$ref": "http://json-schema.org/draft-04/schema#/properties/pattern"},
          "maxItems": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},
          "minItems": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},
          "uniqueItems": {"$ref": "http://json-schema.org/draft-04/schema#/properties/uniqueItems"},
          "maxProperties": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},
          "minProperties": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},
          "required": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/stringArray"},
          "enum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/enum"},
          "additionalProperties": {
            "anyOf": [{"$ref": "#/definitions/schema"}, {"type": "boolean"}],
            "default": {}
          },
          "type": {"$ref": "http://json-schema.org/draft-04/schema#/properties/type"},
          "items": {
            "anyOf": [{"$ref": "#/definitions/schema"}, {
              "type": "array",
              "minItems": 1,
              "items": {"$ref": "#/definitions/schema"}
            }],
            "default": {}
          },
          "allOf": {
            "type": "array",
            "minItems": 1,
            "items": {"$ref": "#/definitions/schema"}
          },
          "properties": {
            "type": "object",
            "additionalProperties": {"$ref": "#/definitions/schema"},
            "default": {}
          },
          "discriminator": {"type": "string"},
          "readOnly": {
            "type": "boolean",
            "default": false
          },
          "xml": {"$ref": "#/definitions/xml"},
          "externalDocs": {"$ref": "#/definitions/externalDocs"},
          "example": {}
        },
        "additionalProperties": false
      },
      "fileSchema": {
        "type": "object",
        "description": "A deterministic version of a JSON Schema object.",
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}},
        "required": ["type"],
        "properties": {
          "format": {"type": "string"},
          "title": {"$ref": "http://json-schema.org/draft-04/schema#/properties/title"},
          "description": {"$ref": "http://json-schema.org/draft-04/schema#/properties/description"},
          "default": {"$ref": "http://json-schema.org/draft-04/schema#/properties/default"},
          "required": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/stringArray"},
          "type": {
            "type": "string",
            "enum": ["file"]
          },
          "readOnly": {
            "type": "boolean",
            "default": false
          },
          "externalDocs": {"$ref": "#/definitions/externalDocs"},
          "example": {}
        },
        "additionalProperties": false
      },
      "primitivesItems": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "type": {
            "type": "string",
            "enum": ["string", "number", "integer", "boolean", "array"]
          },
          "format": {"type": "string"},
          "items": {"$ref": "#/definitions/primitivesItems"},
          "collectionFormat": {"$ref": "#/definitions/collectionFormat"},
          "default": {"$ref": "#/definitions/default"},
          "maximum": {"$ref": "#/definitions/maximum"},
          "exclusiveMaximum": {"$ref": "#/definitions/exclusiveMaximum"},
          "minimum": {"$ref": "#/definitions/minimum"},
          "exclusiveMinimum": {"$ref": "#/definitions/exclusiveMinimum"},
          "maxLength": {"$ref": "#/definitions/maxLength"},
          "minLength": {"$ref": "#/definitions/minLength"},
          "pattern": {"$ref": "#/definitions/pattern"},
          "maxItems": {"$ref": "#/definitions/maxItems"},
          "minItems": {"$ref": "#/definitions/minItems"},
          "uniqueItems": {"$ref": "#/definitions/uniqueItems"},
          "enum": {"$ref": "#/definitions/enum"},
          "multipleOf": {"$ref": "#/definitions/multipleOf"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "security": {
        "type": "array",
        "items": {"$ref": "#/definitions/securityRequirement"},
        "uniqueItems": true
      },
      "securityRequirement": {
        "type": "object",
        "additionalProperties": {
          "type": "array",
          "items": {"type": "string"},
          "uniqueItems": true
        }
      },
      "xml": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "name": {"type": "string"},
          "namespace": {"type": "string"},
          "prefix": {"type": "string"},
          "attribute": {
            "type": "boolean",
            "default": false
          },
          "wrapped": {
            "type": "boolean",
            "default": false
          }
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "tag": {
        "type": "object",
        "additionalProperties": false,
        "required": ["name"],
        "properties": {
          "name": {"type": "string"},
          "description": {"type": "string"},
          "externalDocs": {"$ref": "#/definitions/externalDocs"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "securityDefinitions": {
        "type": "object",
        "additionalProperties": {"oneOf": [{"$ref": "#/definitions/basicAuthenticationSecurity"}, {"$ref": "#/definitions/apiKeySecurity"}, {"$ref": "#/definitions/oauth2ImplicitSecurity"}, {"$ref": "#/definitions/oauth2PasswordSecurity"}, {"$ref": "#/definitions/oauth2ApplicationSecurity"}, {"$ref": "#/definitions/oauth2AccessCodeSecurity"}]}
      },
      "basicAuthenticationSecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["basic"]
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "apiKeySecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "name", "in"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["apiKey"]
          },
          "name": {"type": "string"},
          "in": {
            "type": "string",
            "enum": ["header", "query"]
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "oauth2ImplicitSecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "flow", "authorizationUrl"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["oauth2"]
          },
          "flow": {
            "type": "string",
            "enum": ["implicit"]
          },
          "scopes": {"$ref": "#/definitions/oauth2Scopes"},
          "authorizationUrl": {
            "type": "string",
            "format": "uri"
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "oauth2PasswordSecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "flow", "tokenUrl"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["oauth2"]
          },
          "flow": {
            "type": "string",
            "enum": ["password"]
          },
          "scopes": {"$ref": "#/definitions/oauth2Scopes"},
          "tokenUrl": {
            "type": "string",
            "format": "uri"
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "oauth2ApplicationSecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "flow", "tokenUrl"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["oauth2"]
          },
          "flow": {
            "type": "string",
            "enum": ["application"]
          },
          "scopes": {"$ref": "#/definitions/oauth2Scopes"},
          "tokenUrl": {
            "type": "string",
            "format": "uri"
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "oauth2AccessCodeSecurity": {
        "type": "object",
        "additionalProperties": false,
        "required": ["type", "flow", "authorizationUrl", "tokenUrl"],
        "properties": {
          "type": {
            "type": "string",
            "enum": ["oauth2"]
          },
          "flow": {
            "type": "string",
            "enum": ["accessCode"]
          },
          "scopes": {"$ref": "#/definitions/oauth2Scopes"},
          "authorizationUrl": {
            "type": "string",
            "format": "uri"
          },
          "tokenUrl": {
            "type": "string",
            "format": "uri"
          },
          "description": {"type": "string"}
        },
        "patternProperties": {"^x-": {"$ref": "#/definitions/vendorExtension"}}
      },
      "oauth2Scopes": {
        "type": "object",
        "additionalProperties": {"type": "string"}
      },
      "mediaTypeList": {
        "type": "array",
        "items": {"$ref": "#/definitions/mimeType"},
        "uniqueItems": true
      },
      "parametersList": {
        "type": "array",
        "description": "The parameters needed to send a valid API call.",
        "additionalItems": false,
        "items": {"oneOf": [{"$ref": "#/definitions/parameter"}, {"$ref": "#/definitions/jsonReference"}]},
        "uniqueItems": true
      },
      "schemesList": {
        "type": "array",
        "description": "The transfer protocol of the API.",
        "items": {
          "type": "string",
          "enum": ["http", "https", "ws", "wss"]
        },
        "uniqueItems": true
      },
      "collectionFormat": {
        "type": "string",
        "enum": ["csv", "ssv", "tsv", "pipes"],
        "default": "csv"
      },
      "collectionFormatWithMulti": {
        "type": "string",
        "enum": ["csv", "ssv", "tsv", "pipes", "multi"],
        "default": "csv"
      },
      "title": {"$ref": "http://json-schema.org/draft-04/schema#/properties/title"},
      "description": {"$ref": "http://json-schema.org/draft-04/schema#/properties/description"},
      "default": {"$ref": "http://json-schema.org/draft-04/schema#/properties/default"},
      "multipleOf": {"$ref": "http://json-schema.org/draft-04/schema#/properties/multipleOf"},
      "maximum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/maximum"},
      "exclusiveMaximum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/exclusiveMaximum"},
      "minimum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/minimum"},
      "exclusiveMinimum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/exclusiveMinimum"},
      "maxLength": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},
      "minLength": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},
      "pattern": {"$ref": "http://json-schema.org/draft-04/schema#/properties/pattern"},
      "maxItems": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveInteger"},
      "minItems": {"$ref": "http://json-schema.org/draft-04/schema#/definitions/positiveIntegerDefault0"},
      "uniqueItems": {"$ref": "http://json-schema.org/draft-04/schema#/properties/uniqueItems"},
      "enum": {"$ref": "http://json-schema.org/draft-04/schema#/properties/enum"},
      "jsonReference": {
        "type": "object",
        "required": ["$ref"],
        "additionalProperties": false,
        "properties": {"$ref": {"type": "string"}}
      }
    }
  };
  return module.exports;
});

$__System.registerDynamic("177", ["178", "179", "175", "176"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var util = $__require('178'),
      ono = $__require('179'),
      ZSchema = $__require('175'),
      swaggerSchema = $__require('176');
  module.exports = validateSchema;
  initializeZSchema();
  function validateSchema(api) {
    util.debug('Validating against the Swagger 2.0 schema');
    var isValid = ZSchema.validate(api, swaggerSchema);
    if (isValid) {
      util.debug('    Validated successfully');
    } else {
      var err = ZSchema.getLastError();
      var message = 'Swagger schema validation failed. \n' + formatZSchemaError(err.details);
      throw ono.syntax(err, {details: err.details}, message);
    }
  }
  function initializeZSchema() {
    ZSchema = new ZSchema({
      breakOnFirstError: true,
      noExtraKeywords: true,
      ignoreUnknownFormats: false,
      reportPathAsArray: true
    });
  }
  function formatZSchemaError(errors, indent) {
    indent = indent || '  ';
    var message = '';
    errors.forEach(function(error, index) {
      message += util.format('%s%s at #/%s\n', indent, error.message, error.path.join('/'));
      if (error.inner) {
        message += formatZSchemaError(error.inner, indent + '  ');
      }
    });
    return message;
  }
  return module.exports;
});

$__System.registerDynamic("17a", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = ['get', 'put', 'post', 'delete', 'options', 'head', 'patch'];
  return module.exports;
});

$__System.registerDynamic("17b", ["17a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('17a');
  return module.exports;
});

$__System.registerDynamic("17c", ["178", "179", "17b"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var util = $__require('178'),
      ono = $__require('179'),
      swaggerMethods = $__require('17b'),
      primitiveTypes = ['array', 'boolean', 'integer', 'number', 'string'],
      schemaTypes = ['array', 'boolean', 'integer', 'number', 'string', 'object', 'null', undefined];
  module.exports = validateSpec;
  function validateSpec(api) {
    util.debug('Validating against the Swagger 2.0 spec');
    var paths = Object.keys(api.paths || {});
    paths.forEach(function(pathName) {
      var path = api.paths[pathName];
      var pathId = '/paths' + pathName;
      if (path && pathName.indexOf('/') === 0) {
        validatePath(api, path, pathId);
      }
    });
    util.debug('    Validated successfully');
  }
  function validatePath(api, path, pathId) {
    swaggerMethods.forEach(function(operationName) {
      var operation = path[operationName];
      var operationId = pathId + '/' + operationName;
      if (operation) {
        validateParameters(api, path, pathId, operation, operationId);
        var responses = Object.keys(operation.responses || {});
        responses.forEach(function(responseName) {
          var response = operation.responses[responseName];
          var responseId = operationId + '/responses/' + responseName;
          validateResponse(responseName, response, responseId);
        });
      }
    });
  }
  function validateParameters(api, path, pathId, operation, operationId) {
    var pathParams = path.parameters || [];
    var operationParams = operation.parameters || [];
    try {
      checkForDuplicates(pathParams);
    } catch (e) {
      throw ono.syntax(e, 'Validation failed. %s has duplicate parameters', pathId);
    }
    try {
      checkForDuplicates(operationParams);
    } catch (e) {
      throw ono.syntax(e, 'Validation failed. %s has duplicate parameters', operationId);
    }
    var params = pathParams.reduce(function(combinedParams, value) {
      var duplicate = combinedParams.some(function(param) {
        return param.in === value.in && param.name === value.name;
      });
      if (!duplicate) {
        combinedParams.push(value);
      }
      return combinedParams;
    }, operationParams.slice());
    validateBodyParameters(params, operationId);
    validatePathParameters(params, pathId, operationId);
    validateParameterTypes(params, api, operation, operationId);
  }
  function validateBodyParameters(params, operationId) {
    var bodyParams = params.filter(function(param) {
      return param.in === 'body';
    });
    var formParams = params.filter(function(param) {
      return param.in === 'formData';
    });
    if (bodyParams.length > 1) {
      throw ono.syntax('Validation failed. %s has %d body parameters. Only one is allowed.', operationId, bodyParams.length);
    } else if (bodyParams.length > 0 && formParams.length > 0) {
      throw ono.syntax('Validation failed. %s has body parameters and formData parameters. Only one or the other is allowed.', operationId);
    }
  }
  function validatePathParameters(params, pathId, operationId) {
    var placeholders = pathId.match(util.swaggerParamRegExp) || [];
    for (var i = 0; i < placeholders.length; i++) {
      for (var j = i + 1; j < placeholders.length; j++) {
        if (placeholders[i] === placeholders[j]) {
          throw ono.syntax('Validation failed. %s has multiple path placeholders named %s', operationId, placeholders[i]);
        }
      }
    }
    params.filter(function(param) {
      return param.in === 'path';
    }).forEach(function(param) {
      if (param.required !== true) {
        throw ono.syntax('Validation failed. Path parameters cannot be optional. Set required=true for the "%s" parameter at %s', param.name, operationId);
      }
      var match = placeholders.indexOf('{' + param.name + '}');
      if (match === -1) {
        throw ono.syntax('Validation failed. %s has a path parameter named "%s", ' + 'but there is no corresponding {%s} in the path string', operationId, param.name, param.name);
      }
      placeholders.splice(match, 1);
    });
    if (placeholders.length > 0) {
      throw ono.syntax('Validation failed. %s is missing path parameter(s) for %s', operationId, placeholders);
    }
  }
  function validateParameterTypes(params, api, operation, operationId) {
    params.forEach(function(param) {
      var parameterId = operationId + '/parameters/' + param.name;
      var schema,
          validTypes;
      switch (param.in) {
        case 'body':
          schema = param.schema;
          validTypes = schemaTypes;
          break;
        case 'formData':
          schema = param;
          validTypes = primitiveTypes.concat('file');
          break;
        default:
          schema = param;
          validTypes = primitiveTypes;
      }
      validateSchema(schema, parameterId, validTypes);
      if (schema.type === 'file') {
        var consumes = operation.consumes || api.consumes || [];
        if (consumes.indexOf('multipart/form-data') === -1 && consumes.indexOf('application/x-www-form-urlencoded') === -1) {
          throw ono.syntax('Validation failed. %s has a file parameter, so it must consume multipart/form-data ' + 'or application/x-www-form-urlencoded', operationId);
        }
      }
    });
  }
  function checkForDuplicates(params) {
    for (var i = 0; i < params.length - 1; i++) {
      var outer = params[i];
      for (var j = i + 1; j < params.length; j++) {
        var inner = params[j];
        if (outer.name === inner.name && outer.in === inner.in) {
          throw ono.syntax('Validation failed. Found multiple %s parameters named "%s"', outer.in, outer.name);
        }
      }
    }
  }
  function validateResponse(code, response, responseId) {
    if (code !== 'default' && (code < 100 || code > 599)) {
      throw ono.syntax('Validation failed. %s has an invalid response code (%s)', responseId, code);
    }
    var headers = Object.keys(response.headers || {});
    headers.forEach(function(headerName) {
      var header = response.headers[headerName];
      var headerId = responseId + '/headers/' + headerName;
      validateSchema(header, headerId, primitiveTypes);
    });
    if (response.schema) {
      var validTypes = schemaTypes.concat('file');
      if (validTypes.indexOf(response.schema.type) === -1) {
        throw ono.syntax('Validation failed. %s has an invalid response schema type (%s)', responseId, response.schema.type);
      }
    }
  }
  function validateSchema(schema, schemaId, validTypes) {
    if (validTypes.indexOf(schema.type) === -1) {
      throw ono.syntax('Validation failed. %s has an invalid type (%s)', schemaId, schema.type);
    }
    if (schema.type === 'array' && !schema.items) {
      throw ono.syntax('Validation failed. %s is an array, so it must include an "items" schema', schemaId);
    }
  }
  return module.exports;
});

$__System.registerDynamic("178", ["17d", "17e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var debug = $__require('17d'),
      util = $__require('17e');
  exports.format = util.format;
  exports.inherits = util.inherits;
  exports.debug = debug('swagger:parser');
  exports.swaggerParamRegExp = /\{([^/}]+)}/g;
  return module.exports;
});

$__System.registerDynamic("17f", ["180", "17e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $RefParserOptions = $__require('180'),
      util = $__require('17e');
  module.exports = ParserOptions;
  function ParserOptions(options) {
    $RefParserOptions.call(this, ParserOptions.defaults);
    $RefParserOptions.apply(this, arguments);
  }
  ParserOptions.defaults = {validate: {
      schema: {order: 1},
      spec: {order: 2}
    }};
  util.inherits(ParserOptions, $RefParserOptions);
  return module.exports;
});

$__System.registerDynamic("181", ["182"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = typeof Promise === 'function' ? Promise : $__require('182').Promise;
  return module.exports;
});

$__System.registerDynamic("183", ["184", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var Promise = $__require('184');
    module.exports = {
      order: 100,
      allowEmpty: true,
      canParse: '.json',
      parse: function parseJSON(file) {
        return new Promise(function(resolve, reject) {
          var data = file.data;
          if (Buffer.isBuffer(data)) {
            data = data.toString();
          }
          if (typeof data === 'string') {
            if (data.trim().length === 0) {
              resolve(undefined);
            } else {
              resolve(JSON.parse(data));
            }
          } else {
            resolve(data);
          }
        });
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("186", ["184", "187", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var Promise = $__require('184'),
        YAML = $__require('187');
    module.exports = {
      order: 200,
      allowEmpty: true,
      canParse: ['.yaml', '.yml', '.json'],
      parse: function parseYAML(file) {
        return new Promise(function(resolve, reject) {
          var data = file.data;
          if (Buffer.isBuffer(data)) {
            data = data.toString();
          }
          if (typeof data === 'string') {
            resolve(YAML.parse(data));
          } else {
            resolve(data);
          }
        });
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("188", ["185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var TEXT_REGEXP = /\.(txt|htm|html|md|xml|js|min|map|css|scss|less|svg)$/i;
    module.exports = {
      order: 300,
      allowEmpty: true,
      encoding: 'utf8',
      canParse: function isText(file) {
        return (typeof file.data === 'string' || Buffer.isBuffer(file.data)) && TEXT_REGEXP.test(file.url);
      },
      parse: function parseText(file) {
        if (typeof file.data === 'string') {
          return file.data;
        } else if (Buffer.isBuffer(file.data)) {
          return file.data.toString(this.encoding);
        } else {
          throw new Error('data is not text');
        }
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("189", ["185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var BINARY_REGEXP = /\.(jpeg|jpg|gif|png|bmp|ico)$/i;
    module.exports = {
      order: 400,
      allowEmpty: true,
      canParse: function isBinary(file) {
        return Buffer.isBuffer(file.data) && BINARY_REGEXP.test(file.url);
      },
      parse: function parseBinary(file) {
        if (Buffer.isBuffer(file.data)) {
          return file.data;
        } else {
          return new Buffer(file.data);
        }
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("18a", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  if ($__System._nodeRequire) {
    module.exports = $__System._nodeRequire('fs');
  } else {
    exports.readFileSync = function(address) {
      var output;
      var xhr = new XMLHttpRequest();
      xhr.open('GET', address, false);
      xhr.onreadystatechange = function(e) {
        if (xhr.readyState == 4) {
          var status = xhr.status;
          if ((status > 399 && status < 600) || status == 400) {
            throw 'File read error on ' + address;
          } else
            output = xhr.responseText;
        }
      };
      xhr.send(null);
      return output;
    };
  }
  return module.exports;
});

$__System.registerDynamic("18b", ["18a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('18a');
  return module.exports;
});

$__System.registerDynamic("18c", ["18b", "179", "184", "18d", "18e", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var fs = $__require('18b'),
        ono = $__require('179'),
        Promise = $__require('184'),
        url = $__require('18d'),
        debug = $__require('18e');
    module.exports = {
      order: 100,
      canRead: function isFile(file) {
        return url.isFileSystemPath(file.url);
      },
      read: function readFile(file) {
        return new Promise(function(resolve, reject) {
          var path;
          try {
            path = url.toFileSystemPath(file.url);
          } catch (err) {
            reject(ono.uri(err, 'Malformed URI: %s', file.url));
          }
          debug('Opening file: %s', path);
          try {
            fs.readFile(path, function(err, data) {
              if (err) {
                reject(ono(err, 'Error opening file "%s"', path));
              } else {
                resolve(data);
              }
            });
          } catch (err) {
            reject(ono(err, 'Error opening file "%s"', path));
          }
        });
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("18f", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.fetch = isFunction(global.fetch) && isFunction(global.ReadableByteStream);
  exports.blobConstructor = false;
  try {
    new Blob([new ArrayBuffer(1)]);
    exports.blobConstructor = true;
  } catch (e) {}
  var xhr = new global.XMLHttpRequest();
  xhr.open('GET', global.location.host ? '/' : 'https://example.com');
  function checkTypeSupport(type) {
    try {
      xhr.responseType = type;
      return xhr.responseType === type;
    } catch (e) {}
    return false;
  }
  var haveArrayBuffer = typeof global.ArrayBuffer !== 'undefined';
  var haveSlice = haveArrayBuffer && isFunction(global.ArrayBuffer.prototype.slice);
  exports.arraybuffer = haveArrayBuffer && checkTypeSupport('arraybuffer');
  exports.msstream = !exports.fetch && haveSlice && checkTypeSupport('ms-stream');
  exports.mozchunkedarraybuffer = !exports.fetch && haveArrayBuffer && checkTypeSupport('moz-chunked-arraybuffer');
  exports.overrideMimeType = isFunction(xhr.overrideMimeType);
  exports.vbArray = isFunction(global.VBArray);
  function isFunction(value) {
    return typeof value === 'function';
  }
  xhr = null;
  return module.exports;
});

$__System.registerDynamic("190", ["18f", "191", "192", "185", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    var capability = $__require('18f');
    var inherits = $__require('191');
    var stream = $__require('192');
    var rStates = exports.readyStates = {
      UNSENT: 0,
      OPENED: 1,
      HEADERS_RECEIVED: 2,
      LOADING: 3,
      DONE: 4
    };
    var IncomingMessage = exports.IncomingMessage = function(xhr, response, mode) {
      var self = this;
      stream.Readable.call(self);
      self._mode = mode;
      self.headers = {};
      self.rawHeaders = [];
      self.trailers = {};
      self.rawTrailers = [];
      self.on('end', function() {
        process.nextTick(function() {
          self.emit('close');
        });
      });
      if (mode === 'fetch') {
        self._fetchResponse = response;
        self.url = response.url;
        self.statusCode = response.status;
        self.statusMessage = response.statusText;
        for (var header,
            _i,
            _it = response.headers[Symbol.iterator](); header = (_i = _it.next()).value, !_i.done; ) {
          self.headers[header[0].toLowerCase()] = header[1];
          self.rawHeaders.push(header[0], header[1]);
        }
        var reader = response.body.getReader();
        function read() {
          reader.read().then(function(result) {
            if (self._destroyed)
              return;
            if (result.done) {
              self.push(null);
              return;
            }
            self.push(new Buffer(result.value));
            read();
          });
        }
        read();
      } else {
        self._xhr = xhr;
        self._pos = 0;
        self.url = xhr.responseURL;
        self.statusCode = xhr.status;
        self.statusMessage = xhr.statusText;
        var headers = xhr.getAllResponseHeaders().split(/\r?\n/);
        headers.forEach(function(header) {
          var matches = header.match(/^([^:]+):\s*(.*)/);
          if (matches) {
            var key = matches[1].toLowerCase();
            if (key === 'set-cookie') {
              if (self.headers[key] === undefined) {
                self.headers[key] = [];
              }
              self.headers[key].push(matches[2]);
            } else if (self.headers[key] !== undefined) {
              self.headers[key] += ', ' + matches[2];
            } else {
              self.headers[key] = matches[2];
            }
            self.rawHeaders.push(matches[1], matches[2]);
          }
        });
        self._charset = 'x-user-defined';
        if (!capability.overrideMimeType) {
          var mimeType = self.rawHeaders['mime-type'];
          if (mimeType) {
            var charsetMatch = mimeType.match(/;\s*charset=([^;])(;|$)/);
            if (charsetMatch) {
              self._charset = charsetMatch[1].toLowerCase();
            }
          }
          if (!self._charset)
            self._charset = 'utf-8';
        }
      }
    };
    inherits(IncomingMessage, stream.Readable);
    IncomingMessage.prototype._read = function() {};
    IncomingMessage.prototype._onXHRProgress = function() {
      var self = this;
      var xhr = self._xhr;
      var response = null;
      switch (self._mode) {
        case 'text:vbarray':
          if (xhr.readyState !== rStates.DONE)
            break;
          try {
            response = new global.VBArray(xhr.responseBody).toArray();
          } catch (e) {}
          if (response !== null) {
            self.push(new Buffer(response));
            break;
          }
        case 'text':
          try {
            response = xhr.responseText;
          } catch (e) {
            self._mode = 'text:vbarray';
            break;
          }
          if (response.length > self._pos) {
            var newData = response.substr(self._pos);
            if (self._charset === 'x-user-defined') {
              var buffer = new Buffer(newData.length);
              for (var i = 0; i < newData.length; i++)
                buffer[i] = newData.charCodeAt(i) & 0xff;
              self.push(buffer);
            } else {
              self.push(newData, self._charset);
            }
            self._pos = response.length;
          }
          break;
        case 'arraybuffer':
          if (xhr.readyState !== rStates.DONE)
            break;
          response = xhr.response;
          self.push(new Buffer(new Uint8Array(response)));
          break;
        case 'moz-chunked-arraybuffer':
          response = xhr.response;
          if (xhr.readyState !== rStates.LOADING || !response)
            break;
          self.push(new Buffer(new Uint8Array(response)));
          break;
        case 'ms-stream':
          response = xhr.response;
          if (xhr.readyState !== rStates.LOADING)
            break;
          var reader = new global.MSStreamReader();
          reader.onprogress = function() {
            if (reader.result.byteLength > self._pos) {
              self.push(new Buffer(new Uint8Array(reader.result.slice(self._pos))));
              self._pos = reader.result.byteLength;
            }
          };
          reader.onload = function() {
            self.push(null);
          };
          reader.readAsArrayBuffer(response);
          break;
      }
      if (self._xhr.readyState === rStates.DONE && self._mode !== 'ms-stream') {
        self.push(null);
      }
    };
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("193", ["195", "196", "185", "197", "198", "191", "@empty", "194", "199", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    'use strict';
    module.exports = Readable;
    var processNextTick = $__require('195');
    var isArray = $__require('196');
    var Buffer = $__require('185').Buffer;
    Readable.ReadableState = ReadableState;
    var EE = $__require('197');
    var EElistenerCount = function(emitter, type) {
      return emitter.listeners(type).length;
    };
    var Stream;
    (function() {
      try {
        Stream = $__require('st' + 'ream');
      } catch (_) {} finally {
        if (!Stream)
          Stream = $__require('197').EventEmitter;
      }
    })();
    var Buffer = $__require('185').Buffer;
    var util = $__require('198');
    util.inherits = $__require('191');
    var debugUtil = $__require('@empty');
    var debug = undefined;
    if (debugUtil && debugUtil.debuglog) {
      debug = debugUtil.debuglog('stream');
    } else {
      debug = function() {};
    }
    var StringDecoder;
    util.inherits(Readable, Stream);
    var Duplex;
    function ReadableState(options, stream) {
      Duplex = Duplex || $__require('194');
      options = options || {};
      this.objectMode = !!options.objectMode;
      if (stream instanceof Duplex)
        this.objectMode = this.objectMode || !!options.readableObjectMode;
      var hwm = options.highWaterMark;
      var defaultHwm = this.objectMode ? 16 : 16 * 1024;
      this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm;
      this.highWaterMark = ~~this.highWaterMark;
      this.buffer = [];
      this.length = 0;
      this.pipes = null;
      this.pipesCount = 0;
      this.flowing = null;
      this.ended = false;
      this.endEmitted = false;
      this.reading = false;
      this.sync = true;
      this.needReadable = false;
      this.emittedReadable = false;
      this.readableListening = false;
      this.resumeScheduled = false;
      this.defaultEncoding = options.defaultEncoding || 'utf8';
      this.ranOut = false;
      this.awaitDrain = 0;
      this.readingMore = false;
      this.decoder = null;
      this.encoding = null;
      if (options.encoding) {
        if (!StringDecoder)
          StringDecoder = $__require('199').StringDecoder;
        this.decoder = new StringDecoder(options.encoding);
        this.encoding = options.encoding;
      }
    }
    var Duplex;
    function Readable(options) {
      Duplex = Duplex || $__require('194');
      if (!(this instanceof Readable))
        return new Readable(options);
      this._readableState = new ReadableState(options, this);
      this.readable = true;
      if (options && typeof options.read === 'function')
        this._read = options.read;
      Stream.call(this);
    }
    Readable.prototype.push = function(chunk, encoding) {
      var state = this._readableState;
      if (!state.objectMode && typeof chunk === 'string') {
        encoding = encoding || state.defaultEncoding;
        if (encoding !== state.encoding) {
          chunk = new Buffer(chunk, encoding);
          encoding = '';
        }
      }
      return readableAddChunk(this, state, chunk, encoding, false);
    };
    Readable.prototype.unshift = function(chunk) {
      var state = this._readableState;
      return readableAddChunk(this, state, chunk, '', true);
    };
    Readable.prototype.isPaused = function() {
      return this._readableState.flowing === false;
    };
    function readableAddChunk(stream, state, chunk, encoding, addToFront) {
      var er = chunkInvalid(state, chunk);
      if (er) {
        stream.emit('error', er);
      } else if (chunk === null) {
        state.reading = false;
        onEofChunk(stream, state);
      } else if (state.objectMode || chunk && chunk.length > 0) {
        if (state.ended && !addToFront) {
          var e = new Error('stream.push() after EOF');
          stream.emit('error', e);
        } else if (state.endEmitted && addToFront) {
          var e = new Error('stream.unshift() after end event');
          stream.emit('error', e);
        } else {
          var skipAdd;
          if (state.decoder && !addToFront && !encoding) {
            chunk = state.decoder.write(chunk);
            skipAdd = !state.objectMode && chunk.length === 0;
          }
          if (!addToFront)
            state.reading = false;
          if (!skipAdd) {
            if (state.flowing && state.length === 0 && !state.sync) {
              stream.emit('data', chunk);
              stream.read(0);
            } else {
              state.length += state.objectMode ? 1 : chunk.length;
              if (addToFront)
                state.buffer.unshift(chunk);
              else
                state.buffer.push(chunk);
              if (state.needReadable)
                emitReadable(stream);
            }
          }
          maybeReadMore(stream, state);
        }
      } else if (!addToFront) {
        state.reading = false;
      }
      return needMoreData(state);
    }
    function needMoreData(state) {
      return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0);
    }
    Readable.prototype.setEncoding = function(enc) {
      if (!StringDecoder)
        StringDecoder = $__require('199').StringDecoder;
      this._readableState.decoder = new StringDecoder(enc);
      this._readableState.encoding = enc;
      return this;
    };
    var MAX_HWM = 0x800000;
    function computeNewHighWaterMark(n) {
      if (n >= MAX_HWM) {
        n = MAX_HWM;
      } else {
        n--;
        n |= n >>> 1;
        n |= n >>> 2;
        n |= n >>> 4;
        n |= n >>> 8;
        n |= n >>> 16;
        n++;
      }
      return n;
    }
    function howMuchToRead(n, state) {
      if (state.length === 0 && state.ended)
        return 0;
      if (state.objectMode)
        return n === 0 ? 0 : 1;
      if (n === null || isNaN(n)) {
        if (state.flowing && state.buffer.length)
          return state.buffer[0].length;
        else
          return state.length;
      }
      if (n <= 0)
        return 0;
      if (n > state.highWaterMark)
        state.highWaterMark = computeNewHighWaterMark(n);
      if (n > state.length) {
        if (!state.ended) {
          state.needReadable = true;
          return 0;
        } else {
          return state.length;
        }
      }
      return n;
    }
    Readable.prototype.read = function(n) {
      debug('read', n);
      var state = this._readableState;
      var nOrig = n;
      if (typeof n !== 'number' || n > 0)
        state.emittedReadable = false;
      if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) {
        debug('read: emitReadable', state.length, state.ended);
        if (state.length === 0 && state.ended)
          endReadable(this);
        else
          emitReadable(this);
        return null;
      }
      n = howMuchToRead(n, state);
      if (n === 0 && state.ended) {
        if (state.length === 0)
          endReadable(this);
        return null;
      }
      var doRead = state.needReadable;
      debug('need readable', doRead);
      if (state.length === 0 || state.length - n < state.highWaterMark) {
        doRead = true;
        debug('length less than watermark', doRead);
      }
      if (state.ended || state.reading) {
        doRead = false;
        debug('reading or ended', doRead);
      }
      if (doRead) {
        debug('do read');
        state.reading = true;
        state.sync = true;
        if (state.length === 0)
          state.needReadable = true;
        this._read(state.highWaterMark);
        state.sync = false;
      }
      if (doRead && !state.reading)
        n = howMuchToRead(nOrig, state);
      var ret;
      if (n > 0)
        ret = fromList(n, state);
      else
        ret = null;
      if (ret === null) {
        state.needReadable = true;
        n = 0;
      }
      state.length -= n;
      if (state.length === 0 && !state.ended)
        state.needReadable = true;
      if (nOrig !== n && state.ended && state.length === 0)
        endReadable(this);
      if (ret !== null)
        this.emit('data', ret);
      return ret;
    };
    function chunkInvalid(state, chunk) {
      var er = null;
      if (!Buffer.isBuffer(chunk) && typeof chunk !== 'string' && chunk !== null && chunk !== undefined && !state.objectMode) {
        er = new TypeError('Invalid non-string/buffer chunk');
      }
      return er;
    }
    function onEofChunk(stream, state) {
      if (state.ended)
        return;
      if (state.decoder) {
        var chunk = state.decoder.end();
        if (chunk && chunk.length) {
          state.buffer.push(chunk);
          state.length += state.objectMode ? 1 : chunk.length;
        }
      }
      state.ended = true;
      emitReadable(stream);
    }
    function emitReadable(stream) {
      var state = stream._readableState;
      state.needReadable = false;
      if (!state.emittedReadable) {
        debug('emitReadable', state.flowing);
        state.emittedReadable = true;
        if (state.sync)
          processNextTick(emitReadable_, stream);
        else
          emitReadable_(stream);
      }
    }
    function emitReadable_(stream) {
      debug('emit readable');
      stream.emit('readable');
      flow(stream);
    }
    function maybeReadMore(stream, state) {
      if (!state.readingMore) {
        state.readingMore = true;
        processNextTick(maybeReadMore_, stream, state);
      }
    }
    function maybeReadMore_(stream, state) {
      var len = state.length;
      while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) {
        debug('maybeReadMore read 0');
        stream.read(0);
        if (len === state.length)
          break;
        else
          len = state.length;
      }
      state.readingMore = false;
    }
    Readable.prototype._read = function(n) {
      this.emit('error', new Error('not implemented'));
    };
    Readable.prototype.pipe = function(dest, pipeOpts) {
      var src = this;
      var state = this._readableState;
      switch (state.pipesCount) {
        case 0:
          state.pipes = dest;
          break;
        case 1:
          state.pipes = [state.pipes, dest];
          break;
        default:
          state.pipes.push(dest);
          break;
      }
      state.pipesCount += 1;
      debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts);
      var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr;
      var endFn = doEnd ? onend : cleanup;
      if (state.endEmitted)
        processNextTick(endFn);
      else
        src.once('end', endFn);
      dest.on('unpipe', onunpipe);
      function onunpipe(readable) {
        debug('onunpipe');
        if (readable === src) {
          cleanup();
        }
      }
      function onend() {
        debug('onend');
        dest.end();
      }
      var ondrain = pipeOnDrain(src);
      dest.on('drain', ondrain);
      var cleanedUp = false;
      function cleanup() {
        debug('cleanup');
        dest.removeListener('close', onclose);
        dest.removeListener('finish', onfinish);
        dest.removeListener('drain', ondrain);
        dest.removeListener('error', onerror);
        dest.removeListener('unpipe', onunpipe);
        src.removeListener('end', onend);
        src.removeListener('end', cleanup);
        src.removeListener('data', ondata);
        cleanedUp = true;
        if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain))
          ondrain();
      }
      src.on('data', ondata);
      function ondata(chunk) {
        debug('ondata');
        var ret = dest.write(chunk);
        if (false === ret) {
          if (state.pipesCount === 1 && state.pipes[0] === dest && src.listenerCount('data') === 1 && !cleanedUp) {
            debug('false write response, pause', src._readableState.awaitDrain);
            src._readableState.awaitDrain++;
          }
          src.pause();
        }
      }
      function onerror(er) {
        debug('onerror', er);
        unpipe();
        dest.removeListener('error', onerror);
        if (EElistenerCount(dest, 'error') === 0)
          dest.emit('error', er);
      }
      if (!dest._events || !dest._events.error)
        dest.on('error', onerror);
      else if (isArray(dest._events.error))
        dest._events.error.unshift(onerror);
      else
        dest._events.error = [onerror, dest._events.error];
      function onclose() {
        dest.removeListener('finish', onfinish);
        unpipe();
      }
      dest.once('close', onclose);
      function onfinish() {
        debug('onfinish');
        dest.removeListener('close', onclose);
        unpipe();
      }
      dest.once('finish', onfinish);
      function unpipe() {
        debug('unpipe');
        src.unpipe(dest);
      }
      dest.emit('pipe', src);
      if (!state.flowing) {
        debug('pipe resume');
        src.resume();
      }
      return dest;
    };
    function pipeOnDrain(src) {
      return function() {
        var state = src._readableState;
        debug('pipeOnDrain', state.awaitDrain);
        if (state.awaitDrain)
          state.awaitDrain--;
        if (state.awaitDrain === 0 && EElistenerCount(src, 'data')) {
          state.flowing = true;
          flow(src);
        }
      };
    }
    Readable.prototype.unpipe = function(dest) {
      var state = this._readableState;
      if (state.pipesCount === 0)
        return this;
      if (state.pipesCount === 1) {
        if (dest && dest !== state.pipes)
          return this;
        if (!dest)
          dest = state.pipes;
        state.pipes = null;
        state.pipesCount = 0;
        state.flowing = false;
        if (dest)
          dest.emit('unpipe', this);
        return this;
      }
      if (!dest) {
        var dests = state.pipes;
        var len = state.pipesCount;
        state.pipes = null;
        state.pipesCount = 0;
        state.flowing = false;
        for (var _i = 0; _i < len; _i++) {
          dests[_i].emit('unpipe', this);
        }
        return this;
      }
      var i = indexOf(state.pipes, dest);
      if (i === -1)
        return this;
      state.pipes.splice(i, 1);
      state.pipesCount -= 1;
      if (state.pipesCount === 1)
        state.pipes = state.pipes[0];
      dest.emit('unpipe', this);
      return this;
    };
    Readable.prototype.on = function(ev, fn) {
      var res = Stream.prototype.on.call(this, ev, fn);
      if (ev === 'data' && false !== this._readableState.flowing) {
        this.resume();
      }
      if (ev === 'readable' && !this._readableState.endEmitted) {
        var state = this._readableState;
        if (!state.readableListening) {
          state.readableListening = true;
          state.emittedReadable = false;
          state.needReadable = true;
          if (!state.reading) {
            processNextTick(nReadingNextTick, this);
          } else if (state.length) {
            emitReadable(this, state);
          }
        }
      }
      return res;
    };
    Readable.prototype.addListener = Readable.prototype.on;
    function nReadingNextTick(self) {
      debug('readable nexttick read 0');
      self.read(0);
    }
    Readable.prototype.resume = function() {
      var state = this._readableState;
      if (!state.flowing) {
        debug('resume');
        state.flowing = true;
        resume(this, state);
      }
      return this;
    };
    function resume(stream, state) {
      if (!state.resumeScheduled) {
        state.resumeScheduled = true;
        processNextTick(resume_, stream, state);
      }
    }
    function resume_(stream, state) {
      if (!state.reading) {
        debug('resume read 0');
        stream.read(0);
      }
      state.resumeScheduled = false;
      stream.emit('resume');
      flow(stream);
      if (state.flowing && !state.reading)
        stream.read(0);
    }
    Readable.prototype.pause = function() {
      debug('call pause flowing=%j', this._readableState.flowing);
      if (false !== this._readableState.flowing) {
        debug('pause');
        this._readableState.flowing = false;
        this.emit('pause');
      }
      return this;
    };
    function flow(stream) {
      var state = stream._readableState;
      debug('flow', state.flowing);
      if (state.flowing) {
        do {
          var chunk = stream.read();
        } while (null !== chunk && state.flowing);
      }
    }
    Readable.prototype.wrap = function(stream) {
      var state = this._readableState;
      var paused = false;
      var self = this;
      stream.on('end', function() {
        debug('wrapped end');
        if (state.decoder && !state.ended) {
          var chunk = state.decoder.end();
          if (chunk && chunk.length)
            self.push(chunk);
        }
        self.push(null);
      });
      stream.on('data', function(chunk) {
        debug('wrapped data');
        if (state.decoder)
          chunk = state.decoder.write(chunk);
        if (state.objectMode && (chunk === null || chunk === undefined))
          return;
        else if (!state.objectMode && (!chunk || !chunk.length))
          return;
        var ret = self.push(chunk);
        if (!ret) {
          paused = true;
          stream.pause();
        }
      });
      for (var i in stream) {
        if (this[i] === undefined && typeof stream[i] === 'function') {
          this[i] = function(method) {
            return function() {
              return stream[method].apply(stream, arguments);
            };
          }(i);
        }
      }
      var events = ['error', 'close', 'destroy', 'pause', 'resume'];
      forEach(events, function(ev) {
        stream.on(ev, self.emit.bind(self, ev));
      });
      self._read = function(n) {
        debug('wrapped _read', n);
        if (paused) {
          paused = false;
          stream.resume();
        }
      };
      return self;
    };
    Readable._fromList = fromList;
    function fromList(n, state) {
      var list = state.buffer;
      var length = state.length;
      var stringMode = !!state.decoder;
      var objectMode = !!state.objectMode;
      var ret;
      if (list.length === 0)
        return null;
      if (length === 0)
        ret = null;
      else if (objectMode)
        ret = list.shift();
      else if (!n || n >= length) {
        if (stringMode)
          ret = list.join('');
        else if (list.length === 1)
          ret = list[0];
        else
          ret = Buffer.concat(list, length);
        list.length = 0;
      } else {
        if (n < list[0].length) {
          var buf = list[0];
          ret = buf.slice(0, n);
          list[0] = buf.slice(n);
        } else if (n === list[0].length) {
          ret = list.shift();
        } else {
          if (stringMode)
            ret = '';
          else
            ret = new Buffer(n);
          var c = 0;
          for (var i = 0,
              l = list.length; i < l && c < n; i++) {
            var buf = list[0];
            var cpy = Math.min(n - c, buf.length);
            if (stringMode)
              ret += buf.slice(0, cpy);
            else
              buf.copy(ret, c, 0, cpy);
            if (cpy < buf.length)
              list[0] = buf.slice(cpy);
            else
              list.shift();
            c += cpy;
          }
        }
      }
      return ret;
    }
    function endReadable(stream) {
      var state = stream._readableState;
      if (state.length > 0)
        throw new Error('endReadable called on non-empty stream');
      if (!state.endEmitted) {
        state.ended = true;
        processNextTick(endReadableNT, state, stream);
      }
    }
    function endReadableNT(state, stream) {
      if (!state.endEmitted && state.length === 0) {
        state.endEmitted = true;
        stream.readable = false;
        stream.emit('end');
      }
    }
    function forEach(xs, f) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        f(xs[i], i);
      }
    }
    function indexOf(xs, x) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        if (xs[i] === x)
          return i;
      }
      return -1;
    }
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("19a", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    if (!process.version || process.version.indexOf('v0.') === 0 || process.version.indexOf('v1.') === 0 && process.version.indexOf('v1.8.') !== 0) {
      module.exports = nextTick;
    } else {
      module.exports = process.nextTick;
    }
    function nextTick(fn) {
      var args = new Array(arguments.length - 1);
      var i = 0;
      while (i < args.length) {
        args[i++] = arguments[i];
      }
      process.nextTick(function afterTick() {
        fn.apply(null, args);
      });
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("195", ["19a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('19a');
  return module.exports;
});

$__System.registerDynamic("19b", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = deprecate;
  function deprecate(fn, msg) {
    if (config('noDeprecation')) {
      return fn;
    }
    var warned = false;
    function deprecated() {
      if (!warned) {
        if (config('throwDeprecation')) {
          throw new Error(msg);
        } else if (config('traceDeprecation')) {
          console.trace(msg);
        } else {
          console.warn(msg);
        }
        warned = true;
      }
      return fn.apply(this, arguments);
    }
    return deprecated;
  }
  function config(name) {
    try {
      if (!global.localStorage)
        return false;
    } catch (_) {
      return false;
    }
    var val = global.localStorage[name];
    if (null == val)
      return false;
    return String(val).toLowerCase() === 'true';
  }
  return module.exports;
});

$__System.registerDynamic("19c", ["19b"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('19b');
  return module.exports;
});

$__System.registerDynamic("19d", ["195", "185", "198", "191", "19c", "197", "194", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    'use strict';
    module.exports = Writable;
    var processNextTick = $__require('195');
    var asyncWrite = !process.browser && ['v0.10', 'v0.9.'].indexOf(process.version.slice(0, 5)) > -1 ? setImmediate : processNextTick;
    var Buffer = $__require('185').Buffer;
    Writable.WritableState = WritableState;
    var util = $__require('198');
    util.inherits = $__require('191');
    var internalUtil = {deprecate: $__require('19c')};
    var Stream;
    (function() {
      try {
        Stream = $__require('st' + 'ream');
      } catch (_) {} finally {
        if (!Stream)
          Stream = $__require('197').EventEmitter;
      }
    })();
    var Buffer = $__require('185').Buffer;
    util.inherits(Writable, Stream);
    function nop() {}
    function WriteReq(chunk, encoding, cb) {
      this.chunk = chunk;
      this.encoding = encoding;
      this.callback = cb;
      this.next = null;
    }
    var Duplex;
    function WritableState(options, stream) {
      Duplex = Duplex || $__require('194');
      options = options || {};
      this.objectMode = !!options.objectMode;
      if (stream instanceof Duplex)
        this.objectMode = this.objectMode || !!options.writableObjectMode;
      var hwm = options.highWaterMark;
      var defaultHwm = this.objectMode ? 16 : 16 * 1024;
      this.highWaterMark = hwm || hwm === 0 ? hwm : defaultHwm;
      this.highWaterMark = ~~this.highWaterMark;
      this.needDrain = false;
      this.ending = false;
      this.ended = false;
      this.finished = false;
      var noDecode = options.decodeStrings === false;
      this.decodeStrings = !noDecode;
      this.defaultEncoding = options.defaultEncoding || 'utf8';
      this.length = 0;
      this.writing = false;
      this.corked = 0;
      this.sync = true;
      this.bufferProcessing = false;
      this.onwrite = function(er) {
        onwrite(stream, er);
      };
      this.writecb = null;
      this.writelen = 0;
      this.bufferedRequest = null;
      this.lastBufferedRequest = null;
      this.pendingcb = 0;
      this.prefinished = false;
      this.errorEmitted = false;
      this.bufferedRequestCount = 0;
      this.corkedRequestsFree = new CorkedRequest(this);
      this.corkedRequestsFree.next = new CorkedRequest(this);
    }
    WritableState.prototype.getBuffer = function writableStateGetBuffer() {
      var current = this.bufferedRequest;
      var out = [];
      while (current) {
        out.push(current);
        current = current.next;
      }
      return out;
    };
    (function() {
      try {
        Object.defineProperty(WritableState.prototype, 'buffer', {get: internalUtil.deprecate(function() {
            return this.getBuffer();
          }, '_writableState.buffer is deprecated. Use _writableState.getBuffer ' + 'instead.')});
      } catch (_) {}
    })();
    var Duplex;
    function Writable(options) {
      Duplex = Duplex || $__require('194');
      if (!(this instanceof Writable) && !(this instanceof Duplex))
        return new Writable(options);
      this._writableState = new WritableState(options, this);
      this.writable = true;
      if (options) {
        if (typeof options.write === 'function')
          this._write = options.write;
        if (typeof options.writev === 'function')
          this._writev = options.writev;
      }
      Stream.call(this);
    }
    Writable.prototype.pipe = function() {
      this.emit('error', new Error('Cannot pipe. Not readable.'));
    };
    function writeAfterEnd(stream, cb) {
      var er = new Error('write after end');
      stream.emit('error', er);
      processNextTick(cb, er);
    }
    function validChunk(stream, state, chunk, cb) {
      var valid = true;
      if (!Buffer.isBuffer(chunk) && typeof chunk !== 'string' && chunk !== null && chunk !== undefined && !state.objectMode) {
        var er = new TypeError('Invalid non-string/buffer chunk');
        stream.emit('error', er);
        processNextTick(cb, er);
        valid = false;
      }
      return valid;
    }
    Writable.prototype.write = function(chunk, encoding, cb) {
      var state = this._writableState;
      var ret = false;
      if (typeof encoding === 'function') {
        cb = encoding;
        encoding = null;
      }
      if (Buffer.isBuffer(chunk))
        encoding = 'buffer';
      else if (!encoding)
        encoding = state.defaultEncoding;
      if (typeof cb !== 'function')
        cb = nop;
      if (state.ended)
        writeAfterEnd(this, cb);
      else if (validChunk(this, state, chunk, cb)) {
        state.pendingcb++;
        ret = writeOrBuffer(this, state, chunk, encoding, cb);
      }
      return ret;
    };
    Writable.prototype.cork = function() {
      var state = this._writableState;
      state.corked++;
    };
    Writable.prototype.uncork = function() {
      var state = this._writableState;
      if (state.corked) {
        state.corked--;
        if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.bufferedRequest)
          clearBuffer(this, state);
      }
    };
    Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) {
      if (typeof encoding === 'string')
        encoding = encoding.toLowerCase();
      if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64', 'ucs2', 'ucs-2', 'utf16le', 'utf-16le', 'raw'].indexOf((encoding + '').toLowerCase()) > -1))
        throw new TypeError('Unknown encoding: ' + encoding);
      this._writableState.defaultEncoding = encoding;
    };
    function decodeChunk(state, chunk, encoding) {
      if (!state.objectMode && state.decodeStrings !== false && typeof chunk === 'string') {
        chunk = new Buffer(chunk, encoding);
      }
      return chunk;
    }
    function writeOrBuffer(stream, state, chunk, encoding, cb) {
      chunk = decodeChunk(state, chunk, encoding);
      if (Buffer.isBuffer(chunk))
        encoding = 'buffer';
      var len = state.objectMode ? 1 : chunk.length;
      state.length += len;
      var ret = state.length < state.highWaterMark;
      if (!ret)
        state.needDrain = true;
      if (state.writing || state.corked) {
        var last = state.lastBufferedRequest;
        state.lastBufferedRequest = new WriteReq(chunk, encoding, cb);
        if (last) {
          last.next = state.lastBufferedRequest;
        } else {
          state.bufferedRequest = state.lastBufferedRequest;
        }
        state.bufferedRequestCount += 1;
      } else {
        doWrite(stream, state, false, len, chunk, encoding, cb);
      }
      return ret;
    }
    function doWrite(stream, state, writev, len, chunk, encoding, cb) {
      state.writelen = len;
      state.writecb = cb;
      state.writing = true;
      state.sync = true;
      if (writev)
        stream._writev(chunk, state.onwrite);
      else
        stream._write(chunk, encoding, state.onwrite);
      state.sync = false;
    }
    function onwriteError(stream, state, sync, er, cb) {
      --state.pendingcb;
      if (sync)
        processNextTick(cb, er);
      else
        cb(er);
      stream._writableState.errorEmitted = true;
      stream.emit('error', er);
    }
    function onwriteStateUpdate(state) {
      state.writing = false;
      state.writecb = null;
      state.length -= state.writelen;
      state.writelen = 0;
    }
    function onwrite(stream, er) {
      var state = stream._writableState;
      var sync = state.sync;
      var cb = state.writecb;
      onwriteStateUpdate(state);
      if (er)
        onwriteError(stream, state, sync, er, cb);
      else {
        var finished = needFinish(state);
        if (!finished && !state.corked && !state.bufferProcessing && state.bufferedRequest) {
          clearBuffer(stream, state);
        }
        if (sync) {
          asyncWrite(afterWrite, stream, state, finished, cb);
        } else {
          afterWrite(stream, state, finished, cb);
        }
      }
    }
    function afterWrite(stream, state, finished, cb) {
      if (!finished)
        onwriteDrain(stream, state);
      state.pendingcb--;
      cb();
      finishMaybe(stream, state);
    }
    function onwriteDrain(stream, state) {
      if (state.length === 0 && state.needDrain) {
        state.needDrain = false;
        stream.emit('drain');
      }
    }
    function clearBuffer(stream, state) {
      state.bufferProcessing = true;
      var entry = state.bufferedRequest;
      if (stream._writev && entry && entry.next) {
        var l = state.bufferedRequestCount;
        var buffer = new Array(l);
        var holder = state.corkedRequestsFree;
        holder.entry = entry;
        var count = 0;
        while (entry) {
          buffer[count] = entry;
          entry = entry.next;
          count += 1;
        }
        doWrite(stream, state, true, state.length, buffer, '', holder.finish);
        state.pendingcb++;
        state.lastBufferedRequest = null;
        state.corkedRequestsFree = holder.next;
        holder.next = null;
      } else {
        while (entry) {
          var chunk = entry.chunk;
          var encoding = entry.encoding;
          var cb = entry.callback;
          var len = state.objectMode ? 1 : chunk.length;
          doWrite(stream, state, false, len, chunk, encoding, cb);
          entry = entry.next;
          if (state.writing) {
            break;
          }
        }
        if (entry === null)
          state.lastBufferedRequest = null;
      }
      state.bufferedRequestCount = 0;
      state.bufferedRequest = entry;
      state.bufferProcessing = false;
    }
    Writable.prototype._write = function(chunk, encoding, cb) {
      cb(new Error('not implemented'));
    };
    Writable.prototype._writev = null;
    Writable.prototype.end = function(chunk, encoding, cb) {
      var state = this._writableState;
      if (typeof chunk === 'function') {
        cb = chunk;
        chunk = null;
        encoding = null;
      } else if (typeof encoding === 'function') {
        cb = encoding;
        encoding = null;
      }
      if (chunk !== null && chunk !== undefined)
        this.write(chunk, encoding);
      if (state.corked) {
        state.corked = 1;
        this.uncork();
      }
      if (!state.ending && !state.finished)
        endWritable(this, state, cb);
    };
    function needFinish(state) {
      return state.ending && state.length === 0 && state.bufferedRequest === null && !state.finished && !state.writing;
    }
    function prefinish(stream, state) {
      if (!state.prefinished) {
        state.prefinished = true;
        stream.emit('prefinish');
      }
    }
    function finishMaybe(stream, state) {
      var need = needFinish(state);
      if (need) {
        if (state.pendingcb === 0) {
          prefinish(stream, state);
          state.finished = true;
          stream.emit('finish');
        } else {
          prefinish(stream, state);
        }
      }
      return need;
    }
    function endWritable(stream, state, cb) {
      state.ending = true;
      finishMaybe(stream, state);
      if (cb) {
        if (state.finished)
          processNextTick(cb);
        else
          stream.once('finish', cb);
      }
      state.ended = true;
      stream.writable = false;
    }
    function CorkedRequest(state) {
      var _this = this;
      this.next = null;
      this.entry = null;
      this.finish = function(err) {
        var entry = _this.entry;
        _this.entry = null;
        while (entry) {
          var cb = entry.callback;
          state.pendingcb--;
          cb(err);
          entry = entry.next;
        }
        if (state.corkedRequestsFree) {
          state.corkedRequestsFree.next = _this;
        } else {
          state.corkedRequestsFree = _this;
        }
      };
    }
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("194", ["195", "198", "191", "193", "19d", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    var objectKeys = Object.keys || function(obj) {
      var keys = [];
      for (var key in obj) {
        keys.push(key);
      }
      return keys;
    };
    module.exports = Duplex;
    var processNextTick = $__require('195');
    var util = $__require('198');
    util.inherits = $__require('191');
    var Readable = $__require('193');
    var Writable = $__require('19d');
    util.inherits(Duplex, Readable);
    var keys = objectKeys(Writable.prototype);
    for (var v = 0; v < keys.length; v++) {
      var method = keys[v];
      if (!Duplex.prototype[method])
        Duplex.prototype[method] = Writable.prototype[method];
    }
    function Duplex(options) {
      if (!(this instanceof Duplex))
        return new Duplex(options);
      Readable.call(this, options);
      Writable.call(this, options);
      if (options && options.readable === false)
        this.readable = false;
      if (options && options.writable === false)
        this.writable = false;
      this.allowHalfOpen = true;
      if (options && options.allowHalfOpen === false)
        this.allowHalfOpen = false;
      this.once('end', onend);
    }
    function onend() {
      if (this.allowHalfOpen || this._writableState.ended)
        return;
      processNextTick(onEndNT, this);
    }
    function onEndNT(self) {
      self.end();
    }
    function forEach(xs, f) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        f(xs[i], i);
      }
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("19e", ["194", "198", "191", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    module.exports = Transform;
    var Duplex = $__require('194');
    var util = $__require('198');
    util.inherits = $__require('191');
    util.inherits(Transform, Duplex);
    function TransformState(stream) {
      this.afterTransform = function(er, data) {
        return afterTransform(stream, er, data);
      };
      this.needTransform = false;
      this.transforming = false;
      this.writecb = null;
      this.writechunk = null;
      this.writeencoding = null;
    }
    function afterTransform(stream, er, data) {
      var ts = stream._transformState;
      ts.transforming = false;
      var cb = ts.writecb;
      if (!cb)
        return stream.emit('error', new Error('no writecb in Transform class'));
      ts.writechunk = null;
      ts.writecb = null;
      if (data !== null && data !== undefined)
        stream.push(data);
      cb(er);
      var rs = stream._readableState;
      rs.reading = false;
      if (rs.needReadable || rs.length < rs.highWaterMark) {
        stream._read(rs.highWaterMark);
      }
    }
    function Transform(options) {
      if (!(this instanceof Transform))
        return new Transform(options);
      Duplex.call(this, options);
      this._transformState = new TransformState(this);
      var stream = this;
      this._readableState.needReadable = true;
      this._readableState.sync = false;
      if (options) {
        if (typeof options.transform === 'function')
          this._transform = options.transform;
        if (typeof options.flush === 'function')
          this._flush = options.flush;
      }
      this.once('prefinish', function() {
        if (typeof this._flush === 'function')
          this._flush(function(er) {
            done(stream, er);
          });
        else
          done(stream);
      });
    }
    Transform.prototype.push = function(chunk, encoding) {
      this._transformState.needTransform = false;
      return Duplex.prototype.push.call(this, chunk, encoding);
    };
    Transform.prototype._transform = function(chunk, encoding, cb) {
      throw new Error('not implemented');
    };
    Transform.prototype._write = function(chunk, encoding, cb) {
      var ts = this._transformState;
      ts.writecb = cb;
      ts.writechunk = chunk;
      ts.writeencoding = encoding;
      if (!ts.transforming) {
        var rs = this._readableState;
        if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark)
          this._read(rs.highWaterMark);
      }
    };
    Transform.prototype._read = function(n) {
      var ts = this._transformState;
      if (ts.writechunk !== null && ts.writecb && !ts.transforming) {
        ts.transforming = true;
        this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);
      } else {
        ts.needTransform = true;
      }
    };
    function done(stream, er) {
      if (er)
        return stream.emit('error', er);
      var ws = stream._writableState;
      var ts = stream._transformState;
      if (ws.length)
        throw new Error('calling transform done when ws.length != 0');
      if (ts.transforming)
        throw new Error('calling transform done when still transforming');
      return stream.push(null);
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("19f", ["19e", "198", "191"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = PassThrough;
  var Transform = $__require('19e');
  var util = $__require('198');
  util.inherits = $__require('191');
  util.inherits(PassThrough, Transform);
  function PassThrough(options) {
    if (!(this instanceof PassThrough))
      return new PassThrough(options);
    Transform.call(this, options);
  }
  PassThrough.prototype._transform = function(chunk, encoding, cb) {
    cb(null, chunk);
  };
  return module.exports;
});

$__System.registerDynamic("1a0", ["193", "19d", "194", "19e", "19f", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    var Stream = (function() {
      try {
        return $__require('st' + 'ream');
      } catch (_) {}
    }());
    exports = module.exports = $__require('193');
    exports.Stream = Stream || exports;
    exports.Readable = exports;
    exports.Writable = $__require('19d');
    exports.Duplex = $__require('194');
    exports.Transform = $__require('19e');
    exports.PassThrough = $__require('19f');
    if (!process.browser && process.env.READABLE_STREAM === 'disable' && Stream) {
      module.exports = Stream;
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("192", ["1a0"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1a0');
  return module.exports;
});

$__System.registerDynamic("1a1", ["185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    var Buffer = $__require('185').Buffer;
    module.exports = function(buf) {
      if (buf instanceof Uint8Array) {
        if (buf.byteOffset === 0 && buf.byteLength === buf.buffer.byteLength) {
          return buf.buffer;
        } else if (typeof buf.buffer.slice === 'function') {
          return buf.buffer.slice(buf.byteOffset, buf.byteOffset + buf.byteLength);
        }
      }
      if (Buffer.isBuffer(buf)) {
        var arrayCopy = new Uint8Array(buf.length);
        var len = buf.length;
        for (var i = 0; i < len; i++) {
          arrayCopy[i] = buf[i];
        }
        return arrayCopy.buffer;
      } else {
        throw new Error('Argument must be a Buffer');
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("1a2", ["1a1"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1a1');
  return module.exports;
});

$__System.registerDynamic("1a3", ["18f", "191", "190", "192", "1a2", "185", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    var capability = $__require('18f');
    var inherits = $__require('191');
    var response = $__require('190');
    var stream = $__require('192');
    var toArrayBuffer = $__require('1a2');
    var IncomingMessage = response.IncomingMessage;
    var rStates = response.readyStates;
    function decideMode(preferBinary) {
      if (capability.fetch) {
        return 'fetch';
      } else if (capability.mozchunkedarraybuffer) {
        return 'moz-chunked-arraybuffer';
      } else if (capability.msstream) {
        return 'ms-stream';
      } else if (capability.arraybuffer && preferBinary) {
        return 'arraybuffer';
      } else if (capability.vbArray && preferBinary) {
        return 'text:vbarray';
      } else {
        return 'text';
      }
    }
    var ClientRequest = module.exports = function(opts) {
      var self = this;
      stream.Writable.call(self);
      self._opts = opts;
      self._body = [];
      self._headers = {};
      if (opts.auth)
        self.setHeader('Authorization', 'Basic ' + new Buffer(opts.auth).toString('base64'));
      Object.keys(opts.headers).forEach(function(name) {
        self.setHeader(name, opts.headers[name]);
      });
      var preferBinary;
      if (opts.mode === 'prefer-streaming') {
        preferBinary = false;
      } else if (opts.mode === 'allow-wrong-content-type') {
        preferBinary = !capability.overrideMimeType;
      } else if (!opts.mode || opts.mode === 'default' || opts.mode === 'prefer-fast') {
        preferBinary = true;
      } else {
        throw new Error('Invalid value for opts.mode');
      }
      self._mode = decideMode(preferBinary);
      self.on('finish', function() {
        self._onFinish();
      });
    };
    inherits(ClientRequest, stream.Writable);
    ClientRequest.prototype.setHeader = function(name, value) {
      var self = this;
      var lowerName = name.toLowerCase();
      if (unsafeHeaders.indexOf(lowerName) !== -1)
        return;
      self._headers[lowerName] = {
        name: name,
        value: value
      };
    };
    ClientRequest.prototype.getHeader = function(name) {
      var self = this;
      return self._headers[name.toLowerCase()].value;
    };
    ClientRequest.prototype.removeHeader = function(name) {
      var self = this;
      delete self._headers[name.toLowerCase()];
    };
    ClientRequest.prototype._onFinish = function() {
      var self = this;
      if (self._destroyed)
        return;
      var opts = self._opts;
      var headersObj = self._headers;
      var body;
      if (opts.method === 'POST' || opts.method === 'PUT' || opts.method === 'PATCH') {
        if (capability.blobConstructor) {
          body = new global.Blob(self._body.map(function(buffer) {
            return toArrayBuffer(buffer);
          }), {type: (headersObj['content-type'] || {}).value || ''});
        } else {
          body = Buffer.concat(self._body).toString();
        }
      }
      if (self._mode === 'fetch') {
        var headers = Object.keys(headersObj).map(function(name) {
          return [headersObj[name].name, headersObj[name].value];
        });
        global.fetch(self._opts.url, {
          method: self._opts.method,
          headers: headers,
          body: body,
          mode: 'cors',
          credentials: opts.withCredentials ? 'include' : 'same-origin'
        }).then(function(response) {
          self._fetchResponse = response;
          self._connect();
        }, function(reason) {
          self.emit('error', reason);
        });
      } else {
        var xhr = self._xhr = new global.XMLHttpRequest();
        try {
          xhr.open(self._opts.method, self._opts.url, true);
        } catch (err) {
          process.nextTick(function() {
            self.emit('error', err);
          });
          return;
        }
        if ('responseType' in xhr)
          xhr.responseType = self._mode.split(':')[0];
        if ('withCredentials' in xhr)
          xhr.withCredentials = !!opts.withCredentials;
        if (self._mode === 'text' && 'overrideMimeType' in xhr)
          xhr.overrideMimeType('text/plain; charset=x-user-defined');
        Object.keys(headersObj).forEach(function(name) {
          xhr.setRequestHeader(headersObj[name].name, headersObj[name].value);
        });
        self._response = null;
        xhr.onreadystatechange = function() {
          switch (xhr.readyState) {
            case rStates.LOADING:
            case rStates.DONE:
              self._onXHRProgress();
              break;
          }
        };
        if (self._mode === 'moz-chunked-arraybuffer') {
          xhr.onprogress = function() {
            self._onXHRProgress();
          };
        }
        xhr.onerror = function() {
          if (self._destroyed)
            return;
          self.emit('error', new Error('XHR error'));
        };
        try {
          xhr.send(body);
        } catch (err) {
          process.nextTick(function() {
            self.emit('error', err);
          });
          return;
        }
      }
    };
    function statusValid(xhr) {
      try {
        var status = xhr.status;
        return (status !== null && status !== 0);
      } catch (e) {
        return false;
      }
    }
    ClientRequest.prototype._onXHRProgress = function() {
      var self = this;
      if (!statusValid(self._xhr) || self._destroyed)
        return;
      if (!self._response)
        self._connect();
      self._response._onXHRProgress();
    };
    ClientRequest.prototype._connect = function() {
      var self = this;
      if (self._destroyed)
        return;
      self._response = new IncomingMessage(self._xhr, self._fetchResponse, self._mode);
      self.emit('response', self._response);
    };
    ClientRequest.prototype._write = function(chunk, encoding, cb) {
      var self = this;
      self._body.push(chunk);
      cb();
    };
    ClientRequest.prototype.abort = ClientRequest.prototype.destroy = function() {
      var self = this;
      self._destroyed = true;
      if (self._response)
        self._response._destroyed = true;
      if (self._xhr)
        self._xhr.abort();
    };
    ClientRequest.prototype.end = function(data, encoding, cb) {
      var self = this;
      if (typeof data === 'function') {
        cb = data;
        data = undefined;
      }
      stream.Writable.prototype.end.call(self, data, encoding, cb);
    };
    ClientRequest.prototype.flushHeaders = function() {};
    ClientRequest.prototype.setTimeout = function() {};
    ClientRequest.prototype.setNoDelay = function() {};
    ClientRequest.prototype.setSocketKeepAlive = function() {};
    var unsafeHeaders = ['accept-charset', 'accept-encoding', 'access-control-request-headers', 'access-control-request-method', 'connection', 'content-length', 'cookie', 'cookie2', 'date', 'dnt', 'expect', 'host', 'keep-alive', 'origin', 'referer', 'te', 'trailer', 'transfer-encoding', 'upgrade', 'user-agent', 'via'];
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("1a4", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = extend;
  var hasOwnProperty = Object.prototype.hasOwnProperty;
  function extend() {
    var target = {};
    for (var i = 0; i < arguments.length; i++) {
      var source = arguments[i];
      for (var key in source) {
        if (hasOwnProperty.call(source, key)) {
          target[key] = source[key];
        }
      }
    }
    return target;
  }
  return module.exports;
});

$__System.registerDynamic("1a5", ["1a4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1a4');
  return module.exports;
});

$__System.registerDynamic("1a6", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "100": "Continue",
    "101": "Switching Protocols",
    "102": "Processing",
    "200": "OK",
    "201": "Created",
    "202": "Accepted",
    "203": "Non-Authoritative Information",
    "204": "No Content",
    "205": "Reset Content",
    "206": "Partial Content",
    "207": "Multi-Status",
    "208": "Already Reported",
    "226": "IM Used",
    "300": "Multiple Choices",
    "301": "Moved Permanently",
    "302": "Found",
    "303": "See Other",
    "304": "Not Modified",
    "305": "Use Proxy",
    "307": "Temporary Redirect",
    "308": "Permanent Redirect",
    "400": "Bad Request",
    "401": "Unauthorized",
    "402": "Payment Required",
    "403": "Forbidden",
    "404": "Not Found",
    "405": "Method Not Allowed",
    "406": "Not Acceptable",
    "407": "Proxy Authentication Required",
    "408": "Request Timeout",
    "409": "Conflict",
    "410": "Gone",
    "411": "Length Required",
    "412": "Precondition Failed",
    "413": "Payload Too Large",
    "414": "URI Too Long",
    "415": "Unsupported Media Type",
    "416": "Range Not Satisfiable",
    "417": "Expectation Failed",
    "418": "I'm a teapot",
    "421": "Misdirected Request",
    "422": "Unprocessable Entity",
    "423": "Locked",
    "424": "Failed Dependency",
    "425": "Unordered Collection",
    "426": "Upgrade Required",
    "428": "Precondition Required",
    "429": "Too Many Requests",
    "431": "Request Header Fields Too Large",
    "500": "Internal Server Error",
    "501": "Not Implemented",
    "502": "Bad Gateway",
    "503": "Service Unavailable",
    "504": "Gateway Timeout",
    "505": "HTTP Version Not Supported",
    "506": "Variant Also Negotiates",
    "507": "Insufficient Storage",
    "508": "Loop Detected",
    "509": "Bandwidth Limit Exceeded",
    "510": "Not Extended",
    "511": "Network Authentication Required"
  };
  return module.exports;
});

$__System.registerDynamic("1a7", ["1a6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1a6');
  return module.exports;
});

$__System.registerDynamic("1a8", ["1a3", "1a5", "1a7", "1a9"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ClientRequest = $__require('1a3');
  var extend = $__require('1a5');
  var statusCodes = $__require('1a7');
  var url = $__require('1a9');
  var http = exports;
  http.request = function(opts, cb) {
    if (typeof opts === 'string')
      opts = url.parse(opts);
    else
      opts = extend(opts);
    var defaultProtocol = global.location.protocol.search(/^https?:$/) === -1 ? 'http:' : '';
    var protocol = opts.protocol || defaultProtocol;
    var host = opts.hostname || opts.host;
    var port = opts.port;
    var path = opts.path || '/';
    if (host && host.indexOf(':') !== -1)
      host = '[' + host + ']';
    opts.url = (host ? (protocol + '//' + host) : '') + (port ? ':' + port : '') + path;
    opts.method = (opts.method || 'GET').toUpperCase();
    opts.headers = opts.headers || {};
    var req = new ClientRequest(opts);
    if (cb)
      req.on('response', cb);
    return req;
  };
  http.get = function get(opts, cb) {
    var req = http.request(opts, cb);
    req.end();
    return req;
  };
  http.Agent = function() {};
  http.Agent.defaultMaxSockets = 4;
  http.STATUS_CODES = statusCodes;
  http.METHODS = ['CHECKOUT', 'CONNECT', 'COPY', 'DELETE', 'GET', 'HEAD', 'LOCK', 'M-SEARCH', 'MERGE', 'MKACTIVITY', 'MKCOL', 'MOVE', 'NOTIFY', 'OPTIONS', 'PATCH', 'POST', 'PROPFIND', 'PROPPATCH', 'PURGE', 'PUT', 'REPORT', 'SEARCH', 'SUBSCRIBE', 'TRACE', 'UNLOCK', 'UNSUBSCRIBE'];
  return module.exports;
});

$__System.registerDynamic("1aa", ["1a8"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1a8');
  return module.exports;
});

$__System.registerDynamic("1ab", ["1ac", "1b1", "1ad", "1ae", "1af", "1b0", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    exports = module.exports = $__require('1ac');
    exports.Stream = $__require('1b1');
    exports.Readable = exports;
    exports.Writable = $__require('1ad');
    exports.Duplex = $__require('1ae');
    exports.Transform = $__require('1af');
    exports.PassThrough = $__require('1b0');
    if (!process.browser && process.env.READABLE_STREAM === 'disable') {
      module.exports = $__require('1b1');
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1b2", ["1ad"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1ad');
  return module.exports;
});

$__System.registerDynamic("1b3", ["1ae"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1ae');
  return module.exports;
});

$__System.registerDynamic("1b4", ["1af"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1af');
  return module.exports;
});

$__System.registerDynamic("1b5", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = Array.isArray || function(arr) {
    return Object.prototype.toString.call(arr) == '[object Array]';
  };
  return module.exports;
});

$__System.registerDynamic("1b6", ["1b5"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1b5');
  return module.exports;
});

$__System.registerDynamic("1b7", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  function EventEmitter() {
    this._events = this._events || {};
    this._maxListeners = this._maxListeners || undefined;
  }
  module.exports = EventEmitter;
  EventEmitter.EventEmitter = EventEmitter;
  EventEmitter.prototype._events = undefined;
  EventEmitter.prototype._maxListeners = undefined;
  EventEmitter.defaultMaxListeners = 10;
  EventEmitter.prototype.setMaxListeners = function(n) {
    if (!isNumber(n) || n < 0 || isNaN(n))
      throw TypeError('n must be a positive number');
    this._maxListeners = n;
    return this;
  };
  EventEmitter.prototype.emit = function(type) {
    var er,
        handler,
        len,
        args,
        i,
        listeners;
    if (!this._events)
      this._events = {};
    if (type === 'error') {
      if (!this._events.error || (isObject(this._events.error) && !this._events.error.length)) {
        er = arguments[1];
        if (er instanceof Error) {
          throw er;
        }
        throw TypeError('Uncaught, unspecified "error" event.');
      }
    }
    handler = this._events[type];
    if (isUndefined(handler))
      return false;
    if (isFunction(handler)) {
      switch (arguments.length) {
        case 1:
          handler.call(this);
          break;
        case 2:
          handler.call(this, arguments[1]);
          break;
        case 3:
          handler.call(this, arguments[1], arguments[2]);
          break;
        default:
          len = arguments.length;
          args = new Array(len - 1);
          for (i = 1; i < len; i++)
            args[i - 1] = arguments[i];
          handler.apply(this, args);
      }
    } else if (isObject(handler)) {
      len = arguments.length;
      args = new Array(len - 1);
      for (i = 1; i < len; i++)
        args[i - 1] = arguments[i];
      listeners = handler.slice();
      len = listeners.length;
      for (i = 0; i < len; i++)
        listeners[i].apply(this, args);
    }
    return true;
  };
  EventEmitter.prototype.addListener = function(type, listener) {
    var m;
    if (!isFunction(listener))
      throw TypeError('listener must be a function');
    if (!this._events)
      this._events = {};
    if (this._events.newListener)
      this.emit('newListener', type, isFunction(listener.listener) ? listener.listener : listener);
    if (!this._events[type])
      this._events[type] = listener;
    else if (isObject(this._events[type]))
      this._events[type].push(listener);
    else
      this._events[type] = [this._events[type], listener];
    if (isObject(this._events[type]) && !this._events[type].warned) {
      var m;
      if (!isUndefined(this._maxListeners)) {
        m = this._maxListeners;
      } else {
        m = EventEmitter.defaultMaxListeners;
      }
      if (m && m > 0 && this._events[type].length > m) {
        this._events[type].warned = true;
        console.error('(node) warning: possible EventEmitter memory ' + 'leak detected. %d listeners added. ' + 'Use emitter.setMaxListeners() to increase limit.', this._events[type].length);
        if (typeof console.trace === 'function') {
          console.trace();
        }
      }
    }
    return this;
  };
  EventEmitter.prototype.on = EventEmitter.prototype.addListener;
  EventEmitter.prototype.once = function(type, listener) {
    if (!isFunction(listener))
      throw TypeError('listener must be a function');
    var fired = false;
    function g() {
      this.removeListener(type, g);
      if (!fired) {
        fired = true;
        listener.apply(this, arguments);
      }
    }
    g.listener = listener;
    this.on(type, g);
    return this;
  };
  EventEmitter.prototype.removeListener = function(type, listener) {
    var list,
        position,
        length,
        i;
    if (!isFunction(listener))
      throw TypeError('listener must be a function');
    if (!this._events || !this._events[type])
      return this;
    list = this._events[type];
    length = list.length;
    position = -1;
    if (list === listener || (isFunction(list.listener) && list.listener === listener)) {
      delete this._events[type];
      if (this._events.removeListener)
        this.emit('removeListener', type, listener);
    } else if (isObject(list)) {
      for (i = length; i-- > 0; ) {
        if (list[i] === listener || (list[i].listener && list[i].listener === listener)) {
          position = i;
          break;
        }
      }
      if (position < 0)
        return this;
      if (list.length === 1) {
        list.length = 0;
        delete this._events[type];
      } else {
        list.splice(position, 1);
      }
      if (this._events.removeListener)
        this.emit('removeListener', type, listener);
    }
    return this;
  };
  EventEmitter.prototype.removeAllListeners = function(type) {
    var key,
        listeners;
    if (!this._events)
      return this;
    if (!this._events.removeListener) {
      if (arguments.length === 0)
        this._events = {};
      else if (this._events[type])
        delete this._events[type];
      return this;
    }
    if (arguments.length === 0) {
      for (key in this._events) {
        if (key === 'removeListener')
          continue;
        this.removeAllListeners(key);
      }
      this.removeAllListeners('removeListener');
      this._events = {};
      return this;
    }
    listeners = this._events[type];
    if (isFunction(listeners)) {
      this.removeListener(type, listeners);
    } else {
      while (listeners.length)
        this.removeListener(type, listeners[listeners.length - 1]);
    }
    delete this._events[type];
    return this;
  };
  EventEmitter.prototype.listeners = function(type) {
    var ret;
    if (!this._events || !this._events[type])
      ret = [];
    else if (isFunction(this._events[type]))
      ret = [this._events[type]];
    else
      ret = this._events[type].slice();
    return ret;
  };
  EventEmitter.listenerCount = function(emitter, type) {
    var ret;
    if (!emitter._events || !emitter._events[type])
      ret = 0;
    else if (isFunction(emitter._events[type]))
      ret = 1;
    else
      ret = emitter._events[type].length;
    return ret;
  };
  function isFunction(arg) {
    return typeof arg === 'function';
  }
  function isNumber(arg) {
    return typeof arg === 'number';
  }
  function isObject(arg) {
    return typeof arg === 'object' && arg !== null;
  }
  function isUndefined(arg) {
    return arg === void 0;
  }
  return module.exports;
});

$__System.registerDynamic("1b8", ["1b7"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1b7');
  return module.exports;
});

$__System.registerDynamic("1b9", ["1b8"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('events') : $__require('1b8');
  return module.exports;
});

$__System.registerDynamic("197", ["1b9"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1b9');
  return module.exports;
});

$__System.registerDynamic("1ba", ["185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    var Buffer = $__require('185').Buffer;
    var isBufferEncoding = Buffer.isEncoding || function(encoding) {
      switch (encoding && encoding.toLowerCase()) {
        case 'hex':
        case 'utf8':
        case 'utf-8':
        case 'ascii':
        case 'binary':
        case 'base64':
        case 'ucs2':
        case 'ucs-2':
        case 'utf16le':
        case 'utf-16le':
        case 'raw':
          return true;
        default:
          return false;
      }
    };
    function assertEncoding(encoding) {
      if (encoding && !isBufferEncoding(encoding)) {
        throw new Error('Unknown encoding: ' + encoding);
      }
    }
    var StringDecoder = exports.StringDecoder = function(encoding) {
      this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, '');
      assertEncoding(encoding);
      switch (this.encoding) {
        case 'utf8':
          this.surrogateSize = 3;
          break;
        case 'ucs2':
        case 'utf16le':
          this.surrogateSize = 2;
          this.detectIncompleteChar = utf16DetectIncompleteChar;
          break;
        case 'base64':
          this.surrogateSize = 3;
          this.detectIncompleteChar = base64DetectIncompleteChar;
          break;
        default:
          this.write = passThroughWrite;
          return;
      }
      this.charBuffer = new Buffer(6);
      this.charReceived = 0;
      this.charLength = 0;
    };
    StringDecoder.prototype.write = function(buffer) {
      var charStr = '';
      while (this.charLength) {
        var available = (buffer.length >= this.charLength - this.charReceived) ? this.charLength - this.charReceived : buffer.length;
        buffer.copy(this.charBuffer, this.charReceived, 0, available);
        this.charReceived += available;
        if (this.charReceived < this.charLength) {
          return '';
        }
        buffer = buffer.slice(available, buffer.length);
        charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding);
        var charCode = charStr.charCodeAt(charStr.length - 1);
        if (charCode >= 0xD800 && charCode <= 0xDBFF) {
          this.charLength += this.surrogateSize;
          charStr = '';
          continue;
        }
        this.charReceived = this.charLength = 0;
        if (buffer.length === 0) {
          return charStr;
        }
        break;
      }
      this.detectIncompleteChar(buffer);
      var end = buffer.length;
      if (this.charLength) {
        buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end);
        end -= this.charReceived;
      }
      charStr += buffer.toString(this.encoding, 0, end);
      var end = charStr.length - 1;
      var charCode = charStr.charCodeAt(end);
      if (charCode >= 0xD800 && charCode <= 0xDBFF) {
        var size = this.surrogateSize;
        this.charLength += size;
        this.charReceived += size;
        this.charBuffer.copy(this.charBuffer, size, 0, size);
        buffer.copy(this.charBuffer, 0, 0, size);
        return charStr.substring(0, end);
      }
      return charStr;
    };
    StringDecoder.prototype.detectIncompleteChar = function(buffer) {
      var i = (buffer.length >= 3) ? 3 : buffer.length;
      for (; i > 0; i--) {
        var c = buffer[buffer.length - i];
        if (i == 1 && c >> 5 == 0x06) {
          this.charLength = 2;
          break;
        }
        if (i <= 2 && c >> 4 == 0x0E) {
          this.charLength = 3;
          break;
        }
        if (i <= 3 && c >> 3 == 0x1E) {
          this.charLength = 4;
          break;
        }
      }
      this.charReceived = i;
    };
    StringDecoder.prototype.end = function(buffer) {
      var res = '';
      if (buffer && buffer.length)
        res = this.write(buffer);
      if (this.charReceived) {
        var cr = this.charReceived;
        var buf = this.charBuffer;
        var enc = this.encoding;
        res += buf.slice(0, cr).toString(enc);
      }
      return res;
    };
    function passThroughWrite(buffer) {
      return buffer.toString(this.encoding);
    }
    function utf16DetectIncompleteChar(buffer) {
      this.charReceived = buffer.length % 2;
      this.charLength = this.charReceived ? 2 : 0;
    }
    function base64DetectIncompleteChar(buffer) {
      this.charReceived = buffer.length % 3;
      this.charLength = this.charReceived ? 3 : 0;
    }
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("199", ["1ba"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1ba');
  return module.exports;
});

$__System.registerDynamic("1ac", ["1b6", "185", "197", "1b1", "198", "191", "@empty", "1ae", "199", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    module.exports = Readable;
    var isArray = $__require('1b6');
    var Buffer = $__require('185').Buffer;
    Readable.ReadableState = ReadableState;
    var EE = $__require('197').EventEmitter;
    if (!EE.listenerCount)
      EE.listenerCount = function(emitter, type) {
        return emitter.listeners(type).length;
      };
    var Stream = $__require('1b1');
    var util = $__require('198');
    util.inherits = $__require('191');
    var StringDecoder;
    var debug = $__require('@empty');
    if (debug && debug.debuglog) {
      debug = debug.debuglog('stream');
    } else {
      debug = function() {};
    }
    util.inherits(Readable, Stream);
    function ReadableState(options, stream) {
      var Duplex = $__require('1ae');
      options = options || {};
      var hwm = options.highWaterMark;
      var defaultHwm = options.objectMode ? 16 : 16 * 1024;
      this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
      this.highWaterMark = ~~this.highWaterMark;
      this.buffer = [];
      this.length = 0;
      this.pipes = null;
      this.pipesCount = 0;
      this.flowing = null;
      this.ended = false;
      this.endEmitted = false;
      this.reading = false;
      this.sync = true;
      this.needReadable = false;
      this.emittedReadable = false;
      this.readableListening = false;
      this.objectMode = !!options.objectMode;
      if (stream instanceof Duplex)
        this.objectMode = this.objectMode || !!options.readableObjectMode;
      this.defaultEncoding = options.defaultEncoding || 'utf8';
      this.ranOut = false;
      this.awaitDrain = 0;
      this.readingMore = false;
      this.decoder = null;
      this.encoding = null;
      if (options.encoding) {
        if (!StringDecoder)
          StringDecoder = $__require('199').StringDecoder;
        this.decoder = new StringDecoder(options.encoding);
        this.encoding = options.encoding;
      }
    }
    function Readable(options) {
      var Duplex = $__require('1ae');
      if (!(this instanceof Readable))
        return new Readable(options);
      this._readableState = new ReadableState(options, this);
      this.readable = true;
      Stream.call(this);
    }
    Readable.prototype.push = function(chunk, encoding) {
      var state = this._readableState;
      if (util.isString(chunk) && !state.objectMode) {
        encoding = encoding || state.defaultEncoding;
        if (encoding !== state.encoding) {
          chunk = new Buffer(chunk, encoding);
          encoding = '';
        }
      }
      return readableAddChunk(this, state, chunk, encoding, false);
    };
    Readable.prototype.unshift = function(chunk) {
      var state = this._readableState;
      return readableAddChunk(this, state, chunk, '', true);
    };
    function readableAddChunk(stream, state, chunk, encoding, addToFront) {
      var er = chunkInvalid(state, chunk);
      if (er) {
        stream.emit('error', er);
      } else if (util.isNullOrUndefined(chunk)) {
        state.reading = false;
        if (!state.ended)
          onEofChunk(stream, state);
      } else if (state.objectMode || chunk && chunk.length > 0) {
        if (state.ended && !addToFront) {
          var e = new Error('stream.push() after EOF');
          stream.emit('error', e);
        } else if (state.endEmitted && addToFront) {
          var e = new Error('stream.unshift() after end event');
          stream.emit('error', e);
        } else {
          if (state.decoder && !addToFront && !encoding)
            chunk = state.decoder.write(chunk);
          if (!addToFront)
            state.reading = false;
          if (state.flowing && state.length === 0 && !state.sync) {
            stream.emit('data', chunk);
            stream.read(0);
          } else {
            state.length += state.objectMode ? 1 : chunk.length;
            if (addToFront)
              state.buffer.unshift(chunk);
            else
              state.buffer.push(chunk);
            if (state.needReadable)
              emitReadable(stream);
          }
          maybeReadMore(stream, state);
        }
      } else if (!addToFront) {
        state.reading = false;
      }
      return needMoreData(state);
    }
    function needMoreData(state) {
      return !state.ended && (state.needReadable || state.length < state.highWaterMark || state.length === 0);
    }
    Readable.prototype.setEncoding = function(enc) {
      if (!StringDecoder)
        StringDecoder = $__require('199').StringDecoder;
      this._readableState.decoder = new StringDecoder(enc);
      this._readableState.encoding = enc;
      return this;
    };
    var MAX_HWM = 0x800000;
    function roundUpToNextPowerOf2(n) {
      if (n >= MAX_HWM) {
        n = MAX_HWM;
      } else {
        n--;
        for (var p = 1; p < 32; p <<= 1)
          n |= n >> p;
        n++;
      }
      return n;
    }
    function howMuchToRead(n, state) {
      if (state.length === 0 && state.ended)
        return 0;
      if (state.objectMode)
        return n === 0 ? 0 : 1;
      if (isNaN(n) || util.isNull(n)) {
        if (state.flowing && state.buffer.length)
          return state.buffer[0].length;
        else
          return state.length;
      }
      if (n <= 0)
        return 0;
      if (n > state.highWaterMark)
        state.highWaterMark = roundUpToNextPowerOf2(n);
      if (n > state.length) {
        if (!state.ended) {
          state.needReadable = true;
          return 0;
        } else
          return state.length;
      }
      return n;
    }
    Readable.prototype.read = function(n) {
      debug('read', n);
      var state = this._readableState;
      var nOrig = n;
      if (!util.isNumber(n) || n > 0)
        state.emittedReadable = false;
      if (n === 0 && state.needReadable && (state.length >= state.highWaterMark || state.ended)) {
        debug('read: emitReadable', state.length, state.ended);
        if (state.length === 0 && state.ended)
          endReadable(this);
        else
          emitReadable(this);
        return null;
      }
      n = howMuchToRead(n, state);
      if (n === 0 && state.ended) {
        if (state.length === 0)
          endReadable(this);
        return null;
      }
      var doRead = state.needReadable;
      debug('need readable', doRead);
      if (state.length === 0 || state.length - n < state.highWaterMark) {
        doRead = true;
        debug('length less than watermark', doRead);
      }
      if (state.ended || state.reading) {
        doRead = false;
        debug('reading or ended', doRead);
      }
      if (doRead) {
        debug('do read');
        state.reading = true;
        state.sync = true;
        if (state.length === 0)
          state.needReadable = true;
        this._read(state.highWaterMark);
        state.sync = false;
      }
      if (doRead && !state.reading)
        n = howMuchToRead(nOrig, state);
      var ret;
      if (n > 0)
        ret = fromList(n, state);
      else
        ret = null;
      if (util.isNull(ret)) {
        state.needReadable = true;
        n = 0;
      }
      state.length -= n;
      if (state.length === 0 && !state.ended)
        state.needReadable = true;
      if (nOrig !== n && state.ended && state.length === 0)
        endReadable(this);
      if (!util.isNull(ret))
        this.emit('data', ret);
      return ret;
    };
    function chunkInvalid(state, chunk) {
      var er = null;
      if (!util.isBuffer(chunk) && !util.isString(chunk) && !util.isNullOrUndefined(chunk) && !state.objectMode) {
        er = new TypeError('Invalid non-string/buffer chunk');
      }
      return er;
    }
    function onEofChunk(stream, state) {
      if (state.decoder && !state.ended) {
        var chunk = state.decoder.end();
        if (chunk && chunk.length) {
          state.buffer.push(chunk);
          state.length += state.objectMode ? 1 : chunk.length;
        }
      }
      state.ended = true;
      emitReadable(stream);
    }
    function emitReadable(stream) {
      var state = stream._readableState;
      state.needReadable = false;
      if (!state.emittedReadable) {
        debug('emitReadable', state.flowing);
        state.emittedReadable = true;
        if (state.sync)
          process.nextTick(function() {
            emitReadable_(stream);
          });
        else
          emitReadable_(stream);
      }
    }
    function emitReadable_(stream) {
      debug('emit readable');
      stream.emit('readable');
      flow(stream);
    }
    function maybeReadMore(stream, state) {
      if (!state.readingMore) {
        state.readingMore = true;
        process.nextTick(function() {
          maybeReadMore_(stream, state);
        });
      }
    }
    function maybeReadMore_(stream, state) {
      var len = state.length;
      while (!state.reading && !state.flowing && !state.ended && state.length < state.highWaterMark) {
        debug('maybeReadMore read 0');
        stream.read(0);
        if (len === state.length)
          break;
        else
          len = state.length;
      }
      state.readingMore = false;
    }
    Readable.prototype._read = function(n) {
      this.emit('error', new Error('not implemented'));
    };
    Readable.prototype.pipe = function(dest, pipeOpts) {
      var src = this;
      var state = this._readableState;
      switch (state.pipesCount) {
        case 0:
          state.pipes = dest;
          break;
        case 1:
          state.pipes = [state.pipes, dest];
          break;
        default:
          state.pipes.push(dest);
          break;
      }
      state.pipesCount += 1;
      debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts);
      var doEnd = (!pipeOpts || pipeOpts.end !== false) && dest !== process.stdout && dest !== process.stderr;
      var endFn = doEnd ? onend : cleanup;
      if (state.endEmitted)
        process.nextTick(endFn);
      else
        src.once('end', endFn);
      dest.on('unpipe', onunpipe);
      function onunpipe(readable) {
        debug('onunpipe');
        if (readable === src) {
          cleanup();
        }
      }
      function onend() {
        debug('onend');
        dest.end();
      }
      var ondrain = pipeOnDrain(src);
      dest.on('drain', ondrain);
      function cleanup() {
        debug('cleanup');
        dest.removeListener('close', onclose);
        dest.removeListener('finish', onfinish);
        dest.removeListener('drain', ondrain);
        dest.removeListener('error', onerror);
        dest.removeListener('unpipe', onunpipe);
        src.removeListener('end', onend);
        src.removeListener('end', cleanup);
        src.removeListener('data', ondata);
        if (state.awaitDrain && (!dest._writableState || dest._writableState.needDrain))
          ondrain();
      }
      src.on('data', ondata);
      function ondata(chunk) {
        debug('ondata');
        var ret = dest.write(chunk);
        if (false === ret) {
          debug('false write response, pause', src._readableState.awaitDrain);
          src._readableState.awaitDrain++;
          src.pause();
        }
      }
      function onerror(er) {
        debug('onerror', er);
        unpipe();
        dest.removeListener('error', onerror);
        if (EE.listenerCount(dest, 'error') === 0)
          dest.emit('error', er);
      }
      if (!dest._events || !dest._events.error)
        dest.on('error', onerror);
      else if (isArray(dest._events.error))
        dest._events.error.unshift(onerror);
      else
        dest._events.error = [onerror, dest._events.error];
      function onclose() {
        dest.removeListener('finish', onfinish);
        unpipe();
      }
      dest.once('close', onclose);
      function onfinish() {
        debug('onfinish');
        dest.removeListener('close', onclose);
        unpipe();
      }
      dest.once('finish', onfinish);
      function unpipe() {
        debug('unpipe');
        src.unpipe(dest);
      }
      dest.emit('pipe', src);
      if (!state.flowing) {
        debug('pipe resume');
        src.resume();
      }
      return dest;
    };
    function pipeOnDrain(src) {
      return function() {
        var state = src._readableState;
        debug('pipeOnDrain', state.awaitDrain);
        if (state.awaitDrain)
          state.awaitDrain--;
        if (state.awaitDrain === 0 && EE.listenerCount(src, 'data')) {
          state.flowing = true;
          flow(src);
        }
      };
    }
    Readable.prototype.unpipe = function(dest) {
      var state = this._readableState;
      if (state.pipesCount === 0)
        return this;
      if (state.pipesCount === 1) {
        if (dest && dest !== state.pipes)
          return this;
        if (!dest)
          dest = state.pipes;
        state.pipes = null;
        state.pipesCount = 0;
        state.flowing = false;
        if (dest)
          dest.emit('unpipe', this);
        return this;
      }
      if (!dest) {
        var dests = state.pipes;
        var len = state.pipesCount;
        state.pipes = null;
        state.pipesCount = 0;
        state.flowing = false;
        for (var i = 0; i < len; i++)
          dests[i].emit('unpipe', this);
        return this;
      }
      var i = indexOf(state.pipes, dest);
      if (i === -1)
        return this;
      state.pipes.splice(i, 1);
      state.pipesCount -= 1;
      if (state.pipesCount === 1)
        state.pipes = state.pipes[0];
      dest.emit('unpipe', this);
      return this;
    };
    Readable.prototype.on = function(ev, fn) {
      var res = Stream.prototype.on.call(this, ev, fn);
      if (ev === 'data' && false !== this._readableState.flowing) {
        this.resume();
      }
      if (ev === 'readable' && this.readable) {
        var state = this._readableState;
        if (!state.readableListening) {
          state.readableListening = true;
          state.emittedReadable = false;
          state.needReadable = true;
          if (!state.reading) {
            var self = this;
            process.nextTick(function() {
              debug('readable nexttick read 0');
              self.read(0);
            });
          } else if (state.length) {
            emitReadable(this, state);
          }
        }
      }
      return res;
    };
    Readable.prototype.addListener = Readable.prototype.on;
    Readable.prototype.resume = function() {
      var state = this._readableState;
      if (!state.flowing) {
        debug('resume');
        state.flowing = true;
        if (!state.reading) {
          debug('resume read 0');
          this.read(0);
        }
        resume(this, state);
      }
      return this;
    };
    function resume(stream, state) {
      if (!state.resumeScheduled) {
        state.resumeScheduled = true;
        process.nextTick(function() {
          resume_(stream, state);
        });
      }
    }
    function resume_(stream, state) {
      state.resumeScheduled = false;
      stream.emit('resume');
      flow(stream);
      if (state.flowing && !state.reading)
        stream.read(0);
    }
    Readable.prototype.pause = function() {
      debug('call pause flowing=%j', this._readableState.flowing);
      if (false !== this._readableState.flowing) {
        debug('pause');
        this._readableState.flowing = false;
        this.emit('pause');
      }
      return this;
    };
    function flow(stream) {
      var state = stream._readableState;
      debug('flow', state.flowing);
      if (state.flowing) {
        do {
          var chunk = stream.read();
        } while (null !== chunk && state.flowing);
      }
    }
    Readable.prototype.wrap = function(stream) {
      var state = this._readableState;
      var paused = false;
      var self = this;
      stream.on('end', function() {
        debug('wrapped end');
        if (state.decoder && !state.ended) {
          var chunk = state.decoder.end();
          if (chunk && chunk.length)
            self.push(chunk);
        }
        self.push(null);
      });
      stream.on('data', function(chunk) {
        debug('wrapped data');
        if (state.decoder)
          chunk = state.decoder.write(chunk);
        if (!chunk || !state.objectMode && !chunk.length)
          return;
        var ret = self.push(chunk);
        if (!ret) {
          paused = true;
          stream.pause();
        }
      });
      for (var i in stream) {
        if (util.isFunction(stream[i]) && util.isUndefined(this[i])) {
          this[i] = function(method) {
            return function() {
              return stream[method].apply(stream, arguments);
            };
          }(i);
        }
      }
      var events = ['error', 'close', 'destroy', 'pause', 'resume'];
      forEach(events, function(ev) {
        stream.on(ev, self.emit.bind(self, ev));
      });
      self._read = function(n) {
        debug('wrapped _read', n);
        if (paused) {
          paused = false;
          stream.resume();
        }
      };
      return self;
    };
    Readable._fromList = fromList;
    function fromList(n, state) {
      var list = state.buffer;
      var length = state.length;
      var stringMode = !!state.decoder;
      var objectMode = !!state.objectMode;
      var ret;
      if (list.length === 0)
        return null;
      if (length === 0)
        ret = null;
      else if (objectMode)
        ret = list.shift();
      else if (!n || n >= length) {
        if (stringMode)
          ret = list.join('');
        else
          ret = Buffer.concat(list, length);
        list.length = 0;
      } else {
        if (n < list[0].length) {
          var buf = list[0];
          ret = buf.slice(0, n);
          list[0] = buf.slice(n);
        } else if (n === list[0].length) {
          ret = list.shift();
        } else {
          if (stringMode)
            ret = '';
          else
            ret = new Buffer(n);
          var c = 0;
          for (var i = 0,
              l = list.length; i < l && c < n; i++) {
            var buf = list[0];
            var cpy = Math.min(n - c, buf.length);
            if (stringMode)
              ret += buf.slice(0, cpy);
            else
              buf.copy(ret, c, 0, cpy);
            if (cpy < buf.length)
              list[0] = buf.slice(cpy);
            else
              list.shift();
            c += cpy;
          }
        }
      }
      return ret;
    }
    function endReadable(stream) {
      var state = stream._readableState;
      if (state.length > 0)
        throw new Error('endReadable called on non-empty stream');
      if (!state.endEmitted) {
        state.ended = true;
        process.nextTick(function() {
          if (!state.endEmitted && state.length === 0) {
            state.endEmitted = true;
            stream.readable = false;
            stream.emit('end');
          }
        });
      }
    }
    function forEach(xs, f) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        f(xs[i], i);
      }
    }
    function indexOf(xs, x) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        if (xs[i] === x)
          return i;
      }
      return -1;
    }
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("1ad", ["185", "198", "191", "1b1", "1ae", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    module.exports = Writable;
    var Buffer = $__require('185').Buffer;
    Writable.WritableState = WritableState;
    var util = $__require('198');
    util.inherits = $__require('191');
    var Stream = $__require('1b1');
    util.inherits(Writable, Stream);
    function WriteReq(chunk, encoding, cb) {
      this.chunk = chunk;
      this.encoding = encoding;
      this.callback = cb;
    }
    function WritableState(options, stream) {
      var Duplex = $__require('1ae');
      options = options || {};
      var hwm = options.highWaterMark;
      var defaultHwm = options.objectMode ? 16 : 16 * 1024;
      this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
      this.objectMode = !!options.objectMode;
      if (stream instanceof Duplex)
        this.objectMode = this.objectMode || !!options.writableObjectMode;
      this.highWaterMark = ~~this.highWaterMark;
      this.needDrain = false;
      this.ending = false;
      this.ended = false;
      this.finished = false;
      var noDecode = options.decodeStrings === false;
      this.decodeStrings = !noDecode;
      this.defaultEncoding = options.defaultEncoding || 'utf8';
      this.length = 0;
      this.writing = false;
      this.corked = 0;
      this.sync = true;
      this.bufferProcessing = false;
      this.onwrite = function(er) {
        onwrite(stream, er);
      };
      this.writecb = null;
      this.writelen = 0;
      this.buffer = [];
      this.pendingcb = 0;
      this.prefinished = false;
      this.errorEmitted = false;
    }
    function Writable(options) {
      var Duplex = $__require('1ae');
      if (!(this instanceof Writable) && !(this instanceof Duplex))
        return new Writable(options);
      this._writableState = new WritableState(options, this);
      this.writable = true;
      Stream.call(this);
    }
    Writable.prototype.pipe = function() {
      this.emit('error', new Error('Cannot pipe. Not readable.'));
    };
    function writeAfterEnd(stream, state, cb) {
      var er = new Error('write after end');
      stream.emit('error', er);
      process.nextTick(function() {
        cb(er);
      });
    }
    function validChunk(stream, state, chunk, cb) {
      var valid = true;
      if (!util.isBuffer(chunk) && !util.isString(chunk) && !util.isNullOrUndefined(chunk) && !state.objectMode) {
        var er = new TypeError('Invalid non-string/buffer chunk');
        stream.emit('error', er);
        process.nextTick(function() {
          cb(er);
        });
        valid = false;
      }
      return valid;
    }
    Writable.prototype.write = function(chunk, encoding, cb) {
      var state = this._writableState;
      var ret = false;
      if (util.isFunction(encoding)) {
        cb = encoding;
        encoding = null;
      }
      if (util.isBuffer(chunk))
        encoding = 'buffer';
      else if (!encoding)
        encoding = state.defaultEncoding;
      if (!util.isFunction(cb))
        cb = function() {};
      if (state.ended)
        writeAfterEnd(this, state, cb);
      else if (validChunk(this, state, chunk, cb)) {
        state.pendingcb++;
        ret = writeOrBuffer(this, state, chunk, encoding, cb);
      }
      return ret;
    };
    Writable.prototype.cork = function() {
      var state = this._writableState;
      state.corked++;
    };
    Writable.prototype.uncork = function() {
      var state = this._writableState;
      if (state.corked) {
        state.corked--;
        if (!state.writing && !state.corked && !state.finished && !state.bufferProcessing && state.buffer.length)
          clearBuffer(this, state);
      }
    };
    function decodeChunk(state, chunk, encoding) {
      if (!state.objectMode && state.decodeStrings !== false && util.isString(chunk)) {
        chunk = new Buffer(chunk, encoding);
      }
      return chunk;
    }
    function writeOrBuffer(stream, state, chunk, encoding, cb) {
      chunk = decodeChunk(state, chunk, encoding);
      if (util.isBuffer(chunk))
        encoding = 'buffer';
      var len = state.objectMode ? 1 : chunk.length;
      state.length += len;
      var ret = state.length < state.highWaterMark;
      if (!ret)
        state.needDrain = true;
      if (state.writing || state.corked)
        state.buffer.push(new WriteReq(chunk, encoding, cb));
      else
        doWrite(stream, state, false, len, chunk, encoding, cb);
      return ret;
    }
    function doWrite(stream, state, writev, len, chunk, encoding, cb) {
      state.writelen = len;
      state.writecb = cb;
      state.writing = true;
      state.sync = true;
      if (writev)
        stream._writev(chunk, state.onwrite);
      else
        stream._write(chunk, encoding, state.onwrite);
      state.sync = false;
    }
    function onwriteError(stream, state, sync, er, cb) {
      if (sync)
        process.nextTick(function() {
          state.pendingcb--;
          cb(er);
        });
      else {
        state.pendingcb--;
        cb(er);
      }
      stream._writableState.errorEmitted = true;
      stream.emit('error', er);
    }
    function onwriteStateUpdate(state) {
      state.writing = false;
      state.writecb = null;
      state.length -= state.writelen;
      state.writelen = 0;
    }
    function onwrite(stream, er) {
      var state = stream._writableState;
      var sync = state.sync;
      var cb = state.writecb;
      onwriteStateUpdate(state);
      if (er)
        onwriteError(stream, state, sync, er, cb);
      else {
        var finished = needFinish(stream, state);
        if (!finished && !state.corked && !state.bufferProcessing && state.buffer.length) {
          clearBuffer(stream, state);
        }
        if (sync) {
          process.nextTick(function() {
            afterWrite(stream, state, finished, cb);
          });
        } else {
          afterWrite(stream, state, finished, cb);
        }
      }
    }
    function afterWrite(stream, state, finished, cb) {
      if (!finished)
        onwriteDrain(stream, state);
      state.pendingcb--;
      cb();
      finishMaybe(stream, state);
    }
    function onwriteDrain(stream, state) {
      if (state.length === 0 && state.needDrain) {
        state.needDrain = false;
        stream.emit('drain');
      }
    }
    function clearBuffer(stream, state) {
      state.bufferProcessing = true;
      if (stream._writev && state.buffer.length > 1) {
        var cbs = [];
        for (var c = 0; c < state.buffer.length; c++)
          cbs.push(state.buffer[c].callback);
        state.pendingcb++;
        doWrite(stream, state, true, state.length, state.buffer, '', function(err) {
          for (var i = 0; i < cbs.length; i++) {
            state.pendingcb--;
            cbs[i](err);
          }
        });
        state.buffer = [];
      } else {
        for (var c = 0; c < state.buffer.length; c++) {
          var entry = state.buffer[c];
          var chunk = entry.chunk;
          var encoding = entry.encoding;
          var cb = entry.callback;
          var len = state.objectMode ? 1 : chunk.length;
          doWrite(stream, state, false, len, chunk, encoding, cb);
          if (state.writing) {
            c++;
            break;
          }
        }
        if (c < state.buffer.length)
          state.buffer = state.buffer.slice(c);
        else
          state.buffer.length = 0;
      }
      state.bufferProcessing = false;
    }
    Writable.prototype._write = function(chunk, encoding, cb) {
      cb(new Error('not implemented'));
    };
    Writable.prototype._writev = null;
    Writable.prototype.end = function(chunk, encoding, cb) {
      var state = this._writableState;
      if (util.isFunction(chunk)) {
        cb = chunk;
        chunk = null;
        encoding = null;
      } else if (util.isFunction(encoding)) {
        cb = encoding;
        encoding = null;
      }
      if (!util.isNullOrUndefined(chunk))
        this.write(chunk, encoding);
      if (state.corked) {
        state.corked = 1;
        this.uncork();
      }
      if (!state.ending && !state.finished)
        endWritable(this, state, cb);
    };
    function needFinish(stream, state) {
      return (state.ending && state.length === 0 && !state.finished && !state.writing);
    }
    function prefinish(stream, state) {
      if (!state.prefinished) {
        state.prefinished = true;
        stream.emit('prefinish');
      }
    }
    function finishMaybe(stream, state) {
      var need = needFinish(stream, state);
      if (need) {
        if (state.pendingcb === 0) {
          prefinish(stream, state);
          state.finished = true;
          stream.emit('finish');
        } else
          prefinish(stream, state);
      }
      return need;
    }
    function endWritable(stream, state, cb) {
      state.ending = true;
      finishMaybe(stream, state);
      if (cb) {
        if (state.finished)
          process.nextTick(cb);
        else
          stream.once('finish', cb);
      }
      state.ended = true;
    }
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("1ae", ["198", "191", "1ac", "1ad", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    module.exports = Duplex;
    var objectKeys = Object.keys || function(obj) {
      var keys = [];
      for (var key in obj)
        keys.push(key);
      return keys;
    };
    var util = $__require('198');
    util.inherits = $__require('191');
    var Readable = $__require('1ac');
    var Writable = $__require('1ad');
    util.inherits(Duplex, Readable);
    forEach(objectKeys(Writable.prototype), function(method) {
      if (!Duplex.prototype[method])
        Duplex.prototype[method] = Writable.prototype[method];
    });
    function Duplex(options) {
      if (!(this instanceof Duplex))
        return new Duplex(options);
      Readable.call(this, options);
      Writable.call(this, options);
      if (options && options.readable === false)
        this.readable = false;
      if (options && options.writable === false)
        this.writable = false;
      this.allowHalfOpen = true;
      if (options && options.allowHalfOpen === false)
        this.allowHalfOpen = false;
      this.once('end', onend);
    }
    function onend() {
      if (this.allowHalfOpen || this._writableState.ended)
        return;
      process.nextTick(this.end.bind(this));
    }
    function forEach(xs, f) {
      for (var i = 0,
          l = xs.length; i < l; i++) {
        f(xs[i], i);
      }
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1af", ["1ae", "198", "191", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    module.exports = Transform;
    var Duplex = $__require('1ae');
    var util = $__require('198');
    util.inherits = $__require('191');
    util.inherits(Transform, Duplex);
    function TransformState(options, stream) {
      this.afterTransform = function(er, data) {
        return afterTransform(stream, er, data);
      };
      this.needTransform = false;
      this.transforming = false;
      this.writecb = null;
      this.writechunk = null;
    }
    function afterTransform(stream, er, data) {
      var ts = stream._transformState;
      ts.transforming = false;
      var cb = ts.writecb;
      if (!cb)
        return stream.emit('error', new Error('no writecb in Transform class'));
      ts.writechunk = null;
      ts.writecb = null;
      if (!util.isNullOrUndefined(data))
        stream.push(data);
      if (cb)
        cb(er);
      var rs = stream._readableState;
      rs.reading = false;
      if (rs.needReadable || rs.length < rs.highWaterMark) {
        stream._read(rs.highWaterMark);
      }
    }
    function Transform(options) {
      if (!(this instanceof Transform))
        return new Transform(options);
      Duplex.call(this, options);
      this._transformState = new TransformState(options, this);
      var stream = this;
      this._readableState.needReadable = true;
      this._readableState.sync = false;
      this.once('prefinish', function() {
        if (util.isFunction(this._flush))
          this._flush(function(er) {
            done(stream, er);
          });
        else
          done(stream);
      });
    }
    Transform.prototype.push = function(chunk, encoding) {
      this._transformState.needTransform = false;
      return Duplex.prototype.push.call(this, chunk, encoding);
    };
    Transform.prototype._transform = function(chunk, encoding, cb) {
      throw new Error('not implemented');
    };
    Transform.prototype._write = function(chunk, encoding, cb) {
      var ts = this._transformState;
      ts.writecb = cb;
      ts.writechunk = chunk;
      ts.writeencoding = encoding;
      if (!ts.transforming) {
        var rs = this._readableState;
        if (ts.needTransform || rs.needReadable || rs.length < rs.highWaterMark)
          this._read(rs.highWaterMark);
      }
    };
    Transform.prototype._read = function(n) {
      var ts = this._transformState;
      if (!util.isNull(ts.writechunk) && ts.writecb && !ts.transforming) {
        ts.transforming = true;
        this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);
      } else {
        ts.needTransform = true;
      }
    };
    function done(stream, er) {
      if (er)
        return stream.emit('error', er);
      var ws = stream._writableState;
      var ts = stream._transformState;
      if (ws.length)
        throw new Error('calling transform done when ws.length != 0');
      if (ts.transforming)
        throw new Error('calling transform done when still transforming');
      return stream.push(null);
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1bb", ["185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    function isArray(arg) {
      if (Array.isArray) {
        return Array.isArray(arg);
      }
      return objectToString(arg) === '[object Array]';
    }
    exports.isArray = isArray;
    function isBoolean(arg) {
      return typeof arg === 'boolean';
    }
    exports.isBoolean = isBoolean;
    function isNull(arg) {
      return arg === null;
    }
    exports.isNull = isNull;
    function isNullOrUndefined(arg) {
      return arg == null;
    }
    exports.isNullOrUndefined = isNullOrUndefined;
    function isNumber(arg) {
      return typeof arg === 'number';
    }
    exports.isNumber = isNumber;
    function isString(arg) {
      return typeof arg === 'string';
    }
    exports.isString = isString;
    function isSymbol(arg) {
      return typeof arg === 'symbol';
    }
    exports.isSymbol = isSymbol;
    function isUndefined(arg) {
      return arg === void 0;
    }
    exports.isUndefined = isUndefined;
    function isRegExp(re) {
      return objectToString(re) === '[object RegExp]';
    }
    exports.isRegExp = isRegExp;
    function isObject(arg) {
      return typeof arg === 'object' && arg !== null;
    }
    exports.isObject = isObject;
    function isDate(d) {
      return objectToString(d) === '[object Date]';
    }
    exports.isDate = isDate;
    function isError(e) {
      return (objectToString(e) === '[object Error]' || e instanceof Error);
    }
    exports.isError = isError;
    function isFunction(arg) {
      return typeof arg === 'function';
    }
    exports.isFunction = isFunction;
    function isPrimitive(arg) {
      return arg === null || typeof arg === 'boolean' || typeof arg === 'number' || typeof arg === 'string' || typeof arg === 'symbol' || typeof arg === 'undefined';
    }
    exports.isPrimitive = isPrimitive;
    exports.isBuffer = Buffer.isBuffer;
    function objectToString(o) {
      return Object.prototype.toString.call(o);
    }
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("198", ["1bb"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1bb');
  return module.exports;
});

$__System.registerDynamic("1b0", ["1af", "198", "191"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = PassThrough;
  var Transform = $__require('1af');
  var util = $__require('198');
  util.inherits = $__require('191');
  util.inherits(PassThrough, Transform);
  function PassThrough(options) {
    if (!(this instanceof PassThrough))
      return new PassThrough(options);
    Transform.call(this, options);
  }
  PassThrough.prototype._transform = function(chunk, encoding, cb) {
    cb(null, chunk);
  };
  return module.exports;
});

$__System.registerDynamic("1bc", ["1b0"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1b0');
  return module.exports;
});

$__System.registerDynamic("1b1", ["197", "191", "1ab", "1b2", "1b3", "1b4", "1bc"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = Stream;
  var EE = $__require('197').EventEmitter;
  var inherits = $__require('191');
  inherits(Stream, EE);
  Stream.Readable = $__require('1ab');
  Stream.Writable = $__require('1b2');
  Stream.Duplex = $__require('1b3');
  Stream.Transform = $__require('1b4');
  Stream.PassThrough = $__require('1bc');
  Stream.Stream = Stream;
  function Stream() {
    EE.call(this);
  }
  Stream.prototype.pipe = function(dest, options) {
    var source = this;
    function ondata(chunk) {
      if (dest.writable) {
        if (false === dest.write(chunk) && source.pause) {
          source.pause();
        }
      }
    }
    source.on('data', ondata);
    function ondrain() {
      if (source.readable && source.resume) {
        source.resume();
      }
    }
    dest.on('drain', ondrain);
    if (!dest._isStdio && (!options || options.end !== false)) {
      source.on('end', onend);
      source.on('close', onclose);
    }
    var didOnEnd = false;
    function onend() {
      if (didOnEnd)
        return;
      didOnEnd = true;
      dest.end();
    }
    function onclose() {
      if (didOnEnd)
        return;
      didOnEnd = true;
      if (typeof dest.destroy === 'function')
        dest.destroy();
    }
    function onerror(er) {
      cleanup();
      if (EE.listenerCount(this, 'error') === 0) {
        throw er;
      }
    }
    source.on('error', onerror);
    dest.on('error', onerror);
    function cleanup() {
      source.removeListener('data', ondata);
      dest.removeListener('drain', ondrain);
      source.removeListener('end', onend);
      source.removeListener('close', onclose);
      source.removeListener('error', onerror);
      dest.removeListener('error', onerror);
      source.removeListener('end', cleanup);
      source.removeListener('close', cleanup);
      dest.removeListener('close', cleanup);
    }
    source.on('end', cleanup);
    source.on('close', cleanup);
    dest.on('close', cleanup);
    dest.emit('pipe', source);
    return dest;
  };
  return module.exports;
});

$__System.registerDynamic("1bd", ["1b1"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1b1');
  return module.exports;
});

$__System.registerDynamic("1be", ["1bd"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('stream') : $__require('1bd');
  return module.exports;
});

$__System.registerDynamic("1bf", ["1be"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1be');
  return module.exports;
});

$__System.registerDynamic("1c0", ["1bf", "17e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Stream = $__require('1bf');
  var util = $__require('17e');
  var Response = module.exports = function(res) {
    this.offset = 0;
    this.readable = true;
  };
  util.inherits(Response, Stream);
  var capable = {
    streaming: true,
    status2: true
  };
  function parseHeaders(res) {
    var lines = res.getAllResponseHeaders().split(/\r?\n/);
    var headers = {};
    for (var i = 0; i < lines.length; i++) {
      var line = lines[i];
      if (line === '')
        continue;
      var m = line.match(/^([^:]+):\s*(.*)/);
      if (m) {
        var key = m[1].toLowerCase(),
            value = m[2];
        if (headers[key] !== undefined) {
          if (isArray(headers[key])) {
            headers[key].push(value);
          } else {
            headers[key] = [headers[key], value];
          }
        } else {
          headers[key] = value;
        }
      } else {
        headers[line] = true;
      }
    }
    return headers;
  }
  Response.prototype.getResponse = function(xhr) {
    var respType = String(xhr.responseType).toLowerCase();
    if (respType === 'blob')
      return xhr.responseBlob || xhr.response;
    if (respType === 'arraybuffer')
      return xhr.response;
    return xhr.responseText;
  };
  Response.prototype.getHeader = function(key) {
    return this.headers[key.toLowerCase()];
  };
  Response.prototype.handle = function(res) {
    if (res.readyState === 2 && capable.status2) {
      try {
        this.statusCode = res.status;
        this.headers = parseHeaders(res);
      } catch (err) {
        capable.status2 = false;
      }
      if (capable.status2) {
        this.emit('ready');
      }
    } else if (capable.streaming && res.readyState === 3) {
      try {
        if (!this.statusCode) {
          this.statusCode = res.status;
          this.headers = parseHeaders(res);
          this.emit('ready');
        }
      } catch (err) {}
      try {
        this._emitData(res);
      } catch (err) {
        capable.streaming = false;
      }
    } else if (res.readyState === 4) {
      if (!this.statusCode) {
        this.statusCode = res.status;
        this.emit('ready');
      }
      this._emitData(res);
      if (res.error) {
        this.emit('error', this.getResponse(res));
      } else
        this.emit('end');
      this.emit('close');
    }
  };
  Response.prototype._emitData = function(res) {
    var respBody = this.getResponse(res);
    if (respBody.toString().match(/ArrayBuffer/)) {
      this.emit('data', new Uint8Array(respBody, this.offset));
      this.offset = respBody.byteLength;
      return;
    }
    if (respBody.length > this.offset) {
      this.emit('data', respBody.slice(this.offset));
      this.offset = respBody.length;
    }
  };
  var isArray = Array.isArray || function(xs) {
    return Object.prototype.toString.call(xs) === '[object Array]';
  };
  return module.exports;
});

$__System.registerDynamic("1c1", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  ;
  (function() {
    var object = typeof exports != 'undefined' ? exports : this;
    var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';
    function InvalidCharacterError(message) {
      this.message = message;
    }
    InvalidCharacterError.prototype = new Error;
    InvalidCharacterError.prototype.name = 'InvalidCharacterError';
    object.btoa || (object.btoa = function(input) {
      for (var block,
          charCode,
          idx = 0,
          map = chars,
          output = ''; input.charAt(idx | 0) || (map = '=', idx % 1); output += map.charAt(63 & block >> 8 - idx % 1 * 8)) {
        charCode = input.charCodeAt(idx += 3 / 4);
        if (charCode > 0xFF) {
          throw new InvalidCharacterError("'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.");
        }
        block = block << 8 | charCode;
      }
      return output;
    });
    object.atob || (object.atob = function(input) {
      input = input.replace(/=+$/, '');
      if (input.length % 4 == 1) {
        throw new InvalidCharacterError("'atob' failed: The string to be decoded is not correctly encoded.");
      }
      for (var bc = 0,
          bs,
          buffer,
          idx = 0,
          output = ''; buffer = input.charAt(idx++); ~buffer && (bs = bc % 4 ? bs * 64 + buffer : buffer, bc++ % 4) ? output += String.fromCharCode(255 & bs >> (-2 * bc & 6)) : 0) {
        buffer = chars.indexOf(buffer);
      }
      return output;
    });
  }());
  return module.exports;
});

$__System.registerDynamic("1c2", ["1c1"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1c1');
  return module.exports;
});

$__System.registerDynamic("1c3", ["1bf", "1c0", "1c2", "191"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Stream = $__require('1bf');
  var Response = $__require('1c0');
  var Base64 = $__require('1c2');
  var inherits = $__require('191');
  var Request = module.exports = function(xhr, params) {
    var self = this;
    self.writable = true;
    self.xhr = xhr;
    self.body = [];
    self.uri = (params.protocol || 'http:') + '//' + params.host + (params.port ? ':' + params.port : '') + (params.path || '/');
    ;
    if (typeof params.withCredentials === 'undefined') {
      params.withCredentials = true;
    }
    try {
      xhr.withCredentials = params.withCredentials;
    } catch (e) {}
    if (params.responseType)
      try {
        xhr.responseType = params.responseType;
      } catch (e) {}
    xhr.open(params.method || 'GET', self.uri, true);
    xhr.onerror = function(event) {
      self.emit('error', new Error('Network error'));
    };
    self._headers = {};
    if (params.headers) {
      var keys = objectKeys(params.headers);
      for (var i = 0; i < keys.length; i++) {
        var key = keys[i];
        if (!self.isSafeRequestHeader(key))
          continue;
        var value = params.headers[key];
        self.setHeader(key, value);
      }
    }
    if (params.auth) {
      this.setHeader('Authorization', 'Basic ' + Base64.btoa(params.auth));
    }
    var res = new Response;
    res.on('close', function() {
      self.emit('close');
    });
    res.on('ready', function() {
      self.emit('response', res);
    });
    res.on('error', function(err) {
      self.emit('error', err);
    });
    xhr.onreadystatechange = function() {
      if (xhr.__aborted)
        return;
      res.handle(xhr);
    };
  };
  inherits(Request, Stream);
  Request.prototype.setHeader = function(key, value) {
    this._headers[key.toLowerCase()] = value;
  };
  Request.prototype.getHeader = function(key) {
    return this._headers[key.toLowerCase()];
  };
  Request.prototype.removeHeader = function(key) {
    delete this._headers[key.toLowerCase()];
  };
  Request.prototype.write = function(s) {
    this.body.push(s);
  };
  Request.prototype.destroy = function(s) {
    this.xhr.__aborted = true;
    this.xhr.abort();
    this.emit('close');
  };
  Request.prototype.end = function(s) {
    if (s !== undefined)
      this.body.push(s);
    var keys = objectKeys(this._headers);
    for (var i = 0; i < keys.length; i++) {
      var key = keys[i];
      var value = this._headers[key];
      if (isArray(value)) {
        for (var j = 0; j < value.length; j++) {
          this.xhr.setRequestHeader(key, value[j]);
        }
      } else
        this.xhr.setRequestHeader(key, value);
    }
    if (this.body.length === 0) {
      this.xhr.send('');
    } else if (typeof this.body[0] === 'string') {
      this.xhr.send(this.body.join(''));
    } else if (isArray(this.body[0])) {
      var body = [];
      for (var i = 0; i < this.body.length; i++) {
        body.push.apply(body, this.body[i]);
      }
      this.xhr.send(body);
    } else if (/Array/.test(Object.prototype.toString.call(this.body[0]))) {
      var len = 0;
      for (var i = 0; i < this.body.length; i++) {
        len += this.body[i].length;
      }
      var body = new (this.body[0].constructor)(len);
      var k = 0;
      for (var i = 0; i < this.body.length; i++) {
        var b = this.body[i];
        for (var j = 0; j < b.length; j++) {
          body[k++] = b[j];
        }
      }
      this.xhr.send(body);
    } else if (isXHR2Compatible(this.body[0])) {
      this.xhr.send(this.body[0]);
    } else {
      var body = '';
      for (var i = 0; i < this.body.length; i++) {
        body += this.body[i].toString();
      }
      this.xhr.send(body);
    }
  };
  Request.unsafeHeaders = ["accept-charset", "accept-encoding", "access-control-request-headers", "access-control-request-method", "connection", "content-length", "cookie", "cookie2", "content-transfer-encoding", "date", "expect", "host", "keep-alive", "origin", "referer", "te", "trailer", "transfer-encoding", "upgrade", "user-agent", "via"];
  Request.prototype.isSafeRequestHeader = function(headerName) {
    if (!headerName)
      return false;
    return indexOf(Request.unsafeHeaders, headerName.toLowerCase()) === -1;
  };
  var objectKeys = Object.keys || function(obj) {
    var keys = [];
    for (var key in obj)
      keys.push(key);
    return keys;
  };
  var isArray = Array.isArray || function(xs) {
    return Object.prototype.toString.call(xs) === '[object Array]';
  };
  var indexOf = function(xs, x) {
    if (xs.indexOf)
      return xs.indexOf(x);
    for (var i = 0; i < xs.length; i++) {
      if (xs[i] === x)
        return i;
    }
    return -1;
  };
  var isXHR2Compatible = function(obj) {
    if (typeof Blob !== 'undefined' && obj instanceof Blob)
      return true;
    if (typeof ArrayBuffer !== 'undefined' && obj instanceof ArrayBuffer)
      return true;
    if (typeof FormData !== 'undefined' && obj instanceof FormData)
      return true;
  };
  return module.exports;
});

$__System.registerDynamic("1c4", ["197", "1c3", "1a9"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  if ($__System._nodeRequire) {
    module.exports = $__System._nodeRequire('http');
  } else {
    var http = module.exports;
    var EventEmitter = $__require('197').EventEmitter;
    var Request = $__require('1c3');
    var url = $__require('1a9');
    http.request = function(params, cb) {
      if (typeof params === 'string') {
        params = url.parse(params);
      }
      if (!params)
        params = {};
      if (!params.host && !params.port) {
        params.port = parseInt(window.location.port, 10);
      }
      if (!params.host && params.hostname) {
        params.host = params.hostname;
      }
      if (!params.protocol) {
        if (params.scheme) {
          params.protocol = params.scheme + ':';
        } else {
          params.protocol = window.location.protocol;
        }
      }
      if (!params.host) {
        params.host = window.location.hostname || window.location.host;
      }
      if (/:/.test(params.host)) {
        if (!params.port) {
          params.port = params.host.split(':')[1];
        }
        params.host = params.host.split(':')[0];
      }
      if (!params.port)
        params.port = params.protocol == 'https:' ? 443 : 80;
      var req = new Request(new xhrHttp, params);
      if (cb)
        req.on('response', cb);
      return req;
    };
    http.get = function(params, cb) {
      params.method = 'GET';
      var req = http.request(params, cb);
      req.end();
      return req;
    };
    http.Agent = function() {};
    http.Agent.defaultMaxSockets = 4;
    var xhrHttp = (function() {
      if (typeof window === 'undefined') {
        throw new Error('no window object present');
      } else if (window.XMLHttpRequest) {
        return window.XMLHttpRequest;
      } else if (window.ActiveXObject) {
        var axs = ['Msxml2.XMLHTTP.6.0', 'Msxml2.XMLHTTP.3.0', 'Microsoft.XMLHTTP'];
        for (var i = 0; i < axs.length; i++) {
          try {
            var ax = new (window.ActiveXObject)(axs[i]);
            return function() {
              if (ax) {
                var ax_ = ax;
                ax = null;
                return ax_;
              } else {
                return new (window.ActiveXObject)(axs[i]);
              }
            };
          } catch (e) {}
        }
        throw new Error('ajax not supported in this browser');
      } else {
        throw new Error('ajax not supported in this browser');
      }
    })();
    http.STATUS_CODES = {
      100: 'Continue',
      101: 'Switching Protocols',
      102: 'Processing',
      200: 'OK',
      201: 'Created',
      202: 'Accepted',
      203: 'Non-Authoritative Information',
      204: 'No Content',
      205: 'Reset Content',
      206: 'Partial Content',
      207: 'Multi-Status',
      300: 'Multiple Choices',
      301: 'Moved Permanently',
      302: 'Moved Temporarily',
      303: 'See Other',
      304: 'Not Modified',
      305: 'Use Proxy',
      307: 'Temporary Redirect',
      400: 'Bad Request',
      401: 'Unauthorized',
      402: 'Payment Required',
      403: 'Forbidden',
      404: 'Not Found',
      405: 'Method Not Allowed',
      406: 'Not Acceptable',
      407: 'Proxy Authentication Required',
      408: 'Request Time-out',
      409: 'Conflict',
      410: 'Gone',
      411: 'Length Required',
      412: 'Precondition Failed',
      413: 'Request Entity Too Large',
      414: 'Request-URI Too Large',
      415: 'Unsupported Media Type',
      416: 'Requested Range Not Satisfiable',
      417: 'Expectation Failed',
      418: 'I\'m a teapot',
      422: 'Unprocessable Entity',
      423: 'Locked',
      424: 'Failed Dependency',
      425: 'Unordered Collection',
      426: 'Upgrade Required',
      428: 'Precondition Required',
      429: 'Too Many Requests',
      431: 'Request Header Fields Too Large',
      500: 'Internal Server Error',
      501: 'Not Implemented',
      502: 'Bad Gateway',
      503: 'Service Unavailable',
      504: 'Gateway Time-out',
      505: 'HTTP Version Not Supported',
      506: 'Variant Also Negotiates',
      507: 'Insufficient Storage',
      509: 'Bandwidth Limit Exceeded',
      510: 'Not Extended',
      511: 'Network Authentication Required'
    };
  }
  return module.exports;
});

$__System.registerDynamic("1c5", ["1c4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1c4');
  return module.exports;
});

$__System.registerDynamic("1c6", ["1c5"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var http = $__require('1c5');
  var https = module.exports;
  for (var key in http) {
    if (http.hasOwnProperty(key))
      https[key] = http[key];
  }
  ;
  https.request = function(params, cb) {
    if (!params)
      params = {};
    params.scheme = 'https';
    return http.request.call(this, params, cb);
  };
  return module.exports;
});

$__System.registerDynamic("1c7", ["1c6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1c6');
  return module.exports;
});

$__System.registerDynamic("1c8", ["1c7"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('https') : $__require('1c7');
  return module.exports;
});

$__System.registerDynamic("1c9", ["1c8"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1c8');
  return module.exports;
});

$__System.registerDynamic("1ca", ["1aa", "1c9", "179", "18d", "18e", "184", "185", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    'use strict';
    var http = $__require('1aa'),
        https = $__require('1c9'),
        ono = $__require('179'),
        url = $__require('18d'),
        debug = $__require('18e'),
        Promise = $__require('184');
    module.exports = {
      order: 200,
      headers: null,
      timeout: 5000,
      redirects: 5,
      withCredentials: false,
      canRead: function isHttp(file) {
        return url.isHttp(file.url);
      },
      read: function readHttp(file) {
        var u = url.parse(file.url);
        if (process.browser && !u.protocol) {
          u.protocol = url.parse(location.href).protocol;
        }
        return download(u, this);
      }
    };
    function download(u, httpOptions, redirects) {
      return new Promise(function(resolve, reject) {
        u = url.parse(u);
        redirects = redirects || [];
        redirects.push(u.href);
        get(u, httpOptions).then(function(res) {
          if (res.statusCode >= 400) {
            throw ono({status: res.statusCode}, 'HTTP ERROR %d', res.statusCode);
          } else if (res.statusCode >= 300) {
            if (redirects.length > httpOptions.redirects) {
              reject(ono({status: res.statusCode}, 'Error downloading %s. \nToo many redirects: \n  %s', redirects[0], redirects.join(' \n  ')));
            } else if (!res.headers.location) {
              throw ono({status: res.statusCode}, 'HTTP %d redirect with no location header', res.statusCode);
            } else {
              debug('HTTP %d redirect %s -> %s', res.statusCode, u.href, res.headers.location);
              var redirectTo = url.resolve(u, res.headers.location);
              download(redirectTo, httpOptions, redirects).then(resolve, reject);
            }
          } else {
            resolve(res.body || new Buffer(0));
          }
        }).catch(function(err) {
          reject(ono(err, 'Error downloading', u.href));
        });
      });
    }
    function get(u, httpOptions) {
      return new Promise(function(resolve, reject) {
        debug('GET', u.href);
        var protocol = u.protocol === 'https:' ? https : http;
        var req = protocol.get({
          hostname: u.hostname,
          port: u.port,
          path: u.path,
          auth: u.auth,
          headers: httpOptions.headers || {},
          withCredentials: httpOptions.withCredentials
        });
        if (typeof req.setTimeout === 'function') {
          req.setTimeout(httpOptions.timeout);
        }
        req.on('timeout', function() {
          req.abort();
        });
        req.on('error', reject);
        req.once('response', function(res) {
          res.body = new Buffer(0);
          res.on('data', function(data) {
            res.body = Buffer.concat([res.body, new Buffer(data)]);
          });
          res.on('error', reject);
          res.on('end', function() {
            resolve(res);
          });
        });
      });
    }
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("1cb", ["185", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer, process) {
    'use strict';
    module.exports = {
      order: 100,
      canValidate: function canValidate(file) {
        return !!file.resolved;
      },
      validate: function validate(file) {}
    };
  })($__require('185').Buffer, $__require('22'));
  return module.exports;
});

$__System.registerDynamic("180", ["183", "186", "188", "189", "18c", "1ca", "1cb"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var jsonParser = $__require('183'),
      yamlParser = $__require('186'),
      textParser = $__require('188'),
      binaryParser = $__require('189'),
      fileResolver = $__require('18c'),
      httpResolver = $__require('1ca'),
      zschemaValidator = $__require('1cb');
  module.exports = $RefParserOptions;
  function $RefParserOptions(options) {
    merge(this, $RefParserOptions.defaults);
    merge(this, options);
  }
  $RefParserOptions.defaults = {
    parse: {
      json: jsonParser,
      yaml: yamlParser,
      text: textParser,
      binary: binaryParser
    },
    resolve: {
      file: fileResolver,
      http: httpResolver,
      external: true
    },
    dereference: {circular: true},
    validate: {zschema: zschemaValidator}
  };
  function merge(target, source) {
    if (isMergeable(source)) {
      var keys = Object.keys(source);
      for (var i = 0; i < keys.length; i++) {
        var key = keys[i];
        var sourceSetting = source[key];
        var targetSetting = target[key];
        if (isMergeable(sourceSetting)) {
          target[key] = merge(targetSetting || {}, sourceSetting);
        } else if (sourceSetting !== undefined) {
          target[key] = sourceSetting;
        }
      }
    }
    return target;
  }
  function isMergeable(val) {
    return val && (typeof val === 'object') && !Array.isArray(val) && !(val instanceof RegExp) && !(val instanceof Date);
  }
  return module.exports;
});

$__System.registerDynamic("1cc", ["179", "1cd", "18d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ono = $__require('179'),
      $Ref = $__require('1cd'),
      url = $__require('18d');
  module.exports = $Refs;
  function $Refs() {
    this.circular = false;
    this._$refs = {};
    this._root$Ref = null;
  }
  $Refs.prototype.paths = function(types) {
    var paths = getPaths(this._$refs, arguments);
    return paths.map(function(path) {
      return path.decoded;
    });
  };
  $Refs.prototype.values = function(types) {
    var $refs = this._$refs;
    var paths = getPaths($refs, arguments);
    return paths.reduce(function(obj, path) {
      obj[path.decoded] = $refs[path.encoded].value;
      return obj;
    }, {});
  };
  $Refs.prototype.toJSON = $Refs.prototype.values;
  $Refs.prototype.exists = function(path, options) {
    try {
      this._resolve(path, options);
      return true;
    } catch (e) {
      return false;
    }
  };
  $Refs.prototype.get = function(path, options) {
    return this._resolve(path, options).value;
  };
  $Refs.prototype.set = function(path, value) {
    path = url.resolve(this._root$Ref.path, path);
    var withoutHash = url.stripHash(path);
    var $ref = this._$refs[withoutHash];
    if (!$ref) {
      throw ono('Error resolving $ref pointer "%s". \n"%s" not found.', path, withoutHash);
    }
    $ref.set(path, value);
  };
  $Refs.prototype._add = function(path, value) {
    var withoutHash = url.stripHash(path);
    var $ref = new $Ref();
    $ref.path = withoutHash;
    $ref.value = value;
    $ref.$refs = this;
    this._$refs[withoutHash] = $ref;
    this._root$Ref = this._root$Ref || $ref;
    return $ref;
  };
  $Refs.prototype._resolve = function(path, options) {
    path = url.resolve(this._root$Ref.path, path);
    var withoutHash = url.stripHash(path);
    var $ref = this._$refs[withoutHash];
    if (!$ref) {
      throw ono('Error resolving $ref pointer "%s". \n"%s" not found.', path, withoutHash);
    }
    return $ref.resolve(path, options);
  };
  $Refs.prototype._get$Ref = function(path) {
    path = url.resolve(this._root$Ref.path, path);
    var withoutHash = url.stripHash(path);
    return this._$refs[withoutHash];
  };
  function getPaths($refs, types) {
    var paths = Object.keys($refs);
    types = Array.isArray(types[0]) ? types[0] : Array.prototype.slice.call(types);
    if (types.length > 0 && types[0]) {
      paths = paths.filter(function(key) {
        return types.indexOf($refs[key].pathType) !== -1;
      });
    }
    return paths.map(function(path) {
      return {
        encoded: path,
        decoded: $refs[path].pathType === 'file' ? url.toFileSystemPath(path, true) : path
      };
    });
  }
  return module.exports;
});

$__System.registerDynamic("1ce", ["184", "18e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Promise = $__require('184'),
      debug = $__require('18e');
  exports.all = function(plugins) {
    return Object.keys(plugins).filter(function(key) {
      return typeof plugins[key] === 'object';
    }).map(function(key) {
      plugins[key].name = key;
      return plugins[key];
    });
  };
  exports.filter = function(plugins, method, file) {
    return plugins.filter(function(plugin) {
      return !!getResult(plugin, method, file);
    });
  };
  exports.sort = function(plugins) {
    plugins.forEach(function(plugin) {
      plugin.order = plugin.order || Number.MAX_SAFE_INTEGER;
    });
    return plugins.sort(function(a, b) {
      return a.order - b.order;
    });
  };
  exports.run = function(plugins, method, file) {
    var plugin,
        lastError,
        index = 0;
    return new Promise(function(resolve, reject) {
      runNextPlugin();
      function runNextPlugin() {
        plugin = plugins[index++];
        if (!plugin) {
          return reject(lastError);
        }
        try {
          debug('  %s', plugin.name);
          var result = getResult(plugin, method, file, callback);
          if (result && typeof result.then === 'function') {
            result.then(onSuccess, onError);
          } else if (result !== undefined) {
            onSuccess(result);
          }
        } catch (e) {
          onError(e);
        }
      }
      function callback(err, result) {
        if (err) {
          onError(err);
        } else {
          onSuccess(result);
        }
      }
      function onSuccess(result) {
        debug('    success');
        resolve({
          plugin: plugin,
          result: result
        });
      }
      function onError(err) {
        debug('    %s', err.message || err);
        lastError = err;
        runNextPlugin();
      }
    });
  };
  function getResult(obj, prop, file, callback) {
    var value = obj[prop];
    if (typeof value === 'function') {
      return value.apply(obj, [file, callback]);
    }
    if (!callback) {
      if (value instanceof RegExp) {
        return value.test(file.url);
      } else if (typeof value === 'string') {
        return value === file.extension;
      } else if (Array.isArray(value)) {
        return value.indexOf(file.extension) !== -1;
      }
    }
    return value;
  }
  return module.exports;
});

$__System.registerDynamic("1cf", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  (function(process) {
    (function() {
      "use strict";
      function lib$es6$promise$utils$$objectOrFunction(x) {
        return typeof x === 'function' || (typeof x === 'object' && x !== null);
      }
      function lib$es6$promise$utils$$isFunction(x) {
        return typeof x === 'function';
      }
      function lib$es6$promise$utils$$isMaybeThenable(x) {
        return typeof x === 'object' && x !== null;
      }
      var lib$es6$promise$utils$$_isArray;
      if (!Array.isArray) {
        lib$es6$promise$utils$$_isArray = function(x) {
          return Object.prototype.toString.call(x) === '[object Array]';
        };
      } else {
        lib$es6$promise$utils$$_isArray = Array.isArray;
      }
      var lib$es6$promise$utils$$isArray = lib$es6$promise$utils$$_isArray;
      var lib$es6$promise$asap$$len = 0;
      var lib$es6$promise$asap$$vertxNext;
      var lib$es6$promise$asap$$customSchedulerFn;
      var lib$es6$promise$asap$$asap = function asap(callback, arg) {
        lib$es6$promise$asap$$queue[lib$es6$promise$asap$$len] = callback;
        lib$es6$promise$asap$$queue[lib$es6$promise$asap$$len + 1] = arg;
        lib$es6$promise$asap$$len += 2;
        if (lib$es6$promise$asap$$len === 2) {
          if (lib$es6$promise$asap$$customSchedulerFn) {
            lib$es6$promise$asap$$customSchedulerFn(lib$es6$promise$asap$$flush);
          } else {
            lib$es6$promise$asap$$scheduleFlush();
          }
        }
      };
      function lib$es6$promise$asap$$setScheduler(scheduleFn) {
        lib$es6$promise$asap$$customSchedulerFn = scheduleFn;
      }
      function lib$es6$promise$asap$$setAsap(asapFn) {
        lib$es6$promise$asap$$asap = asapFn;
      }
      var lib$es6$promise$asap$$browserWindow = (typeof window !== 'undefined') ? window : undefined;
      var lib$es6$promise$asap$$browserGlobal = lib$es6$promise$asap$$browserWindow || {};
      var lib$es6$promise$asap$$BrowserMutationObserver = lib$es6$promise$asap$$browserGlobal.MutationObserver || lib$es6$promise$asap$$browserGlobal.WebKitMutationObserver;
      var lib$es6$promise$asap$$isNode = typeof process !== 'undefined' && {}.toString.call(process) === '[object process]';
      var lib$es6$promise$asap$$isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined';
      function lib$es6$promise$asap$$useNextTick() {
        return function() {
          process.nextTick(lib$es6$promise$asap$$flush);
        };
      }
      function lib$es6$promise$asap$$useVertxTimer() {
        return function() {
          lib$es6$promise$asap$$vertxNext(lib$es6$promise$asap$$flush);
        };
      }
      function lib$es6$promise$asap$$useMutationObserver() {
        var iterations = 0;
        var observer = new lib$es6$promise$asap$$BrowserMutationObserver(lib$es6$promise$asap$$flush);
        var node = document.createTextNode('');
        observer.observe(node, {characterData: true});
        return function() {
          node.data = (iterations = ++iterations % 2);
        };
      }
      function lib$es6$promise$asap$$useMessageChannel() {
        var channel = new MessageChannel();
        channel.port1.onmessage = lib$es6$promise$asap$$flush;
        return function() {
          channel.port2.postMessage(0);
        };
      }
      function lib$es6$promise$asap$$useSetTimeout() {
        return function() {
          setTimeout(lib$es6$promise$asap$$flush, 1);
        };
      }
      var lib$es6$promise$asap$$queue = new Array(1000);
      function lib$es6$promise$asap$$flush() {
        for (var i = 0; i < lib$es6$promise$asap$$len; i += 2) {
          var callback = lib$es6$promise$asap$$queue[i];
          var arg = lib$es6$promise$asap$$queue[i + 1];
          callback(arg);
          lib$es6$promise$asap$$queue[i] = undefined;
          lib$es6$promise$asap$$queue[i + 1] = undefined;
        }
        lib$es6$promise$asap$$len = 0;
      }
      function lib$es6$promise$asap$$attemptVertx() {
        try {
          var r = $__require;
          var vertx = r('vertx');
          lib$es6$promise$asap$$vertxNext = vertx.runOnLoop || vertx.runOnContext;
          return lib$es6$promise$asap$$useVertxTimer();
        } catch (e) {
          return lib$es6$promise$asap$$useSetTimeout();
        }
      }
      var lib$es6$promise$asap$$scheduleFlush;
      if (lib$es6$promise$asap$$isNode) {
        lib$es6$promise$asap$$scheduleFlush = lib$es6$promise$asap$$useNextTick();
      } else if (lib$es6$promise$asap$$BrowserMutationObserver) {
        lib$es6$promise$asap$$scheduleFlush = lib$es6$promise$asap$$useMutationObserver();
      } else if (lib$es6$promise$asap$$isWorker) {
        lib$es6$promise$asap$$scheduleFlush = lib$es6$promise$asap$$useMessageChannel();
      } else if (lib$es6$promise$asap$$browserWindow === undefined && typeof $__require === 'function') {
        lib$es6$promise$asap$$scheduleFlush = lib$es6$promise$asap$$attemptVertx();
      } else {
        lib$es6$promise$asap$$scheduleFlush = lib$es6$promise$asap$$useSetTimeout();
      }
      function lib$es6$promise$then$$then(onFulfillment, onRejection) {
        var parent = this;
        var state = parent._state;
        if (state === lib$es6$promise$$internal$$FULFILLED && !onFulfillment || state === lib$es6$promise$$internal$$REJECTED && !onRejection) {
          return this;
        }
        var child = new this.constructor(lib$es6$promise$$internal$$noop);
        var result = parent._result;
        if (state) {
          var callback = arguments[state - 1];
          lib$es6$promise$asap$$asap(function() {
            lib$es6$promise$$internal$$invokeCallback(state, child, callback, result);
          });
        } else {
          lib$es6$promise$$internal$$subscribe(parent, child, onFulfillment, onRejection);
        }
        return child;
      }
      var lib$es6$promise$then$$default = lib$es6$promise$then$$then;
      function lib$es6$promise$promise$resolve$$resolve(object) {
        var Constructor = this;
        if (object && typeof object === 'object' && object.constructor === Constructor) {
          return object;
        }
        var promise = new Constructor(lib$es6$promise$$internal$$noop);
        lib$es6$promise$$internal$$resolve(promise, object);
        return promise;
      }
      var lib$es6$promise$promise$resolve$$default = lib$es6$promise$promise$resolve$$resolve;
      function lib$es6$promise$$internal$$noop() {}
      var lib$es6$promise$$internal$$PENDING = void 0;
      var lib$es6$promise$$internal$$FULFILLED = 1;
      var lib$es6$promise$$internal$$REJECTED = 2;
      var lib$es6$promise$$internal$$GET_THEN_ERROR = new lib$es6$promise$$internal$$ErrorObject();
      function lib$es6$promise$$internal$$selfFulfillment() {
        return new TypeError("You cannot resolve a promise with itself");
      }
      function lib$es6$promise$$internal$$cannotReturnOwn() {
        return new TypeError('A promises callback cannot return that same promise.');
      }
      function lib$es6$promise$$internal$$getThen(promise) {
        try {
          return promise.then;
        } catch (error) {
          lib$es6$promise$$internal$$GET_THEN_ERROR.error = error;
          return lib$es6$promise$$internal$$GET_THEN_ERROR;
        }
      }
      function lib$es6$promise$$internal$$tryThen(then, value, fulfillmentHandler, rejectionHandler) {
        try {
          then.call(value, fulfillmentHandler, rejectionHandler);
        } catch (e) {
          return e;
        }
      }
      function lib$es6$promise$$internal$$handleForeignThenable(promise, thenable, then) {
        lib$es6$promise$asap$$asap(function(promise) {
          var sealed = false;
          var error = lib$es6$promise$$internal$$tryThen(then, thenable, function(value) {
            if (sealed) {
              return;
            }
            sealed = true;
            if (thenable !== value) {
              lib$es6$promise$$internal$$resolve(promise, value);
            } else {
              lib$es6$promise$$internal$$fulfill(promise, value);
            }
          }, function(reason) {
            if (sealed) {
              return;
            }
            sealed = true;
            lib$es6$promise$$internal$$reject(promise, reason);
          }, 'Settle: ' + (promise._label || ' unknown promise'));
          if (!sealed && error) {
            sealed = true;
            lib$es6$promise$$internal$$reject(promise, error);
          }
        }, promise);
      }
      function lib$es6$promise$$internal$$handleOwnThenable(promise, thenable) {
        if (thenable._state === lib$es6$promise$$internal$$FULFILLED) {
          lib$es6$promise$$internal$$fulfill(promise, thenable._result);
        } else if (thenable._state === lib$es6$promise$$internal$$REJECTED) {
          lib$es6$promise$$internal$$reject(promise, thenable._result);
        } else {
          lib$es6$promise$$internal$$subscribe(thenable, undefined, function(value) {
            lib$es6$promise$$internal$$resolve(promise, value);
          }, function(reason) {
            lib$es6$promise$$internal$$reject(promise, reason);
          });
        }
      }
      function lib$es6$promise$$internal$$handleMaybeThenable(promise, maybeThenable, then) {
        if (maybeThenable.constructor === promise.constructor && then === lib$es6$promise$then$$default && constructor.resolve === lib$es6$promise$promise$resolve$$default) {
          lib$es6$promise$$internal$$handleOwnThenable(promise, maybeThenable);
        } else {
          if (then === lib$es6$promise$$internal$$GET_THEN_ERROR) {
            lib$es6$promise$$internal$$reject(promise, lib$es6$promise$$internal$$GET_THEN_ERROR.error);
          } else if (then === undefined) {
            lib$es6$promise$$internal$$fulfill(promise, maybeThenable);
          } else if (lib$es6$promise$utils$$isFunction(then)) {
            lib$es6$promise$$internal$$handleForeignThenable(promise, maybeThenable, then);
          } else {
            lib$es6$promise$$internal$$fulfill(promise, maybeThenable);
          }
        }
      }
      function lib$es6$promise$$internal$$resolve(promise, value) {
        if (promise === value) {
          lib$es6$promise$$internal$$reject(promise, lib$es6$promise$$internal$$selfFulfillment());
        } else if (lib$es6$promise$utils$$objectOrFunction(value)) {
          lib$es6$promise$$internal$$handleMaybeThenable(promise, value, lib$es6$promise$$internal$$getThen(value));
        } else {
          lib$es6$promise$$internal$$fulfill(promise, value);
        }
      }
      function lib$es6$promise$$internal$$publishRejection(promise) {
        if (promise._onerror) {
          promise._onerror(promise._result);
        }
        lib$es6$promise$$internal$$publish(promise);
      }
      function lib$es6$promise$$internal$$fulfill(promise, value) {
        if (promise._state !== lib$es6$promise$$internal$$PENDING) {
          return;
        }
        promise._result = value;
        promise._state = lib$es6$promise$$internal$$FULFILLED;
        if (promise._subscribers.length !== 0) {
          lib$es6$promise$asap$$asap(lib$es6$promise$$internal$$publish, promise);
        }
      }
      function lib$es6$promise$$internal$$reject(promise, reason) {
        if (promise._state !== lib$es6$promise$$internal$$PENDING) {
          return;
        }
        promise._state = lib$es6$promise$$internal$$REJECTED;
        promise._result = reason;
        lib$es6$promise$asap$$asap(lib$es6$promise$$internal$$publishRejection, promise);
      }
      function lib$es6$promise$$internal$$subscribe(parent, child, onFulfillment, onRejection) {
        var subscribers = parent._subscribers;
        var length = subscribers.length;
        parent._onerror = null;
        subscribers[length] = child;
        subscribers[length + lib$es6$promise$$internal$$FULFILLED] = onFulfillment;
        subscribers[length + lib$es6$promise$$internal$$REJECTED] = onRejection;
        if (length === 0 && parent._state) {
          lib$es6$promise$asap$$asap(lib$es6$promise$$internal$$publish, parent);
        }
      }
      function lib$es6$promise$$internal$$publish(promise) {
        var subscribers = promise._subscribers;
        var settled = promise._state;
        if (subscribers.length === 0) {
          return;
        }
        var child,
            callback,
            detail = promise._result;
        for (var i = 0; i < subscribers.length; i += 3) {
          child = subscribers[i];
          callback = subscribers[i + settled];
          if (child) {
            lib$es6$promise$$internal$$invokeCallback(settled, child, callback, detail);
          } else {
            callback(detail);
          }
        }
        promise._subscribers.length = 0;
      }
      function lib$es6$promise$$internal$$ErrorObject() {
        this.error = null;
      }
      var lib$es6$promise$$internal$$TRY_CATCH_ERROR = new lib$es6$promise$$internal$$ErrorObject();
      function lib$es6$promise$$internal$$tryCatch(callback, detail) {
        try {
          return callback(detail);
        } catch (e) {
          lib$es6$promise$$internal$$TRY_CATCH_ERROR.error = e;
          return lib$es6$promise$$internal$$TRY_CATCH_ERROR;
        }
      }
      function lib$es6$promise$$internal$$invokeCallback(settled, promise, callback, detail) {
        var hasCallback = lib$es6$promise$utils$$isFunction(callback),
            value,
            error,
            succeeded,
            failed;
        if (hasCallback) {
          value = lib$es6$promise$$internal$$tryCatch(callback, detail);
          if (value === lib$es6$promise$$internal$$TRY_CATCH_ERROR) {
            failed = true;
            error = value.error;
            value = null;
          } else {
            succeeded = true;
          }
          if (promise === value) {
            lib$es6$promise$$internal$$reject(promise, lib$es6$promise$$internal$$cannotReturnOwn());
            return;
          }
        } else {
          value = detail;
          succeeded = true;
        }
        if (promise._state !== lib$es6$promise$$internal$$PENDING) {} else if (hasCallback && succeeded) {
          lib$es6$promise$$internal$$resolve(promise, value);
        } else if (failed) {
          lib$es6$promise$$internal$$reject(promise, error);
        } else if (settled === lib$es6$promise$$internal$$FULFILLED) {
          lib$es6$promise$$internal$$fulfill(promise, value);
        } else if (settled === lib$es6$promise$$internal$$REJECTED) {
          lib$es6$promise$$internal$$reject(promise, value);
        }
      }
      function lib$es6$promise$$internal$$initializePromise(promise, resolver) {
        try {
          resolver(function resolvePromise(value) {
            lib$es6$promise$$internal$$resolve(promise, value);
          }, function rejectPromise(reason) {
            lib$es6$promise$$internal$$reject(promise, reason);
          });
        } catch (e) {
          lib$es6$promise$$internal$$reject(promise, e);
        }
      }
      function lib$es6$promise$promise$all$$all(entries) {
        return new lib$es6$promise$enumerator$$default(this, entries).promise;
      }
      var lib$es6$promise$promise$all$$default = lib$es6$promise$promise$all$$all;
      function lib$es6$promise$promise$race$$race(entries) {
        var Constructor = this;
        var promise = new Constructor(lib$es6$promise$$internal$$noop);
        if (!lib$es6$promise$utils$$isArray(entries)) {
          lib$es6$promise$$internal$$reject(promise, new TypeError('You must pass an array to race.'));
          return promise;
        }
        var length = entries.length;
        function onFulfillment(value) {
          lib$es6$promise$$internal$$resolve(promise, value);
        }
        function onRejection(reason) {
          lib$es6$promise$$internal$$reject(promise, reason);
        }
        for (var i = 0; promise._state === lib$es6$promise$$internal$$PENDING && i < length; i++) {
          lib$es6$promise$$internal$$subscribe(Constructor.resolve(entries[i]), undefined, onFulfillment, onRejection);
        }
        return promise;
      }
      var lib$es6$promise$promise$race$$default = lib$es6$promise$promise$race$$race;
      function lib$es6$promise$promise$reject$$reject(reason) {
        var Constructor = this;
        var promise = new Constructor(lib$es6$promise$$internal$$noop);
        lib$es6$promise$$internal$$reject(promise, reason);
        return promise;
      }
      var lib$es6$promise$promise$reject$$default = lib$es6$promise$promise$reject$$reject;
      var lib$es6$promise$promise$$counter = 0;
      function lib$es6$promise$promise$$needsResolver() {
        throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');
      }
      function lib$es6$promise$promise$$needsNew() {
        throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");
      }
      var lib$es6$promise$promise$$default = lib$es6$promise$promise$$Promise;
      function lib$es6$promise$promise$$Promise(resolver) {
        this._id = lib$es6$promise$promise$$counter++;
        this._state = undefined;
        this._result = undefined;
        this._subscribers = [];
        if (lib$es6$promise$$internal$$noop !== resolver) {
          typeof resolver !== 'function' && lib$es6$promise$promise$$needsResolver();
          this instanceof lib$es6$promise$promise$$Promise ? lib$es6$promise$$internal$$initializePromise(this, resolver) : lib$es6$promise$promise$$needsNew();
        }
      }
      lib$es6$promise$promise$$Promise.all = lib$es6$promise$promise$all$$default;
      lib$es6$promise$promise$$Promise.race = lib$es6$promise$promise$race$$default;
      lib$es6$promise$promise$$Promise.resolve = lib$es6$promise$promise$resolve$$default;
      lib$es6$promise$promise$$Promise.reject = lib$es6$promise$promise$reject$$default;
      lib$es6$promise$promise$$Promise._setScheduler = lib$es6$promise$asap$$setScheduler;
      lib$es6$promise$promise$$Promise._setAsap = lib$es6$promise$asap$$setAsap;
      lib$es6$promise$promise$$Promise._asap = lib$es6$promise$asap$$asap;
      lib$es6$promise$promise$$Promise.prototype = {
        constructor: lib$es6$promise$promise$$Promise,
        then: lib$es6$promise$then$$default,
        'catch': function(onRejection) {
          return this.then(null, onRejection);
        }
      };
      var lib$es6$promise$enumerator$$default = lib$es6$promise$enumerator$$Enumerator;
      function lib$es6$promise$enumerator$$Enumerator(Constructor, input) {
        this._instanceConstructor = Constructor;
        this.promise = new Constructor(lib$es6$promise$$internal$$noop);
        if (Array.isArray(input)) {
          this._input = input;
          this.length = input.length;
          this._remaining = input.length;
          this._result = new Array(this.length);
          if (this.length === 0) {
            lib$es6$promise$$internal$$fulfill(this.promise, this._result);
          } else {
            this.length = this.length || 0;
            this._enumerate();
            if (this._remaining === 0) {
              lib$es6$promise$$internal$$fulfill(this.promise, this._result);
            }
          }
        } else {
          lib$es6$promise$$internal$$reject(this.promise, this._validationError());
        }
      }
      lib$es6$promise$enumerator$$Enumerator.prototype._validationError = function() {
        return new Error('Array Methods must be provided an Array');
      };
      lib$es6$promise$enumerator$$Enumerator.prototype._enumerate = function() {
        var length = this.length;
        var input = this._input;
        for (var i = 0; this._state === lib$es6$promise$$internal$$PENDING && i < length; i++) {
          this._eachEntry(input[i], i);
        }
      };
      lib$es6$promise$enumerator$$Enumerator.prototype._eachEntry = function(entry, i) {
        var c = this._instanceConstructor;
        var resolve = c.resolve;
        if (resolve === lib$es6$promise$promise$resolve$$default) {
          var then = lib$es6$promise$$internal$$getThen(entry);
          if (then === lib$es6$promise$then$$default && entry._state !== lib$es6$promise$$internal$$PENDING) {
            this._settledAt(entry._state, i, entry._result);
          } else if (typeof then !== 'function') {
            this._remaining--;
            this._result[i] = entry;
          } else if (c === lib$es6$promise$promise$$default) {
            var promise = new c(lib$es6$promise$$internal$$noop);
            lib$es6$promise$$internal$$handleMaybeThenable(promise, entry, then);
            this._willSettleAt(promise, i);
          } else {
            this._willSettleAt(new c(function(resolve) {
              resolve(entry);
            }), i);
          }
        } else {
          this._willSettleAt(resolve(entry), i);
        }
      };
      lib$es6$promise$enumerator$$Enumerator.prototype._settledAt = function(state, i, value) {
        var promise = this.promise;
        if (promise._state === lib$es6$promise$$internal$$PENDING) {
          this._remaining--;
          if (state === lib$es6$promise$$internal$$REJECTED) {
            lib$es6$promise$$internal$$reject(promise, value);
          } else {
            this._result[i] = value;
          }
        }
        if (this._remaining === 0) {
          lib$es6$promise$$internal$$fulfill(promise, this._result);
        }
      };
      lib$es6$promise$enumerator$$Enumerator.prototype._willSettleAt = function(promise, i) {
        var enumerator = this;
        lib$es6$promise$$internal$$subscribe(promise, undefined, function(value) {
          enumerator._settledAt(lib$es6$promise$$internal$$FULFILLED, i, value);
        }, function(reason) {
          enumerator._settledAt(lib$es6$promise$$internal$$REJECTED, i, reason);
        });
      };
      function lib$es6$promise$polyfill$$polyfill() {
        var local;
        if (typeof global !== 'undefined') {
          local = global;
        } else if (typeof self !== 'undefined') {
          local = self;
        } else {
          try {
            local = Function('return this')();
          } catch (e) {
            throw new Error('polyfill failed because global object is unavailable in this environment');
          }
        }
        var P = local.Promise;
        if (P && Object.prototype.toString.call(P.resolve()) === '[object Promise]' && !P.cast) {
          return;
        }
        local.Promise = lib$es6$promise$promise$$default;
      }
      var lib$es6$promise$polyfill$$default = lib$es6$promise$polyfill$$polyfill;
      var lib$es6$promise$umd$$ES6Promise = {
        'Promise': lib$es6$promise$promise$$default,
        'polyfill': lib$es6$promise$polyfill$$default
      };
      if (typeof define === 'function' && define['amd']) {
        define(function() {
          return lib$es6$promise$umd$$ES6Promise;
        });
      } else if (typeof module !== 'undefined' && module['exports']) {
        module['exports'] = lib$es6$promise$umd$$ES6Promise;
      } else if (typeof this !== 'undefined') {
        this['ES6Promise'] = lib$es6$promise$umd$$ES6Promise;
      }
      lib$es6$promise$polyfill$$default();
    }).call(this);
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("182", ["1cf"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1cf');
  return module.exports;
});

$__System.registerDynamic("184", ["182"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = typeof Promise === 'function' ? Promise : $__require('182').Promise;
  return module.exports;
});

$__System.registerDynamic("1d0", ["179", "18e", "18d", "1ce", "184", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var ono = $__require('179'),
        debug = $__require('18e'),
        url = $__require('18d'),
        plugins = $__require('1ce'),
        Promise = $__require('184');
    module.exports = parse;
    function parse(path, $refs, options) {
      try {
        path = url.stripHash(path);
        var $ref = $refs._add(path);
        var file = {
          url: path,
          extension: url.getExtension(path)
        };
        return readFile(file, options).then(function(resolver) {
          $ref.pathType = resolver.plugin.name;
          file.data = resolver.result;
          return parseFile(file, options);
        }).then(function(parser) {
          $ref.value = parser.result;
          return parser.result;
        });
      } catch (e) {
        return Promise.reject(e);
      }
    }
    function readFile(file, options) {
      return new Promise(function(resolve, reject) {
        debug('Reading %s', file.url);
        var resolvers = plugins.all(options.resolve);
        resolvers = plugins.filter(resolvers, 'canRead', file);
        plugins.sort(resolvers);
        plugins.run(resolvers, 'read', file).then(resolve, onError);
        function onError(err) {
          if (err && !(err instanceof SyntaxError)) {
            reject(err);
          } else {
            reject(ono.syntax('Unable to resolve $ref pointer "%s"', file.url));
          }
        }
      });
    }
    function parseFile(file, options) {
      return new Promise(function(resolve, reject) {
        debug('Parsing %s', file.url);
        var allParsers = plugins.all(options.parse);
        var filteredParsers = plugins.filter(allParsers, 'canParse', file);
        var parsers = filteredParsers.length > 0 ? filteredParsers : allParsers;
        plugins.sort(parsers);
        plugins.run(parsers, 'parse', file).then(onParsed, onError);
        function onParsed(parser) {
          if (!parser.plugin.allowEmpty && isEmpty(parser.result)) {
            reject(ono.syntax('Error parsing "%s" as %s. \nParsed value is empty', file.url, parser.plugin.name));
          } else {
            resolve(parser);
          }
        }
        function onError(err) {
          if (err) {
            err = err instanceof Error ? err : new Error(err);
            reject(ono.syntax(err, 'Error parsing %s', file.url));
          } else {
            reject(ono.syntax('Unable to parse %s', file.url));
          }
        }
      });
    }
    function isEmpty(value) {
      return value === undefined || (typeof value === 'object' && Object.keys(value).length === 0) || (typeof value === 'string' && value.trim().length === 0) || (Buffer.isBuffer(value) && value.length === 0);
    }
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("1d1", ["184", "1cd", "1d2", "1d0", "18e", "18d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Promise = $__require('184'),
      $Ref = $__require('1cd'),
      Pointer = $__require('1d2'),
      parse = $__require('1d0'),
      debug = $__require('18e'),
      url = $__require('18d');
  module.exports = resolveExternal;
  function resolveExternal(parser, options) {
    if (!options.resolve.external) {
      return Promise.resolve();
    }
    try {
      debug('Resolving $ref pointers in %s', parser.$refs._root$Ref.path);
      var promises = crawl(parser.schema, parser.$refs._root$Ref.path + '#', parser.$refs, options);
      return Promise.all(promises);
    } catch (e) {
      return Promise.reject(e);
    }
  }
  function crawl(obj, path, $refs, options) {
    var promises = [];
    if (obj && typeof obj === 'object') {
      if ($Ref.isExternal$Ref(obj)) {
        promises.push(resolve$Ref(obj, path, $refs, options));
      } else {
        Object.keys(obj).forEach(function(key) {
          var keyPath = Pointer.join(path, key);
          var value = obj[key];
          if ($Ref.isExternal$Ref(value)) {
            promises.push(resolve$Ref(value, keyPath, $refs, options));
          } else {
            promises = promises.concat(crawl(value, keyPath, $refs, options));
          }
        });
      }
    }
    return promises;
  }
  function resolve$Ref($ref, path, $refs, options) {
    debug('Resolving $ref pointer "%s" at %s', $ref.$ref, path);
    var resolvedPath = url.resolve(path, $ref.$ref);
    var withoutHash = url.stripHash(resolvedPath);
    $ref = $refs._$refs[withoutHash];
    if ($ref) {
      return Promise.resolve($ref.value);
    }
    return parse(resolvedPath, $refs, options).then(function(result) {
      debug('Resolving $ref pointers in %s', withoutHash);
      var promises = crawl(result, withoutHash + '#', $refs, options);
      return Promise.all(promises);
    });
  }
  return module.exports;
});

$__System.registerDynamic("1d3", ["1cd", "1d2", "18e", "18d", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    var $Ref = $__require('1cd'),
        Pointer = $__require('1d2'),
        debug = $__require('18e'),
        url = $__require('18d');
    module.exports = bundle;
    function bundle(parser, options) {
      debug('Bundling $ref pointers in %s', parser.$refs._root$Ref.path);
      var inventory = [];
      crawl(parser, 'schema', parser.$refs._root$Ref.path + '#', '#', inventory, parser.$refs, options);
      remap(inventory);
    }
    function crawl(parent, key, path, pathFromRoot, inventory, $refs, options) {
      var obj = key === null ? parent : parent[key];
      if (obj && typeof obj === 'object') {
        if ($Ref.is$Ref(obj)) {
          inventory$Ref(parent, key, path, pathFromRoot, inventory, $refs, options);
        } else {
          var keys = Object.keys(obj);
          var defs = keys.indexOf('definitions');
          if (defs > 0) {
            keys.splice(0, 0, keys.splice(defs, 1)[0]);
          }
          keys.forEach(function(key) {
            var keyPath = Pointer.join(path, key);
            var keyPathFromRoot = Pointer.join(pathFromRoot, key);
            var value = obj[key];
            if ($Ref.is$Ref(value)) {
              inventory$Ref(obj, key, path, keyPathFromRoot, inventory, $refs, options);
            } else {
              crawl(obj, key, keyPath, keyPathFromRoot, inventory, $refs, options);
            }
          });
        }
      }
    }
    function inventory$Ref($refParent, $refKey, path, pathFromRoot, inventory, $refs, options) {
      if (inventory.some(function(i) {
        return i.parent === $refParent && i.key === $refKey;
      })) {
        return;
      }
      var $ref = $refKey === null ? $refParent : $refParent[$refKey];
      var $refPath = url.resolve(path, $ref.$ref);
      var pointer = $refs._resolve($refPath, options);
      var depth = Pointer.parse(pathFromRoot).length;
      var file = url.stripHash(pointer.path);
      var hash = url.getHash(pointer.path);
      var external = file !== $refs._root$Ref.path;
      var extended = $Ref.isExtended$Ref($ref);
      inventory.push({
        $ref: $ref,
        parent: $refParent,
        key: $refKey,
        pathFromRoot: pathFromRoot,
        depth: depth,
        file: file,
        hash: hash,
        value: pointer.value,
        circular: pointer.circular,
        extended: extended,
        external: external
      });
      crawl(pointer.value, null, pointer.path, pathFromRoot, inventory, $refs, options);
    }
    function remap(inventory) {
      inventory.sort(function(a, b) {
        if (a.file !== b.file) {
          return a.file < b.file ? -1 : +1;
        } else if (a.hash !== b.hash) {
          return a.hash < b.hash ? -1 : +1;
        } else if (a.circular !== b.circular) {
          return a.circular ? -1 : +1;
        } else if (a.extended !== b.extended) {
          return a.extended ? +1 : -1;
        } else if (a.depth !== b.depth) {
          return a.depth - b.depth;
        } else {
          return b.pathFromRoot.lastIndexOf('/definitions') - a.pathFromRoot.lastIndexOf('/definitions');
        }
      });
      var file,
          hash,
          pathFromRoot;
      inventory.forEach(function(i) {
        debug('Re-mapping $ref pointer "%s" at %s', i.$ref.$ref, i.pathFromRoot);
        if (!i.external) {
          i.$ref.$ref = i.hash;
        } else if (i.file === file && i.hash === hash) {
          i.$ref.$ref = pathFromRoot;
        } else if (i.file === file && i.hash.indexOf(hash + '/') === 0) {
          i.$ref.$ref = Pointer.join(pathFromRoot, Pointer.parse(i.hash));
        } else {
          file = i.file;
          hash = i.hash;
          pathFromRoot = i.pathFromRoot;
          i.$ref = i.parent[i.key] = $Ref.dereference(i.$ref, i.value);
          if (i.circular) {
            i.$ref.$ref = i.pathFromRoot;
          }
        }
        debug('    new value: %s', (i.$ref && i.$ref.$ref) ? i.$ref.$ref : '[object Object]');
      });
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1d4", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var next = (global.process && process.nextTick) || global.setImmediate || function(f) {
      setTimeout(f, 0);
    };
    module.exports = function maybe(cb, promise) {
      if (cb) {
        promise.then(function(result) {
          next(function() {
            cb(null, result);
          });
        }, function(err) {
          next(function() {
            cb(err);
          });
        });
        return undefined;
      } else {
        return promise;
      }
    };
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1d5", ["1d4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1d4');
  return module.exports;
});

$__System.registerDynamic("1d6", ["1d7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  function Mark(name, buffer, position, line, column) {
    this.name = name;
    this.buffer = buffer;
    this.position = position;
    this.line = line;
    this.column = column;
  }
  Mark.prototype.getSnippet = function getSnippet(indent, maxLength) {
    var head,
        start,
        tail,
        end,
        snippet;
    if (!this.buffer)
      return null;
    indent = indent || 4;
    maxLength = maxLength || 75;
    head = '';
    start = this.position;
    while (start > 0 && '\x00\r\n\x85\u2028\u2029'.indexOf(this.buffer.charAt(start - 1)) === -1) {
      start -= 1;
      if (this.position - start > (maxLength / 2 - 1)) {
        head = ' ... ';
        start += 5;
        break;
      }
    }
    tail = '';
    end = this.position;
    while (end < this.buffer.length && '\x00\r\n\x85\u2028\u2029'.indexOf(this.buffer.charAt(end)) === -1) {
      end += 1;
      if (end - this.position > (maxLength / 2 - 1)) {
        tail = ' ... ';
        end -= 5;
        break;
      }
    }
    snippet = this.buffer.slice(start, end);
    return common.repeat(' ', indent) + head + snippet + tail + '\n' + common.repeat(' ', indent + this.position - start + head.length) + '^';
  };
  Mark.prototype.toString = function toString(compact) {
    var snippet,
        where = '';
    if (this.name) {
      where += 'in "' + this.name + '" ';
    }
    where += 'at line ' + (this.line + 1) + ', column ' + (this.column + 1);
    if (!compact) {
      snippet = this.getSnippet();
      if (snippet) {
        where += ':\n' + snippet;
      }
    }
    return where;
  };
  module.exports = Mark;
  return module.exports;
});

$__System.registerDynamic("1d8", ["1d7", "1d9", "1d6", "1da", "1db"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  var YAMLException = $__require('1d9');
  var Mark = $__require('1d6');
  var DEFAULT_SAFE_SCHEMA = $__require('1da');
  var DEFAULT_FULL_SCHEMA = $__require('1db');
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
  var CONTEXT_FLOW_IN = 1;
  var CONTEXT_FLOW_OUT = 2;
  var CONTEXT_BLOCK_IN = 3;
  var CONTEXT_BLOCK_OUT = 4;
  var CHOMPING_CLIP = 1;
  var CHOMPING_STRIP = 2;
  var CHOMPING_KEEP = 3;
  var PATTERN_NON_PRINTABLE = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/;
  var PATTERN_NON_ASCII_LINE_BREAKS = /[\x85\u2028\u2029]/;
  var PATTERN_FLOW_INDICATORS = /[,\[\]\{\}]/;
  var PATTERN_TAG_HANDLE = /^(?:!|!!|![a-z\-]+!)$/i;
  var PATTERN_TAG_URI = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;
  function is_EOL(c) {
    return (c === 0x0A) || (c === 0x0D);
  }
  function is_WHITE_SPACE(c) {
    return (c === 0x09) || (c === 0x20);
  }
  function is_WS_OR_EOL(c) {
    return (c === 0x09) || (c === 0x20) || (c === 0x0A) || (c === 0x0D);
  }
  function is_FLOW_INDICATOR(c) {
    return c === 0x2C || c === 0x5B || c === 0x5D || c === 0x7B || c === 0x7D;
  }
  function fromHexCode(c) {
    var lc;
    if ((0x30 <= c) && (c <= 0x39)) {
      return c - 0x30;
    }
    lc = c | 0x20;
    if ((0x61 <= lc) && (lc <= 0x66)) {
      return lc - 0x61 + 10;
    }
    return -1;
  }
  function escapedHexLen(c) {
    if (c === 0x78) {
      return 2;
    }
    if (c === 0x75) {
      return 4;
    }
    if (c === 0x55) {
      return 8;
    }
    return 0;
  }
  function fromDecimalCode(c) {
    if ((0x30 <= c) && (c <= 0x39)) {
      return c - 0x30;
    }
    return -1;
  }
  function simpleEscapeSequence(c) {
    return (c === 0x30) ? '\x00' : (c === 0x61) ? '\x07' : (c === 0x62) ? '\x08' : (c === 0x74) ? '\x09' : (c === 0x09) ? '\x09' : (c === 0x6E) ? '\x0A' : (c === 0x76) ? '\x0B' : (c === 0x66) ? '\x0C' : (c === 0x72) ? '\x0D' : (c === 0x65) ? '\x1B' : (c === 0x20) ? ' ' : (c === 0x22) ? '\x22' : (c === 0x2F) ? '/' : (c === 0x5C) ? '\x5C' : (c === 0x4E) ? '\x85' : (c === 0x5F) ? '\xA0' : (c === 0x4C) ? '\u2028' : (c === 0x50) ? '\u2029' : '';
  }
  function charFromCodepoint(c) {
    if (c <= 0xFFFF) {
      return String.fromCharCode(c);
    }
    return String.fromCharCode(((c - 0x010000) >> 10) + 0xD800, ((c - 0x010000) & 0x03FF) + 0xDC00);
  }
  var simpleEscapeCheck = new Array(256);
  var simpleEscapeMap = new Array(256);
  for (var i = 0; i < 256; i++) {
    simpleEscapeCheck[i] = simpleEscapeSequence(i) ? 1 : 0;
    simpleEscapeMap[i] = simpleEscapeSequence(i);
  }
  function State(input, options) {
    this.input = input;
    this.filename = options['filename'] || null;
    this.schema = options['schema'] || DEFAULT_FULL_SCHEMA;
    this.onWarning = options['onWarning'] || null;
    this.legacy = options['legacy'] || false;
    this.json = options['json'] || false;
    this.listener = options['listener'] || null;
    this.implicitTypes = this.schema.compiledImplicit;
    this.typeMap = this.schema.compiledTypeMap;
    this.length = input.length;
    this.position = 0;
    this.line = 0;
    this.lineStart = 0;
    this.lineIndent = 0;
    this.documents = [];
  }
  function generateError(state, message) {
    return new YAMLException(message, new Mark(state.filename, state.input, state.position, state.line, (state.position - state.lineStart)));
  }
  function throwError(state, message) {
    throw generateError(state, message);
  }
  function throwWarning(state, message) {
    if (state.onWarning) {
      state.onWarning.call(null, generateError(state, message));
    }
  }
  var directiveHandlers = {
    YAML: function handleYamlDirective(state, name, args) {
      var match,
          major,
          minor;
      if (state.version !== null) {
        throwError(state, 'duplication of %YAML directive');
      }
      if (args.length !== 1) {
        throwError(state, 'YAML directive accepts exactly one argument');
      }
      match = /^([0-9]+)\.([0-9]+)$/.exec(args[0]);
      if (match === null) {
        throwError(state, 'ill-formed argument of the YAML directive');
      }
      major = parseInt(match[1], 10);
      minor = parseInt(match[2], 10);
      if (major !== 1) {
        throwError(state, 'unacceptable YAML version of the document');
      }
      state.version = args[0];
      state.checkLineBreaks = (minor < 2);
      if (minor !== 1 && minor !== 2) {
        throwWarning(state, 'unsupported YAML version of the document');
      }
    },
    TAG: function handleTagDirective(state, name, args) {
      var handle,
          prefix;
      if (args.length !== 2) {
        throwError(state, 'TAG directive accepts exactly two arguments');
      }
      handle = args[0];
      prefix = args[1];
      if (!PATTERN_TAG_HANDLE.test(handle)) {
        throwError(state, 'ill-formed tag handle (first argument) of the TAG directive');
      }
      if (_hasOwnProperty.call(state.tagMap, handle)) {
        throwError(state, 'there is a previously declared suffix for "' + handle + '" tag handle');
      }
      if (!PATTERN_TAG_URI.test(prefix)) {
        throwError(state, 'ill-formed tag prefix (second argument) of the TAG directive');
      }
      state.tagMap[handle] = prefix;
    }
  };
  function captureSegment(state, start, end, checkJson) {
    var _position,
        _length,
        _character,
        _result;
    if (start < end) {
      _result = state.input.slice(start, end);
      if (checkJson) {
        for (_position = 0, _length = _result.length; _position < _length; _position += 1) {
          _character = _result.charCodeAt(_position);
          if (!(_character === 0x09 || (0x20 <= _character && _character <= 0x10FFFF))) {
            throwError(state, 'expected valid JSON character');
          }
        }
      } else if (PATTERN_NON_PRINTABLE.test(_result)) {
        throwError(state, 'the stream contains non-printable characters');
      }
      state.result += _result;
    }
  }
  function mergeMappings(state, destination, source, overridableKeys) {
    var sourceKeys,
        key,
        index,
        quantity;
    if (!common.isObject(source)) {
      throwError(state, 'cannot merge mappings; the provided source object is unacceptable');
    }
    sourceKeys = Object.keys(source);
    for (index = 0, quantity = sourceKeys.length; index < quantity; index += 1) {
      key = sourceKeys[index];
      if (!_hasOwnProperty.call(destination, key)) {
        destination[key] = source[key];
        overridableKeys[key] = true;
      }
    }
  }
  function storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, valueNode) {
    var index,
        quantity;
    keyNode = String(keyNode);
    if (_result === null) {
      _result = {};
    }
    if (keyTag === 'tag:yaml.org,2002:merge') {
      if (Array.isArray(valueNode)) {
        for (index = 0, quantity = valueNode.length; index < quantity; index += 1) {
          mergeMappings(state, _result, valueNode[index], overridableKeys);
        }
      } else {
        mergeMappings(state, _result, valueNode, overridableKeys);
      }
    } else {
      if (!state.json && !_hasOwnProperty.call(overridableKeys, keyNode) && _hasOwnProperty.call(_result, keyNode)) {
        throwError(state, 'duplicated mapping key');
      }
      _result[keyNode] = valueNode;
      delete overridableKeys[keyNode];
    }
    return _result;
  }
  function readLineBreak(state) {
    var ch;
    ch = state.input.charCodeAt(state.position);
    if (ch === 0x0A) {
      state.position++;
    } else if (ch === 0x0D) {
      state.position++;
      if (state.input.charCodeAt(state.position) === 0x0A) {
        state.position++;
      }
    } else {
      throwError(state, 'a line break is expected');
    }
    state.line += 1;
    state.lineStart = state.position;
  }
  function skipSeparationSpace(state, allowComments, checkIndent) {
    var lineBreaks = 0,
        ch = state.input.charCodeAt(state.position);
    while (ch !== 0) {
      while (is_WHITE_SPACE(ch)) {
        ch = state.input.charCodeAt(++state.position);
      }
      if (allowComments && ch === 0x23) {
        do {
          ch = state.input.charCodeAt(++state.position);
        } while (ch !== 0x0A && ch !== 0x0D && ch !== 0);
      }
      if (is_EOL(ch)) {
        readLineBreak(state);
        ch = state.input.charCodeAt(state.position);
        lineBreaks++;
        state.lineIndent = 0;
        while (ch === 0x20) {
          state.lineIndent++;
          ch = state.input.charCodeAt(++state.position);
        }
      } else {
        break;
      }
    }
    if (checkIndent !== -1 && lineBreaks !== 0 && state.lineIndent < checkIndent) {
      throwWarning(state, 'deficient indentation');
    }
    return lineBreaks;
  }
  function testDocumentSeparator(state) {
    var _position = state.position,
        ch;
    ch = state.input.charCodeAt(_position);
    if ((ch === 0x2D || ch === 0x2E) && ch === state.input.charCodeAt(_position + 1) && ch === state.input.charCodeAt(_position + 2)) {
      _position += 3;
      ch = state.input.charCodeAt(_position);
      if (ch === 0 || is_WS_OR_EOL(ch)) {
        return true;
      }
    }
    return false;
  }
  function writeFoldedLines(state, count) {
    if (count === 1) {
      state.result += ' ';
    } else if (count > 1) {
      state.result += common.repeat('\n', count - 1);
    }
  }
  function readPlainScalar(state, nodeIndent, withinFlowCollection) {
    var preceding,
        following,
        captureStart,
        captureEnd,
        hasPendingContent,
        _line,
        _lineStart,
        _lineIndent,
        _kind = state.kind,
        _result = state.result,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (is_WS_OR_EOL(ch) || is_FLOW_INDICATOR(ch) || ch === 0x23 || ch === 0x26 || ch === 0x2A || ch === 0x21 || ch === 0x7C || ch === 0x3E || ch === 0x27 || ch === 0x22 || ch === 0x25 || ch === 0x40 || ch === 0x60) {
      return false;
    }
    if (ch === 0x3F || ch === 0x2D) {
      following = state.input.charCodeAt(state.position + 1);
      if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {
        return false;
      }
    }
    state.kind = 'scalar';
    state.result = '';
    captureStart = captureEnd = state.position;
    hasPendingContent = false;
    while (ch !== 0) {
      if (ch === 0x3A) {
        following = state.input.charCodeAt(state.position + 1);
        if (is_WS_OR_EOL(following) || withinFlowCollection && is_FLOW_INDICATOR(following)) {
          break;
        }
      } else if (ch === 0x23) {
        preceding = state.input.charCodeAt(state.position - 1);
        if (is_WS_OR_EOL(preceding)) {
          break;
        }
      } else if ((state.position === state.lineStart && testDocumentSeparator(state)) || withinFlowCollection && is_FLOW_INDICATOR(ch)) {
        break;
      } else if (is_EOL(ch)) {
        _line = state.line;
        _lineStart = state.lineStart;
        _lineIndent = state.lineIndent;
        skipSeparationSpace(state, false, -1);
        if (state.lineIndent >= nodeIndent) {
          hasPendingContent = true;
          ch = state.input.charCodeAt(state.position);
          continue;
        } else {
          state.position = captureEnd;
          state.line = _line;
          state.lineStart = _lineStart;
          state.lineIndent = _lineIndent;
          break;
        }
      }
      if (hasPendingContent) {
        captureSegment(state, captureStart, captureEnd, false);
        writeFoldedLines(state, state.line - _line);
        captureStart = captureEnd = state.position;
        hasPendingContent = false;
      }
      if (!is_WHITE_SPACE(ch)) {
        captureEnd = state.position + 1;
      }
      ch = state.input.charCodeAt(++state.position);
    }
    captureSegment(state, captureStart, captureEnd, false);
    if (state.result) {
      return true;
    }
    state.kind = _kind;
    state.result = _result;
    return false;
  }
  function readSingleQuotedScalar(state, nodeIndent) {
    var ch,
        captureStart,
        captureEnd;
    ch = state.input.charCodeAt(state.position);
    if (ch !== 0x27) {
      return false;
    }
    state.kind = 'scalar';
    state.result = '';
    state.position++;
    captureStart = captureEnd = state.position;
    while ((ch = state.input.charCodeAt(state.position)) !== 0) {
      if (ch === 0x27) {
        captureSegment(state, captureStart, state.position, true);
        ch = state.input.charCodeAt(++state.position);
        if (ch === 0x27) {
          captureStart = captureEnd = state.position;
          state.position++;
        } else {
          return true;
        }
      } else if (is_EOL(ch)) {
        captureSegment(state, captureStart, captureEnd, true);
        writeFoldedLines(state, skipSeparationSpace(state, false, nodeIndent));
        captureStart = captureEnd = state.position;
      } else if (state.position === state.lineStart && testDocumentSeparator(state)) {
        throwError(state, 'unexpected end of the document within a single quoted scalar');
      } else {
        state.position++;
        captureEnd = state.position;
      }
    }
    throwError(state, 'unexpected end of the stream within a single quoted scalar');
  }
  function readDoubleQuotedScalar(state, nodeIndent) {
    var captureStart,
        captureEnd,
        hexLength,
        hexResult,
        tmp,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch !== 0x22) {
      return false;
    }
    state.kind = 'scalar';
    state.result = '';
    state.position++;
    captureStart = captureEnd = state.position;
    while ((ch = state.input.charCodeAt(state.position)) !== 0) {
      if (ch === 0x22) {
        captureSegment(state, captureStart, state.position, true);
        state.position++;
        return true;
      } else if (ch === 0x5C) {
        captureSegment(state, captureStart, state.position, true);
        ch = state.input.charCodeAt(++state.position);
        if (is_EOL(ch)) {
          skipSeparationSpace(state, false, nodeIndent);
        } else if (ch < 256 && simpleEscapeCheck[ch]) {
          state.result += simpleEscapeMap[ch];
          state.position++;
        } else if ((tmp = escapedHexLen(ch)) > 0) {
          hexLength = tmp;
          hexResult = 0;
          for (; hexLength > 0; hexLength--) {
            ch = state.input.charCodeAt(++state.position);
            if ((tmp = fromHexCode(ch)) >= 0) {
              hexResult = (hexResult << 4) + tmp;
            } else {
              throwError(state, 'expected hexadecimal character');
            }
          }
          state.result += charFromCodepoint(hexResult);
          state.position++;
        } else {
          throwError(state, 'unknown escape sequence');
        }
        captureStart = captureEnd = state.position;
      } else if (is_EOL(ch)) {
        captureSegment(state, captureStart, captureEnd, true);
        writeFoldedLines(state, skipSeparationSpace(state, false, nodeIndent));
        captureStart = captureEnd = state.position;
      } else if (state.position === state.lineStart && testDocumentSeparator(state)) {
        throwError(state, 'unexpected end of the document within a double quoted scalar');
      } else {
        state.position++;
        captureEnd = state.position;
      }
    }
    throwError(state, 'unexpected end of the stream within a double quoted scalar');
  }
  function readFlowCollection(state, nodeIndent) {
    var readNext = true,
        _line,
        _tag = state.tag,
        _result,
        _anchor = state.anchor,
        following,
        terminator,
        isPair,
        isExplicitPair,
        isMapping,
        overridableKeys = {},
        keyNode,
        keyTag,
        valueNode,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch === 0x5B) {
      terminator = 0x5D;
      isMapping = false;
      _result = [];
    } else if (ch === 0x7B) {
      terminator = 0x7D;
      isMapping = true;
      _result = {};
    } else {
      return false;
    }
    if (state.anchor !== null) {
      state.anchorMap[state.anchor] = _result;
    }
    ch = state.input.charCodeAt(++state.position);
    while (ch !== 0) {
      skipSeparationSpace(state, true, nodeIndent);
      ch = state.input.charCodeAt(state.position);
      if (ch === terminator) {
        state.position++;
        state.tag = _tag;
        state.anchor = _anchor;
        state.kind = isMapping ? 'mapping' : 'sequence';
        state.result = _result;
        return true;
      } else if (!readNext) {
        throwError(state, 'missed comma between flow collection entries');
      }
      keyTag = keyNode = valueNode = null;
      isPair = isExplicitPair = false;
      if (ch === 0x3F) {
        following = state.input.charCodeAt(state.position + 1);
        if (is_WS_OR_EOL(following)) {
          isPair = isExplicitPair = true;
          state.position++;
          skipSeparationSpace(state, true, nodeIndent);
        }
      }
      _line = state.line;
      composeNode(state, nodeIndent, CONTEXT_FLOW_IN, false, true);
      keyTag = state.tag;
      keyNode = state.result;
      skipSeparationSpace(state, true, nodeIndent);
      ch = state.input.charCodeAt(state.position);
      if ((isExplicitPair || state.line === _line) && ch === 0x3A) {
        isPair = true;
        ch = state.input.charCodeAt(++state.position);
        skipSeparationSpace(state, true, nodeIndent);
        composeNode(state, nodeIndent, CONTEXT_FLOW_IN, false, true);
        valueNode = state.result;
      }
      if (isMapping) {
        storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, valueNode);
      } else if (isPair) {
        _result.push(storeMappingPair(state, null, overridableKeys, keyTag, keyNode, valueNode));
      } else {
        _result.push(keyNode);
      }
      skipSeparationSpace(state, true, nodeIndent);
      ch = state.input.charCodeAt(state.position);
      if (ch === 0x2C) {
        readNext = true;
        ch = state.input.charCodeAt(++state.position);
      } else {
        readNext = false;
      }
    }
    throwError(state, 'unexpected end of the stream within a flow collection');
  }
  function readBlockScalar(state, nodeIndent) {
    var captureStart,
        folding,
        chomping = CHOMPING_CLIP,
        didReadContent = false,
        detectedIndent = false,
        textIndent = nodeIndent,
        emptyLines = 0,
        atMoreIndented = false,
        tmp,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch === 0x7C) {
      folding = false;
    } else if (ch === 0x3E) {
      folding = true;
    } else {
      return false;
    }
    state.kind = 'scalar';
    state.result = '';
    while (ch !== 0) {
      ch = state.input.charCodeAt(++state.position);
      if (ch === 0x2B || ch === 0x2D) {
        if (CHOMPING_CLIP === chomping) {
          chomping = (ch === 0x2B) ? CHOMPING_KEEP : CHOMPING_STRIP;
        } else {
          throwError(state, 'repeat of a chomping mode identifier');
        }
      } else if ((tmp = fromDecimalCode(ch)) >= 0) {
        if (tmp === 0) {
          throwError(state, 'bad explicit indentation width of a block scalar; it cannot be less than one');
        } else if (!detectedIndent) {
          textIndent = nodeIndent + tmp - 1;
          detectedIndent = true;
        } else {
          throwError(state, 'repeat of an indentation width identifier');
        }
      } else {
        break;
      }
    }
    if (is_WHITE_SPACE(ch)) {
      do {
        ch = state.input.charCodeAt(++state.position);
      } while (is_WHITE_SPACE(ch));
      if (ch === 0x23) {
        do {
          ch = state.input.charCodeAt(++state.position);
        } while (!is_EOL(ch) && (ch !== 0));
      }
    }
    while (ch !== 0) {
      readLineBreak(state);
      state.lineIndent = 0;
      ch = state.input.charCodeAt(state.position);
      while ((!detectedIndent || state.lineIndent < textIndent) && (ch === 0x20)) {
        state.lineIndent++;
        ch = state.input.charCodeAt(++state.position);
      }
      if (!detectedIndent && state.lineIndent > textIndent) {
        textIndent = state.lineIndent;
      }
      if (is_EOL(ch)) {
        emptyLines++;
        continue;
      }
      if (state.lineIndent < textIndent) {
        if (chomping === CHOMPING_KEEP) {
          state.result += common.repeat('\n', didReadContent ? 1 + emptyLines : emptyLines);
        } else if (chomping === CHOMPING_CLIP) {
          if (didReadContent) {
            state.result += '\n';
          }
        }
        break;
      }
      if (folding) {
        if (is_WHITE_SPACE(ch)) {
          atMoreIndented = true;
          state.result += common.repeat('\n', didReadContent ? 1 + emptyLines : emptyLines);
        } else if (atMoreIndented) {
          atMoreIndented = false;
          state.result += common.repeat('\n', emptyLines + 1);
        } else if (emptyLines === 0) {
          if (didReadContent) {
            state.result += ' ';
          }
        } else {
          state.result += common.repeat('\n', emptyLines);
        }
      } else {
        state.result += common.repeat('\n', didReadContent ? 1 + emptyLines : emptyLines);
      }
      didReadContent = true;
      detectedIndent = true;
      emptyLines = 0;
      captureStart = state.position;
      while (!is_EOL(ch) && (ch !== 0)) {
        ch = state.input.charCodeAt(++state.position);
      }
      captureSegment(state, captureStart, state.position, false);
    }
    return true;
  }
  function readBlockSequence(state, nodeIndent) {
    var _line,
        _tag = state.tag,
        _anchor = state.anchor,
        _result = [],
        following,
        detected = false,
        ch;
    if (state.anchor !== null) {
      state.anchorMap[state.anchor] = _result;
    }
    ch = state.input.charCodeAt(state.position);
    while (ch !== 0) {
      if (ch !== 0x2D) {
        break;
      }
      following = state.input.charCodeAt(state.position + 1);
      if (!is_WS_OR_EOL(following)) {
        break;
      }
      detected = true;
      state.position++;
      if (skipSeparationSpace(state, true, -1)) {
        if (state.lineIndent <= nodeIndent) {
          _result.push(null);
          ch = state.input.charCodeAt(state.position);
          continue;
        }
      }
      _line = state.line;
      composeNode(state, nodeIndent, CONTEXT_BLOCK_IN, false, true);
      _result.push(state.result);
      skipSeparationSpace(state, true, -1);
      ch = state.input.charCodeAt(state.position);
      if ((state.line === _line || state.lineIndent > nodeIndent) && (ch !== 0)) {
        throwError(state, 'bad indentation of a sequence entry');
      } else if (state.lineIndent < nodeIndent) {
        break;
      }
    }
    if (detected) {
      state.tag = _tag;
      state.anchor = _anchor;
      state.kind = 'sequence';
      state.result = _result;
      return true;
    }
    return false;
  }
  function readBlockMapping(state, nodeIndent, flowIndent) {
    var following,
        allowCompact,
        _line,
        _tag = state.tag,
        _anchor = state.anchor,
        _result = {},
        overridableKeys = {},
        keyTag = null,
        keyNode = null,
        valueNode = null,
        atExplicitKey = false,
        detected = false,
        ch;
    if (state.anchor !== null) {
      state.anchorMap[state.anchor] = _result;
    }
    ch = state.input.charCodeAt(state.position);
    while (ch !== 0) {
      following = state.input.charCodeAt(state.position + 1);
      _line = state.line;
      if ((ch === 0x3F || ch === 0x3A) && is_WS_OR_EOL(following)) {
        if (ch === 0x3F) {
          if (atExplicitKey) {
            storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, null);
            keyTag = keyNode = valueNode = null;
          }
          detected = true;
          atExplicitKey = true;
          allowCompact = true;
        } else if (atExplicitKey) {
          atExplicitKey = false;
          allowCompact = true;
        } else {
          throwError(state, 'incomplete explicit mapping pair; a key node is missed');
        }
        state.position += 1;
        ch = following;
      } else if (composeNode(state, flowIndent, CONTEXT_FLOW_OUT, false, true)) {
        if (state.line === _line) {
          ch = state.input.charCodeAt(state.position);
          while (is_WHITE_SPACE(ch)) {
            ch = state.input.charCodeAt(++state.position);
          }
          if (ch === 0x3A) {
            ch = state.input.charCodeAt(++state.position);
            if (!is_WS_OR_EOL(ch)) {
              throwError(state, 'a whitespace character is expected after the key-value separator within a block mapping');
            }
            if (atExplicitKey) {
              storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, null);
              keyTag = keyNode = valueNode = null;
            }
            detected = true;
            atExplicitKey = false;
            allowCompact = false;
            keyTag = state.tag;
            keyNode = state.result;
          } else if (detected) {
            throwError(state, 'can not read an implicit mapping pair; a colon is missed');
          } else {
            state.tag = _tag;
            state.anchor = _anchor;
            return true;
          }
        } else if (detected) {
          throwError(state, 'can not read a block mapping entry; a multiline key may not be an implicit key');
        } else {
          state.tag = _tag;
          state.anchor = _anchor;
          return true;
        }
      } else {
        break;
      }
      if (state.line === _line || state.lineIndent > nodeIndent) {
        if (composeNode(state, nodeIndent, CONTEXT_BLOCK_OUT, true, allowCompact)) {
          if (atExplicitKey) {
            keyNode = state.result;
          } else {
            valueNode = state.result;
          }
        }
        if (!atExplicitKey) {
          storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, valueNode);
          keyTag = keyNode = valueNode = null;
        }
        skipSeparationSpace(state, true, -1);
        ch = state.input.charCodeAt(state.position);
      }
      if (state.lineIndent > nodeIndent && (ch !== 0)) {
        throwError(state, 'bad indentation of a mapping entry');
      } else if (state.lineIndent < nodeIndent) {
        break;
      }
    }
    if (atExplicitKey) {
      storeMappingPair(state, _result, overridableKeys, keyTag, keyNode, null);
    }
    if (detected) {
      state.tag = _tag;
      state.anchor = _anchor;
      state.kind = 'mapping';
      state.result = _result;
    }
    return detected;
  }
  function readTagProperty(state) {
    var _position,
        isVerbatim = false,
        isNamed = false,
        tagHandle,
        tagName,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch !== 0x21)
      return false;
    if (state.tag !== null) {
      throwError(state, 'duplication of a tag property');
    }
    ch = state.input.charCodeAt(++state.position);
    if (ch === 0x3C) {
      isVerbatim = true;
      ch = state.input.charCodeAt(++state.position);
    } else if (ch === 0x21) {
      isNamed = true;
      tagHandle = '!!';
      ch = state.input.charCodeAt(++state.position);
    } else {
      tagHandle = '!';
    }
    _position = state.position;
    if (isVerbatim) {
      do {
        ch = state.input.charCodeAt(++state.position);
      } while (ch !== 0 && ch !== 0x3E);
      if (state.position < state.length) {
        tagName = state.input.slice(_position, state.position);
        ch = state.input.charCodeAt(++state.position);
      } else {
        throwError(state, 'unexpected end of the stream within a verbatim tag');
      }
    } else {
      while (ch !== 0 && !is_WS_OR_EOL(ch)) {
        if (ch === 0x21) {
          if (!isNamed) {
            tagHandle = state.input.slice(_position - 1, state.position + 1);
            if (!PATTERN_TAG_HANDLE.test(tagHandle)) {
              throwError(state, 'named tag handle cannot contain such characters');
            }
            isNamed = true;
            _position = state.position + 1;
          } else {
            throwError(state, 'tag suffix cannot contain exclamation marks');
          }
        }
        ch = state.input.charCodeAt(++state.position);
      }
      tagName = state.input.slice(_position, state.position);
      if (PATTERN_FLOW_INDICATORS.test(tagName)) {
        throwError(state, 'tag suffix cannot contain flow indicator characters');
      }
    }
    if (tagName && !PATTERN_TAG_URI.test(tagName)) {
      throwError(state, 'tag name cannot contain such characters: ' + tagName);
    }
    if (isVerbatim) {
      state.tag = tagName;
    } else if (_hasOwnProperty.call(state.tagMap, tagHandle)) {
      state.tag = state.tagMap[tagHandle] + tagName;
    } else if (tagHandle === '!') {
      state.tag = '!' + tagName;
    } else if (tagHandle === '!!') {
      state.tag = 'tag:yaml.org,2002:' + tagName;
    } else {
      throwError(state, 'undeclared tag handle "' + tagHandle + '"');
    }
    return true;
  }
  function readAnchorProperty(state) {
    var _position,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch !== 0x26)
      return false;
    if (state.anchor !== null) {
      throwError(state, 'duplication of an anchor property');
    }
    ch = state.input.charCodeAt(++state.position);
    _position = state.position;
    while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {
      ch = state.input.charCodeAt(++state.position);
    }
    if (state.position === _position) {
      throwError(state, 'name of an anchor node must contain at least one character');
    }
    state.anchor = state.input.slice(_position, state.position);
    return true;
  }
  function readAlias(state) {
    var _position,
        alias,
        ch;
    ch = state.input.charCodeAt(state.position);
    if (ch !== 0x2A)
      return false;
    ch = state.input.charCodeAt(++state.position);
    _position = state.position;
    while (ch !== 0 && !is_WS_OR_EOL(ch) && !is_FLOW_INDICATOR(ch)) {
      ch = state.input.charCodeAt(++state.position);
    }
    if (state.position === _position) {
      throwError(state, 'name of an alias node must contain at least one character');
    }
    alias = state.input.slice(_position, state.position);
    if (!state.anchorMap.hasOwnProperty(alias)) {
      throwError(state, 'unidentified alias "' + alias + '"');
    }
    state.result = state.anchorMap[alias];
    skipSeparationSpace(state, true, -1);
    return true;
  }
  function composeNode(state, parentIndent, nodeContext, allowToSeek, allowCompact) {
    var allowBlockStyles,
        allowBlockScalars,
        allowBlockCollections,
        indentStatus = 1,
        atNewLine = false,
        hasContent = false,
        typeIndex,
        typeQuantity,
        type,
        flowIndent,
        blockIndent;
    if (state.listener !== null) {
      state.listener('open', state);
    }
    state.tag = null;
    state.anchor = null;
    state.kind = null;
    state.result = null;
    allowBlockStyles = allowBlockScalars = allowBlockCollections = CONTEXT_BLOCK_OUT === nodeContext || CONTEXT_BLOCK_IN === nodeContext;
    if (allowToSeek) {
      if (skipSeparationSpace(state, true, -1)) {
        atNewLine = true;
        if (state.lineIndent > parentIndent) {
          indentStatus = 1;
        } else if (state.lineIndent === parentIndent) {
          indentStatus = 0;
        } else if (state.lineIndent < parentIndent) {
          indentStatus = -1;
        }
      }
    }
    if (indentStatus === 1) {
      while (readTagProperty(state) || readAnchorProperty(state)) {
        if (skipSeparationSpace(state, true, -1)) {
          atNewLine = true;
          allowBlockCollections = allowBlockStyles;
          if (state.lineIndent > parentIndent) {
            indentStatus = 1;
          } else if (state.lineIndent === parentIndent) {
            indentStatus = 0;
          } else if (state.lineIndent < parentIndent) {
            indentStatus = -1;
          }
        } else {
          allowBlockCollections = false;
        }
      }
    }
    if (allowBlockCollections) {
      allowBlockCollections = atNewLine || allowCompact;
    }
    if (indentStatus === 1 || CONTEXT_BLOCK_OUT === nodeContext) {
      if (CONTEXT_FLOW_IN === nodeContext || CONTEXT_FLOW_OUT === nodeContext) {
        flowIndent = parentIndent;
      } else {
        flowIndent = parentIndent + 1;
      }
      blockIndent = state.position - state.lineStart;
      if (indentStatus === 1) {
        if (allowBlockCollections && (readBlockSequence(state, blockIndent) || readBlockMapping(state, blockIndent, flowIndent)) || readFlowCollection(state, flowIndent)) {
          hasContent = true;
        } else {
          if ((allowBlockScalars && readBlockScalar(state, flowIndent)) || readSingleQuotedScalar(state, flowIndent) || readDoubleQuotedScalar(state, flowIndent)) {
            hasContent = true;
          } else if (readAlias(state)) {
            hasContent = true;
            if (state.tag !== null || state.anchor !== null) {
              throwError(state, 'alias node should not have any properties');
            }
          } else if (readPlainScalar(state, flowIndent, CONTEXT_FLOW_IN === nodeContext)) {
            hasContent = true;
            if (state.tag === null) {
              state.tag = '?';
            }
          }
          if (state.anchor !== null) {
            state.anchorMap[state.anchor] = state.result;
          }
        }
      } else if (indentStatus === 0) {
        hasContent = allowBlockCollections && readBlockSequence(state, blockIndent);
      }
    }
    if (state.tag !== null && state.tag !== '!') {
      if (state.tag === '?') {
        for (typeIndex = 0, typeQuantity = state.implicitTypes.length; typeIndex < typeQuantity; typeIndex += 1) {
          type = state.implicitTypes[typeIndex];
          if (type.resolve(state.result)) {
            state.result = type.construct(state.result);
            state.tag = type.tag;
            if (state.anchor !== null) {
              state.anchorMap[state.anchor] = state.result;
            }
            break;
          }
        }
      } else if (_hasOwnProperty.call(state.typeMap, state.tag)) {
        type = state.typeMap[state.tag];
        if (state.result !== null && type.kind !== state.kind) {
          throwError(state, 'unacceptable node kind for !<' + state.tag + '> tag; it should be "' + type.kind + '", not "' + state.kind + '"');
        }
        if (!type.resolve(state.result)) {
          throwError(state, 'cannot resolve a node with !<' + state.tag + '> explicit tag');
        } else {
          state.result = type.construct(state.result);
          if (state.anchor !== null) {
            state.anchorMap[state.anchor] = state.result;
          }
        }
      } else {
        throwError(state, 'unknown tag !<' + state.tag + '>');
      }
    }
    if (state.listener !== null) {
      state.listener('close', state);
    }
    return state.tag !== null || state.anchor !== null || hasContent;
  }
  function readDocument(state) {
    var documentStart = state.position,
        _position,
        directiveName,
        directiveArgs,
        hasDirectives = false,
        ch;
    state.version = null;
    state.checkLineBreaks = state.legacy;
    state.tagMap = {};
    state.anchorMap = {};
    while ((ch = state.input.charCodeAt(state.position)) !== 0) {
      skipSeparationSpace(state, true, -1);
      ch = state.input.charCodeAt(state.position);
      if (state.lineIndent > 0 || ch !== 0x25) {
        break;
      }
      hasDirectives = true;
      ch = state.input.charCodeAt(++state.position);
      _position = state.position;
      while (ch !== 0 && !is_WS_OR_EOL(ch)) {
        ch = state.input.charCodeAt(++state.position);
      }
      directiveName = state.input.slice(_position, state.position);
      directiveArgs = [];
      if (directiveName.length < 1) {
        throwError(state, 'directive name must not be less than one character in length');
      }
      while (ch !== 0) {
        while (is_WHITE_SPACE(ch)) {
          ch = state.input.charCodeAt(++state.position);
        }
        if (ch === 0x23) {
          do {
            ch = state.input.charCodeAt(++state.position);
          } while (ch !== 0 && !is_EOL(ch));
          break;
        }
        if (is_EOL(ch))
          break;
        _position = state.position;
        while (ch !== 0 && !is_WS_OR_EOL(ch)) {
          ch = state.input.charCodeAt(++state.position);
        }
        directiveArgs.push(state.input.slice(_position, state.position));
      }
      if (ch !== 0)
        readLineBreak(state);
      if (_hasOwnProperty.call(directiveHandlers, directiveName)) {
        directiveHandlers[directiveName](state, directiveName, directiveArgs);
      } else {
        throwWarning(state, 'unknown document directive "' + directiveName + '"');
      }
    }
    skipSeparationSpace(state, true, -1);
    if (state.lineIndent === 0 && state.input.charCodeAt(state.position) === 0x2D && state.input.charCodeAt(state.position + 1) === 0x2D && state.input.charCodeAt(state.position + 2) === 0x2D) {
      state.position += 3;
      skipSeparationSpace(state, true, -1);
    } else if (hasDirectives) {
      throwError(state, 'directives end mark is expected');
    }
    composeNode(state, state.lineIndent - 1, CONTEXT_BLOCK_OUT, false, true);
    skipSeparationSpace(state, true, -1);
    if (state.checkLineBreaks && PATTERN_NON_ASCII_LINE_BREAKS.test(state.input.slice(documentStart, state.position))) {
      throwWarning(state, 'non-ASCII line breaks are interpreted as content');
    }
    state.documents.push(state.result);
    if (state.position === state.lineStart && testDocumentSeparator(state)) {
      if (state.input.charCodeAt(state.position) === 0x2E) {
        state.position += 3;
        skipSeparationSpace(state, true, -1);
      }
      return;
    }
    if (state.position < (state.length - 1)) {
      throwError(state, 'end of the stream or a document separator is expected');
    } else {
      return;
    }
  }
  function loadDocuments(input, options) {
    input = String(input);
    options = options || {};
    if (input.length !== 0) {
      if (input.charCodeAt(input.length - 1) !== 0x0A && input.charCodeAt(input.length - 1) !== 0x0D) {
        input += '\n';
      }
      if (input.charCodeAt(0) === 0xFEFF) {
        input = input.slice(1);
      }
    }
    var state = new State(input, options);
    state.input += '\0';
    while (state.input.charCodeAt(state.position) === 0x20) {
      state.lineIndent += 1;
      state.position += 1;
    }
    while (state.position < (state.length - 1)) {
      readDocument(state);
    }
    return state.documents;
  }
  function loadAll(input, iterator, options) {
    var documents = loadDocuments(input, options),
        index,
        length;
    for (index = 0, length = documents.length; index < length; index += 1) {
      iterator(documents[index]);
    }
  }
  function load(input, options) {
    var documents = loadDocuments(input, options);
    if (documents.length === 0) {
      return undefined;
    } else if (documents.length === 1) {
      return documents[0];
    }
    throw new YAMLException('expected a single document in the stream, but found more');
  }
  function safeLoadAll(input, output, options) {
    loadAll(input, output, common.extend({schema: DEFAULT_SAFE_SCHEMA}, options));
  }
  function safeLoad(input, options) {
    return load(input, common.extend({schema: DEFAULT_SAFE_SCHEMA}, options));
  }
  module.exports.loadAll = loadAll;
  module.exports.load = load;
  module.exports.safeLoadAll = safeLoadAll;
  module.exports.safeLoad = safeLoad;
  return module.exports;
});

$__System.registerDynamic("1dc", ["1d7", "1d9", "1db", "1da"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  var YAMLException = $__require('1d9');
  var DEFAULT_FULL_SCHEMA = $__require('1db');
  var DEFAULT_SAFE_SCHEMA = $__require('1da');
  var _toString = Object.prototype.toString;
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
  var CHAR_TAB = 0x09;
  var CHAR_LINE_FEED = 0x0A;
  var CHAR_SPACE = 0x20;
  var CHAR_EXCLAMATION = 0x21;
  var CHAR_DOUBLE_QUOTE = 0x22;
  var CHAR_SHARP = 0x23;
  var CHAR_PERCENT = 0x25;
  var CHAR_AMPERSAND = 0x26;
  var CHAR_SINGLE_QUOTE = 0x27;
  var CHAR_ASTERISK = 0x2A;
  var CHAR_COMMA = 0x2C;
  var CHAR_MINUS = 0x2D;
  var CHAR_COLON = 0x3A;
  var CHAR_GREATER_THAN = 0x3E;
  var CHAR_QUESTION = 0x3F;
  var CHAR_COMMERCIAL_AT = 0x40;
  var CHAR_LEFT_SQUARE_BRACKET = 0x5B;
  var CHAR_RIGHT_SQUARE_BRACKET = 0x5D;
  var CHAR_GRAVE_ACCENT = 0x60;
  var CHAR_LEFT_CURLY_BRACKET = 0x7B;
  var CHAR_VERTICAL_LINE = 0x7C;
  var CHAR_RIGHT_CURLY_BRACKET = 0x7D;
  var ESCAPE_SEQUENCES = {};
  ESCAPE_SEQUENCES[0x00] = '\\0';
  ESCAPE_SEQUENCES[0x07] = '\\a';
  ESCAPE_SEQUENCES[0x08] = '\\b';
  ESCAPE_SEQUENCES[0x09] = '\\t';
  ESCAPE_SEQUENCES[0x0A] = '\\n';
  ESCAPE_SEQUENCES[0x0B] = '\\v';
  ESCAPE_SEQUENCES[0x0C] = '\\f';
  ESCAPE_SEQUENCES[0x0D] = '\\r';
  ESCAPE_SEQUENCES[0x1B] = '\\e';
  ESCAPE_SEQUENCES[0x22] = '\\"';
  ESCAPE_SEQUENCES[0x5C] = '\\\\';
  ESCAPE_SEQUENCES[0x85] = '\\N';
  ESCAPE_SEQUENCES[0xA0] = '\\_';
  ESCAPE_SEQUENCES[0x2028] = '\\L';
  ESCAPE_SEQUENCES[0x2029] = '\\P';
  var DEPRECATED_BOOLEANS_SYNTAX = ['y', 'Y', 'yes', 'Yes', 'YES', 'on', 'On', 'ON', 'n', 'N', 'no', 'No', 'NO', 'off', 'Off', 'OFF'];
  function compileStyleMap(schema, map) {
    var result,
        keys,
        index,
        length,
        tag,
        style,
        type;
    if (map === null)
      return {};
    result = {};
    keys = Object.keys(map);
    for (index = 0, length = keys.length; index < length; index += 1) {
      tag = keys[index];
      style = String(map[tag]);
      if (tag.slice(0, 2) === '!!') {
        tag = 'tag:yaml.org,2002:' + tag.slice(2);
      }
      type = schema.compiledTypeMap[tag];
      if (type && _hasOwnProperty.call(type.styleAliases, style)) {
        style = type.styleAliases[style];
      }
      result[tag] = style;
    }
    return result;
  }
  function encodeHex(character) {
    var string,
        handle,
        length;
    string = character.toString(16).toUpperCase();
    if (character <= 0xFF) {
      handle = 'x';
      length = 2;
    } else if (character <= 0xFFFF) {
      handle = 'u';
      length = 4;
    } else if (character <= 0xFFFFFFFF) {
      handle = 'U';
      length = 8;
    } else {
      throw new YAMLException('code point within a string may not be greater than 0xFFFFFFFF');
    }
    return '\\' + handle + common.repeat('0', length - string.length) + string;
  }
  function State(options) {
    this.schema = options['schema'] || DEFAULT_FULL_SCHEMA;
    this.indent = Math.max(1, (options['indent'] || 2));
    this.skipInvalid = options['skipInvalid'] || false;
    this.flowLevel = (common.isNothing(options['flowLevel']) ? -1 : options['flowLevel']);
    this.styleMap = compileStyleMap(this.schema, options['styles'] || null);
    this.sortKeys = options['sortKeys'] || false;
    this.lineWidth = options['lineWidth'] || 80;
    this.noRefs = options['noRefs'] || false;
    this.noCompatMode = options['noCompatMode'] || false;
    this.implicitTypes = this.schema.compiledImplicit;
    this.explicitTypes = this.schema.compiledExplicit;
    this.tag = null;
    this.result = '';
    this.duplicates = [];
    this.usedDuplicates = null;
  }
  function indentString(string, spaces) {
    var ind = common.repeat(' ', spaces),
        position = 0,
        next = -1,
        result = '',
        line,
        length = string.length;
    while (position < length) {
      next = string.indexOf('\n', position);
      if (next === -1) {
        line = string.slice(position);
        position = length;
      } else {
        line = string.slice(position, next + 1);
        position = next + 1;
      }
      if (line.length && line !== '\n')
        result += ind;
      result += line;
    }
    return result;
  }
  function generateNextLine(state, level) {
    return '\n' + common.repeat(' ', state.indent * level);
  }
  function testImplicitResolving(state, str) {
    var index,
        length,
        type;
    for (index = 0, length = state.implicitTypes.length; index < length; index += 1) {
      type = state.implicitTypes[index];
      if (type.resolve(str)) {
        return true;
      }
    }
    return false;
  }
  function isWhitespace(c) {
    return c === CHAR_SPACE || c === CHAR_TAB;
  }
  function isPrintable(c) {
    return (0x00020 <= c && c <= 0x00007E) || ((0x000A1 <= c && c <= 0x00D7FF) && c !== 0x2028 && c !== 0x2029) || ((0x0E000 <= c && c <= 0x00FFFD) && c !== 0xFEFF) || (0x10000 <= c && c <= 0x10FFFF);
  }
  function isPlainSafe(c) {
    return isPrintable(c) && c !== 0xFEFF && c !== CHAR_COMMA && c !== CHAR_LEFT_SQUARE_BRACKET && c !== CHAR_RIGHT_SQUARE_BRACKET && c !== CHAR_LEFT_CURLY_BRACKET && c !== CHAR_RIGHT_CURLY_BRACKET && c !== CHAR_COLON && c !== CHAR_SHARP;
  }
  function isPlainSafeFirst(c) {
    return isPrintable(c) && c !== 0xFEFF && !isWhitespace(c) && c !== CHAR_MINUS && c !== CHAR_QUESTION && c !== CHAR_COLON && c !== CHAR_COMMA && c !== CHAR_LEFT_SQUARE_BRACKET && c !== CHAR_RIGHT_SQUARE_BRACKET && c !== CHAR_LEFT_CURLY_BRACKET && c !== CHAR_RIGHT_CURLY_BRACKET && c !== CHAR_SHARP && c !== CHAR_AMPERSAND && c !== CHAR_ASTERISK && c !== CHAR_EXCLAMATION && c !== CHAR_VERTICAL_LINE && c !== CHAR_GREATER_THAN && c !== CHAR_SINGLE_QUOTE && c !== CHAR_DOUBLE_QUOTE && c !== CHAR_PERCENT && c !== CHAR_COMMERCIAL_AT && c !== CHAR_GRAVE_ACCENT;
  }
  var STYLE_PLAIN = 1,
      STYLE_SINGLE = 2,
      STYLE_LITERAL = 3,
      STYLE_FOLDED = 4,
      STYLE_DOUBLE = 5;
  function chooseScalarStyle(string, singleLineOnly, indentPerLevel, lineWidth, testAmbiguousType) {
    var i;
    var char;
    var hasLineBreak = false;
    var hasFoldableLine = false;
    var shouldTrackWidth = lineWidth !== -1;
    var previousLineBreak = -1;
    var plain = isPlainSafeFirst(string.charCodeAt(0)) && !isWhitespace(string.charCodeAt(string.length - 1));
    if (singleLineOnly) {
      for (i = 0; i < string.length; i++) {
        char = string.charCodeAt(i);
        if (!isPrintable(char)) {
          return STYLE_DOUBLE;
        }
        plain = plain && isPlainSafe(char);
      }
    } else {
      for (i = 0; i < string.length; i++) {
        char = string.charCodeAt(i);
        if (char === CHAR_LINE_FEED) {
          hasLineBreak = true;
          if (shouldTrackWidth) {
            hasFoldableLine = hasFoldableLine || (i - previousLineBreak - 1 > lineWidth && string[previousLineBreak + 1] !== ' ');
            previousLineBreak = i;
          }
        } else if (!isPrintable(char)) {
          return STYLE_DOUBLE;
        }
        plain = plain && isPlainSafe(char);
      }
      hasFoldableLine = hasFoldableLine || (shouldTrackWidth && (i - previousLineBreak - 1 > lineWidth && string[previousLineBreak + 1] !== ' '));
    }
    if (!hasLineBreak && !hasFoldableLine) {
      return plain && !testAmbiguousType(string) ? STYLE_PLAIN : STYLE_SINGLE;
    }
    if (string[0] === ' ' && indentPerLevel > 9) {
      return STYLE_DOUBLE;
    }
    return hasFoldableLine ? STYLE_FOLDED : STYLE_LITERAL;
  }
  function writeScalar(state, string, level, iskey) {
    state.dump = (function() {
      if (string.length === 0) {
        return "''";
      }
      if (!state.noCompatMode && DEPRECATED_BOOLEANS_SYNTAX.indexOf(string) !== -1) {
        return "'" + string + "'";
      }
      var indent = state.indent * Math.max(1, level);
      var lineWidth = state.lineWidth === -1 ? -1 : Math.max(Math.min(state.lineWidth, 40), state.lineWidth - indent);
      var singleLineOnly = iskey || (state.flowLevel > -1 && level >= state.flowLevel);
      function testAmbiguity(string) {
        return testImplicitResolving(state, string);
      }
      switch (chooseScalarStyle(string, singleLineOnly, state.indent, lineWidth, testAmbiguity)) {
        case STYLE_PLAIN:
          return string;
        case STYLE_SINGLE:
          return "'" + string.replace(/'/g, "''") + "'";
        case STYLE_LITERAL:
          return '|' + blockHeader(string, state.indent) + dropEndingNewline(indentString(string, indent));
        case STYLE_FOLDED:
          return '>' + blockHeader(string, state.indent) + dropEndingNewline(indentString(foldString(string, lineWidth), indent));
        case STYLE_DOUBLE:
          return '"' + escapeString(string, lineWidth) + '"';
        default:
          throw new YAMLException('impossible error: invalid scalar style');
      }
    }());
  }
  function blockHeader(string, indentPerLevel) {
    var indentIndicator = (string[0] === ' ') ? String(indentPerLevel) : '';
    var clip = string[string.length - 1] === '\n';
    var keep = clip && (string[string.length - 2] === '\n' || string === '\n');
    var chomp = keep ? '+' : (clip ? '' : '-');
    return indentIndicator + chomp + '\n';
  }
  function dropEndingNewline(string) {
    return string[string.length - 1] === '\n' ? string.slice(0, -1) : string;
  }
  function foldString(string, width) {
    var lineRe = /(\n+)([^\n]*)/g;
    var result = (function() {
      var nextLF = string.indexOf('\n');
      nextLF = nextLF !== -1 ? nextLF : string.length;
      lineRe.lastIndex = nextLF;
      return foldLine(string.slice(0, nextLF), width);
    }());
    var prevMoreIndented = string[0] === '\n' || string[0] === ' ';
    var moreIndented;
    var match;
    while ((match = lineRe.exec(string))) {
      var prefix = match[1],
          line = match[2];
      moreIndented = (line[0] === ' ');
      result += prefix + (!prevMoreIndented && !moreIndented && line !== '' ? '\n' : '') + foldLine(line, width);
      prevMoreIndented = moreIndented;
    }
    return result;
  }
  function foldLine(line, width) {
    if (line === '' || line[0] === ' ')
      return line;
    var breakRe = / [^ ]/g;
    var match;
    var start = 0,
        end,
        curr = 0,
        next = 0;
    var result = '';
    while ((match = breakRe.exec(line))) {
      next = match.index;
      if (next - start > width) {
        end = (curr > start) ? curr : next;
        result += '\n' + line.slice(start, end);
        start = end + 1;
      }
      curr = next;
    }
    result += '\n';
    if (line.length - start > width && curr > start) {
      result += line.slice(start, curr) + '\n' + line.slice(curr + 1);
    } else {
      result += line.slice(start);
    }
    return result.slice(1);
  }
  function escapeString(string) {
    var result = '';
    var char;
    var escapeSeq;
    for (var i = 0; i < string.length; i++) {
      char = string.charCodeAt(i);
      escapeSeq = ESCAPE_SEQUENCES[char];
      result += !escapeSeq && isPrintable(char) ? string[i] : escapeSeq || encodeHex(char);
    }
    return result;
  }
  function writeFlowSequence(state, level, object) {
    var _result = '',
        _tag = state.tag,
        index,
        length;
    for (index = 0, length = object.length; index < length; index += 1) {
      if (writeNode(state, level, object[index], false, false)) {
        if (index !== 0)
          _result += ', ';
        _result += state.dump;
      }
    }
    state.tag = _tag;
    state.dump = '[' + _result + ']';
  }
  function writeBlockSequence(state, level, object, compact) {
    var _result = '',
        _tag = state.tag,
        index,
        length;
    for (index = 0, length = object.length; index < length; index += 1) {
      if (writeNode(state, level + 1, object[index], true, true)) {
        if (!compact || index !== 0) {
          _result += generateNextLine(state, level);
        }
        _result += '- ' + state.dump;
      }
    }
    state.tag = _tag;
    state.dump = _result || '[]';
  }
  function writeFlowMapping(state, level, object) {
    var _result = '',
        _tag = state.tag,
        objectKeyList = Object.keys(object),
        index,
        length,
        objectKey,
        objectValue,
        pairBuffer;
    for (index = 0, length = objectKeyList.length; index < length; index += 1) {
      pairBuffer = '';
      if (index !== 0)
        pairBuffer += ', ';
      objectKey = objectKeyList[index];
      objectValue = object[objectKey];
      if (!writeNode(state, level, objectKey, false, false)) {
        continue;
      }
      if (state.dump.length > 1024)
        pairBuffer += '? ';
      pairBuffer += state.dump + ': ';
      if (!writeNode(state, level, objectValue, false, false)) {
        continue;
      }
      pairBuffer += state.dump;
      _result += pairBuffer;
    }
    state.tag = _tag;
    state.dump = '{' + _result + '}';
  }
  function writeBlockMapping(state, level, object, compact) {
    var _result = '',
        _tag = state.tag,
        objectKeyList = Object.keys(object),
        index,
        length,
        objectKey,
        objectValue,
        explicitPair,
        pairBuffer;
    if (state.sortKeys === true) {
      objectKeyList.sort();
    } else if (typeof state.sortKeys === 'function') {
      objectKeyList.sort(state.sortKeys);
    } else if (state.sortKeys) {
      throw new YAMLException('sortKeys must be a boolean or a function');
    }
    for (index = 0, length = objectKeyList.length; index < length; index += 1) {
      pairBuffer = '';
      if (!compact || index !== 0) {
        pairBuffer += generateNextLine(state, level);
      }
      objectKey = objectKeyList[index];
      objectValue = object[objectKey];
      if (!writeNode(state, level + 1, objectKey, true, true, true)) {
        continue;
      }
      explicitPair = (state.tag !== null && state.tag !== '?') || (state.dump && state.dump.length > 1024);
      if (explicitPair) {
        if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0)) {
          pairBuffer += '?';
        } else {
          pairBuffer += '? ';
        }
      }
      pairBuffer += state.dump;
      if (explicitPair) {
        pairBuffer += generateNextLine(state, level);
      }
      if (!writeNode(state, level + 1, objectValue, true, explicitPair)) {
        continue;
      }
      if (state.dump && CHAR_LINE_FEED === state.dump.charCodeAt(0)) {
        pairBuffer += ':';
      } else {
        pairBuffer += ': ';
      }
      pairBuffer += state.dump;
      _result += pairBuffer;
    }
    state.tag = _tag;
    state.dump = _result || '{}';
  }
  function detectType(state, object, explicit) {
    var _result,
        typeList,
        index,
        length,
        type,
        style;
    typeList = explicit ? state.explicitTypes : state.implicitTypes;
    for (index = 0, length = typeList.length; index < length; index += 1) {
      type = typeList[index];
      if ((type.instanceOf || type.predicate) && (!type.instanceOf || ((typeof object === 'object') && (object instanceof type.instanceOf))) && (!type.predicate || type.predicate(object))) {
        state.tag = explicit ? type.tag : '?';
        if (type.represent) {
          style = state.styleMap[type.tag] || type.defaultStyle;
          if (_toString.call(type.represent) === '[object Function]') {
            _result = type.represent(object, style);
          } else if (_hasOwnProperty.call(type.represent, style)) {
            _result = type.represent[style](object, style);
          } else {
            throw new YAMLException('!<' + type.tag + '> tag resolver accepts not "' + style + '" style');
          }
          state.dump = _result;
        }
        return true;
      }
    }
    return false;
  }
  function writeNode(state, level, object, block, compact, iskey) {
    state.tag = null;
    state.dump = object;
    if (!detectType(state, object, false)) {
      detectType(state, object, true);
    }
    var type = _toString.call(state.dump);
    if (block) {
      block = (state.flowLevel < 0 || state.flowLevel > level);
    }
    var objectOrArray = type === '[object Object]' || type === '[object Array]',
        duplicateIndex,
        duplicate;
    if (objectOrArray) {
      duplicateIndex = state.duplicates.indexOf(object);
      duplicate = duplicateIndex !== -1;
    }
    if ((state.tag !== null && state.tag !== '?') || duplicate || (state.indent !== 2 && level > 0)) {
      compact = false;
    }
    if (duplicate && state.usedDuplicates[duplicateIndex]) {
      state.dump = '*ref_' + duplicateIndex;
    } else {
      if (objectOrArray && duplicate && !state.usedDuplicates[duplicateIndex]) {
        state.usedDuplicates[duplicateIndex] = true;
      }
      if (type === '[object Object]') {
        if (block && (Object.keys(state.dump).length !== 0)) {
          writeBlockMapping(state, level, state.dump, compact);
          if (duplicate) {
            state.dump = '&ref_' + duplicateIndex + state.dump;
          }
        } else {
          writeFlowMapping(state, level, state.dump);
          if (duplicate) {
            state.dump = '&ref_' + duplicateIndex + ' ' + state.dump;
          }
        }
      } else if (type === '[object Array]') {
        if (block && (state.dump.length !== 0)) {
          writeBlockSequence(state, level, state.dump, compact);
          if (duplicate) {
            state.dump = '&ref_' + duplicateIndex + state.dump;
          }
        } else {
          writeFlowSequence(state, level, state.dump);
          if (duplicate) {
            state.dump = '&ref_' + duplicateIndex + ' ' + state.dump;
          }
        }
      } else if (type === '[object String]') {
        if (state.tag !== '?') {
          writeScalar(state, state.dump, level, iskey);
        }
      } else {
        if (state.skipInvalid)
          return false;
        throw new YAMLException('unacceptable kind of an object to dump ' + type);
      }
      if (state.tag !== null && state.tag !== '?') {
        state.dump = '!<' + state.tag + '> ' + state.dump;
      }
    }
    return true;
  }
  function getDuplicateReferences(object, state) {
    var objects = [],
        duplicatesIndexes = [],
        index,
        length;
    inspectNode(object, objects, duplicatesIndexes);
    for (index = 0, length = duplicatesIndexes.length; index < length; index += 1) {
      state.duplicates.push(objects[duplicatesIndexes[index]]);
    }
    state.usedDuplicates = new Array(length);
  }
  function inspectNode(object, objects, duplicatesIndexes) {
    var objectKeyList,
        index,
        length;
    if (object !== null && typeof object === 'object') {
      index = objects.indexOf(object);
      if (index !== -1) {
        if (duplicatesIndexes.indexOf(index) === -1) {
          duplicatesIndexes.push(index);
        }
      } else {
        objects.push(object);
        if (Array.isArray(object)) {
          for (index = 0, length = object.length; index < length; index += 1) {
            inspectNode(object[index], objects, duplicatesIndexes);
          }
        } else {
          objectKeyList = Object.keys(object);
          for (index = 0, length = objectKeyList.length; index < length; index += 1) {
            inspectNode(object[objectKeyList[index]], objects, duplicatesIndexes);
          }
        }
      }
    }
  }
  function dump(input, options) {
    options = options || {};
    var state = new State(options);
    if (!state.noRefs)
      getDuplicateReferences(input, state);
    if (writeNode(state, 0, input, true, true))
      return state.dump + '\n';
    return '';
  }
  function safeDump(input, options) {
    return dump(input, common.extend({schema: DEFAULT_SAFE_SCHEMA}, options));
  }
  module.exports.dump = dump;
  module.exports.safeDump = safeDump;
  return module.exports;
});

$__System.registerDynamic("1dd", ["1d7", "1d9", "1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  var YAMLException = $__require('1d9');
  var Type = $__require('1de');
  function compileList(schema, name, result) {
    var exclude = [];
    schema.include.forEach(function(includedSchema) {
      result = compileList(includedSchema, name, result);
    });
    schema[name].forEach(function(currentType) {
      result.forEach(function(previousType, previousIndex) {
        if (previousType.tag === currentType.tag) {
          exclude.push(previousIndex);
        }
      });
      result.push(currentType);
    });
    return result.filter(function(type, index) {
      return exclude.indexOf(index) === -1;
    });
  }
  function compileMap() {
    var result = {},
        index,
        length;
    function collectType(type) {
      result[type.tag] = type;
    }
    for (index = 0, length = arguments.length; index < length; index += 1) {
      arguments[index].forEach(collectType);
    }
    return result;
  }
  function Schema(definition) {
    this.include = definition.include || [];
    this.implicit = definition.implicit || [];
    this.explicit = definition.explicit || [];
    this.implicit.forEach(function(type) {
      if (type.loadKind && type.loadKind !== 'scalar') {
        throw new YAMLException('There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.');
      }
    });
    this.compiledImplicit = compileList(this, 'implicit', []);
    this.compiledExplicit = compileList(this, 'explicit', []);
    this.compiledTypeMap = compileMap(this.compiledImplicit, this.compiledExplicit);
  }
  Schema.DEFAULT = null;
  Schema.create = function createSchema() {
    var schemas,
        types;
    switch (arguments.length) {
      case 1:
        schemas = Schema.DEFAULT;
        types = arguments[0];
        break;
      case 2:
        schemas = arguments[0];
        types = arguments[1];
        break;
      default:
        throw new YAMLException('Wrong number of arguments for Schema.create function');
    }
    schemas = common.toArray(schemas);
    types = common.toArray(types);
    if (!schemas.every(function(schema) {
      return schema instanceof Schema;
    })) {
      throw new YAMLException('Specified list of super schemas (or a single Schema object) contains a non-Schema object.');
    }
    if (!types.every(function(type) {
      return type instanceof Type;
    })) {
      throw new YAMLException('Specified list of YAML types (or a single Type object) contains a non-Type object.');
    }
    return new Schema({
      include: schemas,
      explicit: types
    });
  };
  module.exports = Schema;
  return module.exports;
});

$__System.registerDynamic("1df", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  module.exports = new Type('tag:yaml.org,2002:str', {
    kind: 'scalar',
    construct: function(data) {
      return data !== null ? data : '';
    }
  });
  return module.exports;
});

$__System.registerDynamic("1e0", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  module.exports = new Type('tag:yaml.org,2002:seq', {
    kind: 'sequence',
    construct: function(data) {
      return data !== null ? data : [];
    }
  });
  return module.exports;
});

$__System.registerDynamic("1e1", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  module.exports = new Type('tag:yaml.org,2002:map', {
    kind: 'mapping',
    construct: function(data) {
      return data !== null ? data : {};
    }
  });
  return module.exports;
});

$__System.registerDynamic("1e2", ["1dd", "1df", "1e0", "1e1"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Schema = $__require('1dd');
  module.exports = new Schema({explicit: [$__require('1df'), $__require('1e0'), $__require('1e1')]});
  return module.exports;
});

$__System.registerDynamic("1e3", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  function resolveYamlNull(data) {
    if (data === null)
      return true;
    var max = data.length;
    return (max === 1 && data === '~') || (max === 4 && (data === 'null' || data === 'Null' || data === 'NULL'));
  }
  function constructYamlNull() {
    return null;
  }
  function isNull(object) {
    return object === null;
  }
  module.exports = new Type('tag:yaml.org,2002:null', {
    kind: 'scalar',
    resolve: resolveYamlNull,
    construct: constructYamlNull,
    predicate: isNull,
    represent: {
      canonical: function() {
        return '~';
      },
      lowercase: function() {
        return 'null';
      },
      uppercase: function() {
        return 'NULL';
      },
      camelcase: function() {
        return 'Null';
      }
    },
    defaultStyle: 'lowercase'
  });
  return module.exports;
});

$__System.registerDynamic("1e4", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  function resolveYamlBoolean(data) {
    if (data === null)
      return false;
    var max = data.length;
    return (max === 4 && (data === 'true' || data === 'True' || data === 'TRUE')) || (max === 5 && (data === 'false' || data === 'False' || data === 'FALSE'));
  }
  function constructYamlBoolean(data) {
    return data === 'true' || data === 'True' || data === 'TRUE';
  }
  function isBoolean(object) {
    return Object.prototype.toString.call(object) === '[object Boolean]';
  }
  module.exports = new Type('tag:yaml.org,2002:bool', {
    kind: 'scalar',
    resolve: resolveYamlBoolean,
    construct: constructYamlBoolean,
    predicate: isBoolean,
    represent: {
      lowercase: function(object) {
        return object ? 'true' : 'false';
      },
      uppercase: function(object) {
        return object ? 'TRUE' : 'FALSE';
      },
      camelcase: function(object) {
        return object ? 'True' : 'False';
      }
    },
    defaultStyle: 'lowercase'
  });
  return module.exports;
});

$__System.registerDynamic("1e5", ["1d7", "1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  var Type = $__require('1de');
  function isHexCode(c) {
    return ((0x30 <= c) && (c <= 0x39)) || ((0x41 <= c) && (c <= 0x46)) || ((0x61 <= c) && (c <= 0x66));
  }
  function isOctCode(c) {
    return ((0x30 <= c) && (c <= 0x37));
  }
  function isDecCode(c) {
    return ((0x30 <= c) && (c <= 0x39));
  }
  function resolveYamlInteger(data) {
    if (data === null)
      return false;
    var max = data.length,
        index = 0,
        hasDigits = false,
        ch;
    if (!max)
      return false;
    ch = data[index];
    if (ch === '-' || ch === '+') {
      ch = data[++index];
    }
    if (ch === '0') {
      if (index + 1 === max)
        return true;
      ch = data[++index];
      if (ch === 'b') {
        index++;
        for (; index < max; index++) {
          ch = data[index];
          if (ch === '_')
            continue;
          if (ch !== '0' && ch !== '1')
            return false;
          hasDigits = true;
        }
        return hasDigits;
      }
      if (ch === 'x') {
        index++;
        for (; index < max; index++) {
          ch = data[index];
          if (ch === '_')
            continue;
          if (!isHexCode(data.charCodeAt(index)))
            return false;
          hasDigits = true;
        }
        return hasDigits;
      }
      for (; index < max; index++) {
        ch = data[index];
        if (ch === '_')
          continue;
        if (!isOctCode(data.charCodeAt(index)))
          return false;
        hasDigits = true;
      }
      return hasDigits;
    }
    for (; index < max; index++) {
      ch = data[index];
      if (ch === '_')
        continue;
      if (ch === ':')
        break;
      if (!isDecCode(data.charCodeAt(index))) {
        return false;
      }
      hasDigits = true;
    }
    if (!hasDigits)
      return false;
    if (ch !== ':')
      return true;
    return /^(:[0-5]?[0-9])+$/.test(data.slice(index));
  }
  function constructYamlInteger(data) {
    var value = data,
        sign = 1,
        ch,
        base,
        digits = [];
    if (value.indexOf('_') !== -1) {
      value = value.replace(/_/g, '');
    }
    ch = value[0];
    if (ch === '-' || ch === '+') {
      if (ch === '-')
        sign = -1;
      value = value.slice(1);
      ch = value[0];
    }
    if (value === '0')
      return 0;
    if (ch === '0') {
      if (value[1] === 'b')
        return sign * parseInt(value.slice(2), 2);
      if (value[1] === 'x')
        return sign * parseInt(value, 16);
      return sign * parseInt(value, 8);
    }
    if (value.indexOf(':') !== -1) {
      value.split(':').forEach(function(v) {
        digits.unshift(parseInt(v, 10));
      });
      value = 0;
      base = 1;
      digits.forEach(function(d) {
        value += (d * base);
        base *= 60;
      });
      return sign * value;
    }
    return sign * parseInt(value, 10);
  }
  function isInteger(object) {
    return (Object.prototype.toString.call(object)) === '[object Number]' && (object % 1 === 0 && !common.isNegativeZero(object));
  }
  module.exports = new Type('tag:yaml.org,2002:int', {
    kind: 'scalar',
    resolve: resolveYamlInteger,
    construct: constructYamlInteger,
    predicate: isInteger,
    represent: {
      binary: function(object) {
        return '0b' + object.toString(2);
      },
      octal: function(object) {
        return '0' + object.toString(8);
      },
      decimal: function(object) {
        return object.toString(10);
      },
      hexadecimal: function(object) {
        return '0x' + object.toString(16).toUpperCase();
      }
    },
    defaultStyle: 'decimal',
    styleAliases: {
      binary: [2, 'bin'],
      octal: [8, 'oct'],
      decimal: [10, 'dec'],
      hexadecimal: [16, 'hex']
    }
  });
  return module.exports;
});

$__System.registerDynamic("1d7", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function isNothing(subject) {
    return (typeof subject === 'undefined') || (subject === null);
  }
  function isObject(subject) {
    return (typeof subject === 'object') && (subject !== null);
  }
  function toArray(sequence) {
    if (Array.isArray(sequence))
      return sequence;
    else if (isNothing(sequence))
      return [];
    return [sequence];
  }
  function extend(target, source) {
    var index,
        length,
        key,
        sourceKeys;
    if (source) {
      sourceKeys = Object.keys(source);
      for (index = 0, length = sourceKeys.length; index < length; index += 1) {
        key = sourceKeys[index];
        target[key] = source[key];
      }
    }
    return target;
  }
  function repeat(string, count) {
    var result = '',
        cycle;
    for (cycle = 0; cycle < count; cycle += 1) {
      result += string;
    }
    return result;
  }
  function isNegativeZero(number) {
    return (number === 0) && (Number.NEGATIVE_INFINITY === 1 / number);
  }
  module.exports.isNothing = isNothing;
  module.exports.isObject = isObject;
  module.exports.toArray = toArray;
  module.exports.repeat = repeat;
  module.exports.isNegativeZero = isNegativeZero;
  module.exports.extend = extend;
  return module.exports;
});

$__System.registerDynamic("1e6", ["1d7", "1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var common = $__require('1d7');
  var Type = $__require('1de');
  var YAML_FLOAT_PATTERN = new RegExp('^(?:[-+]?(?:[0-9][0-9_]*)\\.[0-9_]*(?:[eE][-+][0-9]+)?' + '|\\.[0-9_]+(?:[eE][-+][0-9]+)?' + '|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*' + '|[-+]?\\.(?:inf|Inf|INF)' + '|\\.(?:nan|NaN|NAN))$');
  function resolveYamlFloat(data) {
    if (data === null)
      return false;
    if (!YAML_FLOAT_PATTERN.test(data))
      return false;
    return true;
  }
  function constructYamlFloat(data) {
    var value,
        sign,
        base,
        digits;
    value = data.replace(/_/g, '').toLowerCase();
    sign = value[0] === '-' ? -1 : 1;
    digits = [];
    if ('+-'.indexOf(value[0]) >= 0) {
      value = value.slice(1);
    }
    if (value === '.inf') {
      return (sign === 1) ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY;
    } else if (value === '.nan') {
      return NaN;
    } else if (value.indexOf(':') >= 0) {
      value.split(':').forEach(function(v) {
        digits.unshift(parseFloat(v, 10));
      });
      value = 0.0;
      base = 1;
      digits.forEach(function(d) {
        value += d * base;
        base *= 60;
      });
      return sign * value;
    }
    return sign * parseFloat(value, 10);
  }
  var SCIENTIFIC_WITHOUT_DOT = /^[-+]?[0-9]+e/;
  function representYamlFloat(object, style) {
    var res;
    if (isNaN(object)) {
      switch (style) {
        case 'lowercase':
          return '.nan';
        case 'uppercase':
          return '.NAN';
        case 'camelcase':
          return '.NaN';
      }
    } else if (Number.POSITIVE_INFINITY === object) {
      switch (style) {
        case 'lowercase':
          return '.inf';
        case 'uppercase':
          return '.INF';
        case 'camelcase':
          return '.Inf';
      }
    } else if (Number.NEGATIVE_INFINITY === object) {
      switch (style) {
        case 'lowercase':
          return '-.inf';
        case 'uppercase':
          return '-.INF';
        case 'camelcase':
          return '-.Inf';
      }
    } else if (common.isNegativeZero(object)) {
      return '-0.0';
    }
    res = object.toString(10);
    return SCIENTIFIC_WITHOUT_DOT.test(res) ? res.replace('e', '.e') : res;
  }
  function isFloat(object) {
    return (Object.prototype.toString.call(object) === '[object Number]') && (object % 1 !== 0 || common.isNegativeZero(object));
  }
  module.exports = new Type('tag:yaml.org,2002:float', {
    kind: 'scalar',
    resolve: resolveYamlFloat,
    construct: constructYamlFloat,
    predicate: isFloat,
    represent: representYamlFloat,
    defaultStyle: 'lowercase'
  });
  return module.exports;
});

$__System.registerDynamic("1e7", ["1dd", "1e2", "1e3", "1e4", "1e5", "1e6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Schema = $__require('1dd');
  module.exports = new Schema({
    include: [$__require('1e2')],
    implicit: [$__require('1e3'), $__require('1e4'), $__require('1e5'), $__require('1e6')]
  });
  return module.exports;
});

$__System.registerDynamic("1e8", ["1dd", "1e7"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Schema = $__require('1dd');
  module.exports = new Schema({include: [$__require('1e7')]});
  return module.exports;
});

$__System.registerDynamic("1e9", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  var YAML_DATE_REGEXP = new RegExp('^([0-9][0-9][0-9][0-9])' + '-([0-9][0-9])' + '-([0-9][0-9])$');
  var YAML_TIMESTAMP_REGEXP = new RegExp('^([0-9][0-9][0-9][0-9])' + '-([0-9][0-9]?)' + '-([0-9][0-9]?)' + '(?:[Tt]|[ \\t]+)' + '([0-9][0-9]?)' + ':([0-9][0-9])' + ':([0-9][0-9])' + '(?:\\.([0-9]*))?' + '(?:[ \\t]*(Z|([-+])([0-9][0-9]?)' + '(?::([0-9][0-9]))?))?$');
  function resolveYamlTimestamp(data) {
    if (data === null)
      return false;
    if (YAML_DATE_REGEXP.exec(data) !== null)
      return true;
    if (YAML_TIMESTAMP_REGEXP.exec(data) !== null)
      return true;
    return false;
  }
  function constructYamlTimestamp(data) {
    var match,
        year,
        month,
        day,
        hour,
        minute,
        second,
        fraction = 0,
        delta = null,
        tz_hour,
        tz_minute,
        date;
    match = YAML_DATE_REGEXP.exec(data);
    if (match === null)
      match = YAML_TIMESTAMP_REGEXP.exec(data);
    if (match === null)
      throw new Error('Date resolve error');
    year = +(match[1]);
    month = +(match[2]) - 1;
    day = +(match[3]);
    if (!match[4]) {
      return new Date(Date.UTC(year, month, day));
    }
    hour = +(match[4]);
    minute = +(match[5]);
    second = +(match[6]);
    if (match[7]) {
      fraction = match[7].slice(0, 3);
      while (fraction.length < 3) {
        fraction += '0';
      }
      fraction = +fraction;
    }
    if (match[9]) {
      tz_hour = +(match[10]);
      tz_minute = +(match[11] || 0);
      delta = (tz_hour * 60 + tz_minute) * 60000;
      if (match[9] === '-')
        delta = -delta;
    }
    date = new Date(Date.UTC(year, month, day, hour, minute, second, fraction));
    if (delta)
      date.setTime(date.getTime() - delta);
    return date;
  }
  function representYamlTimestamp(object) {
    return object.toISOString();
  }
  module.exports = new Type('tag:yaml.org,2002:timestamp', {
    kind: 'scalar',
    resolve: resolveYamlTimestamp,
    construct: constructYamlTimestamp,
    instanceOf: Date,
    represent: representYamlTimestamp
  });
  return module.exports;
});

$__System.registerDynamic("1ea", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  function resolveYamlMerge(data) {
    return data === '<<' || data === null;
  }
  module.exports = new Type('tag:yaml.org,2002:merge', {
    kind: 'scalar',
    resolve: resolveYamlMerge
  });
  return module.exports;
});

$__System.registerDynamic("1eb", ["1de", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var NodeBuffer;
    try {
      var _require = $__require;
      NodeBuffer = _require('buffer').Buffer;
    } catch (__) {}
    var Type = $__require('1de');
    var BASE64_MAP = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r';
    function resolveYamlBinary(data) {
      if (data === null)
        return false;
      var code,
          idx,
          bitlen = 0,
          max = data.length,
          map = BASE64_MAP;
      for (idx = 0; idx < max; idx++) {
        code = map.indexOf(data.charAt(idx));
        if (code > 64)
          continue;
        if (code < 0)
          return false;
        bitlen += 6;
      }
      return (bitlen % 8) === 0;
    }
    function constructYamlBinary(data) {
      var idx,
          tailbits,
          input = data.replace(/[\r\n=]/g, ''),
          max = input.length,
          map = BASE64_MAP,
          bits = 0,
          result = [];
      for (idx = 0; idx < max; idx++) {
        if ((idx % 4 === 0) && idx) {
          result.push((bits >> 16) & 0xFF);
          result.push((bits >> 8) & 0xFF);
          result.push(bits & 0xFF);
        }
        bits = (bits << 6) | map.indexOf(input.charAt(idx));
      }
      tailbits = (max % 4) * 6;
      if (tailbits === 0) {
        result.push((bits >> 16) & 0xFF);
        result.push((bits >> 8) & 0xFF);
        result.push(bits & 0xFF);
      } else if (tailbits === 18) {
        result.push((bits >> 10) & 0xFF);
        result.push((bits >> 2) & 0xFF);
      } else if (tailbits === 12) {
        result.push((bits >> 4) & 0xFF);
      }
      if (NodeBuffer)
        return new NodeBuffer(result);
      return result;
    }
    function representYamlBinary(object) {
      var result = '',
          bits = 0,
          idx,
          tail,
          max = object.length,
          map = BASE64_MAP;
      for (idx = 0; idx < max; idx++) {
        if ((idx % 3 === 0) && idx) {
          result += map[(bits >> 18) & 0x3F];
          result += map[(bits >> 12) & 0x3F];
          result += map[(bits >> 6) & 0x3F];
          result += map[bits & 0x3F];
        }
        bits = (bits << 8) + object[idx];
      }
      tail = max % 3;
      if (tail === 0) {
        result += map[(bits >> 18) & 0x3F];
        result += map[(bits >> 12) & 0x3F];
        result += map[(bits >> 6) & 0x3F];
        result += map[bits & 0x3F];
      } else if (tail === 2) {
        result += map[(bits >> 10) & 0x3F];
        result += map[(bits >> 4) & 0x3F];
        result += map[(bits << 2) & 0x3F];
        result += map[64];
      } else if (tail === 1) {
        result += map[(bits >> 2) & 0x3F];
        result += map[(bits << 4) & 0x3F];
        result += map[64];
        result += map[64];
      }
      return result;
    }
    function isBinary(object) {
      return NodeBuffer && NodeBuffer.isBuffer(object);
    }
    module.exports = new Type('tag:yaml.org,2002:binary', {
      kind: 'scalar',
      resolve: resolveYamlBinary,
      construct: constructYamlBinary,
      predicate: isBinary,
      represent: representYamlBinary
    });
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("1ec", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
  var _toString = Object.prototype.toString;
  function resolveYamlOmap(data) {
    if (data === null)
      return true;
    var objectKeys = [],
        index,
        length,
        pair,
        pairKey,
        pairHasKey,
        object = data;
    for (index = 0, length = object.length; index < length; index += 1) {
      pair = object[index];
      pairHasKey = false;
      if (_toString.call(pair) !== '[object Object]')
        return false;
      for (pairKey in pair) {
        if (_hasOwnProperty.call(pair, pairKey)) {
          if (!pairHasKey)
            pairHasKey = true;
          else
            return false;
        }
      }
      if (!pairHasKey)
        return false;
      if (objectKeys.indexOf(pairKey) === -1)
        objectKeys.push(pairKey);
      else
        return false;
    }
    return true;
  }
  function constructYamlOmap(data) {
    return data !== null ? data : [];
  }
  module.exports = new Type('tag:yaml.org,2002:omap', {
    kind: 'sequence',
    resolve: resolveYamlOmap,
    construct: constructYamlOmap
  });
  return module.exports;
});

$__System.registerDynamic("1ed", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  var _toString = Object.prototype.toString;
  function resolveYamlPairs(data) {
    if (data === null)
      return true;
    var index,
        length,
        pair,
        keys,
        result,
        object = data;
    result = new Array(object.length);
    for (index = 0, length = object.length; index < length; index += 1) {
      pair = object[index];
      if (_toString.call(pair) !== '[object Object]')
        return false;
      keys = Object.keys(pair);
      if (keys.length !== 1)
        return false;
      result[index] = [keys[0], pair[keys[0]]];
    }
    return true;
  }
  function constructYamlPairs(data) {
    if (data === null)
      return [];
    var index,
        length,
        pair,
        keys,
        result,
        object = data;
    result = new Array(object.length);
    for (index = 0, length = object.length; index < length; index += 1) {
      pair = object[index];
      keys = Object.keys(pair);
      result[index] = [keys[0], pair[keys[0]]];
    }
    return result;
  }
  module.exports = new Type('tag:yaml.org,2002:pairs', {
    kind: 'sequence',
    resolve: resolveYamlPairs,
    construct: constructYamlPairs
  });
  return module.exports;
});

$__System.registerDynamic("1ee", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  var _hasOwnProperty = Object.prototype.hasOwnProperty;
  function resolveYamlSet(data) {
    if (data === null)
      return true;
    var key,
        object = data;
    for (key in object) {
      if (_hasOwnProperty.call(object, key)) {
        if (object[key] !== null)
          return false;
      }
    }
    return true;
  }
  function constructYamlSet(data) {
    return data !== null ? data : {};
  }
  module.exports = new Type('tag:yaml.org,2002:set', {
    kind: 'mapping',
    resolve: resolveYamlSet,
    construct: constructYamlSet
  });
  return module.exports;
});

$__System.registerDynamic("1da", ["1dd", "1e8", "1e9", "1ea", "1eb", "1ec", "1ed", "1ee"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Schema = $__require('1dd');
  module.exports = new Schema({
    include: [$__require('1e8')],
    implicit: [$__require('1e9'), $__require('1ea')],
    explicit: [$__require('1eb'), $__require('1ec'), $__require('1ed'), $__require('1ee')]
  });
  return module.exports;
});

$__System.registerDynamic("1ef", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  function resolveJavascriptUndefined() {
    return true;
  }
  function constructJavascriptUndefined() {
    return undefined;
  }
  function representJavascriptUndefined() {
    return '';
  }
  function isUndefined(object) {
    return typeof object === 'undefined';
  }
  module.exports = new Type('tag:yaml.org,2002:js/undefined', {
    kind: 'scalar',
    resolve: resolveJavascriptUndefined,
    construct: constructJavascriptUndefined,
    predicate: isUndefined,
    represent: representJavascriptUndefined
  });
  return module.exports;
});

$__System.registerDynamic("1f0", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Type = $__require('1de');
  function resolveJavascriptRegExp(data) {
    if (data === null)
      return false;
    if (data.length === 0)
      return false;
    var regexp = data,
        tail = /\/([gim]*)$/.exec(data),
        modifiers = '';
    if (regexp[0] === '/') {
      if (tail)
        modifiers = tail[1];
      if (modifiers.length > 3)
        return false;
      if (regexp[regexp.length - modifiers.length - 1] !== '/')
        return false;
    }
    return true;
  }
  function constructJavascriptRegExp(data) {
    var regexp = data,
        tail = /\/([gim]*)$/.exec(data),
        modifiers = '';
    if (regexp[0] === '/') {
      if (tail)
        modifiers = tail[1];
      regexp = regexp.slice(1, regexp.length - modifiers.length - 1);
    }
    return new RegExp(regexp, modifiers);
  }
  function representJavascriptRegExp(object) {
    var result = '/' + object.source + '/';
    if (object.global)
      result += 'g';
    if (object.multiline)
      result += 'm';
    if (object.ignoreCase)
      result += 'i';
    return result;
  }
  function isRegExp(object) {
    return Object.prototype.toString.call(object) === '[object RegExp]';
  }
  module.exports = new Type('tag:yaml.org,2002:js/regexp', {
    kind: 'scalar',
    resolve: resolveJavascriptRegExp,
    construct: constructJavascriptRegExp,
    predicate: isRegExp,
    represent: representJavascriptRegExp
  });
  return module.exports;
});

$__System.registerDynamic("1de", ["1d9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var YAMLException = $__require('1d9');
  var TYPE_CONSTRUCTOR_OPTIONS = ['kind', 'resolve', 'construct', 'instanceOf', 'predicate', 'represent', 'defaultStyle', 'styleAliases'];
  var YAML_NODE_KINDS = ['scalar', 'sequence', 'mapping'];
  function compileStyleAliases(map) {
    var result = {};
    if (map !== null) {
      Object.keys(map).forEach(function(style) {
        map[style].forEach(function(alias) {
          result[String(alias)] = style;
        });
      });
    }
    return result;
  }
  function Type(tag, options) {
    options = options || {};
    Object.keys(options).forEach(function(name) {
      if (TYPE_CONSTRUCTOR_OPTIONS.indexOf(name) === -1) {
        throw new YAMLException('Unknown option "' + name + '" is met in definition of "' + tag + '" YAML type.');
      }
    });
    this.tag = tag;
    this.kind = options['kind'] || null;
    this.resolve = options['resolve'] || function() {
      return true;
    };
    this.construct = options['construct'] || function(data) {
      return data;
    };
    this.instanceOf = options['instanceOf'] || null;
    this.predicate = options['predicate'] || null;
    this.represent = options['represent'] || null;
    this.defaultStyle = options['defaultStyle'] || null;
    this.styleAliases = compileStyleAliases(options['styleAliases'] || null);
    if (YAML_NODE_KINDS.indexOf(this.kind) === -1) {
      throw new YAMLException('Unknown kind "' + this.kind + '" is specified for "' + tag + '" YAML type.');
    }
  }
  module.exports = Type;
  return module.exports;
});

$__System.registerDynamic("1f1", ["1de"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var esprima;
  try {
    var _require = $__require;
    esprima = _require('esprima');
  } catch (_) {
    if (typeof window !== 'undefined')
      esprima = window.esprima;
  }
  var Type = $__require('1de');
  function resolveJavascriptFunction(data) {
    if (data === null)
      return false;
    try {
      var source = '(' + data + ')',
          ast = esprima.parse(source, {range: true});
      if (ast.type !== 'Program' || ast.body.length !== 1 || ast.body[0].type !== 'ExpressionStatement' || ast.body[0].expression.type !== 'FunctionExpression') {
        return false;
      }
      return true;
    } catch (err) {
      return false;
    }
  }
  function constructJavascriptFunction(data) {
    var source = '(' + data + ')',
        ast = esprima.parse(source, {range: true}),
        params = [],
        body;
    if (ast.type !== 'Program' || ast.body.length !== 1 || ast.body[0].type !== 'ExpressionStatement' || ast.body[0].expression.type !== 'FunctionExpression') {
      throw new Error('Failed to resolve function');
    }
    ast.body[0].expression.params.forEach(function(param) {
      params.push(param.name);
    });
    body = ast.body[0].expression.body.range;
    return new Function(params, source.slice(body[0] + 1, body[1] - 1));
  }
  function representJavascriptFunction(object) {
    return object.toString();
  }
  function isFunction(object) {
    return Object.prototype.toString.call(object) === '[object Function]';
  }
  module.exports = new Type('tag:yaml.org,2002:js/function', {
    kind: 'scalar',
    resolve: resolveJavascriptFunction,
    construct: constructJavascriptFunction,
    predicate: isFunction,
    represent: representJavascriptFunction
  });
  return module.exports;
});

$__System.registerDynamic("1db", ["1dd", "1da", "1ef", "1f0", "1f1"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Schema = $__require('1dd');
  module.exports = Schema.DEFAULT = new Schema({
    include: [$__require('1da')],
    explicit: [$__require('1ef'), $__require('1f0'), $__require('1f1')]
  });
  return module.exports;
});

$__System.registerDynamic("1d9", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function YAMLException(reason, mark) {
    Error.call(this);
    if (Error.captureStackTrace) {
      Error.captureStackTrace(this, this.constructor);
    } else {
      this.stack = (new Error()).stack || '';
    }
    this.name = 'YAMLException';
    this.reason = reason;
    this.mark = mark;
    this.message = (this.reason || '(unknown reason)') + (this.mark ? ' ' + this.mark.toString() : '');
  }
  YAMLException.prototype = Object.create(Error.prototype);
  YAMLException.prototype.constructor = YAMLException;
  YAMLException.prototype.toString = function toString(compact) {
    var result = this.name + ': ';
    result += this.reason || '(unknown reason)';
    if (!compact && this.mark) {
      result += ' ' + this.mark.toString();
    }
    return result;
  };
  module.exports = YAMLException;
  return module.exports;
});

$__System.registerDynamic("1f2", ["1d8", "1dc", "1de", "1dd", "1e2", "1e7", "1e8", "1da", "1db", "1d9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var loader = $__require('1d8');
  var dumper = $__require('1dc');
  function deprecated(name) {
    return function() {
      throw new Error('Function ' + name + ' is deprecated and cannot be used.');
    };
  }
  module.exports.Type = $__require('1de');
  module.exports.Schema = $__require('1dd');
  module.exports.FAILSAFE_SCHEMA = $__require('1e2');
  module.exports.JSON_SCHEMA = $__require('1e7');
  module.exports.CORE_SCHEMA = $__require('1e8');
  module.exports.DEFAULT_SAFE_SCHEMA = $__require('1da');
  module.exports.DEFAULT_FULL_SCHEMA = $__require('1db');
  module.exports.load = loader.load;
  module.exports.loadAll = loader.loadAll;
  module.exports.safeLoad = loader.safeLoad;
  module.exports.safeLoadAll = loader.safeLoadAll;
  module.exports.dump = dumper.dump;
  module.exports.safeDump = dumper.safeDump;
  module.exports.YAMLException = $__require('1d9');
  module.exports.MINIMAL_SCHEMA = $__require('1e2');
  module.exports.SAFE_SCHEMA = $__require('1da');
  module.exports.DEFAULT_SCHEMA = $__require('1db');
  module.exports.scan = deprecated('scan');
  module.exports.parse = deprecated('parse');
  module.exports.compose = deprecated('compose');
  module.exports.addConstructor = deprecated('addConstructor');
  return module.exports;
});

$__System.registerDynamic("1f3", ["1f2"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var yaml = $__require('1f2');
  module.exports = yaml;
  return module.exports;
});

$__System.registerDynamic("1f4", ["1f3"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1f3');
  return module.exports;
});

$__System.registerDynamic("187", ["1f4", "179"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var yaml = $__require('1f4'),
      ono = $__require('179');
  module.exports = {
    parse: function yamlParse(text, reviver) {
      try {
        return yaml.safeLoad(text);
      } catch (e) {
        if (e instanceof Error) {
          throw e;
        } else {
          throw ono(e, e.message);
        }
      }
    },
    stringify: function yamlStringify(value, replacer, space) {
      try {
        var indent = (typeof space === 'string' ? space.length : space) || 2;
        return yaml.safeDump(value, {indent: indent});
      } catch (e) {
        if (e instanceof Error) {
          throw e;
        } else {
          throw ono(e, e.message);
        }
      }
    }
  };
  return module.exports;
});

$__System.registerDynamic("1f5", ["184", "180", "1cc", "1d0", "1d1", "1d3", "1f6", "18d", "1d5", "179", "187", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    var Promise = $__require('184'),
        Options = $__require('180'),
        $Refs = $__require('1cc'),
        parse = $__require('1d0'),
        resolveExternal = $__require('1d1'),
        bundle = $__require('1d3'),
        dereference = $__require('1f6'),
        url = $__require('18d'),
        maybe = $__require('1d5'),
        ono = $__require('179');
    module.exports = $RefParser;
    module.exports.YAML = $__require('187');
    function $RefParser() {
      this.schema = null;
      this.$refs = new $Refs();
    }
    $RefParser.parse = function(schema, options, callback) {
      var Class = this;
      var instance = new Class();
      return instance.parse.apply(instance, arguments);
    };
    $RefParser.prototype.parse = function(schema, options, callback) {
      var args = normalizeArgs(arguments);
      var promise;
      if (!args.path && !args.schema) {
        var err = ono('Expected a file path, URL, or object. Got %s', args.path || args.schema);
        return maybe(args.callback, Promise.reject(err));
      }
      this.schema = null;
      this.$refs = new $Refs();
      if (url.isFileSystemPath(args.path)) {
        args.path = url.fromFileSystemPath(args.path);
      }
      args.path = url.resolve(url.cwd(), args.path);
      if (args.schema && typeof args.schema === 'object') {
        this.$refs._add(args.path, args.schema);
        promise = Promise.resolve(args.schema);
      } else {
        promise = parse(args.path, this.$refs, args.options);
      }
      var me = this;
      return promise.then(function(result) {
        if (!result || typeof result !== 'object' || Buffer.isBuffer(result)) {
          throw ono.syntax('"%s" is not a valid JSON Schema', me.$refs._root$Ref.path || result);
        } else {
          me.schema = result;
          return maybe(args.callback, Promise.resolve(me.schema));
        }
      }).catch(function(e) {
        return maybe(args.callback, Promise.reject(e));
      });
    };
    $RefParser.resolve = function(schema, options, callback) {
      var Class = this;
      var instance = new Class();
      return instance.resolve.apply(instance, arguments);
    };
    $RefParser.prototype.resolve = function(schema, options, callback) {
      var me = this;
      var args = normalizeArgs(arguments);
      return this.parse(args.path, args.schema, args.options).then(function() {
        return resolveExternal(me, args.options);
      }).then(function() {
        return maybe(args.callback, Promise.resolve(me.$refs));
      }).catch(function(err) {
        return maybe(args.callback, Promise.reject(err));
      });
    };
    $RefParser.bundle = function(schema, options, callback) {
      var Class = this;
      var instance = new Class();
      return instance.bundle.apply(instance, arguments);
    };
    $RefParser.prototype.bundle = function(schema, options, callback) {
      var me = this;
      var args = normalizeArgs(arguments);
      return this.resolve(args.path, args.schema, args.options).then(function() {
        bundle(me, args.options);
        return maybe(args.callback, Promise.resolve(me.schema));
      }).catch(function(err) {
        return maybe(args.callback, Promise.reject(err));
      });
    };
    $RefParser.dereference = function(schema, options, callback) {
      var Class = this;
      var instance = new Class();
      return instance.dereference.apply(instance, arguments);
    };
    $RefParser.prototype.dereference = function(schema, options, callback) {
      var me = this;
      var args = normalizeArgs(arguments);
      return this.resolve(args.path, args.schema, args.options).then(function() {
        dereference(me, args.options);
        return maybe(args.callback, Promise.resolve(me.schema));
      }).catch(function(err) {
        return maybe(args.callback, Promise.reject(err));
      });
    };
    function normalizeArgs(args) {
      var path,
          schema,
          options,
          callback;
      args = Array.prototype.slice.call(args);
      if (typeof args[args.length - 1] === 'function') {
        callback = args.pop();
      }
      if (typeof args[0] === 'string') {
        path = args[0];
        if (typeof args[2] === 'object') {
          schema = args[1];
          options = args[2];
        } else {
          schema = undefined;
          options = args[1];
        }
      } else {
        path = '';
        schema = args[0];
        options = args[1];
      }
      if (!(options instanceof Options)) {
        options = new Options(options);
      }
      return {
        path: path,
        schema: schema,
        options: options,
        callback: callback
      };
    }
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("1f7", ["1f5"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1f5');
  return module.exports;
});

$__System.registerDynamic("1cd", ["1d2", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    module.exports = $Ref;
    var Pointer = $__require('1d2');
    function $Ref() {
      this.path = undefined;
      this.value = undefined;
      this.$refs = undefined;
      this.pathType = undefined;
    }
    $Ref.prototype.exists = function(path, options) {
      try {
        this.resolve(path, options);
        return true;
      } catch (e) {
        return false;
      }
    };
    $Ref.prototype.get = function(path, options) {
      return this.resolve(path, options).value;
    };
    $Ref.prototype.resolve = function(path, options) {
      var pointer = new Pointer(this, path);
      return pointer.resolve(this.value, options);
    };
    $Ref.prototype.set = function(path, value) {
      var pointer = new Pointer(this, path);
      this.value = pointer.set(this.value, value);
    };
    $Ref.is$Ref = function(value) {
      return value && typeof value === 'object' && typeof value.$ref === 'string' && value.$ref.length > 0;
    };
    $Ref.isExternal$Ref = function(value) {
      return $Ref.is$Ref(value) && value.$ref[0] !== '#';
    };
    $Ref.isAllowed$Ref = function(value, options) {
      if ($Ref.is$Ref(value)) {
        if (value.$ref[0] === '#' || !options || options.resolve.external) {
          return true;
        }
      }
    };
    $Ref.isExtended$Ref = function(value) {
      return $Ref.is$Ref(value) && Object.keys(value).length > 1;
    };
    $Ref.dereference = function($ref, resolvedValue) {
      if (resolvedValue && typeof resolvedValue === 'object' && $Ref.isExtended$Ref($ref)) {
        var merged = {};
        Object.keys($ref).forEach(function(key) {
          if (key !== '$ref') {
            merged[key] = $ref[key];
          }
        });
        Object.keys(resolvedValue).forEach(function(key) {
          if (!(key in merged)) {
            merged[key] = resolvedValue[key];
          }
        });
        return merged;
      } else {
        return resolvedValue;
      }
    };
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("1f8", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lookup = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
  ;
  (function(exports) {
    'use strict';
    var Arr = (typeof Uint8Array !== 'undefined') ? Uint8Array : Array;
    var PLUS = '+'.charCodeAt(0);
    var SLASH = '/'.charCodeAt(0);
    var NUMBER = '0'.charCodeAt(0);
    var LOWER = 'a'.charCodeAt(0);
    var UPPER = 'A'.charCodeAt(0);
    var PLUS_URL_SAFE = '-'.charCodeAt(0);
    var SLASH_URL_SAFE = '_'.charCodeAt(0);
    function decode(elt) {
      var code = elt.charCodeAt(0);
      if (code === PLUS || code === PLUS_URL_SAFE)
        return 62;
      if (code === SLASH || code === SLASH_URL_SAFE)
        return 63;
      if (code < NUMBER)
        return -1;
      if (code < NUMBER + 10)
        return code - NUMBER + 26 + 26;
      if (code < UPPER + 26)
        return code - UPPER;
      if (code < LOWER + 26)
        return code - LOWER + 26;
    }
    function b64ToByteArray(b64) {
      var i,
          j,
          l,
          tmp,
          placeHolders,
          arr;
      if (b64.length % 4 > 0) {
        throw new Error('Invalid string. Length must be a multiple of 4');
      }
      var len = b64.length;
      placeHolders = '=' === b64.charAt(len - 2) ? 2 : '=' === b64.charAt(len - 1) ? 1 : 0;
      arr = new Arr(b64.length * 3 / 4 - placeHolders);
      l = placeHolders > 0 ? b64.length - 4 : b64.length;
      var L = 0;
      function push(v) {
        arr[L++] = v;
      }
      for (i = 0, j = 0; i < l; i += 4, j += 3) {
        tmp = (decode(b64.charAt(i)) << 18) | (decode(b64.charAt(i + 1)) << 12) | (decode(b64.charAt(i + 2)) << 6) | decode(b64.charAt(i + 3));
        push((tmp & 0xFF0000) >> 16);
        push((tmp & 0xFF00) >> 8);
        push(tmp & 0xFF);
      }
      if (placeHolders === 2) {
        tmp = (decode(b64.charAt(i)) << 2) | (decode(b64.charAt(i + 1)) >> 4);
        push(tmp & 0xFF);
      } else if (placeHolders === 1) {
        tmp = (decode(b64.charAt(i)) << 10) | (decode(b64.charAt(i + 1)) << 4) | (decode(b64.charAt(i + 2)) >> 2);
        push((tmp >> 8) & 0xFF);
        push(tmp & 0xFF);
      }
      return arr;
    }
    function uint8ToBase64(uint8) {
      var i,
          extraBytes = uint8.length % 3,
          output = "",
          temp,
          length;
      function encode(num) {
        return lookup.charAt(num);
      }
      function tripletToBase64(num) {
        return encode(num >> 18 & 0x3F) + encode(num >> 12 & 0x3F) + encode(num >> 6 & 0x3F) + encode(num & 0x3F);
      }
      for (i = 0, length = uint8.length - extraBytes; i < length; i += 3) {
        temp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2]);
        output += tripletToBase64(temp);
      }
      switch (extraBytes) {
        case 1:
          temp = uint8[uint8.length - 1];
          output += encode(temp >> 2);
          output += encode((temp << 4) & 0x3F);
          output += '==';
          break;
        case 2:
          temp = (uint8[uint8.length - 2] << 8) + (uint8[uint8.length - 1]);
          output += encode(temp >> 10);
          output += encode((temp >> 4) & 0x3F);
          output += encode((temp << 2) & 0x3F);
          output += '=';
          break;
      }
      return output;
    }
    exports.toByteArray = b64ToByteArray;
    exports.fromByteArray = uint8ToBase64;
  }(typeof exports === 'undefined' ? (this.base64js = {}) : exports));
  return module.exports;
});

$__System.registerDynamic("1f9", ["1f8"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1f8');
  return module.exports;
});

$__System.registerDynamic("1fa", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.read = function(buffer, offset, isLE, mLen, nBytes) {
    var e,
        m;
    var eLen = nBytes * 8 - mLen - 1;
    var eMax = (1 << eLen) - 1;
    var eBias = eMax >> 1;
    var nBits = -7;
    var i = isLE ? (nBytes - 1) : 0;
    var d = isLE ? -1 : 1;
    var s = buffer[offset + i];
    i += d;
    e = s & ((1 << (-nBits)) - 1);
    s >>= (-nBits);
    nBits += eLen;
    for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {}
    m = e & ((1 << (-nBits)) - 1);
    e >>= (-nBits);
    nBits += mLen;
    for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {}
    if (e === 0) {
      e = 1 - eBias;
    } else if (e === eMax) {
      return m ? NaN : ((s ? -1 : 1) * Infinity);
    } else {
      m = m + Math.pow(2, mLen);
      e = e - eBias;
    }
    return (s ? -1 : 1) * m * Math.pow(2, e - mLen);
  };
  exports.write = function(buffer, value, offset, isLE, mLen, nBytes) {
    var e,
        m,
        c;
    var eLen = nBytes * 8 - mLen - 1;
    var eMax = (1 << eLen) - 1;
    var eBias = eMax >> 1;
    var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0);
    var i = isLE ? 0 : (nBytes - 1);
    var d = isLE ? 1 : -1;
    var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0;
    value = Math.abs(value);
    if (isNaN(value) || value === Infinity) {
      m = isNaN(value) ? 1 : 0;
      e = eMax;
    } else {
      e = Math.floor(Math.log(value) / Math.LN2);
      if (value * (c = Math.pow(2, -e)) < 1) {
        e--;
        c *= 2;
      }
      if (e + eBias >= 1) {
        value += rt / c;
      } else {
        value += rt * Math.pow(2, 1 - eBias);
      }
      if (value * c >= 2) {
        e++;
        c /= 2;
      }
      if (e + eBias >= eMax) {
        m = 0;
        e = eMax;
      } else if (e + eBias >= 1) {
        m = (value * c - 1) * Math.pow(2, mLen);
        e = e + eBias;
      } else {
        m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen);
        e = 0;
      }
    }
    for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}
    e = (e << mLen) | m;
    eLen += mLen;
    for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}
    buffer[offset + i - d] |= s * 128;
  };
  return module.exports;
});

$__System.registerDynamic("1fb", ["1fa"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1fa');
  return module.exports;
});

$__System.registerDynamic("1fc", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toString = {}.toString;
  module.exports = Array.isArray || function(arr) {
    return toString.call(arr) == '[object Array]';
  };
  return module.exports;
});

$__System.registerDynamic("196", ["1fc"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1fc');
  return module.exports;
});

$__System.registerDynamic("1fd", ["1f9", "1fb", "196"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var base64 = $__require('1f9');
  var ieee754 = $__require('1fb');
  var isArray = $__require('196');
  exports.Buffer = Buffer;
  exports.SlowBuffer = SlowBuffer;
  exports.INSPECT_MAX_BYTES = 50;
  Buffer.poolSize = 8192;
  var rootParent = {};
  Buffer.TYPED_ARRAY_SUPPORT = global.TYPED_ARRAY_SUPPORT !== undefined ? global.TYPED_ARRAY_SUPPORT : typedArraySupport();
  function typedArraySupport() {
    function Bar() {}
    try {
      var arr = new Uint8Array(1);
      arr.foo = function() {
        return 42;
      };
      arr.constructor = Bar;
      return arr.foo() === 42 && arr.constructor === Bar && typeof arr.subarray === 'function' && arr.subarray(1, 1).byteLength === 0;
    } catch (e) {
      return false;
    }
  }
  function kMaxLength() {
    return Buffer.TYPED_ARRAY_SUPPORT ? 0x7fffffff : 0x3fffffff;
  }
  function Buffer(arg) {
    if (!(this instanceof Buffer)) {
      if (arguments.length > 1)
        return new Buffer(arg, arguments[1]);
      return new Buffer(arg);
    }
    if (!Buffer.TYPED_ARRAY_SUPPORT) {
      this.length = 0;
      this.parent = undefined;
    }
    if (typeof arg === 'number') {
      return fromNumber(this, arg);
    }
    if (typeof arg === 'string') {
      return fromString(this, arg, arguments.length > 1 ? arguments[1] : 'utf8');
    }
    return fromObject(this, arg);
  }
  function fromNumber(that, length) {
    that = allocate(that, length < 0 ? 0 : checked(length) | 0);
    if (!Buffer.TYPED_ARRAY_SUPPORT) {
      for (var i = 0; i < length; i++) {
        that[i] = 0;
      }
    }
    return that;
  }
  function fromString(that, string, encoding) {
    if (typeof encoding !== 'string' || encoding === '')
      encoding = 'utf8';
    var length = byteLength(string, encoding) | 0;
    that = allocate(that, length);
    that.write(string, encoding);
    return that;
  }
  function fromObject(that, object) {
    if (Buffer.isBuffer(object))
      return fromBuffer(that, object);
    if (isArray(object))
      return fromArray(that, object);
    if (object == null) {
      throw new TypeError('must start with number, buffer, array or string');
    }
    if (typeof ArrayBuffer !== 'undefined') {
      if (object.buffer instanceof ArrayBuffer) {
        return fromTypedArray(that, object);
      }
      if (object instanceof ArrayBuffer) {
        return fromArrayBuffer(that, object);
      }
    }
    if (object.length)
      return fromArrayLike(that, object);
    return fromJsonObject(that, object);
  }
  function fromBuffer(that, buffer) {
    var length = checked(buffer.length) | 0;
    that = allocate(that, length);
    buffer.copy(that, 0, 0, length);
    return that;
  }
  function fromArray(that, array) {
    var length = checked(array.length) | 0;
    that = allocate(that, length);
    for (var i = 0; i < length; i += 1) {
      that[i] = array[i] & 255;
    }
    return that;
  }
  function fromTypedArray(that, array) {
    var length = checked(array.length) | 0;
    that = allocate(that, length);
    for (var i = 0; i < length; i += 1) {
      that[i] = array[i] & 255;
    }
    return that;
  }
  function fromArrayBuffer(that, array) {
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      array.byteLength;
      that = Buffer._augment(new Uint8Array(array));
    } else {
      that = fromTypedArray(that, new Uint8Array(array));
    }
    return that;
  }
  function fromArrayLike(that, array) {
    var length = checked(array.length) | 0;
    that = allocate(that, length);
    for (var i = 0; i < length; i += 1) {
      that[i] = array[i] & 255;
    }
    return that;
  }
  function fromJsonObject(that, object) {
    var array;
    var length = 0;
    if (object.type === 'Buffer' && isArray(object.data)) {
      array = object.data;
      length = checked(array.length) | 0;
    }
    that = allocate(that, length);
    for (var i = 0; i < length; i += 1) {
      that[i] = array[i] & 255;
    }
    return that;
  }
  if (Buffer.TYPED_ARRAY_SUPPORT) {
    Buffer.prototype.__proto__ = Uint8Array.prototype;
    Buffer.__proto__ = Uint8Array;
  } else {
    Buffer.prototype.length = undefined;
    Buffer.prototype.parent = undefined;
  }
  function allocate(that, length) {
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      that = Buffer._augment(new Uint8Array(length));
      that.__proto__ = Buffer.prototype;
    } else {
      that.length = length;
      that._isBuffer = true;
    }
    var fromPool = length !== 0 && length <= Buffer.poolSize >>> 1;
    if (fromPool)
      that.parent = rootParent;
    return that;
  }
  function checked(length) {
    if (length >= kMaxLength()) {
      throw new RangeError('Attempt to allocate Buffer larger than maximum ' + 'size: 0x' + kMaxLength().toString(16) + ' bytes');
    }
    return length | 0;
  }
  function SlowBuffer(subject, encoding) {
    if (!(this instanceof SlowBuffer))
      return new SlowBuffer(subject, encoding);
    var buf = new Buffer(subject, encoding);
    delete buf.parent;
    return buf;
  }
  Buffer.isBuffer = function isBuffer(b) {
    return !!(b != null && b._isBuffer);
  };
  Buffer.compare = function compare(a, b) {
    if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {
      throw new TypeError('Arguments must be Buffers');
    }
    if (a === b)
      return 0;
    var x = a.length;
    var y = b.length;
    var i = 0;
    var len = Math.min(x, y);
    while (i < len) {
      if (a[i] !== b[i])
        break;
      ++i;
    }
    if (i !== len) {
      x = a[i];
      y = b[i];
    }
    if (x < y)
      return -1;
    if (y < x)
      return 1;
    return 0;
  };
  Buffer.isEncoding = function isEncoding(encoding) {
    switch (String(encoding).toLowerCase()) {
      case 'hex':
      case 'utf8':
      case 'utf-8':
      case 'ascii':
      case 'binary':
      case 'base64':
      case 'raw':
      case 'ucs2':
      case 'ucs-2':
      case 'utf16le':
      case 'utf-16le':
        return true;
      default:
        return false;
    }
  };
  Buffer.concat = function concat(list, length) {
    if (!isArray(list))
      throw new TypeError('list argument must be an Array of Buffers.');
    if (list.length === 0) {
      return new Buffer(0);
    }
    var i;
    if (length === undefined) {
      length = 0;
      for (i = 0; i < list.length; i++) {
        length += list[i].length;
      }
    }
    var buf = new Buffer(length);
    var pos = 0;
    for (i = 0; i < list.length; i++) {
      var item = list[i];
      item.copy(buf, pos);
      pos += item.length;
    }
    return buf;
  };
  function byteLength(string, encoding) {
    if (typeof string !== 'string')
      string = '' + string;
    var len = string.length;
    if (len === 0)
      return 0;
    var loweredCase = false;
    for (; ; ) {
      switch (encoding) {
        case 'ascii':
        case 'binary':
        case 'raw':
        case 'raws':
          return len;
        case 'utf8':
        case 'utf-8':
          return utf8ToBytes(string).length;
        case 'ucs2':
        case 'ucs-2':
        case 'utf16le':
        case 'utf-16le':
          return len * 2;
        case 'hex':
          return len >>> 1;
        case 'base64':
          return base64ToBytes(string).length;
        default:
          if (loweredCase)
            return utf8ToBytes(string).length;
          encoding = ('' + encoding).toLowerCase();
          loweredCase = true;
      }
    }
  }
  Buffer.byteLength = byteLength;
  function slowToString(encoding, start, end) {
    var loweredCase = false;
    start = start | 0;
    end = end === undefined || end === Infinity ? this.length : end | 0;
    if (!encoding)
      encoding = 'utf8';
    if (start < 0)
      start = 0;
    if (end > this.length)
      end = this.length;
    if (end <= start)
      return '';
    while (true) {
      switch (encoding) {
        case 'hex':
          return hexSlice(this, start, end);
        case 'utf8':
        case 'utf-8':
          return utf8Slice(this, start, end);
        case 'ascii':
          return asciiSlice(this, start, end);
        case 'binary':
          return binarySlice(this, start, end);
        case 'base64':
          return base64Slice(this, start, end);
        case 'ucs2':
        case 'ucs-2':
        case 'utf16le':
        case 'utf-16le':
          return utf16leSlice(this, start, end);
        default:
          if (loweredCase)
            throw new TypeError('Unknown encoding: ' + encoding);
          encoding = (encoding + '').toLowerCase();
          loweredCase = true;
      }
    }
  }
  Buffer.prototype.toString = function toString() {
    var length = this.length | 0;
    if (length === 0)
      return '';
    if (arguments.length === 0)
      return utf8Slice(this, 0, length);
    return slowToString.apply(this, arguments);
  };
  Buffer.prototype.equals = function equals(b) {
    if (!Buffer.isBuffer(b))
      throw new TypeError('Argument must be a Buffer');
    if (this === b)
      return true;
    return Buffer.compare(this, b) === 0;
  };
  Buffer.prototype.inspect = function inspect() {
    var str = '';
    var max = exports.INSPECT_MAX_BYTES;
    if (this.length > 0) {
      str = this.toString('hex', 0, max).match(/.{2}/g).join(' ');
      if (this.length > max)
        str += ' ... ';
    }
    return '<Buffer ' + str + '>';
  };
  Buffer.prototype.compare = function compare(b) {
    if (!Buffer.isBuffer(b))
      throw new TypeError('Argument must be a Buffer');
    if (this === b)
      return 0;
    return Buffer.compare(this, b);
  };
  Buffer.prototype.indexOf = function indexOf(val, byteOffset) {
    if (byteOffset > 0x7fffffff)
      byteOffset = 0x7fffffff;
    else if (byteOffset < -0x80000000)
      byteOffset = -0x80000000;
    byteOffset >>= 0;
    if (this.length === 0)
      return -1;
    if (byteOffset >= this.length)
      return -1;
    if (byteOffset < 0)
      byteOffset = Math.max(this.length + byteOffset, 0);
    if (typeof val === 'string') {
      if (val.length === 0)
        return -1;
      return String.prototype.indexOf.call(this, val, byteOffset);
    }
    if (Buffer.isBuffer(val)) {
      return arrayIndexOf(this, val, byteOffset);
    }
    if (typeof val === 'number') {
      if (Buffer.TYPED_ARRAY_SUPPORT && Uint8Array.prototype.indexOf === 'function') {
        return Uint8Array.prototype.indexOf.call(this, val, byteOffset);
      }
      return arrayIndexOf(this, [val], byteOffset);
    }
    function arrayIndexOf(arr, val, byteOffset) {
      var foundIndex = -1;
      for (var i = 0; byteOffset + i < arr.length; i++) {
        if (arr[byteOffset + i] === val[foundIndex === -1 ? 0 : i - foundIndex]) {
          if (foundIndex === -1)
            foundIndex = i;
          if (i - foundIndex + 1 === val.length)
            return byteOffset + foundIndex;
        } else {
          foundIndex = -1;
        }
      }
      return -1;
    }
    throw new TypeError('val must be string, number or Buffer');
  };
  Buffer.prototype.get = function get(offset) {
    console.log('.get() is deprecated. Access using array indexes instead.');
    return this.readUInt8(offset);
  };
  Buffer.prototype.set = function set(v, offset) {
    console.log('.set() is deprecated. Access using array indexes instead.');
    return this.writeUInt8(v, offset);
  };
  function hexWrite(buf, string, offset, length) {
    offset = Number(offset) || 0;
    var remaining = buf.length - offset;
    if (!length) {
      length = remaining;
    } else {
      length = Number(length);
      if (length > remaining) {
        length = remaining;
      }
    }
    var strLen = string.length;
    if (strLen % 2 !== 0)
      throw new Error('Invalid hex string');
    if (length > strLen / 2) {
      length = strLen / 2;
    }
    for (var i = 0; i < length; i++) {
      var parsed = parseInt(string.substr(i * 2, 2), 16);
      if (isNaN(parsed))
        throw new Error('Invalid hex string');
      buf[offset + i] = parsed;
    }
    return i;
  }
  function utf8Write(buf, string, offset, length) {
    return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length);
  }
  function asciiWrite(buf, string, offset, length) {
    return blitBuffer(asciiToBytes(string), buf, offset, length);
  }
  function binaryWrite(buf, string, offset, length) {
    return asciiWrite(buf, string, offset, length);
  }
  function base64Write(buf, string, offset, length) {
    return blitBuffer(base64ToBytes(string), buf, offset, length);
  }
  function ucs2Write(buf, string, offset, length) {
    return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length);
  }
  Buffer.prototype.write = function write(string, offset, length, encoding) {
    if (offset === undefined) {
      encoding = 'utf8';
      length = this.length;
      offset = 0;
    } else if (length === undefined && typeof offset === 'string') {
      encoding = offset;
      length = this.length;
      offset = 0;
    } else if (isFinite(offset)) {
      offset = offset | 0;
      if (isFinite(length)) {
        length = length | 0;
        if (encoding === undefined)
          encoding = 'utf8';
      } else {
        encoding = length;
        length = undefined;
      }
    } else {
      var swap = encoding;
      encoding = offset;
      offset = length | 0;
      length = swap;
    }
    var remaining = this.length - offset;
    if (length === undefined || length > remaining)
      length = remaining;
    if ((string.length > 0 && (length < 0 || offset < 0)) || offset > this.length) {
      throw new RangeError('attempt to write outside buffer bounds');
    }
    if (!encoding)
      encoding = 'utf8';
    var loweredCase = false;
    for (; ; ) {
      switch (encoding) {
        case 'hex':
          return hexWrite(this, string, offset, length);
        case 'utf8':
        case 'utf-8':
          return utf8Write(this, string, offset, length);
        case 'ascii':
          return asciiWrite(this, string, offset, length);
        case 'binary':
          return binaryWrite(this, string, offset, length);
        case 'base64':
          return base64Write(this, string, offset, length);
        case 'ucs2':
        case 'ucs-2':
        case 'utf16le':
        case 'utf-16le':
          return ucs2Write(this, string, offset, length);
        default:
          if (loweredCase)
            throw new TypeError('Unknown encoding: ' + encoding);
          encoding = ('' + encoding).toLowerCase();
          loweredCase = true;
      }
    }
  };
  Buffer.prototype.toJSON = function toJSON() {
    return {
      type: 'Buffer',
      data: Array.prototype.slice.call(this._arr || this, 0)
    };
  };
  function base64Slice(buf, start, end) {
    if (start === 0 && end === buf.length) {
      return base64.fromByteArray(buf);
    } else {
      return base64.fromByteArray(buf.slice(start, end));
    }
  }
  function utf8Slice(buf, start, end) {
    end = Math.min(buf.length, end);
    var res = [];
    var i = start;
    while (i < end) {
      var firstByte = buf[i];
      var codePoint = null;
      var bytesPerSequence = (firstByte > 0xEF) ? 4 : (firstByte > 0xDF) ? 3 : (firstByte > 0xBF) ? 2 : 1;
      if (i + bytesPerSequence <= end) {
        var secondByte,
            thirdByte,
            fourthByte,
            tempCodePoint;
        switch (bytesPerSequence) {
          case 1:
            if (firstByte < 0x80) {
              codePoint = firstByte;
            }
            break;
          case 2:
            secondByte = buf[i + 1];
            if ((secondByte & 0xC0) === 0x80) {
              tempCodePoint = (firstByte & 0x1F) << 0x6 | (secondByte & 0x3F);
              if (tempCodePoint > 0x7F) {
                codePoint = tempCodePoint;
              }
            }
            break;
          case 3:
            secondByte = buf[i + 1];
            thirdByte = buf[i + 2];
            if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {
              tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | (thirdByte & 0x3F);
              if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {
                codePoint = tempCodePoint;
              }
            }
            break;
          case 4:
            secondByte = buf[i + 1];
            thirdByte = buf[i + 2];
            fourthByte = buf[i + 3];
            if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {
              tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | (fourthByte & 0x3F);
              if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {
                codePoint = tempCodePoint;
              }
            }
        }
      }
      if (codePoint === null) {
        codePoint = 0xFFFD;
        bytesPerSequence = 1;
      } else if (codePoint > 0xFFFF) {
        codePoint -= 0x10000;
        res.push(codePoint >>> 10 & 0x3FF | 0xD800);
        codePoint = 0xDC00 | codePoint & 0x3FF;
      }
      res.push(codePoint);
      i += bytesPerSequence;
    }
    return decodeCodePointsArray(res);
  }
  var MAX_ARGUMENTS_LENGTH = 0x1000;
  function decodeCodePointsArray(codePoints) {
    var len = codePoints.length;
    if (len <= MAX_ARGUMENTS_LENGTH) {
      return String.fromCharCode.apply(String, codePoints);
    }
    var res = '';
    var i = 0;
    while (i < len) {
      res += String.fromCharCode.apply(String, codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH));
    }
    return res;
  }
  function asciiSlice(buf, start, end) {
    var ret = '';
    end = Math.min(buf.length, end);
    for (var i = start; i < end; i++) {
      ret += String.fromCharCode(buf[i] & 0x7F);
    }
    return ret;
  }
  function binarySlice(buf, start, end) {
    var ret = '';
    end = Math.min(buf.length, end);
    for (var i = start; i < end; i++) {
      ret += String.fromCharCode(buf[i]);
    }
    return ret;
  }
  function hexSlice(buf, start, end) {
    var len = buf.length;
    if (!start || start < 0)
      start = 0;
    if (!end || end < 0 || end > len)
      end = len;
    var out = '';
    for (var i = start; i < end; i++) {
      out += toHex(buf[i]);
    }
    return out;
  }
  function utf16leSlice(buf, start, end) {
    var bytes = buf.slice(start, end);
    var res = '';
    for (var i = 0; i < bytes.length; i += 2) {
      res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256);
    }
    return res;
  }
  Buffer.prototype.slice = function slice(start, end) {
    var len = this.length;
    start = ~~start;
    end = end === undefined ? len : ~~end;
    if (start < 0) {
      start += len;
      if (start < 0)
        start = 0;
    } else if (start > len) {
      start = len;
    }
    if (end < 0) {
      end += len;
      if (end < 0)
        end = 0;
    } else if (end > len) {
      end = len;
    }
    if (end < start)
      end = start;
    var newBuf;
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      newBuf = Buffer._augment(this.subarray(start, end));
    } else {
      var sliceLen = end - start;
      newBuf = new Buffer(sliceLen, undefined);
      for (var i = 0; i < sliceLen; i++) {
        newBuf[i] = this[i + start];
      }
    }
    if (newBuf.length)
      newBuf.parent = this.parent || this;
    return newBuf;
  };
  function checkOffset(offset, ext, length) {
    if ((offset % 1) !== 0 || offset < 0)
      throw new RangeError('offset is not uint');
    if (offset + ext > length)
      throw new RangeError('Trying to access beyond buffer length');
  }
  Buffer.prototype.readUIntLE = function readUIntLE(offset, byteLength, noAssert) {
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert)
      checkOffset(offset, byteLength, this.length);
    var val = this[offset];
    var mul = 1;
    var i = 0;
    while (++i < byteLength && (mul *= 0x100)) {
      val += this[offset + i] * mul;
    }
    return val;
  };
  Buffer.prototype.readUIntBE = function readUIntBE(offset, byteLength, noAssert) {
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert) {
      checkOffset(offset, byteLength, this.length);
    }
    var val = this[offset + --byteLength];
    var mul = 1;
    while (byteLength > 0 && (mul *= 0x100)) {
      val += this[offset + --byteLength] * mul;
    }
    return val;
  };
  Buffer.prototype.readUInt8 = function readUInt8(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 1, this.length);
    return this[offset];
  };
  Buffer.prototype.readUInt16LE = function readUInt16LE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 2, this.length);
    return this[offset] | (this[offset + 1] << 8);
  };
  Buffer.prototype.readUInt16BE = function readUInt16BE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 2, this.length);
    return (this[offset] << 8) | this[offset + 1];
  };
  Buffer.prototype.readUInt32LE = function readUInt32LE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return ((this[offset]) | (this[offset + 1] << 8) | (this[offset + 2] << 16)) + (this[offset + 3] * 0x1000000);
  };
  Buffer.prototype.readUInt32BE = function readUInt32BE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return (this[offset] * 0x1000000) + ((this[offset + 1] << 16) | (this[offset + 2] << 8) | this[offset + 3]);
  };
  Buffer.prototype.readIntLE = function readIntLE(offset, byteLength, noAssert) {
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert)
      checkOffset(offset, byteLength, this.length);
    var val = this[offset];
    var mul = 1;
    var i = 0;
    while (++i < byteLength && (mul *= 0x100)) {
      val += this[offset + i] * mul;
    }
    mul *= 0x80;
    if (val >= mul)
      val -= Math.pow(2, 8 * byteLength);
    return val;
  };
  Buffer.prototype.readIntBE = function readIntBE(offset, byteLength, noAssert) {
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert)
      checkOffset(offset, byteLength, this.length);
    var i = byteLength;
    var mul = 1;
    var val = this[offset + --i];
    while (i > 0 && (mul *= 0x100)) {
      val += this[offset + --i] * mul;
    }
    mul *= 0x80;
    if (val >= mul)
      val -= Math.pow(2, 8 * byteLength);
    return val;
  };
  Buffer.prototype.readInt8 = function readInt8(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 1, this.length);
    if (!(this[offset] & 0x80))
      return (this[offset]);
    return ((0xff - this[offset] + 1) * -1);
  };
  Buffer.prototype.readInt16LE = function readInt16LE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 2, this.length);
    var val = this[offset] | (this[offset + 1] << 8);
    return (val & 0x8000) ? val | 0xFFFF0000 : val;
  };
  Buffer.prototype.readInt16BE = function readInt16BE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 2, this.length);
    var val = this[offset + 1] | (this[offset] << 8);
    return (val & 0x8000) ? val | 0xFFFF0000 : val;
  };
  Buffer.prototype.readInt32LE = function readInt32LE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return (this[offset]) | (this[offset + 1] << 8) | (this[offset + 2] << 16) | (this[offset + 3] << 24);
  };
  Buffer.prototype.readInt32BE = function readInt32BE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return (this[offset] << 24) | (this[offset + 1] << 16) | (this[offset + 2] << 8) | (this[offset + 3]);
  };
  Buffer.prototype.readFloatLE = function readFloatLE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return ieee754.read(this, offset, true, 23, 4);
  };
  Buffer.prototype.readFloatBE = function readFloatBE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 4, this.length);
    return ieee754.read(this, offset, false, 23, 4);
  };
  Buffer.prototype.readDoubleLE = function readDoubleLE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 8, this.length);
    return ieee754.read(this, offset, true, 52, 8);
  };
  Buffer.prototype.readDoubleBE = function readDoubleBE(offset, noAssert) {
    if (!noAssert)
      checkOffset(offset, 8, this.length);
    return ieee754.read(this, offset, false, 52, 8);
  };
  function checkInt(buf, value, offset, ext, max, min) {
    if (!Buffer.isBuffer(buf))
      throw new TypeError('buffer must be a Buffer instance');
    if (value > max || value < min)
      throw new RangeError('value is out of bounds');
    if (offset + ext > buf.length)
      throw new RangeError('index out of range');
  }
  Buffer.prototype.writeUIntLE = function writeUIntLE(value, offset, byteLength, noAssert) {
    value = +value;
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert)
      checkInt(this, value, offset, byteLength, Math.pow(2, 8 * byteLength), 0);
    var mul = 1;
    var i = 0;
    this[offset] = value & 0xFF;
    while (++i < byteLength && (mul *= 0x100)) {
      this[offset + i] = (value / mul) & 0xFF;
    }
    return offset + byteLength;
  };
  Buffer.prototype.writeUIntBE = function writeUIntBE(value, offset, byteLength, noAssert) {
    value = +value;
    offset = offset | 0;
    byteLength = byteLength | 0;
    if (!noAssert)
      checkInt(this, value, offset, byteLength, Math.pow(2, 8 * byteLength), 0);
    var i = byteLength - 1;
    var mul = 1;
    this[offset + i] = value & 0xFF;
    while (--i >= 0 && (mul *= 0x100)) {
      this[offset + i] = (value / mul) & 0xFF;
    }
    return offset + byteLength;
  };
  Buffer.prototype.writeUInt8 = function writeUInt8(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 1, 0xff, 0);
    if (!Buffer.TYPED_ARRAY_SUPPORT)
      value = Math.floor(value);
    this[offset] = (value & 0xff);
    return offset + 1;
  };
  function objectWriteUInt16(buf, value, offset, littleEndian) {
    if (value < 0)
      value = 0xffff + value + 1;
    for (var i = 0,
        j = Math.min(buf.length - offset, 2); i < j; i++) {
      buf[offset + i] = (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>> (littleEndian ? i : 1 - i) * 8;
    }
  }
  Buffer.prototype.writeUInt16LE = function writeUInt16LE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 2, 0xffff, 0);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value & 0xff);
      this[offset + 1] = (value >>> 8);
    } else {
      objectWriteUInt16(this, value, offset, true);
    }
    return offset + 2;
  };
  Buffer.prototype.writeUInt16BE = function writeUInt16BE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 2, 0xffff, 0);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value >>> 8);
      this[offset + 1] = (value & 0xff);
    } else {
      objectWriteUInt16(this, value, offset, false);
    }
    return offset + 2;
  };
  function objectWriteUInt32(buf, value, offset, littleEndian) {
    if (value < 0)
      value = 0xffffffff + value + 1;
    for (var i = 0,
        j = Math.min(buf.length - offset, 4); i < j; i++) {
      buf[offset + i] = (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff;
    }
  }
  Buffer.prototype.writeUInt32LE = function writeUInt32LE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 4, 0xffffffff, 0);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset + 3] = (value >>> 24);
      this[offset + 2] = (value >>> 16);
      this[offset + 1] = (value >>> 8);
      this[offset] = (value & 0xff);
    } else {
      objectWriteUInt32(this, value, offset, true);
    }
    return offset + 4;
  };
  Buffer.prototype.writeUInt32BE = function writeUInt32BE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 4, 0xffffffff, 0);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value >>> 24);
      this[offset + 1] = (value >>> 16);
      this[offset + 2] = (value >>> 8);
      this[offset + 3] = (value & 0xff);
    } else {
      objectWriteUInt32(this, value, offset, false);
    }
    return offset + 4;
  };
  Buffer.prototype.writeIntLE = function writeIntLE(value, offset, byteLength, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert) {
      var limit = Math.pow(2, 8 * byteLength - 1);
      checkInt(this, value, offset, byteLength, limit - 1, -limit);
    }
    var i = 0;
    var mul = 1;
    var sub = value < 0 ? 1 : 0;
    this[offset] = value & 0xFF;
    while (++i < byteLength && (mul *= 0x100)) {
      this[offset + i] = ((value / mul) >> 0) - sub & 0xFF;
    }
    return offset + byteLength;
  };
  Buffer.prototype.writeIntBE = function writeIntBE(value, offset, byteLength, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert) {
      var limit = Math.pow(2, 8 * byteLength - 1);
      checkInt(this, value, offset, byteLength, limit - 1, -limit);
    }
    var i = byteLength - 1;
    var mul = 1;
    var sub = value < 0 ? 1 : 0;
    this[offset + i] = value & 0xFF;
    while (--i >= 0 && (mul *= 0x100)) {
      this[offset + i] = ((value / mul) >> 0) - sub & 0xFF;
    }
    return offset + byteLength;
  };
  Buffer.prototype.writeInt8 = function writeInt8(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 1, 0x7f, -0x80);
    if (!Buffer.TYPED_ARRAY_SUPPORT)
      value = Math.floor(value);
    if (value < 0)
      value = 0xff + value + 1;
    this[offset] = (value & 0xff);
    return offset + 1;
  };
  Buffer.prototype.writeInt16LE = function writeInt16LE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 2, 0x7fff, -0x8000);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value & 0xff);
      this[offset + 1] = (value >>> 8);
    } else {
      objectWriteUInt16(this, value, offset, true);
    }
    return offset + 2;
  };
  Buffer.prototype.writeInt16BE = function writeInt16BE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 2, 0x7fff, -0x8000);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value >>> 8);
      this[offset + 1] = (value & 0xff);
    } else {
      objectWriteUInt16(this, value, offset, false);
    }
    return offset + 2;
  };
  Buffer.prototype.writeInt32LE = function writeInt32LE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value & 0xff);
      this[offset + 1] = (value >>> 8);
      this[offset + 2] = (value >>> 16);
      this[offset + 3] = (value >>> 24);
    } else {
      objectWriteUInt32(this, value, offset, true);
    }
    return offset + 4;
  };
  Buffer.prototype.writeInt32BE = function writeInt32BE(value, offset, noAssert) {
    value = +value;
    offset = offset | 0;
    if (!noAssert)
      checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);
    if (value < 0)
      value = 0xffffffff + value + 1;
    if (Buffer.TYPED_ARRAY_SUPPORT) {
      this[offset] = (value >>> 24);
      this[offset + 1] = (value >>> 16);
      this[offset + 2] = (value >>> 8);
      this[offset + 3] = (value & 0xff);
    } else {
      objectWriteUInt32(this, value, offset, false);
    }
    return offset + 4;
  };
  function checkIEEE754(buf, value, offset, ext, max, min) {
    if (value > max || value < min)
      throw new RangeError('value is out of bounds');
    if (offset + ext > buf.length)
      throw new RangeError('index out of range');
    if (offset < 0)
      throw new RangeError('index out of range');
  }
  function writeFloat(buf, value, offset, littleEndian, noAssert) {
    if (!noAssert) {
      checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38);
    }
    ieee754.write(buf, value, offset, littleEndian, 23, 4);
    return offset + 4;
  }
  Buffer.prototype.writeFloatLE = function writeFloatLE(value, offset, noAssert) {
    return writeFloat(this, value, offset, true, noAssert);
  };
  Buffer.prototype.writeFloatBE = function writeFloatBE(value, offset, noAssert) {
    return writeFloat(this, value, offset, false, noAssert);
  };
  function writeDouble(buf, value, offset, littleEndian, noAssert) {
    if (!noAssert) {
      checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308);
    }
    ieee754.write(buf, value, offset, littleEndian, 52, 8);
    return offset + 8;
  }
  Buffer.prototype.writeDoubleLE = function writeDoubleLE(value, offset, noAssert) {
    return writeDouble(this, value, offset, true, noAssert);
  };
  Buffer.prototype.writeDoubleBE = function writeDoubleBE(value, offset, noAssert) {
    return writeDouble(this, value, offset, false, noAssert);
  };
  Buffer.prototype.copy = function copy(target, targetStart, start, end) {
    if (!start)
      start = 0;
    if (!end && end !== 0)
      end = this.length;
    if (targetStart >= target.length)
      targetStart = target.length;
    if (!targetStart)
      targetStart = 0;
    if (end > 0 && end < start)
      end = start;
    if (end === start)
      return 0;
    if (target.length === 0 || this.length === 0)
      return 0;
    if (targetStart < 0) {
      throw new RangeError('targetStart out of bounds');
    }
    if (start < 0 || start >= this.length)
      throw new RangeError('sourceStart out of bounds');
    if (end < 0)
      throw new RangeError('sourceEnd out of bounds');
    if (end > this.length)
      end = this.length;
    if (target.length - targetStart < end - start) {
      end = target.length - targetStart + start;
    }
    var len = end - start;
    var i;
    if (this === target && start < targetStart && targetStart < end) {
      for (i = len - 1; i >= 0; i--) {
        target[i + targetStart] = this[i + start];
      }
    } else if (len < 1000 || !Buffer.TYPED_ARRAY_SUPPORT) {
      for (i = 0; i < len; i++) {
        target[i + targetStart] = this[i + start];
      }
    } else {
      target._set(this.subarray(start, start + len), targetStart);
    }
    return len;
  };
  Buffer.prototype.fill = function fill(value, start, end) {
    if (!value)
      value = 0;
    if (!start)
      start = 0;
    if (!end)
      end = this.length;
    if (end < start)
      throw new RangeError('end < start');
    if (end === start)
      return;
    if (this.length === 0)
      return;
    if (start < 0 || start >= this.length)
      throw new RangeError('start out of bounds');
    if (end < 0 || end > this.length)
      throw new RangeError('end out of bounds');
    var i;
    if (typeof value === 'number') {
      for (i = start; i < end; i++) {
        this[i] = value;
      }
    } else {
      var bytes = utf8ToBytes(value.toString());
      var len = bytes.length;
      for (i = start; i < end; i++) {
        this[i] = bytes[i % len];
      }
    }
    return this;
  };
  Buffer.prototype.toArrayBuffer = function toArrayBuffer() {
    if (typeof Uint8Array !== 'undefined') {
      if (Buffer.TYPED_ARRAY_SUPPORT) {
        return (new Buffer(this)).buffer;
      } else {
        var buf = new Uint8Array(this.length);
        for (var i = 0,
            len = buf.length; i < len; i += 1) {
          buf[i] = this[i];
        }
        return buf.buffer;
      }
    } else {
      throw new TypeError('Buffer.toArrayBuffer not supported in this browser');
    }
  };
  var BP = Buffer.prototype;
  Buffer._augment = function _augment(arr) {
    arr.constructor = Buffer;
    arr._isBuffer = true;
    arr._set = arr.set;
    arr.get = BP.get;
    arr.set = BP.set;
    arr.write = BP.write;
    arr.toString = BP.toString;
    arr.toLocaleString = BP.toString;
    arr.toJSON = BP.toJSON;
    arr.equals = BP.equals;
    arr.compare = BP.compare;
    arr.indexOf = BP.indexOf;
    arr.copy = BP.copy;
    arr.slice = BP.slice;
    arr.readUIntLE = BP.readUIntLE;
    arr.readUIntBE = BP.readUIntBE;
    arr.readUInt8 = BP.readUInt8;
    arr.readUInt16LE = BP.readUInt16LE;
    arr.readUInt16BE = BP.readUInt16BE;
    arr.readUInt32LE = BP.readUInt32LE;
    arr.readUInt32BE = BP.readUInt32BE;
    arr.readIntLE = BP.readIntLE;
    arr.readIntBE = BP.readIntBE;
    arr.readInt8 = BP.readInt8;
    arr.readInt16LE = BP.readInt16LE;
    arr.readInt16BE = BP.readInt16BE;
    arr.readInt32LE = BP.readInt32LE;
    arr.readInt32BE = BP.readInt32BE;
    arr.readFloatLE = BP.readFloatLE;
    arr.readFloatBE = BP.readFloatBE;
    arr.readDoubleLE = BP.readDoubleLE;
    arr.readDoubleBE = BP.readDoubleBE;
    arr.writeUInt8 = BP.writeUInt8;
    arr.writeUIntLE = BP.writeUIntLE;
    arr.writeUIntBE = BP.writeUIntBE;
    arr.writeUInt16LE = BP.writeUInt16LE;
    arr.writeUInt16BE = BP.writeUInt16BE;
    arr.writeUInt32LE = BP.writeUInt32LE;
    arr.writeUInt32BE = BP.writeUInt32BE;
    arr.writeIntLE = BP.writeIntLE;
    arr.writeIntBE = BP.writeIntBE;
    arr.writeInt8 = BP.writeInt8;
    arr.writeInt16LE = BP.writeInt16LE;
    arr.writeInt16BE = BP.writeInt16BE;
    arr.writeInt32LE = BP.writeInt32LE;
    arr.writeInt32BE = BP.writeInt32BE;
    arr.writeFloatLE = BP.writeFloatLE;
    arr.writeFloatBE = BP.writeFloatBE;
    arr.writeDoubleLE = BP.writeDoubleLE;
    arr.writeDoubleBE = BP.writeDoubleBE;
    arr.fill = BP.fill;
    arr.inspect = BP.inspect;
    arr.toArrayBuffer = BP.toArrayBuffer;
    return arr;
  };
  var INVALID_BASE64_RE = /[^+\/0-9A-Za-z-_]/g;
  function base64clean(str) {
    str = stringtrim(str).replace(INVALID_BASE64_RE, '');
    if (str.length < 2)
      return '';
    while (str.length % 4 !== 0) {
      str = str + '=';
    }
    return str;
  }
  function stringtrim(str) {
    if (str.trim)
      return str.trim();
    return str.replace(/^\s+|\s+$/g, '');
  }
  function toHex(n) {
    if (n < 16)
      return '0' + n.toString(16);
    return n.toString(16);
  }
  function utf8ToBytes(string, units) {
    units = units || Infinity;
    var codePoint;
    var length = string.length;
    var leadSurrogate = null;
    var bytes = [];
    for (var i = 0; i < length; i++) {
      codePoint = string.charCodeAt(i);
      if (codePoint > 0xD7FF && codePoint < 0xE000) {
        if (!leadSurrogate) {
          if (codePoint > 0xDBFF) {
            if ((units -= 3) > -1)
              bytes.push(0xEF, 0xBF, 0xBD);
            continue;
          } else if (i + 1 === length) {
            if ((units -= 3) > -1)
              bytes.push(0xEF, 0xBF, 0xBD);
            continue;
          }
          leadSurrogate = codePoint;
          continue;
        }
        if (codePoint < 0xDC00) {
          if ((units -= 3) > -1)
            bytes.push(0xEF, 0xBF, 0xBD);
          leadSurrogate = codePoint;
          continue;
        }
        codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000;
      } else if (leadSurrogate) {
        if ((units -= 3) > -1)
          bytes.push(0xEF, 0xBF, 0xBD);
      }
      leadSurrogate = null;
      if (codePoint < 0x80) {
        if ((units -= 1) < 0)
          break;
        bytes.push(codePoint);
      } else if (codePoint < 0x800) {
        if ((units -= 2) < 0)
          break;
        bytes.push(codePoint >> 0x6 | 0xC0, codePoint & 0x3F | 0x80);
      } else if (codePoint < 0x10000) {
        if ((units -= 3) < 0)
          break;
        bytes.push(codePoint >> 0xC | 0xE0, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);
      } else if (codePoint < 0x110000) {
        if ((units -= 4) < 0)
          break;
        bytes.push(codePoint >> 0x12 | 0xF0, codePoint >> 0xC & 0x3F | 0x80, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);
      } else {
        throw new Error('Invalid code point');
      }
    }
    return bytes;
  }
  function asciiToBytes(str) {
    var byteArray = [];
    for (var i = 0; i < str.length; i++) {
      byteArray.push(str.charCodeAt(i) & 0xFF);
    }
    return byteArray;
  }
  function utf16leToBytes(str, units) {
    var c,
        hi,
        lo;
    var byteArray = [];
    for (var i = 0; i < str.length; i++) {
      if ((units -= 2) < 0)
        break;
      c = str.charCodeAt(i);
      hi = c >> 8;
      lo = c % 256;
      byteArray.push(lo);
      byteArray.push(hi);
    }
    return byteArray;
  }
  function base64ToBytes(str) {
    return base64.toByteArray(base64clean(str));
  }
  function blitBuffer(src, dst, offset, length) {
    for (var i = 0; i < length; i++) {
      if ((i + offset >= dst.length) || (i >= src.length))
        break;
      dst[i + offset] = src[i];
    }
    return i;
  }
  return module.exports;
});

$__System.registerDynamic("1fe", ["1fd"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1fd');
  return module.exports;
});

$__System.registerDynamic("1ff", ["1fe"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('buffer') : $__require('1fe');
  return module.exports;
});

$__System.registerDynamic("185", ["1ff"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('1ff');
  return module.exports;
});

$__System.registerDynamic("1d2", ["1cd", "18d", "179", "185"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(Buffer) {
    'use strict';
    module.exports = Pointer;
    var $Ref = $__require('1cd'),
        url = $__require('18d'),
        ono = $__require('179'),
        slashes = /\//g,
        tildes = /~/g,
        escapedSlash = /~1/g,
        escapedTilde = /~0/g;
    function Pointer($ref, path) {
      this.$ref = $ref;
      this.path = path;
      this.value = undefined;
      this.circular = false;
    }
    Pointer.prototype.resolve = function(obj, options) {
      var tokens = Pointer.parse(this.path);
      this.value = obj;
      for (var i = 0; i < tokens.length; i++) {
        if (resolveIf$Ref(this, options)) {
          this.path = Pointer.join(this.path, tokens.slice(i));
        }
        var token = tokens[i];
        if (this.value[token] === undefined) {
          throw ono.syntax('Error resolving $ref pointer "%s". \nToken "%s" does not exist.', this.path, token);
        } else {
          this.value = this.value[token];
        }
      }
      resolveIf$Ref(this, options);
      return this;
    };
    Pointer.prototype.set = function(obj, value, options) {
      var tokens = Pointer.parse(this.path);
      var token;
      if (tokens.length === 0) {
        this.value = value;
        return value;
      }
      this.value = obj;
      for (var i = 0; i < tokens.length - 1; i++) {
        resolveIf$Ref(this, options);
        token = tokens[i];
        if (this.value && this.value[token] !== undefined) {
          this.value = this.value[token];
        } else {
          this.value = setValue(this, token, {});
        }
      }
      resolveIf$Ref(this, options);
      token = tokens[tokens.length - 1];
      setValue(this, token, value);
      return obj;
    };
    Pointer.parse = function(path) {
      var pointer = url.getHash(path).substr(1);
      if (!pointer) {
        return [];
      }
      pointer = pointer.split('/');
      for (var i = 0; i < pointer.length; i++) {
        pointer[i] = decodeURI(pointer[i].replace(escapedSlash, '/').replace(escapedTilde, '~'));
      }
      if (pointer[0] !== '') {
        throw ono.syntax('Invalid $ref pointer "%s". Pointers must begin with "#/"', pointer);
      }
      return pointer.slice(1);
    };
    Pointer.join = function(base, tokens) {
      if (base.indexOf('#') === -1) {
        base += '#';
      }
      tokens = Array.isArray(tokens) ? tokens : [tokens];
      for (var i = 0; i < tokens.length; i++) {
        var token = tokens[i];
        base += '/' + encodeURI(token.replace(tildes, '~0').replace(slashes, '~1'));
      }
      return base;
    };
    function resolveIf$Ref(pointer, options) {
      if ($Ref.isAllowed$Ref(pointer.value, options)) {
        var $refPath = url.resolve(pointer.path, pointer.value.$ref);
        if ($refPath === pointer.path) {
          pointer.circular = true;
        } else {
          var resolved = pointer.$ref.$refs._resolve($refPath, options);
          if ($Ref.isExtended$Ref(pointer.value)) {
            pointer.value = $Ref.dereference(pointer.value, resolved.value);
          } else {
            pointer.$ref = resolved.$ref;
            pointer.path = resolved.path;
            pointer.value = resolved.value;
          }
          return true;
        }
      }
    }
    function setValue(pointer, token, value) {
      if (pointer.value && typeof pointer.value === 'object') {
        if (token === '-' && Array.isArray(pointer.value)) {
          pointer.value.push(value);
        } else {
          pointer.value[token] = value;
        }
      } else {
        throw ono.syntax('Error assigning $ref pointer "%s". \nCannot set "%s" of a non-object.', pointer.path, token);
      }
      return value;
    }
  })($__require('185').Buffer);
  return module.exports;
});

$__System.registerDynamic("200", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function isBuffer(arg) {
    return arg && typeof arg === 'object' && typeof arg.copy === 'function' && typeof arg.fill === 'function' && typeof arg.readUInt8 === 'function';
  };
  return module.exports;
});

$__System.registerDynamic("201", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  if (typeof Object.create === 'function') {
    module.exports = function inherits(ctor, superCtor) {
      ctor.super_ = superCtor;
      ctor.prototype = Object.create(superCtor.prototype, {constructor: {
          value: ctor,
          enumerable: false,
          writable: true,
          configurable: true
        }});
    };
  } else {
    module.exports = function inherits(ctor, superCtor) {
      ctor.super_ = superCtor;
      var TempCtor = function() {};
      TempCtor.prototype = superCtor.prototype;
      ctor.prototype = new TempCtor();
      ctor.prototype.constructor = ctor;
    };
  }
  return module.exports;
});

$__System.registerDynamic("191", ["201"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('201');
  return module.exports;
});

$__System.registerDynamic("202", ["200", "191", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    var formatRegExp = /%[sdj%]/g;
    exports.format = function(f) {
      if (!isString(f)) {
        var objects = [];
        for (var i = 0; i < arguments.length; i++) {
          objects.push(inspect(arguments[i]));
        }
        return objects.join(' ');
      }
      var i = 1;
      var args = arguments;
      var len = args.length;
      var str = String(f).replace(formatRegExp, function(x) {
        if (x === '%%')
          return '%';
        if (i >= len)
          return x;
        switch (x) {
          case '%s':
            return String(args[i++]);
          case '%d':
            return Number(args[i++]);
          case '%j':
            try {
              return JSON.stringify(args[i++]);
            } catch (_) {
              return '[Circular]';
            }
          default:
            return x;
        }
      });
      for (var x = args[i]; i < len; x = args[++i]) {
        if (isNull(x) || !isObject(x)) {
          str += ' ' + x;
        } else {
          str += ' ' + inspect(x);
        }
      }
      return str;
    };
    exports.deprecate = function(fn, msg) {
      if (isUndefined(global.process)) {
        return function() {
          return exports.deprecate(fn, msg).apply(this, arguments);
        };
      }
      if (process.noDeprecation === true) {
        return fn;
      }
      var warned = false;
      function deprecated() {
        if (!warned) {
          if (process.throwDeprecation) {
            throw new Error(msg);
          } else if (process.traceDeprecation) {
            console.trace(msg);
          } else {
            console.error(msg);
          }
          warned = true;
        }
        return fn.apply(this, arguments);
      }
      return deprecated;
    };
    var debugs = {};
    var debugEnviron;
    exports.debuglog = function(set) {
      if (isUndefined(debugEnviron))
        debugEnviron = process.env.NODE_DEBUG || '';
      set = set.toUpperCase();
      if (!debugs[set]) {
        if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
          var pid = process.pid;
          debugs[set] = function() {
            var msg = exports.format.apply(exports, arguments);
            console.error('%s %d: %s', set, pid, msg);
          };
        } else {
          debugs[set] = function() {};
        }
      }
      return debugs[set];
    };
    function inspect(obj, opts) {
      var ctx = {
        seen: [],
        stylize: stylizeNoColor
      };
      if (arguments.length >= 3)
        ctx.depth = arguments[2];
      if (arguments.length >= 4)
        ctx.colors = arguments[3];
      if (isBoolean(opts)) {
        ctx.showHidden = opts;
      } else if (opts) {
        exports._extend(ctx, opts);
      }
      if (isUndefined(ctx.showHidden))
        ctx.showHidden = false;
      if (isUndefined(ctx.depth))
        ctx.depth = 2;
      if (isUndefined(ctx.colors))
        ctx.colors = false;
      if (isUndefined(ctx.customInspect))
        ctx.customInspect = true;
      if (ctx.colors)
        ctx.stylize = stylizeWithColor;
      return formatValue(ctx, obj, ctx.depth);
    }
    exports.inspect = inspect;
    inspect.colors = {
      'bold': [1, 22],
      'italic': [3, 23],
      'underline': [4, 24],
      'inverse': [7, 27],
      'white': [37, 39],
      'grey': [90, 39],
      'black': [30, 39],
      'blue': [34, 39],
      'cyan': [36, 39],
      'green': [32, 39],
      'magenta': [35, 39],
      'red': [31, 39],
      'yellow': [33, 39]
    };
    inspect.styles = {
      'special': 'cyan',
      'number': 'yellow',
      'boolean': 'yellow',
      'undefined': 'grey',
      'null': 'bold',
      'string': 'green',
      'date': 'magenta',
      'regexp': 'red'
    };
    function stylizeWithColor(str, styleType) {
      var style = inspect.styles[styleType];
      if (style) {
        return '\u001b[' + inspect.colors[style][0] + 'm' + str + '\u001b[' + inspect.colors[style][1] + 'm';
      } else {
        return str;
      }
    }
    function stylizeNoColor(str, styleType) {
      return str;
    }
    function arrayToHash(array) {
      var hash = {};
      array.forEach(function(val, idx) {
        hash[val] = true;
      });
      return hash;
    }
    function formatValue(ctx, value, recurseTimes) {
      if (ctx.customInspect && value && isFunction(value.inspect) && value.inspect !== exports.inspect && !(value.constructor && value.constructor.prototype === value)) {
        var ret = value.inspect(recurseTimes, ctx);
        if (!isString(ret)) {
          ret = formatValue(ctx, ret, recurseTimes);
        }
        return ret;
      }
      var primitive = formatPrimitive(ctx, value);
      if (primitive) {
        return primitive;
      }
      var keys = Object.keys(value);
      var visibleKeys = arrayToHash(keys);
      if (ctx.showHidden) {
        keys = Object.getOwnPropertyNames(value);
      }
      if (isError(value) && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {
        return formatError(value);
      }
      if (keys.length === 0) {
        if (isFunction(value)) {
          var name = value.name ? ': ' + value.name : '';
          return ctx.stylize('[Function' + name + ']', 'special');
        }
        if (isRegExp(value)) {
          return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
        }
        if (isDate(value)) {
          return ctx.stylize(Date.prototype.toString.call(value), 'date');
        }
        if (isError(value)) {
          return formatError(value);
        }
      }
      var base = '',
          array = false,
          braces = ['{', '}'];
      if (isArray(value)) {
        array = true;
        braces = ['[', ']'];
      }
      if (isFunction(value)) {
        var n = value.name ? ': ' + value.name : '';
        base = ' [Function' + n + ']';
      }
      if (isRegExp(value)) {
        base = ' ' + RegExp.prototype.toString.call(value);
      }
      if (isDate(value)) {
        base = ' ' + Date.prototype.toUTCString.call(value);
      }
      if (isError(value)) {
        base = ' ' + formatError(value);
      }
      if (keys.length === 0 && (!array || value.length == 0)) {
        return braces[0] + base + braces[1];
      }
      if (recurseTimes < 0) {
        if (isRegExp(value)) {
          return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
        } else {
          return ctx.stylize('[Object]', 'special');
        }
      }
      ctx.seen.push(value);
      var output;
      if (array) {
        output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
      } else {
        output = keys.map(function(key) {
          return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
        });
      }
      ctx.seen.pop();
      return reduceToSingleString(output, base, braces);
    }
    function formatPrimitive(ctx, value) {
      if (isUndefined(value))
        return ctx.stylize('undefined', 'undefined');
      if (isString(value)) {
        var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '').replace(/'/g, "\\'").replace(/\\"/g, '"') + '\'';
        return ctx.stylize(simple, 'string');
      }
      if (isNumber(value))
        return ctx.stylize('' + value, 'number');
      if (isBoolean(value))
        return ctx.stylize('' + value, 'boolean');
      if (isNull(value))
        return ctx.stylize('null', 'null');
    }
    function formatError(value) {
      return '[' + Error.prototype.toString.call(value) + ']';
    }
    function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
      var output = [];
      for (var i = 0,
          l = value.length; i < l; ++i) {
        if (hasOwnProperty(value, String(i))) {
          output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, String(i), true));
        } else {
          output.push('');
        }
      }
      keys.forEach(function(key) {
        if (!key.match(/^\d+$/)) {
          output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, key, true));
        }
      });
      return output;
    }
    function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
      var name,
          str,
          desc;
      desc = Object.getOwnPropertyDescriptor(value, key) || {value: value[key]};
      if (desc.get) {
        if (desc.set) {
          str = ctx.stylize('[Getter/Setter]', 'special');
        } else {
          str = ctx.stylize('[Getter]', 'special');
        }
      } else {
        if (desc.set) {
          str = ctx.stylize('[Setter]', 'special');
        }
      }
      if (!hasOwnProperty(visibleKeys, key)) {
        name = '[' + key + ']';
      }
      if (!str) {
        if (ctx.seen.indexOf(desc.value) < 0) {
          if (isNull(recurseTimes)) {
            str = formatValue(ctx, desc.value, null);
          } else {
            str = formatValue(ctx, desc.value, recurseTimes - 1);
          }
          if (str.indexOf('\n') > -1) {
            if (array) {
              str = str.split('\n').map(function(line) {
                return '  ' + line;
              }).join('\n').substr(2);
            } else {
              str = '\n' + str.split('\n').map(function(line) {
                return '   ' + line;
              }).join('\n');
            }
          }
        } else {
          str = ctx.stylize('[Circular]', 'special');
        }
      }
      if (isUndefined(name)) {
        if (array && key.match(/^\d+$/)) {
          return str;
        }
        name = JSON.stringify('' + key);
        if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
          name = name.substr(1, name.length - 2);
          name = ctx.stylize(name, 'name');
        } else {
          name = name.replace(/'/g, "\\'").replace(/\\"/g, '"').replace(/(^"|"$)/g, "'");
          name = ctx.stylize(name, 'string');
        }
      }
      return name + ': ' + str;
    }
    function reduceToSingleString(output, base, braces) {
      var numLinesEst = 0;
      var length = output.reduce(function(prev, cur) {
        numLinesEst++;
        if (cur.indexOf('\n') >= 0)
          numLinesEst++;
        return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
      }, 0);
      if (length > 60) {
        return braces[0] + (base === '' ? '' : base + '\n ') + ' ' + output.join(',\n  ') + ' ' + braces[1];
      }
      return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
    }
    function isArray(ar) {
      return Array.isArray(ar);
    }
    exports.isArray = isArray;
    function isBoolean(arg) {
      return typeof arg === 'boolean';
    }
    exports.isBoolean = isBoolean;
    function isNull(arg) {
      return arg === null;
    }
    exports.isNull = isNull;
    function isNullOrUndefined(arg) {
      return arg == null;
    }
    exports.isNullOrUndefined = isNullOrUndefined;
    function isNumber(arg) {
      return typeof arg === 'number';
    }
    exports.isNumber = isNumber;
    function isString(arg) {
      return typeof arg === 'string';
    }
    exports.isString = isString;
    function isSymbol(arg) {
      return typeof arg === 'symbol';
    }
    exports.isSymbol = isSymbol;
    function isUndefined(arg) {
      return arg === void 0;
    }
    exports.isUndefined = isUndefined;
    function isRegExp(re) {
      return isObject(re) && objectToString(re) === '[object RegExp]';
    }
    exports.isRegExp = isRegExp;
    function isObject(arg) {
      return typeof arg === 'object' && arg !== null;
    }
    exports.isObject = isObject;
    function isDate(d) {
      return isObject(d) && objectToString(d) === '[object Date]';
    }
    exports.isDate = isDate;
    function isError(e) {
      return isObject(e) && (objectToString(e) === '[object Error]' || e instanceof Error);
    }
    exports.isError = isError;
    function isFunction(arg) {
      return typeof arg === 'function';
    }
    exports.isFunction = isFunction;
    function isPrimitive(arg) {
      return arg === null || typeof arg === 'boolean' || typeof arg === 'number' || typeof arg === 'string' || typeof arg === 'symbol' || typeof arg === 'undefined';
    }
    exports.isPrimitive = isPrimitive;
    exports.isBuffer = $__require('200');
    function objectToString(o) {
      return Object.prototype.toString.call(o);
    }
    function pad(n) {
      return n < 10 ? '0' + n.toString(10) : n.toString(10);
    }
    var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
    function timestamp() {
      var d = new Date();
      var time = [pad(d.getHours()), pad(d.getMinutes()), pad(d.getSeconds())].join(':');
      return [d.getDate(), months[d.getMonth()], time].join(' ');
    }
    exports.log = function() {
      console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
    };
    exports.inherits = $__require('191');
    exports._extend = function(origin, add) {
      if (!add || !isObject(add))
        return origin;
      var keys = Object.keys(add);
      var i = keys.length;
      while (i--) {
        origin[keys[i]] = add[keys[i]];
      }
      return origin;
    };
    function hasOwnProperty(obj, prop) {
      return Object.prototype.hasOwnProperty.call(obj, prop);
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("203", ["202"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('202');
  return module.exports;
});

$__System.registerDynamic("204", ["203"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('util') : $__require('203');
  return module.exports;
});

$__System.registerDynamic("17e", ["204"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('204');
  return module.exports;
});

$__System.registerDynamic("205", ["17e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var util = $__require('17e'),
      slice = Array.prototype.slice,
      vendorSpecificErrorProperties = ['name', 'message', 'description', 'number', 'fileName', 'lineNumber', 'columnNumber', 'sourceURL', 'line', 'column', 'stack'];
  module.exports = create(Error);
  module.exports.error = create(Error);
  module.exports.eval = create(EvalError);
  module.exports.range = create(RangeError);
  module.exports.reference = create(ReferenceError);
  module.exports.syntax = create(SyntaxError);
  module.exports.type = create(TypeError);
  module.exports.uri = create(URIError);
  module.exports.formatter = util.format;
  function create(Klass) {
    return function ono(err, props, message, params) {
      var formattedMessage;
      var formatter = module.exports.formatter;
      if (typeof(err) === 'string') {
        formattedMessage = formatter.apply(null, arguments);
        err = props = undefined;
      } else if (typeof(props) === 'string') {
        formattedMessage = formatter.apply(null, slice.call(arguments, 1));
      } else {
        formattedMessage = formatter.apply(null, slice.call(arguments, 2));
      }
      if (!(err instanceof Error)) {
        props = err;
        err = undefined;
      }
      if (err) {
        formattedMessage += (formattedMessage ? ' \n' : '') + err.message;
      }
      var newError = new Klass(formattedMessage);
      extendError(newError, err);
      extendToJSON(newError);
      extend(newError, props);
      return newError;
    };
  }
  function extendError(targetError, sourceError) {
    if (sourceError) {
      extendStack(targetError, sourceError);
      extend(targetError, sourceError, true);
    }
  }
  function extendToJSON(error) {
    error.toJSON = errorToJSON;
    error.inspect = errorToString;
  }
  function extend(target, source, omitVendorSpecificProperties) {
    if (source && typeof(source) === 'object') {
      var keys = Object.keys(source);
      for (var i = 0; i < keys.length; i++) {
        var key = keys[i];
        if (omitVendorSpecificProperties && vendorSpecificErrorProperties.indexOf(key) >= 0) {
          continue;
        }
        try {
          target[key] = source[key];
        } catch (e) {}
      }
    }
  }
  function errorToJSON() {
    var json = {};
    var keys = Object.keys(this);
    keys = keys.concat(vendorSpecificErrorProperties);
    for (var i = 0; i < keys.length; i++) {
      var key = keys[i];
      var value = this[key];
      var type = typeof value;
      if (type !== 'undefined' && type !== 'function') {
        json[key] = value;
      }
    }
    return json;
  }
  function errorToString() {
    return JSON.stringify(this, null, 2).replace(/\\n/g, '\n');
  }
  function extendStack(targetError, sourceError) {
    if (hasLazyStack(sourceError)) {
      extendStackProperty(targetError, sourceError);
    } else {
      var stack = sourceError.stack;
      if (stack) {
        targetError.stack += ' \n\n' + sourceError.stack;
      }
    }
  }
  var supportsLazyStack = (function() {
    return !!(Object.getOwnPropertyDescriptor && Object.defineProperty && (typeof navigator === 'undefined' || !/Android/.test(navigator.userAgent)));
  })();
  function hasLazyStack(err) {
    if (!supportsLazyStack) {
      return false;
    }
    var descriptor = Object.getOwnPropertyDescriptor(err, 'stack');
    if (!descriptor) {
      return false;
    }
    return typeof descriptor.get === 'function';
  }
  function extendStackProperty(targetError, sourceError) {
    var sourceStack = Object.getOwnPropertyDescriptor(sourceError, 'stack');
    if (sourceStack) {
      var targetStack = Object.getOwnPropertyDescriptor(targetError, 'stack');
      Object.defineProperty(targetError, 'stack', {
        get: function() {
          return targetStack.get.apply(targetError) + ' \n\n' + sourceError.stack;
        },
        enumerable: false,
        configurable: true
      });
    }
  }
  return module.exports;
});

$__System.registerDynamic("179", ["205"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('205');
  return module.exports;
});

$__System.registerDynamic("206", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var s = 1000;
  var m = s * 60;
  var h = m * 60;
  var d = h * 24;
  var y = d * 365.25;
  module.exports = function(val, options) {
    options = options || {};
    if ('string' == typeof val)
      return parse(val);
    return options.long ? long(val) : short(val);
  };
  function parse(str) {
    str = '' + str;
    if (str.length > 10000)
      return;
    var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(str);
    if (!match)
      return;
    var n = parseFloat(match[1]);
    var type = (match[2] || 'ms').toLowerCase();
    switch (type) {
      case 'years':
      case 'year':
      case 'yrs':
      case 'yr':
      case 'y':
        return n * y;
      case 'days':
      case 'day':
      case 'd':
        return n * d;
      case 'hours':
      case 'hour':
      case 'hrs':
      case 'hr':
      case 'h':
        return n * h;
      case 'minutes':
      case 'minute':
      case 'mins':
      case 'min':
      case 'm':
        return n * m;
      case 'seconds':
      case 'second':
      case 'secs':
      case 'sec':
      case 's':
        return n * s;
      case 'milliseconds':
      case 'millisecond':
      case 'msecs':
      case 'msec':
      case 'ms':
        return n;
    }
  }
  function short(ms) {
    if (ms >= d)
      return Math.round(ms / d) + 'd';
    if (ms >= h)
      return Math.round(ms / h) + 'h';
    if (ms >= m)
      return Math.round(ms / m) + 'm';
    if (ms >= s)
      return Math.round(ms / s) + 's';
    return ms + 'ms';
  }
  function long(ms) {
    return plural(ms, d, 'day') || plural(ms, h, 'hour') || plural(ms, m, 'minute') || plural(ms, s, 'second') || ms + ' ms';
  }
  function plural(ms, n, name) {
    if (ms < n)
      return;
    if (ms < n * 1.5)
      return Math.floor(ms / n) + ' ' + name;
    return Math.ceil(ms / n) + ' ' + name + 's';
  }
  return module.exports;
});

$__System.registerDynamic("207", ["206"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('206');
  return module.exports;
});

$__System.registerDynamic("208", ["207"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports = module.exports = debug;
  exports.coerce = coerce;
  exports.disable = disable;
  exports.enable = enable;
  exports.enabled = enabled;
  exports.humanize = $__require('207');
  exports.names = [];
  exports.skips = [];
  exports.formatters = {};
  var prevColor = 0;
  var prevTime;
  function selectColor() {
    return exports.colors[prevColor++ % exports.colors.length];
  }
  function debug(namespace) {
    function disabled() {}
    disabled.enabled = false;
    function enabled() {
      var self = enabled;
      var curr = +new Date();
      var ms = curr - (prevTime || curr);
      self.diff = ms;
      self.prev = prevTime;
      self.curr = curr;
      prevTime = curr;
      if (null == self.useColors)
        self.useColors = exports.useColors();
      if (null == self.color && self.useColors)
        self.color = selectColor();
      var args = Array.prototype.slice.call(arguments);
      args[0] = exports.coerce(args[0]);
      if ('string' !== typeof args[0]) {
        args = ['%o'].concat(args);
      }
      var index = 0;
      args[0] = args[0].replace(/%([a-z%])/g, function(match, format) {
        if (match === '%%')
          return match;
        index++;
        var formatter = exports.formatters[format];
        if ('function' === typeof formatter) {
          var val = args[index];
          match = formatter.call(self, val);
          args.splice(index, 1);
          index--;
        }
        return match;
      });
      if ('function' === typeof exports.formatArgs) {
        args = exports.formatArgs.apply(self, args);
      }
      var logFn = enabled.log || exports.log || console.log.bind(console);
      logFn.apply(self, args);
    }
    enabled.enabled = true;
    var fn = exports.enabled(namespace) ? enabled : disabled;
    fn.namespace = namespace;
    return fn;
  }
  function enable(namespaces) {
    exports.save(namespaces);
    var split = (namespaces || '').split(/[\s,]+/);
    var len = split.length;
    for (var i = 0; i < len; i++) {
      if (!split[i])
        continue;
      namespaces = split[i].replace(/\*/g, '.*?');
      if (namespaces[0] === '-') {
        exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
      } else {
        exports.names.push(new RegExp('^' + namespaces + '$'));
      }
    }
  }
  function disable() {
    exports.enable('');
  }
  function enabled(name) {
    var i,
        len;
    for (i = 0, len = exports.skips.length; i < len; i++) {
      if (exports.skips[i].test(name)) {
        return false;
      }
    }
    for (i = 0, len = exports.names.length; i < len; i++) {
      if (exports.names[i].test(name)) {
        return true;
      }
    }
    return false;
  }
  function coerce(val) {
    if (val instanceof Error)
      return val.stack || val.message;
    return val;
  }
  return module.exports;
});

$__System.registerDynamic("209", ["208"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports = module.exports = $__require('208');
  exports.log = log;
  exports.formatArgs = formatArgs;
  exports.save = save;
  exports.load = load;
  exports.useColors = useColors;
  exports.storage = 'undefined' != typeof chrome && 'undefined' != typeof chrome.storage ? chrome.storage.local : localstorage();
  exports.colors = ['lightseagreen', 'forestgreen', 'goldenrod', 'dodgerblue', 'darkorchid', 'crimson'];
  function useColors() {
    return ('WebkitAppearance' in document.documentElement.style) || (window.console && (console.firebug || (console.exception && console.table))) || (navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31);
  }
  exports.formatters.j = function(v) {
    return JSON.stringify(v);
  };
  function formatArgs() {
    var args = arguments;
    var useColors = this.useColors;
    args[0] = (useColors ? '%c' : '') + this.namespace + (useColors ? ' %c' : ' ') + args[0] + (useColors ? '%c ' : ' ') + '+' + exports.humanize(this.diff);
    if (!useColors)
      return args;
    var c = 'color: ' + this.color;
    args = [args[0], c, 'color: inherit'].concat(Array.prototype.slice.call(args, 1));
    var index = 0;
    var lastC = 0;
    args[0].replace(/%[a-z%]/g, function(match) {
      if ('%%' === match)
        return;
      index++;
      if ('%c' === match) {
        lastC = index;
      }
    });
    args.splice(lastC, 0, c);
    return args;
  }
  function log() {
    return 'object' === typeof console && console.log && Function.prototype.apply.call(console.log, console, arguments);
  }
  function save(namespaces) {
    try {
      if (null == namespaces) {
        exports.storage.removeItem('debug');
      } else {
        exports.storage.debug = namespaces;
      }
    } catch (e) {}
  }
  function load() {
    var r;
    try {
      r = exports.storage.debug;
    } catch (e) {}
    return r;
  }
  exports.enable(load());
  function localstorage() {
    try {
      return window.localStorage;
    } catch (e) {}
  }
  return module.exports;
});

$__System.registerDynamic("17d", ["209"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('209');
  return module.exports;
});

$__System.registerDynamic("18e", ["17d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var debug = $__require('17d');
  module.exports = debug('json-schema-ref-parser');
  return module.exports;
});

$__System.registerDynamic("20a", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  (function(process) {
    ;
    (function(root) {
      var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;
      var freeModule = typeof module == 'object' && module && !module.nodeType && module;
      var freeGlobal = typeof global == 'object' && global;
      if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal || freeGlobal.self === freeGlobal) {
        root = freeGlobal;
      }
      var punycode,
          maxInt = 2147483647,
          base = 36,
          tMin = 1,
          tMax = 26,
          skew = 38,
          damp = 700,
          initialBias = 72,
          initialN = 128,
          delimiter = '-',
          regexPunycode = /^xn--/,
          regexNonASCII = /[^\x20-\x7E]/,
          regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g,
          errors = {
            'overflow': 'Overflow: input needs wider integers to process',
            'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
            'invalid-input': 'Invalid input'
          },
          baseMinusTMin = base - tMin,
          floor = Math.floor,
          stringFromCharCode = String.fromCharCode,
          key;
      function error(type) {
        throw RangeError(errors[type]);
      }
      function map(array, fn) {
        var length = array.length;
        var result = [];
        while (length--) {
          result[length] = fn(array[length]);
        }
        return result;
      }
      function mapDomain(string, fn) {
        var parts = string.split('@');
        var result = '';
        if (parts.length > 1) {
          result = parts[0] + '@';
          string = parts[1];
        }
        string = string.replace(regexSeparators, '\x2E');
        var labels = string.split('.');
        var encoded = map(labels, fn).join('.');
        return result + encoded;
      }
      function ucs2decode(string) {
        var output = [],
            counter = 0,
            length = string.length,
            value,
            extra;
        while (counter < length) {
          value = string.charCodeAt(counter++);
          if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
            extra = string.charCodeAt(counter++);
            if ((extra & 0xFC00) == 0xDC00) {
              output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
            } else {
              output.push(value);
              counter--;
            }
          } else {
            output.push(value);
          }
        }
        return output;
      }
      function ucs2encode(array) {
        return map(array, function(value) {
          var output = '';
          if (value > 0xFFFF) {
            value -= 0x10000;
            output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);
            value = 0xDC00 | value & 0x3FF;
          }
          output += stringFromCharCode(value);
          return output;
        }).join('');
      }
      function basicToDigit(codePoint) {
        if (codePoint - 48 < 10) {
          return codePoint - 22;
        }
        if (codePoint - 65 < 26) {
          return codePoint - 65;
        }
        if (codePoint - 97 < 26) {
          return codePoint - 97;
        }
        return base;
      }
      function digitToBasic(digit, flag) {
        return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
      }
      function adapt(delta, numPoints, firstTime) {
        var k = 0;
        delta = firstTime ? floor(delta / damp) : delta >> 1;
        delta += floor(delta / numPoints);
        for (; delta > baseMinusTMin * tMax >> 1; k += base) {
          delta = floor(delta / baseMinusTMin);
        }
        return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
      }
      function decode(input) {
        var output = [],
            inputLength = input.length,
            out,
            i = 0,
            n = initialN,
            bias = initialBias,
            basic,
            j,
            index,
            oldi,
            w,
            k,
            digit,
            t,
            baseMinusT;
        basic = input.lastIndexOf(delimiter);
        if (basic < 0) {
          basic = 0;
        }
        for (j = 0; j < basic; ++j) {
          if (input.charCodeAt(j) >= 0x80) {
            error('not-basic');
          }
          output.push(input.charCodeAt(j));
        }
        for (index = basic > 0 ? basic + 1 : 0; index < inputLength; ) {
          for (oldi = i, w = 1, k = base; ; k += base) {
            if (index >= inputLength) {
              error('invalid-input');
            }
            digit = basicToDigit(input.charCodeAt(index++));
            if (digit >= base || digit > floor((maxInt - i) / w)) {
              error('overflow');
            }
            i += digit * w;
            t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
            if (digit < t) {
              break;
            }
            baseMinusT = base - t;
            if (w > floor(maxInt / baseMinusT)) {
              error('overflow');
            }
            w *= baseMinusT;
          }
          out = output.length + 1;
          bias = adapt(i - oldi, out, oldi == 0);
          if (floor(i / out) > maxInt - n) {
            error('overflow');
          }
          n += floor(i / out);
          i %= out;
          output.splice(i++, 0, n);
        }
        return ucs2encode(output);
      }
      function encode(input) {
        var n,
            delta,
            handledCPCount,
            basicLength,
            bias,
            j,
            m,
            q,
            k,
            t,
            currentValue,
            output = [],
            inputLength,
            handledCPCountPlusOne,
            baseMinusT,
            qMinusT;
        input = ucs2decode(input);
        inputLength = input.length;
        n = initialN;
        delta = 0;
        bias = initialBias;
        for (j = 0; j < inputLength; ++j) {
          currentValue = input[j];
          if (currentValue < 0x80) {
            output.push(stringFromCharCode(currentValue));
          }
        }
        handledCPCount = basicLength = output.length;
        if (basicLength) {
          output.push(delimiter);
        }
        while (handledCPCount < inputLength) {
          for (m = maxInt, j = 0; j < inputLength; ++j) {
            currentValue = input[j];
            if (currentValue >= n && currentValue < m) {
              m = currentValue;
            }
          }
          handledCPCountPlusOne = handledCPCount + 1;
          if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
            error('overflow');
          }
          delta += (m - n) * handledCPCountPlusOne;
          n = m;
          for (j = 0; j < inputLength; ++j) {
            currentValue = input[j];
            if (currentValue < n && ++delta > maxInt) {
              error('overflow');
            }
            if (currentValue == n) {
              for (q = delta, k = base; ; k += base) {
                t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
                if (q < t) {
                  break;
                }
                qMinusT = q - t;
                baseMinusT = base - t;
                output.push(stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0)));
                q = floor(qMinusT / baseMinusT);
              }
              output.push(stringFromCharCode(digitToBasic(q, 0)));
              bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);
              delta = 0;
              ++handledCPCount;
            }
          }
          ++delta;
          ++n;
        }
        return output.join('');
      }
      function toUnicode(input) {
        return mapDomain(input, function(string) {
          return regexPunycode.test(string) ? decode(string.slice(4).toLowerCase()) : string;
        });
      }
      function toASCII(input) {
        return mapDomain(input, function(string) {
          return regexNonASCII.test(string) ? 'xn--' + encode(string) : string;
        });
      }
      punycode = {
        'version': '1.3.2',
        'ucs2': {
          'decode': ucs2decode,
          'encode': ucs2encode
        },
        'decode': decode,
        'encode': encode,
        'toASCII': toASCII,
        'toUnicode': toUnicode
      };
      if (typeof define == 'function' && typeof define.amd == 'object' && define.amd) {
        define('punycode', function() {
          return punycode;
        });
      } else if (freeExports && freeModule) {
        if (module.exports == freeExports) {
          freeModule.exports = punycode;
        } else {
          for (key in punycode) {
            punycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);
          }
        }
      } else {
        root.punycode = punycode;
      }
    }(this));
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("20b", ["20a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('20a');
  return module.exports;
});

$__System.registerDynamic("20c", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function hasOwnProperty(obj, prop) {
    return Object.prototype.hasOwnProperty.call(obj, prop);
  }
  module.exports = function(qs, sep, eq, options) {
    sep = sep || '&';
    eq = eq || '=';
    var obj = {};
    if (typeof qs !== 'string' || qs.length === 0) {
      return obj;
    }
    var regexp = /\+/g;
    qs = qs.split(sep);
    var maxKeys = 1000;
    if (options && typeof options.maxKeys === 'number') {
      maxKeys = options.maxKeys;
    }
    var len = qs.length;
    if (maxKeys > 0 && len > maxKeys) {
      len = maxKeys;
    }
    for (var i = 0; i < len; ++i) {
      var x = qs[i].replace(regexp, '%20'),
          idx = x.indexOf(eq),
          kstr,
          vstr,
          k,
          v;
      if (idx >= 0) {
        kstr = x.substr(0, idx);
        vstr = x.substr(idx + 1);
      } else {
        kstr = x;
        vstr = '';
      }
      k = decodeURIComponent(kstr);
      v = decodeURIComponent(vstr);
      if (!hasOwnProperty(obj, k)) {
        obj[k] = v;
      } else if (Array.isArray(obj[k])) {
        obj[k].push(v);
      } else {
        obj[k] = [obj[k], v];
      }
    }
    return obj;
  };
  return module.exports;
});

$__System.registerDynamic("20d", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var stringifyPrimitive = function(v) {
    switch (typeof v) {
      case 'string':
        return v;
      case 'boolean':
        return v ? 'true' : 'false';
      case 'number':
        return isFinite(v) ? v : '';
      default:
        return '';
    }
  };
  module.exports = function(obj, sep, eq, name) {
    sep = sep || '&';
    eq = eq || '=';
    if (obj === null) {
      obj = undefined;
    }
    if (typeof obj === 'object') {
      return Object.keys(obj).map(function(k) {
        var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;
        if (Array.isArray(obj[k])) {
          return obj[k].map(function(v) {
            return ks + encodeURIComponent(stringifyPrimitive(v));
          }).join(sep);
        } else {
          return ks + encodeURIComponent(stringifyPrimitive(obj[k]));
        }
      }).join(sep);
    }
    if (!name)
      return '';
    return encodeURIComponent(stringifyPrimitive(name)) + eq + encodeURIComponent(stringifyPrimitive(obj));
  };
  return module.exports;
});

$__System.registerDynamic("20e", ["20c", "20d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.decode = exports.parse = $__require('20c');
  exports.encode = exports.stringify = $__require('20d');
  return module.exports;
});

$__System.registerDynamic("20f", ["20e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('20e');
  return module.exports;
});

$__System.registerDynamic("210", ["20b", "20f"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var punycode = $__require('20b');
  exports.parse = urlParse;
  exports.resolve = urlResolve;
  exports.resolveObject = urlResolveObject;
  exports.format = urlFormat;
  exports.Url = Url;
  function Url() {
    this.protocol = null;
    this.slashes = null;
    this.auth = null;
    this.host = null;
    this.port = null;
    this.hostname = null;
    this.hash = null;
    this.search = null;
    this.query = null;
    this.pathname = null;
    this.path = null;
    this.href = null;
  }
  var protocolPattern = /^([a-z0-9.+-]+:)/i,
      portPattern = /:[0-9]*$/,
      delims = ['<', '>', '"', '`', ' ', '\r', '\n', '\t'],
      unwise = ['{', '}', '|', '\\', '^', '`'].concat(delims),
      autoEscape = ['\''].concat(unwise),
      nonHostChars = ['%', '/', '?', ';', '#'].concat(autoEscape),
      hostEndingChars = ['/', '?', '#'],
      hostnameMaxLen = 255,
      hostnamePartPattern = /^[a-z0-9A-Z_-]{0,63}$/,
      hostnamePartStart = /^([a-z0-9A-Z_-]{0,63})(.*)$/,
      unsafeProtocol = {
        'javascript': true,
        'javascript:': true
      },
      hostlessProtocol = {
        'javascript': true,
        'javascript:': true
      },
      slashedProtocol = {
        'http': true,
        'https': true,
        'ftp': true,
        'gopher': true,
        'file': true,
        'http:': true,
        'https:': true,
        'ftp:': true,
        'gopher:': true,
        'file:': true
      },
      querystring = $__require('20f');
  function urlParse(url, parseQueryString, slashesDenoteHost) {
    if (url && isObject(url) && url instanceof Url)
      return url;
    var u = new Url;
    u.parse(url, parseQueryString, slashesDenoteHost);
    return u;
  }
  Url.prototype.parse = function(url, parseQueryString, slashesDenoteHost) {
    if (!isString(url)) {
      throw new TypeError("Parameter 'url' must be a string, not " + typeof url);
    }
    var rest = url;
    rest = rest.trim();
    var proto = protocolPattern.exec(rest);
    if (proto) {
      proto = proto[0];
      var lowerProto = proto.toLowerCase();
      this.protocol = lowerProto;
      rest = rest.substr(proto.length);
    }
    if (slashesDenoteHost || proto || rest.match(/^\/\/[^@\/]+@[^@\/]+/)) {
      var slashes = rest.substr(0, 2) === '//';
      if (slashes && !(proto && hostlessProtocol[proto])) {
        rest = rest.substr(2);
        this.slashes = true;
      }
    }
    if (!hostlessProtocol[proto] && (slashes || (proto && !slashedProtocol[proto]))) {
      var hostEnd = -1;
      for (var i = 0; i < hostEndingChars.length; i++) {
        var hec = rest.indexOf(hostEndingChars[i]);
        if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))
          hostEnd = hec;
      }
      var auth,
          atSign;
      if (hostEnd === -1) {
        atSign = rest.lastIndexOf('@');
      } else {
        atSign = rest.lastIndexOf('@', hostEnd);
      }
      if (atSign !== -1) {
        auth = rest.slice(0, atSign);
        rest = rest.slice(atSign + 1);
        this.auth = decodeURIComponent(auth);
      }
      hostEnd = -1;
      for (var i = 0; i < nonHostChars.length; i++) {
        var hec = rest.indexOf(nonHostChars[i]);
        if (hec !== -1 && (hostEnd === -1 || hec < hostEnd))
          hostEnd = hec;
      }
      if (hostEnd === -1)
        hostEnd = rest.length;
      this.host = rest.slice(0, hostEnd);
      rest = rest.slice(hostEnd);
      this.parseHost();
      this.hostname = this.hostname || '';
      var ipv6Hostname = this.hostname[0] === '[' && this.hostname[this.hostname.length - 1] === ']';
      if (!ipv6Hostname) {
        var hostparts = this.hostname.split(/\./);
        for (var i = 0,
            l = hostparts.length; i < l; i++) {
          var part = hostparts[i];
          if (!part)
            continue;
          if (!part.match(hostnamePartPattern)) {
            var newpart = '';
            for (var j = 0,
                k = part.length; j < k; j++) {
              if (part.charCodeAt(j) > 127) {
                newpart += 'x';
              } else {
                newpart += part[j];
              }
            }
            if (!newpart.match(hostnamePartPattern)) {
              var validParts = hostparts.slice(0, i);
              var notHost = hostparts.slice(i + 1);
              var bit = part.match(hostnamePartStart);
              if (bit) {
                validParts.push(bit[1]);
                notHost.unshift(bit[2]);
              }
              if (notHost.length) {
                rest = '/' + notHost.join('.') + rest;
              }
              this.hostname = validParts.join('.');
              break;
            }
          }
        }
      }
      if (this.hostname.length > hostnameMaxLen) {
        this.hostname = '';
      } else {
        this.hostname = this.hostname.toLowerCase();
      }
      if (!ipv6Hostname) {
        var domainArray = this.hostname.split('.');
        var newOut = [];
        for (var i = 0; i < domainArray.length; ++i) {
          var s = domainArray[i];
          newOut.push(s.match(/[^A-Za-z0-9_-]/) ? 'xn--' + punycode.encode(s) : s);
        }
        this.hostname = newOut.join('.');
      }
      var p = this.port ? ':' + this.port : '';
      var h = this.hostname || '';
      this.host = h + p;
      this.href += this.host;
      if (ipv6Hostname) {
        this.hostname = this.hostname.substr(1, this.hostname.length - 2);
        if (rest[0] !== '/') {
          rest = '/' + rest;
        }
      }
    }
    if (!unsafeProtocol[lowerProto]) {
      for (var i = 0,
          l = autoEscape.length; i < l; i++) {
        var ae = autoEscape[i];
        var esc = encodeURIComponent(ae);
        if (esc === ae) {
          esc = escape(ae);
        }
        rest = rest.split(ae).join(esc);
      }
    }
    var hash = rest.indexOf('#');
    if (hash !== -1) {
      this.hash = rest.substr(hash);
      rest = rest.slice(0, hash);
    }
    var qm = rest.indexOf('?');
    if (qm !== -1) {
      this.search = rest.substr(qm);
      this.query = rest.substr(qm + 1);
      if (parseQueryString) {
        this.query = querystring.parse(this.query);
      }
      rest = rest.slice(0, qm);
    } else if (parseQueryString) {
      this.search = '';
      this.query = {};
    }
    if (rest)
      this.pathname = rest;
    if (slashedProtocol[lowerProto] && this.hostname && !this.pathname) {
      this.pathname = '/';
    }
    if (this.pathname || this.search) {
      var p = this.pathname || '';
      var s = this.search || '';
      this.path = p + s;
    }
    this.href = this.format();
    return this;
  };
  function urlFormat(obj) {
    if (isString(obj))
      obj = urlParse(obj);
    if (!(obj instanceof Url))
      return Url.prototype.format.call(obj);
    return obj.format();
  }
  Url.prototype.format = function() {
    var auth = this.auth || '';
    if (auth) {
      auth = encodeURIComponent(auth);
      auth = auth.replace(/%3A/i, ':');
      auth += '@';
    }
    var protocol = this.protocol || '',
        pathname = this.pathname || '',
        hash = this.hash || '',
        host = false,
        query = '';
    if (this.host) {
      host = auth + this.host;
    } else if (this.hostname) {
      host = auth + (this.hostname.indexOf(':') === -1 ? this.hostname : '[' + this.hostname + ']');
      if (this.port) {
        host += ':' + this.port;
      }
    }
    if (this.query && isObject(this.query) && Object.keys(this.query).length) {
      query = querystring.stringify(this.query);
    }
    var search = this.search || (query && ('?' + query)) || '';
    if (protocol && protocol.substr(-1) !== ':')
      protocol += ':';
    if (this.slashes || (!protocol || slashedProtocol[protocol]) && host !== false) {
      host = '//' + (host || '');
      if (pathname && pathname.charAt(0) !== '/')
        pathname = '/' + pathname;
    } else if (!host) {
      host = '';
    }
    if (hash && hash.charAt(0) !== '#')
      hash = '#' + hash;
    if (search && search.charAt(0) !== '?')
      search = '?' + search;
    pathname = pathname.replace(/[?#]/g, function(match) {
      return encodeURIComponent(match);
    });
    search = search.replace('#', '%23');
    return protocol + host + pathname + search + hash;
  };
  function urlResolve(source, relative) {
    return urlParse(source, false, true).resolve(relative);
  }
  Url.prototype.resolve = function(relative) {
    return this.resolveObject(urlParse(relative, false, true)).format();
  };
  function urlResolveObject(source, relative) {
    if (!source)
      return relative;
    return urlParse(source, false, true).resolveObject(relative);
  }
  Url.prototype.resolveObject = function(relative) {
    if (isString(relative)) {
      var rel = new Url();
      rel.parse(relative, false, true);
      relative = rel;
    }
    var result = new Url();
    Object.keys(this).forEach(function(k) {
      result[k] = this[k];
    }, this);
    result.hash = relative.hash;
    if (relative.href === '') {
      result.href = result.format();
      return result;
    }
    if (relative.slashes && !relative.protocol) {
      Object.keys(relative).forEach(function(k) {
        if (k !== 'protocol')
          result[k] = relative[k];
      });
      if (slashedProtocol[result.protocol] && result.hostname && !result.pathname) {
        result.path = result.pathname = '/';
      }
      result.href = result.format();
      return result;
    }
    if (relative.protocol && relative.protocol !== result.protocol) {
      if (!slashedProtocol[relative.protocol]) {
        Object.keys(relative).forEach(function(k) {
          result[k] = relative[k];
        });
        result.href = result.format();
        return result;
      }
      result.protocol = relative.protocol;
      if (!relative.host && !hostlessProtocol[relative.protocol]) {
        var relPath = (relative.pathname || '').split('/');
        while (relPath.length && !(relative.host = relPath.shift()))
          ;
        if (!relative.host)
          relative.host = '';
        if (!relative.hostname)
          relative.hostname = '';
        if (relPath[0] !== '')
          relPath.unshift('');
        if (relPath.length < 2)
          relPath.unshift('');
        result.pathname = relPath.join('/');
      } else {
        result.pathname = relative.pathname;
      }
      result.search = relative.search;
      result.query = relative.query;
      result.host = relative.host || '';
      result.auth = relative.auth;
      result.hostname = relative.hostname || relative.host;
      result.port = relative.port;
      if (result.pathname || result.search) {
        var p = result.pathname || '';
        var s = result.search || '';
        result.path = p + s;
      }
      result.slashes = result.slashes || relative.slashes;
      result.href = result.format();
      return result;
    }
    var isSourceAbs = (result.pathname && result.pathname.charAt(0) === '/'),
        isRelAbs = (relative.host || relative.pathname && relative.pathname.charAt(0) === '/'),
        mustEndAbs = (isRelAbs || isSourceAbs || (result.host && relative.pathname)),
        removeAllDots = mustEndAbs,
        srcPath = result.pathname && result.pathname.split('/') || [],
        relPath = relative.pathname && relative.pathname.split('/') || [],
        psychotic = result.protocol && !slashedProtocol[result.protocol];
    if (psychotic) {
      result.hostname = '';
      result.port = null;
      if (result.host) {
        if (srcPath[0] === '')
          srcPath[0] = result.host;
        else
          srcPath.unshift(result.host);
      }
      result.host = '';
      if (relative.protocol) {
        relative.hostname = null;
        relative.port = null;
        if (relative.host) {
          if (relPath[0] === '')
            relPath[0] = relative.host;
          else
            relPath.unshift(relative.host);
        }
        relative.host = null;
      }
      mustEndAbs = mustEndAbs && (relPath[0] === '' || srcPath[0] === '');
    }
    if (isRelAbs) {
      result.host = (relative.host || relative.host === '') ? relative.host : result.host;
      result.hostname = (relative.hostname || relative.hostname === '') ? relative.hostname : result.hostname;
      result.search = relative.search;
      result.query = relative.query;
      srcPath = relPath;
    } else if (relPath.length) {
      if (!srcPath)
        srcPath = [];
      srcPath.pop();
      srcPath = srcPath.concat(relPath);
      result.search = relative.search;
      result.query = relative.query;
    } else if (!isNullOrUndefined(relative.search)) {
      if (psychotic) {
        result.hostname = result.host = srcPath.shift();
        var authInHost = result.host && result.host.indexOf('@') > 0 ? result.host.split('@') : false;
        if (authInHost) {
          result.auth = authInHost.shift();
          result.host = result.hostname = authInHost.shift();
        }
      }
      result.search = relative.search;
      result.query = relative.query;
      if (!isNull(result.pathname) || !isNull(result.search)) {
        result.path = (result.pathname ? result.pathname : '') + (result.search ? result.search : '');
      }
      result.href = result.format();
      return result;
    }
    if (!srcPath.length) {
      result.pathname = null;
      if (result.search) {
        result.path = '/' + result.search;
      } else {
        result.path = null;
      }
      result.href = result.format();
      return result;
    }
    var last = srcPath.slice(-1)[0];
    var hasTrailingSlash = ((result.host || relative.host) && (last === '.' || last === '..') || last === '');
    var up = 0;
    for (var i = srcPath.length; i >= 0; i--) {
      last = srcPath[i];
      if (last == '.') {
        srcPath.splice(i, 1);
      } else if (last === '..') {
        srcPath.splice(i, 1);
        up++;
      } else if (up) {
        srcPath.splice(i, 1);
        up--;
      }
    }
    if (!mustEndAbs && !removeAllDots) {
      for (; up--; up) {
        srcPath.unshift('..');
      }
    }
    if (mustEndAbs && srcPath[0] !== '' && (!srcPath[0] || srcPath[0].charAt(0) !== '/')) {
      srcPath.unshift('');
    }
    if (hasTrailingSlash && (srcPath.join('/').substr(-1) !== '/')) {
      srcPath.push('');
    }
    var isAbsolute = srcPath[0] === '' || (srcPath[0] && srcPath[0].charAt(0) === '/');
    if (psychotic) {
      result.hostname = result.host = isAbsolute ? '' : srcPath.length ? srcPath.shift() : '';
      var authInHost = result.host && result.host.indexOf('@') > 0 ? result.host.split('@') : false;
      if (authInHost) {
        result.auth = authInHost.shift();
        result.host = result.hostname = authInHost.shift();
      }
    }
    mustEndAbs = mustEndAbs || (result.host && srcPath.length);
    if (mustEndAbs && !isAbsolute) {
      srcPath.unshift('');
    }
    if (!srcPath.length) {
      result.pathname = null;
      result.path = null;
    } else {
      result.pathname = srcPath.join('/');
    }
    if (!isNull(result.pathname) || !isNull(result.search)) {
      result.path = (result.pathname ? result.pathname : '') + (result.search ? result.search : '');
    }
    result.auth = relative.auth || result.auth;
    result.slashes = result.slashes || relative.slashes;
    result.href = result.format();
    return result;
  };
  Url.prototype.parseHost = function() {
    var host = this.host;
    var port = portPattern.exec(host);
    if (port) {
      port = port[0];
      if (port !== ':') {
        this.port = port.substr(1);
      }
      host = host.substr(0, host.length - port.length);
    }
    if (host)
      this.hostname = host;
  };
  function isString(arg) {
    return typeof arg === "string";
  }
  function isObject(arg) {
    return typeof arg === 'object' && arg !== null;
  }
  function isNull(arg) {
    return arg === null;
  }
  function isNullOrUndefined(arg) {
    return arg == null;
  }
  return module.exports;
});

$__System.registerDynamic("211", ["210"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('210');
  return module.exports;
});

$__System.registerDynamic("212", ["211"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? $__System._nodeRequire('url') : $__require('211');
  return module.exports;
});

$__System.registerDynamic("1a9", ["212"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('212');
  return module.exports;
});

$__System.registerDynamic("18d", ["1a9", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    'use strict';
    var isWindows = /^win/.test(process.platform),
        forwardSlashPattern = /\//g,
        protocolPattern = /^([a-z0-9.+-]+):\/\//i,
        url = module.exports;
    var urlEncodePatterns = [/\?/g, '%3F', /\#/g, '%23', isWindows ? /\\/g : /\//, '/'];
    var urlDecodePatterns = [/\%23/g, '#', /\%24/g, '$', /\%26/g, '&', /\%2C/g, ',', /\%40/g, '@'];
    exports.parse = $__require('1a9').parse;
    exports.resolve = $__require('1a9').resolve;
    exports.cwd = function cwd() {
      return process.browser ? location.href : process.cwd() + '/';
    };
    exports.getProtocol = function getProtocol(path) {
      var match = protocolPattern.exec(path);
      if (match) {
        return match[1].toLowerCase();
      }
    };
    exports.getExtension = function getExtension(path) {
      var lastDot = path.lastIndexOf('.');
      if (lastDot >= 0) {
        return path.substr(lastDot).toLowerCase();
      }
      return '';
    };
    exports.getHash = function getHash(path) {
      var hashIndex = path.indexOf('#');
      if (hashIndex >= 0) {
        return path.substr(hashIndex);
      }
      return '#';
    };
    exports.stripHash = function stripHash(path) {
      var hashIndex = path.indexOf('#');
      if (hashIndex >= 0) {
        path = path.substr(0, hashIndex);
      }
      return path;
    };
    exports.isHttp = function isHttp(path) {
      var protocol = url.getProtocol(path);
      if (protocol === 'http' || protocol === 'https') {
        return true;
      } else if (protocol === undefined) {
        return process.browser;
      } else {
        return false;
      }
    };
    exports.isFileSystemPath = function isFileSystemPath(path) {
      if (process.browser) {
        return false;
      }
      var protocol = url.getProtocol(path);
      return protocol === undefined || protocol === 'file';
    };
    exports.fromFileSystemPath = function fromFileSystemPath(path) {
      for (var i = 0; i < urlEncodePatterns.length; i += 2) {
        path = path.replace(urlEncodePatterns[i], urlEncodePatterns[i + 1]);
      }
      return encodeURI(path);
    };
    exports.toFileSystemPath = function toFileSystemPath(path, keepFileProtocol) {
      path = decodeURI(path);
      for (var i = 0; i < urlDecodePatterns.length; i += 2) {
        path = path.replace(urlDecodePatterns[i], urlDecodePatterns[i + 1]);
      }
      var isFileUrl = path.substr(0, 7).toLowerCase() === 'file://';
      if (isFileUrl) {
        path = path[7] === '/' ? path.substr(8) : path.substr(7);
        if (isWindows && path[1] === '/') {
          path = path[0] + ':' + path.substr(1);
        }
        if (keepFileProtocol) {
          path = 'file:///' + path;
        } else {
          isFileUrl = false;
          path = isWindows ? path : '/' + path;
        }
      }
      if (isWindows && !isFileUrl) {
        path = path.replace(forwardSlashPattern, '\\');
      }
      return path;
    };
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("1f6", ["1cd", "1d2", "179", "18e", "18d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $Ref = $__require('1cd'),
      Pointer = $__require('1d2'),
      ono = $__require('179'),
      debug = $__require('18e'),
      url = $__require('18d');
  module.exports = dereference;
  function dereference(parser, options) {
    debug('Dereferencing $ref pointers in %s', parser.$refs._root$Ref.path);
    var dereferenced = crawl(parser.schema, parser.$refs._root$Ref.path, '#', [], parser.$refs, options);
    parser.$refs.circular = dereferenced.circular;
    parser.schema = dereferenced.value;
  }
  function crawl(obj, path, pathFromRoot, parents, $refs, options) {
    var dereferenced;
    var result = {
      value: obj,
      circular: false
    };
    if (obj && typeof obj === 'object') {
      parents.push(obj);
      if ($Ref.isAllowed$Ref(obj, options)) {
        dereferenced = dereference$Ref(obj, path, pathFromRoot, parents, $refs, options);
        result.circular = dereferenced.circular;
        result.value = dereferenced.value;
      } else {
        Object.keys(obj).forEach(function(key) {
          var keyPath = Pointer.join(path, key);
          var keyPathFromRoot = Pointer.join(pathFromRoot, key);
          var value = obj[key];
          var circular = false;
          if ($Ref.isAllowed$Ref(value, options)) {
            dereferenced = dereference$Ref(value, keyPath, keyPathFromRoot, parents, $refs, options);
            circular = dereferenced.circular;
            obj[key] = dereferenced.value;
          } else {
            if (parents.indexOf(value) === -1) {
              dereferenced = crawl(value, keyPath, keyPathFromRoot, parents, $refs, options);
              circular = dereferenced.circular;
              obj[key] = dereferenced.value;
            } else {
              circular = foundCircularReference(keyPath, $refs, options);
            }
          }
          result.circular = result.circular || circular;
        });
      }
      parents.pop();
    }
    return result;
  }
  function dereference$Ref($ref, path, pathFromRoot, parents, $refs, options) {
    debug('Dereferencing $ref pointer "%s" at %s', $ref.$ref, path);
    var $refPath = url.resolve(path, $ref.$ref);
    var pointer = $refs._resolve($refPath, options);
    var directCircular = pointer.circular;
    var circular = directCircular || parents.indexOf(pointer.value) !== -1;
    circular && foundCircularReference(path, $refs, options);
    var dereferencedValue = $Ref.dereference($ref, pointer.value);
    if (!circular) {
      var dereferenced = crawl(dereferencedValue, pointer.path, pathFromRoot, parents, $refs, options);
      circular = dereferenced.circular;
      dereferencedValue = dereferenced.value;
    }
    if (circular && !directCircular && options.dereference.circular === 'ignore') {
      dereferencedValue = $ref;
    }
    if (directCircular) {
      dereferencedValue.$ref = pathFromRoot;
    }
    return {
      circular: circular,
      value: dereferencedValue
    };
  }
  function foundCircularReference(keyPath, $refs, options) {
    $refs.circular = true;
    if (!options.dereference.circular) {
      throw ono.reference('Circular $ref pointer found at %s', keyPath);
    }
    return true;
  }
  return module.exports;
});

$__System.registerDynamic("213", ["177", "17c", "178", "17f", "181", "1d5", "179", "1f7", "1f6"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var validateSchema = $__require('177'),
      validateSpec = $__require('17c'),
      util = $__require('178'),
      Options = $__require('17f'),
      Promise = $__require('181'),
      maybe = $__require('1d5'),
      ono = $__require('179'),
      $RefParser = $__require('1f7'),
      dereference = $__require('1f6');
  module.exports = SwaggerParser;
  function SwaggerParser() {
    $RefParser.apply(this, arguments);
  }
  util.inherits(SwaggerParser, $RefParser);
  SwaggerParser.YAML = $RefParser.YAML;
  SwaggerParser.parse = $RefParser.parse;
  SwaggerParser.resolve = $RefParser.resolve;
  SwaggerParser.bundle = $RefParser.bundle;
  SwaggerParser.dereference = $RefParser.dereference;
  Object.defineProperty(SwaggerParser.prototype, 'api', {
    configurable: true,
    enumerable: true,
    get: function() {
      return this.schema;
    }
  });
  SwaggerParser.prototype.parse = function(api, options, callback) {
    var args = normalizeArgs(arguments);
    return $RefParser.prototype.parse.call(this, args.path, args.api, args.options).then(function(schema) {
      var supportedSwaggerVersions = ['2.0'];
      if (schema.swagger === undefined || schema.info === undefined || schema.paths === undefined) {
        throw ono.syntax('%s is not a valid Swagger API definition', args.path || args.api);
      } else if (typeof schema.swagger === 'number') {
        throw ono.syntax('Swagger version number must be a string (e.g. "2.0") not a number.');
      } else if (typeof schema.info.version === 'number') {
        throw ono.syntax('API version number must be a string (e.g. "1.0.0") not a number.');
      } else if (supportedSwaggerVersions.indexOf(schema.swagger) === -1) {
        throw ono.syntax('Unsupported Swagger version: %d. Swagger Parser only supports version %s', schema.swagger, supportedSwaggerVersions.join(', '));
      }
      return maybe(args.callback, Promise.resolve(schema));
    }).catch(function(err) {
      return maybe(args.callback, Promise.reject(err));
    });
  };
  SwaggerParser.validate = function(api, options, callback) {
    var Class = this;
    var instance = new Class();
    return instance.validate.apply(instance, arguments);
  };
  SwaggerParser.prototype.validate = function(api, options, callback) {
    var me = this;
    var args = normalizeArgs(arguments);
    var circular$RefOption = args.options.dereference.circular;
    args.options.validate.schema && (args.options.dereference.circular = 'ignore');
    return this.dereference(args.path, args.api, args.options).then(function() {
      args.options.dereference.circular = circular$RefOption;
      if (args.options.validate.schema) {
        validateSchema(me.api);
        if (me.$refs.circular) {
          if (circular$RefOption === true) {
            dereference(me, args.options);
          } else if (circular$RefOption === false) {
            throw ono.reference('The API contains circular references');
          }
        }
      }
      if (args.options.validate.spec) {
        validateSpec(me.api);
      }
      return maybe(args.callback, Promise.resolve(me.schema));
    }).catch(function(err) {
      return maybe(args.callback, Promise.reject(err));
    });
  };
  function normalizeArgs(args) {
    var path,
        api,
        options,
        callback;
    args = Array.prototype.slice.call(args);
    if (typeof args[args.length - 1] === 'function') {
      callback = args.pop();
    }
    if (typeof args[0] === 'string') {
      path = args[0];
      if (typeof args[2] === 'object') {
        api = args[1];
        options = args[2];
      } else {
        api = undefined;
        options = args[1];
      }
    } else {
      path = '';
      api = args[0];
      options = args[1];
    }
    if (!(options instanceof Options)) {
      options = new Options(options);
    }
    return {
      path: path,
      api: api,
      options: options,
      callback: callback
    };
  }
  return module.exports;
});

$__System.registerDynamic("214", ["213"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('213');
  return module.exports;
});

$__System.registerDynamic("119", ["10b", "f6", "215"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $export = $__require('10b'),
      core = $__require('f6'),
      fails = $__require('215');
  module.exports = function(KEY, exec) {
    var fn = (core.Object || {})[KEY] || Object[KEY],
        exp = {};
    exp[KEY] = exec(fn);
    $export($export.S + $export.F * fails(function() {
      fn(1);
    }), 'Object', exp);
  };
  return module.exports;
});

$__System.registerDynamic("216", ["217", "119"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toIObject = $__require('217');
  $__require('119')('getOwnPropertyDescriptor', function($getOwnPropertyDescriptor) {
    return function getOwnPropertyDescriptor(it, key) {
      return $getOwnPropertyDescriptor(toIObject(it), key);
    };
  });
  return module.exports;
});

$__System.registerDynamic("218", ["109", "216"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109');
  $__require('216');
  module.exports = function getOwnPropertyDescriptor(it, key) {
    return $.getDesc(it, key);
  };
  return module.exports;
});

$__System.registerDynamic("219", ["218"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('218'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("87", ["219"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _Object$getOwnPropertyDescriptor = $__require('219')["default"];
  exports["default"] = function get(_x, _x2, _x3) {
    var _again = true;
    _function: while (_again) {
      var object = _x,
          property = _x2,
          receiver = _x3;
      _again = false;
      if (object === null)
        object = Function.prototype;
      var desc = _Object$getOwnPropertyDescriptor(object, property);
      if (desc === undefined) {
        var parent = Object.getPrototypeOf(object);
        if (parent === null) {
          return undefined;
        } else {
          _x = parent;
          _x2 = property;
          _x3 = receiver;
          _again = true;
          desc = parent = undefined;
          continue _function;
        }
      } else if ("value" in desc) {
        return desc.value;
      } else {
        var getter = desc.get;
        if (getter === undefined) {
          return undefined;
        }
        return getter.call(receiver);
      }
    }
  };
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("21a", ["109"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109');
  module.exports = function create(P, D) {
    return $.create(P, D);
  };
  return module.exports;
});

$__System.registerDynamic("21b", ["21a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('21a'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("10e", ["109", "103", "fd", "105"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var getDesc = $__require('109').getDesc,
      isObject = $__require('103'),
      anObject = $__require('fd');
  var check = function(O, proto) {
    anObject(O);
    if (!isObject(proto) && proto !== null)
      throw TypeError(proto + ": can't set as prototype!");
  };
  module.exports = {
    set: Object.setPrototypeOf || ('__proto__' in {} ? function(test, buggy, set) {
      try {
        set = $__require('105')(Function.call, getDesc(Object.prototype, '__proto__').set, 2);
        set(test, []);
        buggy = !(test instanceof Array);
      } catch (e) {
        buggy = true;
      }
      return function setPrototypeOf(O, proto) {
        check(O, proto);
        if (buggy)
          O.__proto__ = proto;
        else
          set(O, proto);
        return O;
      };
    }({}, false) : undefined),
    check: check
  };
  return module.exports;
});

$__System.registerDynamic("21c", ["10b", "10e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $export = $__require('10b');
  $export($export.S, 'Object', {setPrototypeOf: $__require('10e').set});
  return module.exports;
});

$__System.registerDynamic("21d", ["21c", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('21c');
  module.exports = $__require('f6').Object.setPrototypeOf;
  return module.exports;
});

$__System.registerDynamic("21e", ["21d"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('21d'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("88", ["21b", "21e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _Object$create = $__require('21b')["default"];
  var _Object$setPrototypeOf = $__require('21e')["default"];
  exports["default"] = function(subClass, superClass) {
    if (typeof superClass !== "function" && superClass !== null) {
      throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
    }
    subClass.prototype = _Object$create(superClass && superClass.prototype, {constructor: {
        value: subClass,
        enumerable: false,
        writable: true,
        configurable: true
      }});
    if (superClass)
      _Object$setPrototypeOf ? _Object$setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
  };
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("21f", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var hasOwn = Object.prototype.hasOwnProperty;
  var toString = Object.prototype.toString;
  module.exports = function forEach(obj, fn, ctx) {
    if (toString.call(fn) !== '[object Function]') {
      throw new TypeError('iterator must be a function');
    }
    var l = obj.length;
    if (l === +l) {
      for (var i = 0; i < l; i++) {
        fn.call(ctx, obj[i], i, obj);
      }
    } else {
      for (var k in obj) {
        if (hasOwn.call(obj, k)) {
          fn.call(ctx, obj[k], k, obj);
        }
      }
    }
  };
  return module.exports;
});

$__System.registerDynamic("220", ["21f"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('21f');
  return module.exports;
});

$__System.registerDynamic("221", ["220"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var each = $__require('220');
  module.exports = api;
  function api(obj, pointer, value) {
    if (arguments.length === 3) {
      return api.set(obj, pointer, value);
    }
    if (arguments.length === 2) {
      return api.get(obj, pointer);
    }
    var wrapped = api.bind(api, obj);
    for (var name in api) {
      if (api.hasOwnProperty(name)) {
        wrapped[name] = api[name].bind(wrapped, obj);
      }
    }
    return wrapped;
  }
  api.get = function get(obj, pointer) {
    var tok,
        refTokens = api.parse(pointer);
    while (refTokens.length) {
      tok = refTokens.shift();
      if (!(tok in obj)) {
        throw new Error('Invalid reference token: ' + tok);
      }
      obj = obj[tok];
    }
    return obj;
  };
  api.set = function set(obj, pointer, value) {
    var refTokens = api.parse(pointer),
        tok,
        nextTok = refTokens[0];
    while (refTokens.length > 1) {
      tok = refTokens.shift();
      if (tok === '-' && Array.isArray(obj)) {
        tok = obj.length;
      }
      nextTok = refTokens[0];
      if (!(tok in obj)) {
        if (nextTok.match(/^(\d+|-)$/)) {
          obj[tok] = [];
        } else {
          obj[tok] = {};
        }
      }
      obj = obj[tok];
    }
    if (nextTok === '-' && Array.isArray(obj)) {
      nextTok = obj.length;
    }
    obj[nextTok] = value;
    return this;
  };
  api.remove = function(obj, pointer) {
    var refTokens = api.parse(pointer);
    var finalToken = refTokens.pop();
    if (finalToken === undefined) {
      throw new Error('Invalid JSON pointer for remove: "' + pointer + '"');
    }
    delete api.get(obj, api.compile(refTokens))[finalToken];
  };
  api.dict = function dict(obj, descend) {
    var results = {};
    api.walk(obj, function(value, pointer) {
      results[pointer] = value;
    }, descend);
    return results;
  };
  api.walk = function walk(obj, iterator, descend) {
    var refTokens = [];
    descend = descend || function(value) {
      var type = Object.prototype.toString.call(value);
      return type === '[object Object]' || type === '[object Array]';
    };
    (function next(cur) {
      each(cur, function(value, key) {
        refTokens.push(String(key));
        if (descend(value)) {
          next(value);
        } else {
          iterator(value, api.compile(refTokens));
        }
        refTokens.pop();
      });
    }(obj));
  };
  api.has = function has(obj, pointer) {
    try {
      api.get(obj, pointer);
    } catch (e) {
      return false;
    }
    return true;
  };
  api.escape = function escape(str) {
    return str.toString().replace(/~/g, '~0').replace(/\//g, '~1');
  };
  api.unescape = function unescape(str) {
    return str.replace(/~1/g, '/').replace(/~0/g, '~');
  };
  api.parse = function parse(pointer) {
    if (pointer === '') {
      return [];
    }
    if (pointer.charAt(0) !== '/') {
      throw new Error('Invalid JSON pointer: ' + pointer);
    }
    return pointer.substring(1).split(/\//).map(api.unescape);
  };
  api.compile = function compile(refTokens) {
    if (refTokens.length === 0) {
      return '';
    }
    return '/' + refTokens.map(api.escape).join('/');
  };
  return module.exports;
});

$__System.registerDynamic("222", ["221"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('221');
  return module.exports;
});

$__System.register('91', ['87', '88', '89', '92', '222', '8a'], function (_export) {
  var _get, _inherits, _createClass, _Object$assign, JsonPointerLib, _classCallCheck, JsonPointer;

  return {
    setters: [function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_4) {
      _Object$assign = _4['default'];
    }, function (_5) {
      JsonPointerLib = _5['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {

      /**
       * Wrapper for JsonPointer. Provides common operations
       */
      'use strict';

      JsonPointer = (function (_JsonPointerLib) {
        _inherits(JsonPointer, _JsonPointerLib);

        function JsonPointer() {
          _classCallCheck(this, JsonPointer);

          _get(Object.getPrototypeOf(JsonPointer.prototype), 'constructor', this).apply(this, arguments);
        }

        _createClass(JsonPointer, null, [{
          key: 'baseName',

          /**
           * returns last JsonPointer token
           * if level > 1 returns levels last (second last/third last)
           * @example
           * // returns subpath
           * JsonPointerHelper.baseName('/path/0/subpath')
           * // returns foo
           * JsonPointerHelper.baseName('/path/foo/subpath', 2)
           */
          value: function baseName(pointer) {
            var level = arguments.length <= 1 || arguments[1] === undefined ? 1 : arguments[1];

            var tokens = JsonPointer.parse(pointer);
            return tokens[tokens.length - level];
          }

          /**
           * returns dirname of pointer
           * if level > 1 returns corresponding dirname in the hierarchy
           * @example
           * // returns /path/0
           * JsonPointerHelper.dirName('/path/0/subpath')
           * // returns /path
           * JsonPointerHelper.dirName('/path/foo/subpath', 2)
           */
        }, {
          key: 'dirName',
          value: function dirName(pointer) {
            var level = arguments.length <= 1 || arguments[1] === undefined ? 1 : arguments[1];

            var tokens = JsonPointer.parse(pointer);
            return JsonPointer.compile(tokens.slice(0, tokens.length - level));
          }

          /**
           * overridden JsonPointer original parse to take care of prefixing '#' symbol
           * that is not valid JsonPointer
           */
        }, {
          key: 'parse',
          value: function parse(pointer) {
            var ptr = pointer;
            if (ptr.charAt(0) === '#') {
              ptr = ptr.substring(1);
            }
            return JsonPointerLib._origParse(ptr);
          }

          /**
          * Creates a JSON pointer path, by joining one or more tokens to a base path.
          *
          * @param {string} base - The base path
          * @param {string|string[]} tokens - The token(s) to append (e.g. ["name", "first"])
          * @returns {string}
          */
        }, {
          key: 'join',
          value: function join(base, tokens) {
            // TODO: optimize
            var baseTokens = JsonPointer.parse(base);
            var resTokens = baseTokens.concat(tokens);
            return JsonPointer.compile(resTokens);
          }
        }]);

        return JsonPointer;
      })(JsonPointerLib);

      _export('JsonPointer', JsonPointer);

      JsonPointerLib._origParse = JsonPointerLib.parse;
      JsonPointerLib.parse = JsonPointer.parse;

      _Object$assign(JsonPointer, JsonPointerLib);

      _export('default', JsonPointer);
    }
  };
});
$__System.register('223', ['224'], function (_export) {
  var _Set, methods;

  return {
    setters: [function (_) {
      _Set = _['default'];
    }],
    execute: function () {
      'use strict';

      methods = new _Set(['get', 'put', 'post', 'delete', 'options', 'head', 'patch']);

      _export('methods', methods);
    }
  };
});
$__System.register('93', ['89', '91', '116', '124', '214', '223', '8a', '8f', 'aa'], function (_export) {
  var _createClass, JsonPointer, _Promise, _Map, SwaggerParser, swaggerMethods, _classCallCheck, _Object$keys, _getIterator, SchemaManager;

  return {
    setters: [function (_) {
      _createClass = _['default'];
    }, function (_5) {
      JsonPointer = _5['default'];
    }, function (_2) {
      _Promise = _2['default'];
    }, function (_3) {
      _Map = _3['default'];
    }, function (_4) {
      SwaggerParser = _4['default'];
    }, function (_6) {
      swaggerMethods = _6.methods;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_f) {
      _Object$keys = _f['default'];
    }, function (_aa) {
      _getIterator = _aa['default'];
    }],
    execute: function () {
      'use strict';

      SchemaManager = (function () {
        function SchemaManager() {
          _classCallCheck(this, SchemaManager);

          if (SchemaManager.prototype._instance) {
            return SchemaManager.prototype._instance;
          }

          SchemaManager.prototype._instance = this;

          this._schema = {};
        }

        _createClass(SchemaManager, [{
          key: 'load',
          value: function load(url) {
            var _this = this;

            var promise = new _Promise(function (resolve, reject) {
              _this._schema = {};

              SwaggerParser.bundle(url, { http: { withCredentials: false } }).then(function (schema) {
                _this._schema = schema;
                resolve(_this._schema);
                _this.init();
              }, function (err) {
                return reject(err);
              });
            });

            return promise;
          }

          /* calculate common used values */
        }, {
          key: 'init',
          value: function init() {
            if (!this._schema || !this._schema.schemes) return;
            this.apiUrl = this._schema.schemes[0] + '://' + this._schema.host + this._schema.basePath;
            if (this.apiUrl.endsWith('/')) {
              this.apiUrl = this.apiUrl.substr(0, this.apiUrl.length - 1);
            }
          }
        }, {
          key: 'byPointer',
          value: function byPointer(pointer) {
            var res = null;
            try {
              // TODO: remove decodeURIComponent after this issue is fixed: https://github.com/BigstickCarpet/swagger-parser/issues/31
              res = JsonPointer.get(this._schema, decodeURIComponent(pointer));
            } catch (e) {/*skip*/}
            return res;
          }
        }, {
          key: 'resolveRefs',
          value: function resolveRefs(obj) {
            var _this2 = this;

            _Object$keys(obj).forEach(function (key) {
              if (obj[key].$ref) {
                var resolved = _this2.byPointer(obj[key].$ref);
                resolved._pointer = obj[key].$ref;
                obj[key] = resolved;
              }
            });
            return obj;
          }
        }, {
          key: 'getMethodParams',
          value: function getMethodParams(methodPtr, resolveRefs) {
            /* inject JsonPointer into array elements */
            function injectPointers(array, root) {
              if (!Array.isArray(array)) {
                throw new Error('parameters must be an array. Got ' + typeof array + ' at ' + root);
              }
              return array.map(function (element, idx) {
                element._pointer = JsonPointer.join(root, idx);
                return element;
              });
            }

            // accept pointer directly to parameters as well
            if (JsonPointer.baseName(methodPtr) === 'parameters') {
              methodPtr = JsonPointer.dirName(methodPtr);
            }

            //get path params
            var pathParamsPtr = JsonPointer.join(JsonPointer.dirName(methodPtr), ['parameters']);
            var pathParams = this.byPointer(pathParamsPtr) || [];

            var methodParamsPtr = JsonPointer.join(methodPtr, ['parameters']);
            var methodParams = this.byPointer(methodParamsPtr) || [];
            pathParams = injectPointers(pathParams, pathParamsPtr);
            methodParams = injectPointers(methodParams, methodParamsPtr);

            if (resolveRefs) {
              methodParams = this.resolveRefs(methodParams);
              pathParams = this.resolveRefs(pathParams);
            }
            return methodParams.concat(pathParams);
          }
        }, {
          key: 'getTagsMap',
          value: function getTagsMap() {
            var tags = this._schema.tags || [];
            var tagsMap = {};
            var _iteratorNormalCompletion = true;
            var _didIteratorError = false;
            var _iteratorError = undefined;

            try {
              for (var _iterator = _getIterator(tags), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
                var tag = _step.value;

                tagsMap[tag.name] = {
                  description: tag.description,
                  'x-traitTag': tag['x-traitTag'] || false
                };
              }
            } catch (err) {
              _didIteratorError = true;
              _iteratorError = err;
            } finally {
              try {
                if (!_iteratorNormalCompletion && _iterator['return']) {
                  _iterator['return']();
                }
              } finally {
                if (_didIteratorError) {
                  throw _iteratorError;
                }
              }
            }

            return tagsMap;
          }

          /* returns ES6 Map */
        }, {
          key: 'buildMenuTree',
          value: function buildMenuTree() {
            var tag2MethodMapping = new _Map();

            var definedTags = this._schema.tags || [];
            // add tags into map to preserve order
            var _iteratorNormalCompletion2 = true;
            var _didIteratorError2 = false;
            var _iteratorError2 = undefined;

            try {
              for (var _iterator2 = _getIterator(definedTags), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
                var tag = _step2.value;

                tag2MethodMapping.set(tag.name, {
                  'description': tag.description,
                  'x-traitTag': tag['x-traitTag'],
                  'methods': []
                });
              }
            } catch (err) {
              _didIteratorError2 = true;
              _iteratorError2 = err;
            } finally {
              try {
                if (!_iteratorNormalCompletion2 && _iterator2['return']) {
                  _iterator2['return']();
                }
              } finally {
                if (_didIteratorError2) {
                  throw _iteratorError2;
                }
              }
            }

            var paths = this._schema.paths;
            var _iteratorNormalCompletion3 = true;
            var _didIteratorError3 = false;
            var _iteratorError3 = undefined;

            try {
              for (var _iterator3 = _getIterator(_Object$keys(paths)), _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = true) {
                var path = _step3.value;

                var methods = _Object$keys(paths[path]).filter(function (k) {
                  return swaggerMethods.has(k);
                });
                var _iteratorNormalCompletion4 = true;
                var _didIteratorError4 = false;
                var _iteratorError4 = undefined;

                try {
                  for (var _iterator4 = _getIterator(methods), _step4; !(_iteratorNormalCompletion4 = (_step4 = _iterator4.next()).done); _iteratorNormalCompletion4 = true) {
                    var method = _step4.value;

                    var methodInfo = paths[path][method];
                    var tags = methodInfo.tags;

                    //TODO: mb need to do something cleverer
                    if (!tags || !tags.length) {
                      tags = ['[Other]'];
                    }
                    var methodPointer = JsonPointer.compile(['paths', path, method]);
                    var methodSummary = methodInfo.summary;
                    var _iteratorNormalCompletion5 = true;
                    var _didIteratorError5 = false;
                    var _iteratorError5 = undefined;

                    try {
                      for (var _iterator5 = _getIterator(tags), _step5; !(_iteratorNormalCompletion5 = (_step5 = _iterator5.next()).done); _iteratorNormalCompletion5 = true) {
                        var tag = _step5.value;

                        var tagDetails = tag2MethodMapping.get(tag);
                        if (!tagDetails) {
                          tagDetails = {};
                          tag2MethodMapping.set(tag, tagDetails);
                        }
                        if (tagDetails['x-traitTag']) continue;
                        if (!tagDetails.methods) tagDetails.methods = [];
                        tagDetails.methods.push({
                          pointer: methodPointer,
                          summary: methodSummary,
                          operationId: methodInfo.operationId
                        });
                      }
                    } catch (err) {
                      _didIteratorError5 = true;
                      _iteratorError5 = err;
                    } finally {
                      try {
                        if (!_iteratorNormalCompletion5 && _iterator5['return']) {
                          _iterator5['return']();
                        }
                      } finally {
                        if (_didIteratorError5) {
                          throw _iteratorError5;
                        }
                      }
                    }
                  }
                } catch (err) {
                  _didIteratorError4 = true;
                  _iteratorError4 = err;
                } finally {
                  try {
                    if (!_iteratorNormalCompletion4 && _iterator4['return']) {
                      _iterator4['return']();
                    }
                  } finally {
                    if (_didIteratorError4) {
                      throw _iteratorError4;
                    }
                  }
                }
              }
            } catch (err) {
              _didIteratorError3 = true;
              _iteratorError3 = err;
            } finally {
              try {
                if (!_iteratorNormalCompletion3 && _iterator3['return']) {
                  _iterator3['return']();
                }
              } finally {
                if (_didIteratorError3) {
                  throw _iteratorError3;
                }
              }
            }

            return tag2MethodMapping;
          }
        }, {
          key: 'findDerivedDefinitions',
          value: function findDerivedDefinitions(defPointer) {
            var definition = this.byPointer(defPointer);
            if (!definition) throw new Error('Can\'t load schema at ' + defPointer);
            if (!definition.discriminator) return [];

            var globalDefs = this._schema.definitions || {};
            var res = [];
            var _iteratorNormalCompletion6 = true;
            var _didIteratorError6 = false;
            var _iteratorError6 = undefined;

            try {
              for (var _iterator6 = _getIterator(_Object$keys(globalDefs)), _step6; !(_iteratorNormalCompletion6 = (_step6 = _iterator6.next()).done); _iteratorNormalCompletion6 = true) {
                var defName = _step6.value;

                if (!globalDefs[defName].allOf) continue;

                var subTypes = globalDefs[defName].allOf;
                var idx = subTypes.findIndex(function (subType) {
                  if (subType.$ref === defPointer) return true;
                  return false;
                });
                if (idx < 0) continue;

                var empty = false;
                if (subTypes.length === 1) {
                  empty = true;
                }
                res.push({ name: defName, $ref: '#/definitions/' + defName, empty: empty });
              }
            } catch (err) {
              _didIteratorError6 = true;
              _iteratorError6 = err;
            } finally {
              try {
                if (!_iteratorNormalCompletion6 && _iterator6['return']) {
                  _iterator6['return']();
                }
              } finally {
                if (_didIteratorError6) {
                  throw _iteratorError6;
                }
              }
            }

            return res;
          }
        }, {
          key: 'schema',
          get: function get() {
            // TODO: consider returning promise
            return this._schema;
          }
        }], [{
          key: 'instance',
          value: function instance() {
            return new SchemaManager();
          }
        }]);

        return SchemaManager;
      })();

      _export('default', SchemaManager);
    }
  };
});
$__System.register('225', ['11', '89', '93', '226', '227', '8a', 'a1', 'a2'], function (_export) {
  var Injectable, EventEmitter, _createClass, SchemaManager, ScrollService, INVIEW_POSITION, Hash, _classCallCheck, _slicedToArray, _Array$from, CHANGE, MenuService;

  return {
    setters: [function (_2) {
      Injectable = _2.Injectable;
      EventEmitter = _2.EventEmitter;
    }, function (_) {
      _createClass = _['default'];
    }, function (_5) {
      SchemaManager = _5['default'];
    }, function (_3) {
      ScrollService = _3.ScrollService;
      INVIEW_POSITION = _3.INVIEW_POSITION;
    }, function (_4) {
      Hash = _4.Hash;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_a1) {
      _slicedToArray = _a1['default'];
    }, function (_a2) {
      _Array$from = _a2['default'];
    }],
    execute: function () {
      'use strict';
      CHANGE = {
        NEXT: 1,
        BACK: -1,
        INITIAL: 0
      };

      MenuService = (function () {
        function MenuService(hash, scrollService, schemaMgr) {
          var _this = this;

          _classCallCheck(this, _MenuService);

          this.hash = hash;
          this.scrollService = scrollService;

          this.activeCatIdx = 0;
          this.activeMethodIdx = -1;
          this.changed = new EventEmitter();

          this.categories = _Array$from(schemaMgr.buildMenuTree().entries()).map(function (el) {
            return { name: el[0], description: el[1].description, methods: el[1].methods };
          });

          scrollService.scroll.subscribe(function (evt) {
            _this.scrollUpdate(evt.isScrolledDown);
          });

          this.changeActive(CHANGE.INITIAL);

          this.hash.changed.subscribe(function (hash) {
            _this.hashScroll(hash);
          });
        }

        _createClass(MenuService, [{
          key: 'scrollUpdate',
          value: function scrollUpdate(isScrolledDown) {
            var stable = false;
            while (!stable) {
              var $activeMethodHost = this.getCurrentMethodEl();
              if (!$activeMethodHost) return;
              var elementInViewPos = this.scrollService.getElementPos($activeMethodHost);
              if (isScrolledDown && elementInViewPos === INVIEW_POSITION.BELLOW) {
                stable = this.changeActive(CHANGE.NEXT);
                continue;
              }
              if (!isScrolledDown && elementInViewPos === INVIEW_POSITION.ABOVE) {
                stable = this.changeActive(CHANGE.BACK);
                continue;
              }
              stable = true;
            }
          }
        }, {
          key: 'getCurrentMethodEl',
          value: function getCurrentMethodEl() {
            return this.getMethodElByPtr(this.activeMethodPtr, this.categories[this.activeCatIdx].name);
          }
        }, {
          key: 'getMethodElByPtr',
          value: function getMethodElByPtr(ptr, tag) {
            var selector = ptr ? '[pointer="' + ptr + '"][tag="' + tag + '"]' : '[tag="' + tag + '"]';
            return document.querySelector(selector);
          }
        }, {
          key: 'getMethodElByOperId',
          value: function getMethodElByOperId(operationId) {
            var selector = '[operation-id="' + operationId + '"]';
            return document.querySelector(selector);
          }
        }, {
          key: 'activate',
          value: function activate(catIdx, methodIdx) {
            var menu = this.categories;

            menu[this.activeCatIdx].active = false;
            if (menu[this.activeCatIdx].methods.length) {
              if (this.activeMethodIdx >= 0) {
                menu[this.activeCatIdx].methods[this.activeMethodIdx].active = false;
              }
            }

            this.activeCatIdx = catIdx;
            this.activeMethodIdx = methodIdx;
            menu[catIdx].active = true;
            this.activeMethodPtr = null;
            var currentItem = undefined;
            if (menu[catIdx].methods.length && methodIdx > -1) {
              currentItem = menu[catIdx].methods[methodIdx];
              currentItem.active = true;
              this.activeMethodPtr = currentItem.pointer;
            }

            this.changed.next(menu[catIdx], currentItem);
          }
        }, {
          key: '_calcActiveIndexes',
          value: function _calcActiveIndexes(offset) {
            var menu = this.categories;
            var catCount = menu.length;
            var catLength = menu[this.activeCatIdx].methods.length;

            var resMethodIdx = this.activeMethodIdx + offset;
            var resCatIdx = this.activeCatIdx;

            if (resMethodIdx > catLength - 1) {
              resCatIdx++;
              resMethodIdx = -1;
            }
            if (resMethodIdx < -1) {
              var prevCatIdx = --resCatIdx;
              catLength = menu[Math.max(prevCatIdx, 0)].methods.length;
              resMethodIdx = catLength - 1;
            }
            if (resCatIdx > catCount - 1) {
              resCatIdx = catCount - 1;
              resMethodIdx = catLength - 1;
            }
            if (resCatIdx < 0) {
              resCatIdx = 0;
              resMethodIdx = 0;
            }

            return [resCatIdx, resMethodIdx];
          }
        }, {
          key: 'changeActive',
          value: function changeActive() {
            var offset = arguments.length <= 0 || arguments[0] === undefined ? 1 : arguments[0];

            var _calcActiveIndexes2 = this._calcActiveIndexes(offset);

            var _calcActiveIndexes22 = _slicedToArray(_calcActiveIndexes2, 2);

            var catIdx = _calcActiveIndexes22[0];
            var methodIdx = _calcActiveIndexes22[1];

            this.activate(catIdx, methodIdx);
            return methodIdx === 0 && catIdx === 0;
          }
        }, {
          key: 'scrollToActive',
          value: function scrollToActive() {
            this.scrollService.scrollTo(this.getCurrentMethodEl());
          }
        }, {
          key: 'hashScroll',
          value: function hashScroll(hash) {
            if (!hash) return;

            var $el = undefined;
            hash = hash.substr(1);
            var namespace = hash.split('/')[0];
            var ptr = decodeURIComponent(hash.substr(namespace.length + 1));
            if (namespace === 'operation') {
              $el = this.getMethodElByOperId(ptr);
            } else if (namespace === 'tag') {
              var tag = ptr.split('/')[0];
              ptr = ptr.substr(tag.length);
              $el = this.getMethodElByPtr(ptr, tag);
            }

            if ($el) this.scrollService.scrollTo($el);
          }
        }]);

        var _MenuService = MenuService;
        MenuService = Injectable()(MenuService) || MenuService;
        MenuService = Reflect.metadata('parameters', [[Hash], [ScrollService], [SchemaManager]])(MenuService) || MenuService;
        return MenuService;
      })();

      _export('MenuService', MenuService);
    }
  };
});
$__System.registerDynamic("115", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  "format cjs";
  return module.exports;
});

$__System.registerDynamic("228", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function() {};
  return module.exports;
});

$__System.registerDynamic("217", ["229", "22a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var IObject = $__require('229'),
      defined = $__require('22a');
  module.exports = function(it) {
    return IObject(defined(it));
  };
  return module.exports;
});

$__System.registerDynamic("22b", ["228", "22c", "f5", "217", "22d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var addToUnscopables = $__require('228'),
      step = $__require('22c'),
      Iterators = $__require('f5'),
      toIObject = $__require('217');
  module.exports = $__require('22d')(Array, 'Array', function(iterated, kind) {
    this._t = toIObject(iterated);
    this._i = 0;
    this._k = kind;
  }, function() {
    var O = this._t,
        kind = this._k,
        index = this._i++;
    if (!O || index >= O.length) {
      this._t = undefined;
      return step(1);
    }
    if (kind == 'keys')
      return step(0, index);
    if (kind == 'values')
      return step(0, O[index]);
    return step(0, [index, O[index]]);
  }, 'values');
  Iterators.Arguments = Iterators.Array;
  addToUnscopables('keys');
  addToUnscopables('values');
  addToUnscopables('entries');
  return module.exports;
});

$__System.registerDynamic("f8", ["22b", "f5"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('22b');
  var Iterators = $__require('f5');
  Iterators.NodeList = Iterators.HTMLCollection = Iterators.Array;
  return module.exports;
});

$__System.registerDynamic("22c", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(done, value) {
    return {
      value: value,
      done: !!done
    };
  };
  return module.exports;
});

$__System.registerDynamic("112", ["f6", "109", "10f", "f4"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core = $__require('f6'),
      $ = $__require('109'),
      DESCRIPTORS = $__require('10f'),
      SPECIES = $__require('f4')('species');
  module.exports = function(KEY) {
    var C = core[KEY];
    if (DESCRIPTORS && C && !C[SPECIES])
      $.setDesc(C, SPECIES, {
        configurable: true,
        get: function() {
          return this;
        }
      });
  };
  return module.exports;
});

$__System.registerDynamic("11f", ["109", "22e", "110", "105", "10c", "22a", "10d", "22d", "22c", "22f", "230", "103", "112", "10f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109'),
      hide = $__require('22e'),
      redefineAll = $__require('110'),
      ctx = $__require('105'),
      strictNew = $__require('10c'),
      defined = $__require('22a'),
      forOf = $__require('10d'),
      $iterDefine = $__require('22d'),
      step = $__require('22c'),
      ID = $__require('22f')('id'),
      $has = $__require('230'),
      isObject = $__require('103'),
      setSpecies = $__require('112'),
      DESCRIPTORS = $__require('10f'),
      isExtensible = Object.isExtensible || isObject,
      SIZE = DESCRIPTORS ? '_s' : 'size',
      id = 0;
  var fastKey = function(it, create) {
    if (!isObject(it))
      return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
    if (!$has(it, ID)) {
      if (!isExtensible(it))
        return 'F';
      if (!create)
        return 'E';
      hide(it, ID, ++id);
    }
    return 'O' + it[ID];
  };
  var getEntry = function(that, key) {
    var index = fastKey(key),
        entry;
    if (index !== 'F')
      return that._i[index];
    for (entry = that._f; entry; entry = entry.n) {
      if (entry.k == key)
        return entry;
    }
  };
  module.exports = {
    getConstructor: function(wrapper, NAME, IS_MAP, ADDER) {
      var C = wrapper(function(that, iterable) {
        strictNew(that, C, NAME);
        that._i = $.create(null);
        that._f = undefined;
        that._l = undefined;
        that[SIZE] = 0;
        if (iterable != undefined)
          forOf(iterable, IS_MAP, that[ADDER], that);
      });
      redefineAll(C.prototype, {
        clear: function clear() {
          for (var that = this,
              data = that._i,
              entry = that._f; entry; entry = entry.n) {
            entry.r = true;
            if (entry.p)
              entry.p = entry.p.n = undefined;
            delete data[entry.i];
          }
          that._f = that._l = undefined;
          that[SIZE] = 0;
        },
        'delete': function(key) {
          var that = this,
              entry = getEntry(that, key);
          if (entry) {
            var next = entry.n,
                prev = entry.p;
            delete that._i[entry.i];
            entry.r = true;
            if (prev)
              prev.n = next;
            if (next)
              next.p = prev;
            if (that._f == entry)
              that._f = next;
            if (that._l == entry)
              that._l = prev;
            that[SIZE]--;
          }
          return !!entry;
        },
        forEach: function forEach(callbackfn) {
          var f = ctx(callbackfn, arguments.length > 1 ? arguments[1] : undefined, 3),
              entry;
          while (entry = entry ? entry.n : this._f) {
            f(entry.v, entry.k, this);
            while (entry && entry.r)
              entry = entry.p;
          }
        },
        has: function has(key) {
          return !!getEntry(this, key);
        }
      });
      if (DESCRIPTORS)
        $.setDesc(C.prototype, 'size', {get: function() {
            return defined(this[SIZE]);
          }});
      return C;
    },
    def: function(that, key, value) {
      var entry = getEntry(that, key),
          prev,
          index;
      if (entry) {
        entry.v = value;
      } else {
        that._l = entry = {
          i: index = fastKey(key, true),
          k: key,
          v: value,
          p: prev = that._l,
          n: undefined,
          r: false
        };
        if (!that._f)
          that._f = entry;
        if (prev)
          prev.n = entry;
        that[SIZE]++;
        if (index !== 'F')
          that._i[index] = entry;
      }
      return that;
    },
    getEntry: getEntry,
    setStrong: function(C, NAME, IS_MAP) {
      $iterDefine(C, NAME, function(iterated, kind) {
        this._t = iterated;
        this._k = kind;
        this._l = undefined;
      }, function() {
        var that = this,
            kind = that._k,
            entry = that._l;
        while (entry && entry.r)
          entry = entry.p;
        if (!that._t || !(that._l = entry = entry ? entry.n : that._t._f)) {
          that._t = undefined;
          return step(1);
        }
        if (kind == 'keys')
          return step(0, entry.k);
        if (kind == 'values')
          return step(0, entry.v);
        return step(0, [entry.k, entry.v]);
      }, IS_MAP ? 'entries' : 'values', !IS_MAP, true);
      setSpecies(NAME);
    }
  };
  return module.exports;
});

$__System.registerDynamic("110", ["231"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var redefine = $__require('231');
  module.exports = function(target, src) {
    for (var key in src)
      redefine(target, key, src[key]);
    return target;
  };
  return module.exports;
});

$__System.registerDynamic("10c", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(it, Constructor, name) {
    if (!(it instanceof Constructor))
      throw TypeError(name + ": use the 'new' operator!");
    return it;
  };
  return module.exports;
});

$__System.registerDynamic("120", ["109", "101", "10b", "215", "22e", "110", "10d", "10c", "103", "111", "10f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109'),
      global = $__require('101'),
      $export = $__require('10b'),
      fails = $__require('215'),
      hide = $__require('22e'),
      redefineAll = $__require('110'),
      forOf = $__require('10d'),
      strictNew = $__require('10c'),
      isObject = $__require('103'),
      setToStringTag = $__require('111'),
      DESCRIPTORS = $__require('10f');
  module.exports = function(NAME, wrapper, methods, common, IS_MAP, IS_WEAK) {
    var Base = global[NAME],
        C = Base,
        ADDER = IS_MAP ? 'set' : 'add',
        proto = C && C.prototype,
        O = {};
    if (!DESCRIPTORS || typeof C != 'function' || !(IS_WEAK || proto.forEach && !fails(function() {
      new C().entries().next();
    }))) {
      C = common.getConstructor(wrapper, NAME, IS_MAP, ADDER);
      redefineAll(C.prototype, methods);
    } else {
      C = wrapper(function(target, iterable) {
        strictNew(target, C, NAME);
        target._c = new Base;
        if (iterable != undefined)
          forOf(iterable, IS_MAP, target[ADDER], target);
      });
      $.each.call('add,clear,delete,forEach,get,has,set,keys,values,entries'.split(','), function(KEY) {
        var IS_ADDER = KEY == 'add' || KEY == 'set';
        if (KEY in proto && !(IS_WEAK && KEY == 'clear'))
          hide(C.prototype, KEY, function(a, b) {
            if (!IS_ADDER && IS_WEAK && !isObject(a))
              return KEY == 'get' ? undefined : false;
            var result = this._c[KEY](a === 0 ? 0 : a, b);
            return IS_ADDER ? this : result;
          });
      });
      if ('size' in proto)
        $.setDesc(C.prototype, 'size', {get: function() {
            return this._c.size;
          }});
    }
    setToStringTag(C, NAME);
    O[NAME] = C;
    $export($export.G + $export.W + $export.F, O);
    if (!IS_WEAK)
      common.setStrong(C, NAME, IS_MAP);
    return C;
  };
  return module.exports;
});

$__System.registerDynamic("232", ["11f", "120"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var strong = $__require('11f');
  $__require('120')('Set', function(get) {
    return function Set() {
      return get(this, arguments.length > 0 ? arguments[0] : undefined);
    };
  }, {add: function add(value) {
      return strong.def(this, value = value === 0 ? 0 : value, value);
    }}, strong);
  return module.exports;
});

$__System.registerDynamic("10d", ["105", "233", "234", "fd", "235", "11c"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ctx = $__require('105'),
      call = $__require('233'),
      isArrayIter = $__require('234'),
      anObject = $__require('fd'),
      toLength = $__require('235'),
      getIterFn = $__require('11c');
  module.exports = function(iterable, entries, fn, that) {
    var iterFn = getIterFn(iterable),
        f = ctx(fn, that, entries ? 2 : 1),
        index = 0,
        length,
        step,
        iterator;
    if (typeof iterFn != 'function')
      throw TypeError(iterable + ' is not iterable!');
    if (isArrayIter(iterFn))
      for (length = toLength(iterable.length); length > index; index++) {
        entries ? f(anObject(step = iterable[index])[0], step[1]) : f(iterable[index]);
      }
    else
      for (iterator = iterFn.call(iterable); !(step = iterator.next()).done; ) {
        call(iterator, f, step.value, entries);
      }
  };
  return module.exports;
});

$__System.registerDynamic("122", ["10d", "f3"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var forOf = $__require('10d'),
      classof = $__require('f3');
  module.exports = function(NAME) {
    return function toJSON() {
      if (classof(this) != NAME)
        throw TypeError(NAME + "#toJSON isn't generic");
      var arr = [];
      forOf(this, false, arr.push, arr);
      return arr;
    };
  };
  return module.exports;
});

$__System.registerDynamic("236", ["10b", "122"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $export = $__require('10b');
  $export($export.P, 'Set', {toJSON: $__require('122')('Set')});
  return module.exports;
});

$__System.registerDynamic("237", ["115", "f9", "f8", "232", "236", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('115');
  $__require('f9');
  $__require('f8');
  $__require('232');
  $__require('236');
  module.exports = $__require('f6').Set;
  return module.exports;
});

$__System.registerDynamic("224", ["237"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('237'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("238", ["239", "22a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toInteger = $__require('239'),
      defined = $__require('22a');
  module.exports = function(TO_STRING) {
    return function(that, pos) {
      var s = String(defined(that)),
          i = toInteger(pos),
          l = s.length,
          a,
          b;
      if (i < 0 || i >= l)
        return TO_STRING ? '' : undefined;
      a = s.charCodeAt(i);
      return a < 0xd800 || a > 0xdbff || i + 1 === l || (b = s.charCodeAt(i + 1)) < 0xdc00 || b > 0xdfff ? TO_STRING ? s.charAt(i) : a : TO_STRING ? s.slice(i, i + 2) : (a - 0xd800 << 10) + (b - 0xdc00) + 0x10000;
    };
  };
  return module.exports;
});

$__System.registerDynamic("10a", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = true;
  return module.exports;
});

$__System.registerDynamic("231", ["22e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('22e');
  return module.exports;
});

$__System.registerDynamic("23a", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(bitmap, value) {
    return {
      enumerable: !(bitmap & 1),
      configurable: !(bitmap & 2),
      writable: !(bitmap & 4),
      value: value
    };
  };
  return module.exports;
});

$__System.registerDynamic("10f", ["215"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = !$__require('215')(function() {
    return Object.defineProperty({}, 'a', {get: function() {
        return 7;
      }}).a != 7;
  });
  return module.exports;
});

$__System.registerDynamic("22e", ["109", "23a", "10f"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109'),
      createDesc = $__require('23a');
  module.exports = $__require('10f') ? function(object, key, value) {
    return $.setDesc(object, key, createDesc(1, value));
  } : function(object, key, value) {
    object[key] = value;
    return object;
  };
  return module.exports;
});

$__System.registerDynamic("23b", ["109", "23a", "111", "22e", "f4"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109'),
      descriptor = $__require('23a'),
      setToStringTag = $__require('111'),
      IteratorPrototype = {};
  $__require('22e')(IteratorPrototype, $__require('f4')('iterator'), function() {
    return this;
  });
  module.exports = function(Constructor, NAME, next) {
    Constructor.prototype = $.create(IteratorPrototype, {next: descriptor(1, next)});
    setToStringTag(Constructor, NAME + ' Iterator');
  };
  return module.exports;
});

$__System.registerDynamic("230", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var hasOwnProperty = {}.hasOwnProperty;
  module.exports = function(it, key) {
    return hasOwnProperty.call(it, key);
  };
  return module.exports;
});

$__System.registerDynamic("111", ["109", "230", "f4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var def = $__require('109').setDesc,
      has = $__require('230'),
      TAG = $__require('f4')('toStringTag');
  module.exports = function(it, tag, stat) {
    if (it && !has(it = stat ? it : it.prototype, TAG))
      def(it, TAG, {
        configurable: true,
        value: tag
      });
  };
  return module.exports;
});

$__System.registerDynamic("22d", ["10a", "10b", "231", "22e", "230", "f5", "23b", "111", "109", "f4"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var LIBRARY = $__require('10a'),
      $export = $__require('10b'),
      redefine = $__require('231'),
      hide = $__require('22e'),
      has = $__require('230'),
      Iterators = $__require('f5'),
      $iterCreate = $__require('23b'),
      setToStringTag = $__require('111'),
      getProto = $__require('109').getProto,
      ITERATOR = $__require('f4')('iterator'),
      BUGGY = !([].keys && 'next' in [].keys()),
      FF_ITERATOR = '@@iterator',
      KEYS = 'keys',
      VALUES = 'values';
  var returnThis = function() {
    return this;
  };
  module.exports = function(Base, NAME, Constructor, next, DEFAULT, IS_SET, FORCED) {
    $iterCreate(Constructor, NAME, next);
    var getMethod = function(kind) {
      if (!BUGGY && kind in proto)
        return proto[kind];
      switch (kind) {
        case KEYS:
          return function keys() {
            return new Constructor(this, kind);
          };
        case VALUES:
          return function values() {
            return new Constructor(this, kind);
          };
      }
      return function entries() {
        return new Constructor(this, kind);
      };
    };
    var TAG = NAME + ' Iterator',
        DEF_VALUES = DEFAULT == VALUES,
        VALUES_BUG = false,
        proto = Base.prototype,
        $native = proto[ITERATOR] || proto[FF_ITERATOR] || DEFAULT && proto[DEFAULT],
        $default = $native || getMethod(DEFAULT),
        methods,
        key;
    if ($native) {
      var IteratorPrototype = getProto($default.call(new Base));
      setToStringTag(IteratorPrototype, TAG, true);
      if (!LIBRARY && has(proto, FF_ITERATOR))
        hide(IteratorPrototype, ITERATOR, returnThis);
      if (DEF_VALUES && $native.name !== VALUES) {
        VALUES_BUG = true;
        $default = function values() {
          return $native.call(this);
        };
      }
    }
    if ((!LIBRARY || FORCED) && (BUGGY || VALUES_BUG || !proto[ITERATOR])) {
      hide(proto, ITERATOR, $default);
    }
    Iterators[NAME] = $default;
    Iterators[TAG] = returnThis;
    if (DEFAULT) {
      methods = {
        values: DEF_VALUES ? $default : getMethod(VALUES),
        keys: IS_SET ? $default : getMethod(KEYS),
        entries: !DEF_VALUES ? $default : getMethod('entries')
      };
      if (FORCED)
        for (key in methods) {
          if (!(key in proto))
            redefine(proto, key, methods[key]);
        }
      else
        $export($export.P + $export.F * (BUGGY || VALUES_BUG), NAME, methods);
    }
    return methods;
  };
  return module.exports;
});

$__System.registerDynamic("f9", ["238", "22d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $at = $__require('238')(true);
  $__require('22d')(String, 'String', function(iterated) {
    this._t = String(iterated);
    this._i = 0;
  }, function() {
    var O = this._t,
        index = this._i,
        point;
    if (index >= O.length)
      return {
        value: undefined,
        done: true
      };
    point = $at(O, index);
    this._i += point.length;
    return {
      value: point,
      done: false
    };
  });
  return module.exports;
});

$__System.registerDynamic("103", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(it) {
    return typeof it === 'object' ? it !== null : typeof it === 'function';
  };
  return module.exports;
});

$__System.registerDynamic("fd", ["103"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var isObject = $__require('103');
  module.exports = function(it) {
    if (!isObject(it))
      throw TypeError(it + ' is not an object!');
    return it;
  };
  return module.exports;
});

$__System.registerDynamic("233", ["fd"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var anObject = $__require('fd');
  module.exports = function(iterator, fn, value, entries) {
    try {
      return entries ? fn(anObject(value)[0], value[1]) : fn(value);
    } catch (e) {
      var ret = iterator['return'];
      if (ret !== undefined)
        anObject(ret.call(iterator));
      throw e;
    }
  };
  return module.exports;
});

$__System.registerDynamic("234", ["f5", "f4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Iterators = $__require('f5'),
      ITERATOR = $__require('f4')('iterator'),
      ArrayProto = Array.prototype;
  module.exports = function(it) {
    return it !== undefined && (Iterators.Array === it || ArrayProto[ITERATOR] === it);
  };
  return module.exports;
});

$__System.registerDynamic("239", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ceil = Math.ceil,
      floor = Math.floor;
  module.exports = function(it) {
    return isNaN(it = +it) ? 0 : (it > 0 ? floor : ceil)(it);
  };
  return module.exports;
});

$__System.registerDynamic("235", ["239"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toInteger = $__require('239'),
      min = Math.min;
  module.exports = function(it) {
    return it > 0 ? min(toInteger(it), 0x1fffffffffffff) : 0;
  };
  return module.exports;
});

$__System.registerDynamic("f3", ["106", "f4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var cof = $__require('106'),
      TAG = $__require('f4')('toStringTag'),
      ARG = cof(function() {
        return arguments;
      }()) == 'Arguments';
  module.exports = function(it) {
    var O,
        T,
        B;
    return it === undefined ? 'Undefined' : it === null ? 'Null' : typeof(T = (O = Object(it))[TAG]) == 'string' ? T : ARG ? cof(O) : (B = cof(O)) == 'Object' && typeof O.callee == 'function' ? 'Arguments' : B;
  };
  return module.exports;
});

$__System.registerDynamic("f5", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {};
  return module.exports;
});

$__System.registerDynamic("11c", ["f3", "f4", "f5", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var classof = $__require('f3'),
      ITERATOR = $__require('f4')('iterator'),
      Iterators = $__require('f5');
  module.exports = $__require('f6').getIteratorMethod = function(it) {
    if (it != undefined)
      return it[ITERATOR] || it['@@iterator'] || Iterators[classof(it)];
  };
  return module.exports;
});

$__System.registerDynamic("23c", ["101"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var global = $__require('101'),
      SHARED = '__core-js_shared__',
      store = global[SHARED] || (global[SHARED] = {});
  module.exports = function(key) {
    return store[key] || (store[key] = {});
  };
  return module.exports;
});

$__System.registerDynamic("22f", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var id = 0,
      px = Math.random();
  module.exports = function(key) {
    return 'Symbol('.concat(key === undefined ? '' : key, ')_', (++id + px).toString(36));
  };
  return module.exports;
});

$__System.registerDynamic("f4", ["23c", "22f", "101"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var store = $__require('23c')('wks'),
      uid = $__require('22f'),
      Symbol = $__require('101').Symbol;
  module.exports = function(name) {
    return store[name] || (store[name] = Symbol && Symbol[name] || (Symbol || uid)('Symbol.' + name));
  };
  return module.exports;
});

$__System.registerDynamic("113", ["f4"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ITERATOR = $__require('f4')('iterator'),
      SAFE_CLOSING = false;
  try {
    var riter = [7][ITERATOR]();
    riter['return'] = function() {
      SAFE_CLOSING = true;
    };
    Array.from(riter, function() {
      throw 2;
    });
  } catch (e) {}
  module.exports = function(exec, skipClosing) {
    if (!skipClosing && !SAFE_CLOSING)
      return false;
    var safe = false;
    try {
      var arr = [7],
          iter = arr[ITERATOR]();
      iter.next = function() {
        safe = true;
      };
      arr[ITERATOR] = function() {
        return iter;
      };
      exec(arr);
    } catch (e) {}
    return safe;
  };
  return module.exports;
});

$__System.registerDynamic("23d", ["105", "10b", "118", "233", "234", "235", "11c", "113"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ctx = $__require('105'),
      $export = $__require('10b'),
      toObject = $__require('118'),
      call = $__require('233'),
      isArrayIter = $__require('234'),
      toLength = $__require('235'),
      getIterFn = $__require('11c');
  $export($export.S + $export.F * !$__require('113')(function(iter) {
    Array.from(iter);
  }), 'Array', {from: function from(arrayLike) {
      var O = toObject(arrayLike),
          C = typeof this == 'function' ? this : Array,
          $$ = arguments,
          $$len = $$.length,
          mapfn = $$len > 1 ? $$[1] : undefined,
          mapping = mapfn !== undefined,
          index = 0,
          iterFn = getIterFn(O),
          length,
          result,
          step,
          iterator;
      if (mapping)
        mapfn = ctx(mapfn, $$len > 2 ? $$[2] : undefined, 2);
      if (iterFn != undefined && !(C == Array && isArrayIter(iterFn))) {
        for (iterator = iterFn.call(O), result = new C; !(step = iterator.next()).done; index++) {
          result[index] = mapping ? call(iterator, mapfn, [step.value, index], true) : step.value;
        }
      } else {
        length = toLength(O.length);
        for (result = new C(length); length > index; index++) {
          result[index] = mapping ? mapfn(O[index], index) : O[index];
        }
      }
      result.length = index;
      return result;
    }});
  return module.exports;
});

$__System.registerDynamic("23e", ["f9", "23d", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('f9');
  $__require('23d');
  module.exports = $__require('f6').Array.from;
  return module.exports;
});

$__System.registerDynamic("a2", ["23e"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('23e'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("101", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var global = module.exports = typeof window != 'undefined' && window.Math == Math ? window : typeof self != 'undefined' && self.Math == Math ? self : Function('return this')();
  if (typeof __g == 'number')
    __g = global;
  return module.exports;
});

$__System.registerDynamic("fe", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(it) {
    if (typeof it != 'function')
      throw TypeError(it + ' is not a function!');
    return it;
  };
  return module.exports;
});

$__System.registerDynamic("105", ["fe"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var aFunction = $__require('fe');
  module.exports = function(fn, that, length) {
    aFunction(fn);
    if (that === undefined)
      return fn;
    switch (length) {
      case 1:
        return function(a) {
          return fn.call(that, a);
        };
      case 2:
        return function(a, b) {
          return fn.call(that, a, b);
        };
      case 3:
        return function(a, b, c) {
          return fn.call(that, a, b, c);
        };
    }
    return function() {
      return fn.apply(that, arguments);
    };
  };
  return module.exports;
});

$__System.registerDynamic("10b", ["101", "f6", "105"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var global = $__require('101'),
      core = $__require('f6'),
      ctx = $__require('105'),
      PROTOTYPE = 'prototype';
  var $export = function(type, name, source) {
    var IS_FORCED = type & $export.F,
        IS_GLOBAL = type & $export.G,
        IS_STATIC = type & $export.S,
        IS_PROTO = type & $export.P,
        IS_BIND = type & $export.B,
        IS_WRAP = type & $export.W,
        exports = IS_GLOBAL ? core : core[name] || (core[name] = {}),
        target = IS_GLOBAL ? global : IS_STATIC ? global[name] : (global[name] || {})[PROTOTYPE],
        key,
        own,
        out;
    if (IS_GLOBAL)
      source = name;
    for (key in source) {
      own = !IS_FORCED && target && key in target;
      if (own && key in exports)
        continue;
      out = own ? target[key] : source[key];
      exports[key] = IS_GLOBAL && typeof target[key] != 'function' ? source[key] : IS_BIND && own ? ctx(out, global) : IS_WRAP && target[key] == out ? (function(C) {
        var F = function(param) {
          return this instanceof C ? new C(param) : C(param);
        };
        F[PROTOTYPE] = C[PROTOTYPE];
        return F;
      })(out) : IS_PROTO && typeof out == 'function' ? ctx(Function.call, out) : out;
      if (IS_PROTO)
        (exports[PROTOTYPE] || (exports[PROTOTYPE] = {}))[key] = out;
    }
  };
  $export.F = 1;
  $export.G = 2;
  $export.S = 4;
  $export.P = 8;
  $export.B = 16;
  $export.W = 32;
  module.exports = $export;
  return module.exports;
});

$__System.registerDynamic("22a", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(it) {
    if (it == undefined)
      throw TypeError("Can't call method on  " + it);
    return it;
  };
  return module.exports;
});

$__System.registerDynamic("118", ["22a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var defined = $__require('22a');
  module.exports = function(it) {
    return Object(defined(it));
  };
  return module.exports;
});

$__System.registerDynamic("106", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var toString = {}.toString;
  module.exports = function(it) {
    return toString.call(it).slice(8, -1);
  };
  return module.exports;
});

$__System.registerDynamic("229", ["106"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var cof = $__require('106');
  module.exports = Object('z').propertyIsEnumerable(0) ? Object : function(it) {
    return cof(it) == 'String' ? it.split('') : Object(it);
  };
  return module.exports;
});

$__System.registerDynamic("215", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = function(exec) {
    try {
      return !!exec();
    } catch (e) {
      return true;
    }
  };
  return module.exports;
});

$__System.registerDynamic("23f", ["109", "118", "229", "215"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109'),
      toObject = $__require('118'),
      IObject = $__require('229');
  module.exports = $__require('215')(function() {
    var a = Object.assign,
        A = {},
        B = {},
        S = Symbol(),
        K = 'abcdefghijklmnopqrst';
    A[S] = 7;
    K.split('').forEach(function(k) {
      B[k] = k;
    });
    return a({}, A)[S] != 7 || Object.keys(a({}, B)).join('') != K;
  }) ? function assign(target, source) {
    var T = toObject(target),
        $$ = arguments,
        $$len = $$.length,
        index = 1,
        getKeys = $.getKeys,
        getSymbols = $.getSymbols,
        isEnum = $.isEnum;
    while ($$len > index) {
      var S = IObject($$[index++]),
          keys = getSymbols ? getKeys(S).concat(getSymbols(S)) : getKeys(S),
          length = keys.length,
          j = 0,
          key;
      while (length > j)
        if (isEnum.call(S, key = keys[j++]))
          T[key] = S[key];
    }
    return T;
  } : Object.assign;
  return module.exports;
});

$__System.registerDynamic("240", ["10b", "23f"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $export = $__require('10b');
  $export($export.S + $export.F, 'Object', {assign: $__require('23f')});
  return module.exports;
});

$__System.registerDynamic("f6", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var core = module.exports = {version: '1.2.6'};
  if (typeof __e == 'number')
    __e = core;
  return module.exports;
});

$__System.registerDynamic("241", ["240", "f6"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  $__require('240');
  module.exports = $__require('f6').Object.assign;
  return module.exports;
});

$__System.registerDynamic("92", ["241"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('241'),
    __esModule: true
  };
  return module.exports;
});

$__System.register('242', ['11', '89', '92', '224', '8a', 'a2', '9c', '5e'], function (_export) {
  var Injectable, _createClass, _Object$assign, _Set, _classCallCheck, _Array$from, isFunction, isString, global, BrowserDomAdapter, defaults, OPTION_NAMES, OptionsService;

  return {
    setters: [function (_4) {
      Injectable = _4.Injectable;
    }, function (_) {
      _createClass = _['default'];
    }, function (_3) {
      _Object$assign = _3['default'];
    }, function (_2) {
      _Set = _2['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_a2) {
      _Array$from = _a2['default'];
    }, function (_c) {
      isFunction = _c.isFunction;
      isString = _c.isString;
      global = _c.global;
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }],
    execute: function () {
      'use strict';
      defaults = {
        scrollYOffset: 0,
        disableLazySchemas: false,
        debugMode: global && global.redocDebugMode
      };
      OPTION_NAMES = new _Set(['scrollYOffset', 'disableLazySchemas', 'specUrl']);

      OptionsService = (function () {
        function OptionsService(dom) {
          _classCallCheck(this, _OptionsService);

          this._options = defaults;
          this.dom = dom;
        }

        _createClass(OptionsService, [{
          key: 'parseOptions',
          value: function parseOptions(el) {
            var parsedOpts = undefined;
            var attributesMap = this.dom.attributeMap(el);
            parsedOpts = {};
            _Array$from(attributesMap.keys())
            //camelCasify
            .map(function (k) {
              return {
                attrName: k,
                name: k.replace(/-(.)/g, function (m, $1) {
                  return $1.toUpperCase();
                })
              };
            }).filter(function (option) {
              return OPTION_NAMES.has(option.name);
            }).forEach(function (option) {
              parsedOpts[option.name] = attributesMap.get(option.attrName);
            });

            this.options = parsedOpts;
            this._normalizeOptions();
          }
        }, {
          key: '_normalizeOptions',
          value: function _normalizeOptions() {
            var _this = this;

            // modify scrollYOffset to always be a function
            if (!isFunction(this._options.scrollYOffset)) {
              if (isFinite(this._options.scrollYOffset)) {
                (function () {
                  // if number specified create function that returns this value
                  var numberOffset = parseFloat(_this._options.scrollYOffset);
                  _this.options.scrollYOffset = function () {
                    return numberOffset;
                  };
                })();
              } else {
                (function () {
                  // if selector or node function that returns bottom offset of this node
                  var el = _this._options.scrollYOffset;
                  if (!(el instanceof Node)) {
                    el = _this.dom.query(el);
                  }
                  if (!el) {
                    _this._options.scrollYOffset = function () {
                      return 0;
                    };
                  } else {
                    _this._options.scrollYOffset = function () {
                      return el.offsetTop + el.offsetHeight;
                    };
                  }
                })();
              }
            }

            if (isString(this._options.disableLazySchemas)) this._options.disableLazySchemas = true;
          }
        }, {
          key: 'options',
          get: function get() {
            return this._options;
          },
          set: function set(opts) {
            this._options = _Object$assign(this._options, opts);
          }
        }]);

        var _OptionsService = OptionsService;
        OptionsService = Reflect.metadata('parameters', [[BrowserDomAdapter]])(OptionsService) || OptionsService;
        OptionsService = Injectable()(OptionsService) || OptionsService;
        return OptionsService;
      })();

      _export('OptionsService', OptionsService);
    }
  };
});
$__System.register('226', ['11', '89', '242', '8a', '5e'], function (_export) {
  var Injectable, EventEmitter, _createClass, OptionsService, _classCallCheck, BrowserDomAdapter, INVIEW_POSITION, ScrollService;

  return {
    setters: [function (_2) {
      Injectable = _2.Injectable;
      EventEmitter = _2.EventEmitter;
    }, function (_) {
      _createClass = _['default'];
    }, function (_3) {
      OptionsService = _3.OptionsService;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }],
    execute: function () {
      'use strict';
      INVIEW_POSITION = {
        ABOVE: 1,
        BELLOW: -1,
        INVIEW: 0
      };

      _export('INVIEW_POSITION', INVIEW_POSITION);

      ScrollService = (function () {
        function ScrollService(dom, optionsService) {
          _classCallCheck(this, _ScrollService);

          //events.bootstrapped.subscribe(() => this.hashScroll());
          this.scrollYOffset = function () {
            return optionsService.options.scrollYOffset();
          };
          this.$scrollParent = optionsService.options.$scrollParent;
          this.scroll = new EventEmitter();
          this.dom = dom;
          this.bind();
        }

        _createClass(ScrollService, [{
          key: 'scrollY',
          value: function scrollY() {
            return this.$scrollParent.pageYOffset != null ? this.$scrollParent.pageYOffset : this.$scrollParent.scrollTop;
          }

          /* returns 1 if element if above the view, 0 if in view and -1 below the view */
        }, {
          key: 'getElementPos',
          value: function getElementPos($el) {
            if (Math.floor($el.getBoundingClientRect().top) > this.scrollYOffset()) {
              return INVIEW_POSITION.ABOVE;
            }

            if ($el.getBoundingClientRect().bottom <= this.scrollYOffset()) {
              return INVIEW_POSITION.BELLOW;
            }
            return INVIEW_POSITION.INVIEW;
          }
        }, {
          key: 'scrollTo',
          value: function scrollTo($el) {
            // TODO: rewrite this to use offsetTop as more reliable solution
            var subjRect = $el.getBoundingClientRect();
            var offset = this.scrollY() + subjRect.top - this.scrollYOffset() + 1;
            if (this.$scrollParent.scrollTo) {
              this.$scrollParent.scrollTo(0, offset);
            } else {
              this.$scrollParent.scrollTop = offset;
            }
          }
        }, {
          key: 'scrollHandler',
          value: function scrollHandler(evt) {
            var isScrolledDown = this.scrollY() - this.prevOffsetY > 0;
            this.prevOffsetY = this.scrollY();
            this.scroll.next({ isScrolledDown: isScrolledDown, evt: evt });
          }
        }, {
          key: 'bind',
          value: function bind() {
            var _this = this;

            this.prevOffsetY = this.scrollY();
            this._cancel = this.dom.onAndCancel(this.$scrollParent, 'scroll', function (evt) {
              _this.scrollHandler(evt);
            });
          }
        }, {
          key: 'unbind',
          value: function unbind() {
            this._cancel();
          }
        }]);

        var _ScrollService = ScrollService;
        ScrollService = Injectable()(ScrollService) || ScrollService;
        ScrollService = Reflect.metadata('parameters', [[BrowserDomAdapter], [OptionsService]])(ScrollService) || ScrollService;
        return ScrollService;
      })();

      _export('ScrollService', ScrollService);
    }
  };
});
$__System.registerDynamic("109", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $Object = Object;
  module.exports = {
    create: $Object.create,
    getProto: $Object.getPrototypeOf,
    isEnum: {}.propertyIsEnumerable,
    getDesc: $Object.getOwnPropertyDescriptor,
    setDesc: $Object.defineProperty,
    setDescs: $Object.defineProperties,
    getKeys: $Object.keys,
    getNames: $Object.getOwnPropertyNames,
    getSymbols: $Object.getOwnPropertySymbols,
    each: [].forEach
  };
  return module.exports;
});

$__System.registerDynamic("243", ["109"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var $ = $__require('109');
  module.exports = function defineProperty(it, key, desc) {
    return $.setDesc(it, key, desc);
  };
  return module.exports;
});

$__System.registerDynamic("244", ["243"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = {
    "default": $__require('243'),
    __esModule: true
  };
  return module.exports;
});

$__System.registerDynamic("89", ["244"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var _Object$defineProperty = $__require('244')["default"];
  exports["default"] = (function() {
    function defineProperties(target, props) {
      for (var i = 0; i < props.length; i++) {
        var descriptor = props[i];
        descriptor.enumerable = descriptor.enumerable || false;
        descriptor.configurable = true;
        if ("value" in descriptor)
          descriptor.writable = true;
        _Object$defineProperty(target, descriptor.key, descriptor);
      }
    }
    return function(Constructor, protoProps, staticProps) {
      if (protoProps)
        defineProperties(Constructor.prototype, protoProps);
      if (staticProps)
        defineProperties(Constructor, staticProps);
      return Constructor;
    };
  })();
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("64", ["65"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  exports.Map = lang_1.global.Map;
  exports.Set = lang_1.global.Set;
  var createMapFromPairs = (function() {
    try {
      if (new exports.Map([[1, 2]]).size === 1) {
        return function createMapFromPairs(pairs) {
          return new exports.Map(pairs);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromPairs(pairs) {
      var map = new exports.Map();
      for (var i = 0; i < pairs.length; i++) {
        var pair = pairs[i];
        map.set(pair[0], pair[1]);
      }
      return map;
    };
  })();
  var createMapFromMap = (function() {
    try {
      if (new exports.Map(new exports.Map())) {
        return function createMapFromMap(m) {
          return new exports.Map(m);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromMap(m) {
      var map = new exports.Map();
      m.forEach(function(v, k) {
        map.set(k, v);
      });
      return map;
    };
  })();
  var _clearValues = (function() {
    if ((new exports.Map()).keys().next) {
      return function _clearValues(m) {
        var keyIterator = m.keys();
        var k;
        while (!((k = keyIterator.next()).done)) {
          m.set(k.value, null);
        }
      };
    } else {
      return function _clearValuesWithForeEach(m) {
        m.forEach(function(v, k) {
          m.set(k, null);
        });
      };
    }
  })();
  var _arrayFromMap = (function() {
    try {
      if ((new exports.Map()).values().next) {
        return function createArrayFromMap(m, getValues) {
          return getValues ? Array.from(m.values()) : Array.from(m.keys());
        };
      }
    } catch (e) {}
    return function createArrayFromMapWithForeach(m, getValues) {
      var res = ListWrapper.createFixedSize(m.size),
          i = 0;
      m.forEach(function(v, k) {
        res[i] = getValues ? v : k;
        i++;
      });
      return res;
    };
  })();
  var MapWrapper = (function() {
    function MapWrapper() {}
    MapWrapper.clone = function(m) {
      return createMapFromMap(m);
    };
    MapWrapper.createFromStringMap = function(stringMap) {
      var result = new exports.Map();
      for (var prop in stringMap) {
        result.set(prop, stringMap[prop]);
      }
      return result;
    };
    MapWrapper.toStringMap = function(m) {
      var r = {};
      m.forEach(function(v, k) {
        return r[k] = v;
      });
      return r;
    };
    MapWrapper.createFromPairs = function(pairs) {
      return createMapFromPairs(pairs);
    };
    MapWrapper.clearValues = function(m) {
      _clearValues(m);
    };
    MapWrapper.iterable = function(m) {
      return m;
    };
    MapWrapper.keys = function(m) {
      return _arrayFromMap(m, false);
    };
    MapWrapper.values = function(m) {
      return _arrayFromMap(m, true);
    };
    return MapWrapper;
  }());
  exports.MapWrapper = MapWrapper;
  var StringMapWrapper = (function() {
    function StringMapWrapper() {}
    StringMapWrapper.create = function() {
      return {};
    };
    StringMapWrapper.contains = function(map, key) {
      return map.hasOwnProperty(key);
    };
    StringMapWrapper.get = function(map, key) {
      return map.hasOwnProperty(key) ? map[key] : undefined;
    };
    StringMapWrapper.set = function(map, key, value) {
      map[key] = value;
    };
    StringMapWrapper.keys = function(map) {
      return Object.keys(map);
    };
    StringMapWrapper.values = function(map) {
      return Object.keys(map).reduce(function(r, a) {
        r.push(map[a]);
        return r;
      }, []);
    };
    StringMapWrapper.isEmpty = function(map) {
      for (var prop in map) {
        return false;
      }
      return true;
    };
    StringMapWrapper.delete = function(map, key) {
      delete map[key];
    };
    StringMapWrapper.forEach = function(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    };
    StringMapWrapper.merge = function(m1, m2) {
      var m = {};
      for (var attr in m1) {
        if (m1.hasOwnProperty(attr)) {
          m[attr] = m1[attr];
        }
      }
      for (var attr in m2) {
        if (m2.hasOwnProperty(attr)) {
          m[attr] = m2[attr];
        }
      }
      return m;
    };
    StringMapWrapper.equals = function(m1, m2) {
      var k1 = Object.keys(m1);
      var k2 = Object.keys(m2);
      if (k1.length != k2.length) {
        return false;
      }
      var key;
      for (var i = 0; i < k1.length; i++) {
        key = k1[i];
        if (m1[key] !== m2[key]) {
          return false;
        }
      }
      return true;
    };
    return StringMapWrapper;
  }());
  exports.StringMapWrapper = StringMapWrapper;
  var ListWrapper = (function() {
    function ListWrapper() {}
    ListWrapper.createFixedSize = function(size) {
      return new Array(size);
    };
    ListWrapper.createGrowableSize = function(size) {
      return new Array(size);
    };
    ListWrapper.clone = function(array) {
      return array.slice(0);
    };
    ListWrapper.forEachWithIndex = function(array, fn) {
      for (var i = 0; i < array.length; i++) {
        fn(array[i], i);
      }
    };
    ListWrapper.first = function(array) {
      if (!array)
        return null;
      return array[0];
    };
    ListWrapper.last = function(array) {
      if (!array || array.length == 0)
        return null;
      return array[array.length - 1];
    };
    ListWrapper.indexOf = function(array, value, startIndex) {
      if (startIndex === void 0) {
        startIndex = 0;
      }
      return array.indexOf(value, startIndex);
    };
    ListWrapper.contains = function(list, el) {
      return list.indexOf(el) !== -1;
    };
    ListWrapper.reversed = function(array) {
      var a = ListWrapper.clone(array);
      return a.reverse();
    };
    ListWrapper.concat = function(a, b) {
      return a.concat(b);
    };
    ListWrapper.insert = function(list, index, value) {
      list.splice(index, 0, value);
    };
    ListWrapper.removeAt = function(list, index) {
      var res = list[index];
      list.splice(index, 1);
      return res;
    };
    ListWrapper.removeAll = function(list, items) {
      for (var i = 0; i < items.length; ++i) {
        var index = list.indexOf(items[i]);
        list.splice(index, 1);
      }
    };
    ListWrapper.remove = function(list, el) {
      var index = list.indexOf(el);
      if (index > -1) {
        list.splice(index, 1);
        return true;
      }
      return false;
    };
    ListWrapper.clear = function(list) {
      list.length = 0;
    };
    ListWrapper.isEmpty = function(list) {
      return list.length == 0;
    };
    ListWrapper.fill = function(list, value, start, end) {
      if (start === void 0) {
        start = 0;
      }
      if (end === void 0) {
        end = null;
      }
      list.fill(value, start, end === null ? list.length : end);
    };
    ListWrapper.equals = function(a, b) {
      if (a.length != b.length)
        return false;
      for (var i = 0; i < a.length; ++i) {
        if (a[i] !== b[i])
          return false;
      }
      return true;
    };
    ListWrapper.slice = function(l, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return l.slice(from, to === null ? undefined : to);
    };
    ListWrapper.splice = function(l, from, length) {
      return l.splice(from, length);
    };
    ListWrapper.sort = function(l, compareFn) {
      if (lang_1.isPresent(compareFn)) {
        l.sort(compareFn);
      } else {
        l.sort();
      }
    };
    ListWrapper.toString = function(l) {
      return l.toString();
    };
    ListWrapper.toJSON = function(l) {
      return JSON.stringify(l);
    };
    ListWrapper.maximum = function(list, predicate) {
      if (list.length == 0) {
        return null;
      }
      var solution = null;
      var maxValue = -Infinity;
      for (var index = 0; index < list.length; index++) {
        var candidate = list[index];
        if (lang_1.isBlank(candidate)) {
          continue;
        }
        var candidateValue = predicate(candidate);
        if (candidateValue > maxValue) {
          solution = candidate;
          maxValue = candidateValue;
        }
      }
      return solution;
    };
    ListWrapper.flatten = function(list) {
      var target = [];
      _flattenArray(list, target);
      return target;
    };
    ListWrapper.addAll = function(list, source) {
      for (var i = 0; i < source.length; i++) {
        list.push(source[i]);
      }
    };
    return ListWrapper;
  }());
  exports.ListWrapper = ListWrapper;
  function _flattenArray(source, target) {
    if (lang_1.isPresent(source)) {
      for (var i = 0; i < source.length; i++) {
        var item = source[i];
        if (lang_1.isArray(item)) {
          _flattenArray(item, target);
        } else {
          target.push(item);
        }
      }
    }
    return target;
  }
  function isListLikeIterable(obj) {
    if (!lang_1.isJsObject(obj))
      return false;
    return lang_1.isArray(obj) || (!(obj instanceof exports.Map) && lang_1.getSymbolIterator() in obj);
  }
  exports.isListLikeIterable = isListLikeIterable;
  function areIterablesEqual(a, b, comparator) {
    var iterator1 = a[lang_1.getSymbolIterator()]();
    var iterator2 = b[lang_1.getSymbolIterator()]();
    while (true) {
      var item1 = iterator1.next();
      var item2 = iterator2.next();
      if (item1.done && item2.done)
        return true;
      if (item1.done || item2.done)
        return false;
      if (!comparator(item1.value, item2.value))
        return false;
    }
  }
  exports.areIterablesEqual = areIterablesEqual;
  function iterateListLike(obj, fn) {
    if (lang_1.isArray(obj)) {
      for (var i = 0; i < obj.length; i++) {
        fn(obj[i]);
      }
    } else {
      var iterator = obj[lang_1.getSymbolIterator()]();
      var item;
      while (!((item = iterator.next()).done)) {
        fn(item.value);
      }
    }
  }
  exports.iterateListLike = iterateListLike;
  var createSetFromList = (function() {
    var test = new exports.Set([1, 2, 3]);
    if (test.size === 3) {
      return function createSetFromList(lst) {
        return new exports.Set(lst);
      };
    } else {
      return function createSetAndPopulateFromList(lst) {
        var res = new exports.Set(lst);
        if (res.size !== lst.length) {
          for (var i = 0; i < lst.length; i++) {
            res.add(lst[i]);
          }
        }
        return res;
      };
    }
  })();
  var SetWrapper = (function() {
    function SetWrapper() {}
    SetWrapper.createFromList = function(lst) {
      return createSetFromList(lst);
    };
    SetWrapper.has = function(s, key) {
      return s.has(key);
    };
    SetWrapper.delete = function(m, k) {
      m.delete(k);
    };
    return SetWrapper;
  }());
  exports.SetWrapper = SetWrapper;
  return module.exports;
});

$__System.registerDynamic("245", ["64", "65", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var collection_1 = $__require('64');
  var lang_1 = $__require('65');
  var dom_adapter_1 = $__require('5d');
  var GenericBrowserDomAdapter = (function(_super) {
    __extends(GenericBrowserDomAdapter, _super);
    function GenericBrowserDomAdapter() {
      var _this = this;
      _super.call(this);
      this._animationPrefix = null;
      this._transitionEnd = null;
      try {
        var element = this.createElement('div', this.defaultDoc());
        if (lang_1.isPresent(this.getStyle(element, 'animationName'))) {
          this._animationPrefix = '';
        } else {
          var domPrefixes = ['Webkit', 'Moz', 'O', 'ms'];
          for (var i = 0; i < domPrefixes.length; i++) {
            if (lang_1.isPresent(this.getStyle(element, domPrefixes[i] + 'AnimationName'))) {
              this._animationPrefix = '-' + domPrefixes[i].toLowerCase() + '-';
              break;
            }
          }
        }
        var transEndEventNames = {
          WebkitTransition: 'webkitTransitionEnd',
          MozTransition: 'transitionend',
          OTransition: 'oTransitionEnd otransitionend',
          transition: 'transitionend'
        };
        collection_1.StringMapWrapper.forEach(transEndEventNames, function(value, key) {
          if (lang_1.isPresent(_this.getStyle(element, key))) {
            _this._transitionEnd = value;
          }
        });
      } catch (e) {
        this._animationPrefix = null;
        this._transitionEnd = null;
      }
    }
    GenericBrowserDomAdapter.prototype.getDistributedNodes = function(el) {
      return el.getDistributedNodes();
    };
    GenericBrowserDomAdapter.prototype.resolveAndSetHref = function(el, baseUrl, href) {
      el.href = href == null ? baseUrl : baseUrl + '/../' + href;
    };
    GenericBrowserDomAdapter.prototype.supportsDOMEvents = function() {
      return true;
    };
    GenericBrowserDomAdapter.prototype.supportsNativeShadowDOM = function() {
      return lang_1.isFunction(this.defaultDoc().body.createShadowRoot);
    };
    GenericBrowserDomAdapter.prototype.getAnimationPrefix = function() {
      return lang_1.isPresent(this._animationPrefix) ? this._animationPrefix : "";
    };
    GenericBrowserDomAdapter.prototype.getTransitionEnd = function() {
      return lang_1.isPresent(this._transitionEnd) ? this._transitionEnd : "";
    };
    GenericBrowserDomAdapter.prototype.supportsAnimation = function() {
      return lang_1.isPresent(this._animationPrefix) && lang_1.isPresent(this._transitionEnd);
    };
    return GenericBrowserDomAdapter;
  }(dom_adapter_1.DomAdapter));
  exports.GenericBrowserDomAdapter = GenericBrowserDomAdapter;
  return module.exports;
});

$__System.registerDynamic("65", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var globalScope;
  if (typeof window === 'undefined') {
    if (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) {
      globalScope = self;
    } else {
      globalScope = global;
    }
  } else {
    globalScope = window;
  }
  function scheduleMicroTask(fn) {
    Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
  }
  exports.scheduleMicroTask = scheduleMicroTask;
  exports.IS_DART = false;
  var _global = globalScope;
  exports.global = _global;
  exports.Type = Function;
  function getTypeNameForDebugging(type) {
    if (type['name']) {
      return type['name'];
    }
    return typeof type;
  }
  exports.getTypeNameForDebugging = getTypeNameForDebugging;
  exports.Math = _global.Math;
  exports.Date = _global.Date;
  var _devMode = true;
  var _modeLocked = false;
  function lockMode() {
    _modeLocked = true;
  }
  exports.lockMode = lockMode;
  function enableProdMode() {
    if (_modeLocked) {
      throw 'Cannot enable prod mode after platform setup.';
    }
    _devMode = false;
  }
  exports.enableProdMode = enableProdMode;
  function assertionsEnabled() {
    return _devMode;
  }
  exports.assertionsEnabled = assertionsEnabled;
  _global.assert = function assert(condition) {};
  function isPresent(obj) {
    return obj !== undefined && obj !== null;
  }
  exports.isPresent = isPresent;
  function isBlank(obj) {
    return obj === undefined || obj === null;
  }
  exports.isBlank = isBlank;
  function isBoolean(obj) {
    return typeof obj === "boolean";
  }
  exports.isBoolean = isBoolean;
  function isNumber(obj) {
    return typeof obj === "number";
  }
  exports.isNumber = isNumber;
  function isString(obj) {
    return typeof obj === "string";
  }
  exports.isString = isString;
  function isFunction(obj) {
    return typeof obj === "function";
  }
  exports.isFunction = isFunction;
  function isType(obj) {
    return isFunction(obj);
  }
  exports.isType = isType;
  function isStringMap(obj) {
    return typeof obj === 'object' && obj !== null;
  }
  exports.isStringMap = isStringMap;
  var STRING_MAP_PROTO = Object.getPrototypeOf({});
  function isStrictStringMap(obj) {
    return isStringMap(obj) && Object.getPrototypeOf(obj) === STRING_MAP_PROTO;
  }
  exports.isStrictStringMap = isStrictStringMap;
  function isPromise(obj) {
    return obj instanceof _global.Promise;
  }
  exports.isPromise = isPromise;
  function isArray(obj) {
    return Array.isArray(obj);
  }
  exports.isArray = isArray;
  function isDate(obj) {
    return obj instanceof exports.Date && !isNaN(obj.valueOf());
  }
  exports.isDate = isDate;
  function noop() {}
  exports.noop = noop;
  function stringify(token) {
    if (typeof token === 'string') {
      return token;
    }
    if (token === undefined || token === null) {
      return '' + token;
    }
    if (token.name) {
      return token.name;
    }
    if (token.overriddenName) {
      return token.overriddenName;
    }
    var res = token.toString();
    var newLineIndex = res.indexOf("\n");
    return (newLineIndex === -1) ? res : res.substring(0, newLineIndex);
  }
  exports.stringify = stringify;
  function serializeEnum(val) {
    return val;
  }
  exports.serializeEnum = serializeEnum;
  function deserializeEnum(val, values) {
    return val;
  }
  exports.deserializeEnum = deserializeEnum;
  function resolveEnumToken(enumValue, val) {
    return enumValue[val];
  }
  exports.resolveEnumToken = resolveEnumToken;
  var StringWrapper = (function() {
    function StringWrapper() {}
    StringWrapper.fromCharCode = function(code) {
      return String.fromCharCode(code);
    };
    StringWrapper.charCodeAt = function(s, index) {
      return s.charCodeAt(index);
    };
    StringWrapper.split = function(s, regExp) {
      return s.split(regExp);
    };
    StringWrapper.equals = function(s, s2) {
      return s === s2;
    };
    StringWrapper.stripLeft = function(s, charVal) {
      if (s && s.length) {
        var pos = 0;
        for (var i = 0; i < s.length; i++) {
          if (s[i] != charVal)
            break;
          pos++;
        }
        s = s.substring(pos);
      }
      return s;
    };
    StringWrapper.stripRight = function(s, charVal) {
      if (s && s.length) {
        var pos = s.length;
        for (var i = s.length - 1; i >= 0; i--) {
          if (s[i] != charVal)
            break;
          pos--;
        }
        s = s.substring(0, pos);
      }
      return s;
    };
    StringWrapper.replace = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.replaceAll = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.slice = function(s, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return s.slice(from, to === null ? undefined : to);
    };
    StringWrapper.replaceAllMapped = function(s, from, cb) {
      return s.replace(from, function() {
        var matches = [];
        for (var _i = 0; _i < arguments.length; _i++) {
          matches[_i - 0] = arguments[_i];
        }
        matches.splice(-2, 2);
        return cb(matches);
      });
    };
    StringWrapper.contains = function(s, substr) {
      return s.indexOf(substr) != -1;
    };
    StringWrapper.compare = function(a, b) {
      if (a < b) {
        return -1;
      } else if (a > b) {
        return 1;
      } else {
        return 0;
      }
    };
    return StringWrapper;
  }());
  exports.StringWrapper = StringWrapper;
  var StringJoiner = (function() {
    function StringJoiner(parts) {
      if (parts === void 0) {
        parts = [];
      }
      this.parts = parts;
    }
    StringJoiner.prototype.add = function(part) {
      this.parts.push(part);
    };
    StringJoiner.prototype.toString = function() {
      return this.parts.join("");
    };
    return StringJoiner;
  }());
  exports.StringJoiner = StringJoiner;
  var NumberParseError = (function(_super) {
    __extends(NumberParseError, _super);
    function NumberParseError(message) {
      _super.call(this);
      this.message = message;
    }
    NumberParseError.prototype.toString = function() {
      return this.message;
    };
    return NumberParseError;
  }(Error));
  exports.NumberParseError = NumberParseError;
  var NumberWrapper = (function() {
    function NumberWrapper() {}
    NumberWrapper.toFixed = function(n, fractionDigits) {
      return n.toFixed(fractionDigits);
    };
    NumberWrapper.equal = function(a, b) {
      return a === b;
    };
    NumberWrapper.parseIntAutoRadix = function(text) {
      var result = parseInt(text);
      if (isNaN(result)) {
        throw new NumberParseError("Invalid integer literal when parsing " + text);
      }
      return result;
    };
    NumberWrapper.parseInt = function(text, radix) {
      if (radix == 10) {
        if (/^(\-|\+)?[0-9]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else if (radix == 16) {
        if (/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else {
        var result = parseInt(text, radix);
        if (!isNaN(result)) {
          return result;
        }
      }
      throw new NumberParseError("Invalid integer literal when parsing " + text + " in base " + radix);
    };
    NumberWrapper.parseFloat = function(text) {
      return parseFloat(text);
    };
    Object.defineProperty(NumberWrapper, "NaN", {
      get: function() {
        return NaN;
      },
      enumerable: true,
      configurable: true
    });
    NumberWrapper.isNaN = function(value) {
      return isNaN(value);
    };
    NumberWrapper.isInteger = function(value) {
      return Number.isInteger(value);
    };
    return NumberWrapper;
  }());
  exports.NumberWrapper = NumberWrapper;
  exports.RegExp = _global.RegExp;
  var RegExpWrapper = (function() {
    function RegExpWrapper() {}
    RegExpWrapper.create = function(regExpStr, flags) {
      if (flags === void 0) {
        flags = '';
      }
      flags = flags.replace(/g/g, '');
      return new _global.RegExp(regExpStr, flags + 'g');
    };
    RegExpWrapper.firstMatch = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.exec(input);
    };
    RegExpWrapper.test = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.test(input);
    };
    RegExpWrapper.matcher = function(regExp, input) {
      regExp.lastIndex = 0;
      return {
        re: regExp,
        input: input
      };
    };
    RegExpWrapper.replaceAll = function(regExp, input, replace) {
      var c = regExp.exec(input);
      var res = '';
      regExp.lastIndex = 0;
      var prev = 0;
      while (c) {
        res += input.substring(prev, c.index);
        res += replace(c);
        prev = c.index + c[0].length;
        regExp.lastIndex = prev;
        c = regExp.exec(input);
      }
      res += input.substring(prev);
      return res;
    };
    return RegExpWrapper;
  }());
  exports.RegExpWrapper = RegExpWrapper;
  var RegExpMatcherWrapper = (function() {
    function RegExpMatcherWrapper() {}
    RegExpMatcherWrapper.next = function(matcher) {
      return matcher.re.exec(matcher.input);
    };
    return RegExpMatcherWrapper;
  }());
  exports.RegExpMatcherWrapper = RegExpMatcherWrapper;
  var FunctionWrapper = (function() {
    function FunctionWrapper() {}
    FunctionWrapper.apply = function(fn, posArgs) {
      return fn.apply(null, posArgs);
    };
    return FunctionWrapper;
  }());
  exports.FunctionWrapper = FunctionWrapper;
  function looseIdentical(a, b) {
    return a === b || typeof a === "number" && typeof b === "number" && isNaN(a) && isNaN(b);
  }
  exports.looseIdentical = looseIdentical;
  function getMapKey(value) {
    return value;
  }
  exports.getMapKey = getMapKey;
  function normalizeBlank(obj) {
    return isBlank(obj) ? null : obj;
  }
  exports.normalizeBlank = normalizeBlank;
  function normalizeBool(obj) {
    return isBlank(obj) ? false : obj;
  }
  exports.normalizeBool = normalizeBool;
  function isJsObject(o) {
    return o !== null && (typeof o === "function" || typeof o === "object");
  }
  exports.isJsObject = isJsObject;
  function print(obj) {
    console.log(obj);
  }
  exports.print = print;
  function warn(obj) {
    console.warn(obj);
  }
  exports.warn = warn;
  var Json = (function() {
    function Json() {}
    Json.parse = function(s) {
      return _global.JSON.parse(s);
    };
    Json.stringify = function(data) {
      return _global.JSON.stringify(data, null, 2);
    };
    return Json;
  }());
  exports.Json = Json;
  var DateWrapper = (function() {
    function DateWrapper() {}
    DateWrapper.create = function(year, month, day, hour, minutes, seconds, milliseconds) {
      if (month === void 0) {
        month = 1;
      }
      if (day === void 0) {
        day = 1;
      }
      if (hour === void 0) {
        hour = 0;
      }
      if (minutes === void 0) {
        minutes = 0;
      }
      if (seconds === void 0) {
        seconds = 0;
      }
      if (milliseconds === void 0) {
        milliseconds = 0;
      }
      return new exports.Date(year, month - 1, day, hour, minutes, seconds, milliseconds);
    };
    DateWrapper.fromISOString = function(str) {
      return new exports.Date(str);
    };
    DateWrapper.fromMillis = function(ms) {
      return new exports.Date(ms);
    };
    DateWrapper.toMillis = function(date) {
      return date.getTime();
    };
    DateWrapper.now = function() {
      return new exports.Date();
    };
    DateWrapper.toJson = function(date) {
      return date.toJSON();
    };
    return DateWrapper;
  }());
  exports.DateWrapper = DateWrapper;
  function setValueOnPath(global, path, value) {
    var parts = path.split('.');
    var obj = global;
    while (parts.length > 1) {
      var name = parts.shift();
      if (obj.hasOwnProperty(name) && isPresent(obj[name])) {
        obj = obj[name];
      } else {
        obj = obj[name] = {};
      }
    }
    if (obj === undefined || obj === null) {
      obj = {};
    }
    obj[parts.shift()] = value;
  }
  exports.setValueOnPath = setValueOnPath;
  var _symbolIterator = null;
  function getSymbolIterator() {
    if (isBlank(_symbolIterator)) {
      if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
        _symbolIterator = Symbol.iterator;
      } else {
        var keys = Object.getOwnPropertyNames(Map.prototype);
        for (var i = 0; i < keys.length; ++i) {
          var key = keys[i];
          if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
            _symbolIterator = key;
          }
        }
      }
    }
    return _symbolIterator;
  }
  exports.getSymbolIterator = getSymbolIterator;
  function evalExpression(sourceUrl, expr, declarations, vars) {
    var fnBody = declarations + "\nreturn " + expr + "\n//# sourceURL=" + sourceUrl;
    var fnArgNames = [];
    var fnArgValues = [];
    for (var argName in vars) {
      fnArgNames.push(argName);
      fnArgValues.push(vars[argName]);
    }
    return new (Function.bind.apply(Function, [void 0].concat(fnArgNames.concat(fnBody))))().apply(void 0, fnArgValues);
  }
  exports.evalExpression = evalExpression;
  function isPrimitive(obj) {
    return !isJsObject(obj);
  }
  exports.isPrimitive = isPrimitive;
  function hasConstructor(value, type) {
    return value.constructor === type;
  }
  exports.hasConstructor = hasConstructor;
  function bitWiseOr(values) {
    return values.reduce(function(a, b) {
      return a | b;
    });
  }
  exports.bitWiseOr = bitWiseOr;
  function bitWiseAnd(values) {
    return values.reduce(function(a, b) {
      return a & b;
    });
  }
  exports.bitWiseAnd = bitWiseAnd;
  function escape(s) {
    return _global.encodeURI(s);
  }
  exports.escape = escape;
  return module.exports;
});

$__System.registerDynamic("5d", ["65"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('65');
  var _DOM = null;
  function getDOM() {
    return _DOM;
  }
  exports.getDOM = getDOM;
  function setDOM(adapter) {
    _DOM = adapter;
  }
  exports.setDOM = setDOM;
  function setRootDomAdapter(adapter) {
    if (lang_1.isBlank(_DOM)) {
      _DOM = adapter;
    }
  }
  exports.setRootDomAdapter = setRootDomAdapter;
  var DomAdapter = (function() {
    function DomAdapter() {
      this.xhrType = null;
    }
    DomAdapter.prototype.getXHR = function() {
      return this.xhrType;
    };
    Object.defineProperty(DomAdapter.prototype, "attrToPropMap", {
      get: function() {
        return this._attrToPropMap;
      },
      set: function(value) {
        this._attrToPropMap = value;
      },
      enumerable: true,
      configurable: true
    });
    ;
    ;
    return DomAdapter;
  }());
  exports.DomAdapter = DomAdapter;
  return module.exports;
});

$__System.registerDynamic("5e", ["64", "65", "245", "5d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var collection_1 = $__require('64');
  var lang_1 = $__require('65');
  var generic_browser_adapter_1 = $__require('245');
  var dom_adapter_1 = $__require('5d');
  var _attrToPropMap = {
    'class': 'className',
    'innerHtml': 'innerHTML',
    'readonly': 'readOnly',
    'tabindex': 'tabIndex'
  };
  var DOM_KEY_LOCATION_NUMPAD = 3;
  var _keyMap = {
    '\b': 'Backspace',
    '\t': 'Tab',
    '\x7F': 'Delete',
    '\x1B': 'Escape',
    'Del': 'Delete',
    'Esc': 'Escape',
    'Left': 'ArrowLeft',
    'Right': 'ArrowRight',
    'Up': 'ArrowUp',
    'Down': 'ArrowDown',
    'Menu': 'ContextMenu',
    'Scroll': 'ScrollLock',
    'Win': 'OS'
  };
  var _chromeNumKeyPadMap = {
    'A': '1',
    'B': '2',
    'C': '3',
    'D': '4',
    'E': '5',
    'F': '6',
    'G': '7',
    'H': '8',
    'I': '9',
    'J': '*',
    'K': '+',
    'M': '-',
    'N': '.',
    'O': '/',
    '\x60': '0',
    '\x90': 'NumLock'
  };
  var BrowserDomAdapter = (function(_super) {
    __extends(BrowserDomAdapter, _super);
    function BrowserDomAdapter() {
      _super.apply(this, arguments);
    }
    BrowserDomAdapter.prototype.parse = function(templateHtml) {
      throw new Error("parse not implemented");
    };
    BrowserDomAdapter.makeCurrent = function() {
      dom_adapter_1.setRootDomAdapter(new BrowserDomAdapter());
    };
    BrowserDomAdapter.prototype.hasProperty = function(element, name) {
      return name in element;
    };
    BrowserDomAdapter.prototype.setProperty = function(el, name, value) {
      el[name] = value;
    };
    BrowserDomAdapter.prototype.getProperty = function(el, name) {
      return el[name];
    };
    BrowserDomAdapter.prototype.invoke = function(el, methodName, args) {
      el[methodName].apply(el, args);
    };
    BrowserDomAdapter.prototype.logError = function(error) {
      if (window.console.error) {
        window.console.error(error);
      } else {
        window.console.log(error);
      }
    };
    BrowserDomAdapter.prototype.log = function(error) {
      window.console.log(error);
    };
    BrowserDomAdapter.prototype.logGroup = function(error) {
      if (window.console.group) {
        window.console.group(error);
        this.logError(error);
      } else {
        window.console.log(error);
      }
    };
    BrowserDomAdapter.prototype.logGroupEnd = function() {
      if (window.console.groupEnd) {
        window.console.groupEnd();
      }
    };
    Object.defineProperty(BrowserDomAdapter.prototype, "attrToPropMap", {
      get: function() {
        return _attrToPropMap;
      },
      enumerable: true,
      configurable: true
    });
    BrowserDomAdapter.prototype.query = function(selector) {
      return document.querySelector(selector);
    };
    BrowserDomAdapter.prototype.querySelector = function(el, selector) {
      return el.querySelector(selector);
    };
    BrowserDomAdapter.prototype.querySelectorAll = function(el, selector) {
      return el.querySelectorAll(selector);
    };
    BrowserDomAdapter.prototype.on = function(el, evt, listener) {
      el.addEventListener(evt, listener, false);
    };
    BrowserDomAdapter.prototype.onAndCancel = function(el, evt, listener) {
      el.addEventListener(evt, listener, false);
      return function() {
        el.removeEventListener(evt, listener, false);
      };
    };
    BrowserDomAdapter.prototype.dispatchEvent = function(el, evt) {
      el.dispatchEvent(evt);
    };
    BrowserDomAdapter.prototype.createMouseEvent = function(eventType) {
      var evt = document.createEvent('MouseEvent');
      evt.initEvent(eventType, true, true);
      return evt;
    };
    BrowserDomAdapter.prototype.createEvent = function(eventType) {
      var evt = document.createEvent('Event');
      evt.initEvent(eventType, true, true);
      return evt;
    };
    BrowserDomAdapter.prototype.preventDefault = function(evt) {
      evt.preventDefault();
      evt.returnValue = false;
    };
    BrowserDomAdapter.prototype.isPrevented = function(evt) {
      return evt.defaultPrevented || lang_1.isPresent(evt.returnValue) && !evt.returnValue;
    };
    BrowserDomAdapter.prototype.getInnerHTML = function(el) {
      return el.innerHTML;
    };
    BrowserDomAdapter.prototype.getOuterHTML = function(el) {
      return el.outerHTML;
    };
    BrowserDomAdapter.prototype.nodeName = function(node) {
      return node.nodeName;
    };
    BrowserDomAdapter.prototype.nodeValue = function(node) {
      return node.nodeValue;
    };
    BrowserDomAdapter.prototype.type = function(node) {
      return node.type;
    };
    BrowserDomAdapter.prototype.content = function(node) {
      if (this.hasProperty(node, "content")) {
        return node.content;
      } else {
        return node;
      }
    };
    BrowserDomAdapter.prototype.firstChild = function(el) {
      return el.firstChild;
    };
    BrowserDomAdapter.prototype.nextSibling = function(el) {
      return el.nextSibling;
    };
    BrowserDomAdapter.prototype.parentElement = function(el) {
      return el.parentNode;
    };
    BrowserDomAdapter.prototype.childNodes = function(el) {
      return el.childNodes;
    };
    BrowserDomAdapter.prototype.childNodesAsList = function(el) {
      var childNodes = el.childNodes;
      var res = collection_1.ListWrapper.createFixedSize(childNodes.length);
      for (var i = 0; i < childNodes.length; i++) {
        res[i] = childNodes[i];
      }
      return res;
    };
    BrowserDomAdapter.prototype.clearNodes = function(el) {
      while (el.firstChild) {
        el.removeChild(el.firstChild);
      }
    };
    BrowserDomAdapter.prototype.appendChild = function(el, node) {
      el.appendChild(node);
    };
    BrowserDomAdapter.prototype.removeChild = function(el, node) {
      el.removeChild(node);
    };
    BrowserDomAdapter.prototype.replaceChild = function(el, newChild, oldChild) {
      el.replaceChild(newChild, oldChild);
    };
    BrowserDomAdapter.prototype.remove = function(node) {
      if (node.parentNode) {
        node.parentNode.removeChild(node);
      }
      return node;
    };
    BrowserDomAdapter.prototype.insertBefore = function(el, node) {
      el.parentNode.insertBefore(node, el);
    };
    BrowserDomAdapter.prototype.insertAllBefore = function(el, nodes) {
      nodes.forEach(function(n) {
        return el.parentNode.insertBefore(n, el);
      });
    };
    BrowserDomAdapter.prototype.insertAfter = function(el, node) {
      el.parentNode.insertBefore(node, el.nextSibling);
    };
    BrowserDomAdapter.prototype.setInnerHTML = function(el, value) {
      el.innerHTML = value;
    };
    BrowserDomAdapter.prototype.getText = function(el) {
      return el.textContent;
    };
    BrowserDomAdapter.prototype.setText = function(el, value) {
      el.textContent = value;
    };
    BrowserDomAdapter.prototype.getValue = function(el) {
      return el.value;
    };
    BrowserDomAdapter.prototype.setValue = function(el, value) {
      el.value = value;
    };
    BrowserDomAdapter.prototype.getChecked = function(el) {
      return el.checked;
    };
    BrowserDomAdapter.prototype.setChecked = function(el, value) {
      el.checked = value;
    };
    BrowserDomAdapter.prototype.createComment = function(text) {
      return document.createComment(text);
    };
    BrowserDomAdapter.prototype.createTemplate = function(html) {
      var t = document.createElement('template');
      t.innerHTML = html;
      return t;
    };
    BrowserDomAdapter.prototype.createElement = function(tagName, doc) {
      if (doc === void 0) {
        doc = document;
      }
      return doc.createElement(tagName);
    };
    BrowserDomAdapter.prototype.createElementNS = function(ns, tagName, doc) {
      if (doc === void 0) {
        doc = document;
      }
      return doc.createElementNS(ns, tagName);
    };
    BrowserDomAdapter.prototype.createTextNode = function(text, doc) {
      if (doc === void 0) {
        doc = document;
      }
      return doc.createTextNode(text);
    };
    BrowserDomAdapter.prototype.createScriptTag = function(attrName, attrValue, doc) {
      if (doc === void 0) {
        doc = document;
      }
      var el = doc.createElement('SCRIPT');
      el.setAttribute(attrName, attrValue);
      return el;
    };
    BrowserDomAdapter.prototype.createStyleElement = function(css, doc) {
      if (doc === void 0) {
        doc = document;
      }
      var style = doc.createElement('style');
      this.appendChild(style, this.createTextNode(css));
      return style;
    };
    BrowserDomAdapter.prototype.createShadowRoot = function(el) {
      return el.createShadowRoot();
    };
    BrowserDomAdapter.prototype.getShadowRoot = function(el) {
      return el.shadowRoot;
    };
    BrowserDomAdapter.prototype.getHost = function(el) {
      return el.host;
    };
    BrowserDomAdapter.prototype.clone = function(node) {
      return node.cloneNode(true);
    };
    BrowserDomAdapter.prototype.getElementsByClassName = function(element, name) {
      return element.getElementsByClassName(name);
    };
    BrowserDomAdapter.prototype.getElementsByTagName = function(element, name) {
      return element.getElementsByTagName(name);
    };
    BrowserDomAdapter.prototype.classList = function(element) {
      return Array.prototype.slice.call(element.classList, 0);
    };
    BrowserDomAdapter.prototype.addClass = function(element, className) {
      element.classList.add(className);
    };
    BrowserDomAdapter.prototype.removeClass = function(element, className) {
      element.classList.remove(className);
    };
    BrowserDomAdapter.prototype.hasClass = function(element, className) {
      return element.classList.contains(className);
    };
    BrowserDomAdapter.prototype.setStyle = function(element, styleName, styleValue) {
      element.style[styleName] = styleValue;
    };
    BrowserDomAdapter.prototype.removeStyle = function(element, stylename) {
      element.style[stylename] = null;
    };
    BrowserDomAdapter.prototype.getStyle = function(element, stylename) {
      return element.style[stylename];
    };
    BrowserDomAdapter.prototype.hasStyle = function(element, styleName, styleValue) {
      if (styleValue === void 0) {
        styleValue = null;
      }
      var value = this.getStyle(element, styleName) || '';
      return styleValue ? value == styleValue : value.length > 0;
    };
    BrowserDomAdapter.prototype.tagName = function(element) {
      return element.tagName;
    };
    BrowserDomAdapter.prototype.attributeMap = function(element) {
      var res = new Map();
      var elAttrs = element.attributes;
      for (var i = 0; i < elAttrs.length; i++) {
        var attrib = elAttrs[i];
        res.set(attrib.name, attrib.value);
      }
      return res;
    };
    BrowserDomAdapter.prototype.hasAttribute = function(element, attribute) {
      return element.hasAttribute(attribute);
    };
    BrowserDomAdapter.prototype.hasAttributeNS = function(element, ns, attribute) {
      return element.hasAttributeNS(ns, attribute);
    };
    BrowserDomAdapter.prototype.getAttribute = function(element, attribute) {
      return element.getAttribute(attribute);
    };
    BrowserDomAdapter.prototype.getAttributeNS = function(element, ns, name) {
      return element.getAttributeNS(ns, name);
    };
    BrowserDomAdapter.prototype.setAttribute = function(element, name, value) {
      element.setAttribute(name, value);
    };
    BrowserDomAdapter.prototype.setAttributeNS = function(element, ns, name, value) {
      element.setAttributeNS(ns, name, value);
    };
    BrowserDomAdapter.prototype.removeAttribute = function(element, attribute) {
      element.removeAttribute(attribute);
    };
    BrowserDomAdapter.prototype.removeAttributeNS = function(element, ns, name) {
      element.removeAttributeNS(ns, name);
    };
    BrowserDomAdapter.prototype.templateAwareRoot = function(el) {
      return this.isTemplateElement(el) ? this.content(el) : el;
    };
    BrowserDomAdapter.prototype.createHtmlDocument = function() {
      return document.implementation.createHTMLDocument('fakeTitle');
    };
    BrowserDomAdapter.prototype.defaultDoc = function() {
      return document;
    };
    BrowserDomAdapter.prototype.getBoundingClientRect = function(el) {
      try {
        return el.getBoundingClientRect();
      } catch (e) {
        return {
          top: 0,
          bottom: 0,
          left: 0,
          right: 0,
          width: 0,
          height: 0
        };
      }
    };
    BrowserDomAdapter.prototype.getTitle = function() {
      return document.title;
    };
    BrowserDomAdapter.prototype.setTitle = function(newTitle) {
      document.title = newTitle || '';
    };
    BrowserDomAdapter.prototype.elementMatches = function(n, selector) {
      var matches = false;
      if (n instanceof HTMLElement) {
        if (n.matches) {
          matches = n.matches(selector);
        } else if (n.msMatchesSelector) {
          matches = n.msMatchesSelector(selector);
        } else if (n.webkitMatchesSelector) {
          matches = n.webkitMatchesSelector(selector);
        }
      }
      return matches;
    };
    BrowserDomAdapter.prototype.isTemplateElement = function(el) {
      return el instanceof HTMLElement && el.nodeName == "TEMPLATE";
    };
    BrowserDomAdapter.prototype.isTextNode = function(node) {
      return node.nodeType === Node.TEXT_NODE;
    };
    BrowserDomAdapter.prototype.isCommentNode = function(node) {
      return node.nodeType === Node.COMMENT_NODE;
    };
    BrowserDomAdapter.prototype.isElementNode = function(node) {
      return node.nodeType === Node.ELEMENT_NODE;
    };
    BrowserDomAdapter.prototype.hasShadowRoot = function(node) {
      return node instanceof HTMLElement && lang_1.isPresent(node.shadowRoot);
    };
    BrowserDomAdapter.prototype.isShadowRoot = function(node) {
      return node instanceof DocumentFragment;
    };
    BrowserDomAdapter.prototype.importIntoDoc = function(node) {
      var toImport = node;
      if (this.isTemplateElement(node)) {
        toImport = this.content(node);
      }
      return document.importNode(toImport, true);
    };
    BrowserDomAdapter.prototype.adoptNode = function(node) {
      return document.adoptNode(node);
    };
    BrowserDomAdapter.prototype.getHref = function(el) {
      return el.href;
    };
    BrowserDomAdapter.prototype.getEventKey = function(event) {
      var key = event.key;
      if (lang_1.isBlank(key)) {
        key = event.keyIdentifier;
        if (lang_1.isBlank(key)) {
          return 'Unidentified';
        }
        if (key.startsWith('U+')) {
          key = String.fromCharCode(parseInt(key.substring(2), 16));
          if (event.location === DOM_KEY_LOCATION_NUMPAD && _chromeNumKeyPadMap.hasOwnProperty(key)) {
            key = _chromeNumKeyPadMap[key];
          }
        }
      }
      if (_keyMap.hasOwnProperty(key)) {
        key = _keyMap[key];
      }
      return key;
    };
    BrowserDomAdapter.prototype.getGlobalEventTarget = function(target) {
      if (target == "window") {
        return window;
      } else if (target == "document") {
        return document;
      } else if (target == "body") {
        return document.body;
      }
    };
    BrowserDomAdapter.prototype.getHistory = function() {
      return window.history;
    };
    BrowserDomAdapter.prototype.getLocation = function() {
      return window.location;
    };
    BrowserDomAdapter.prototype.getBaseHref = function() {
      var href = getBaseElementHref();
      if (lang_1.isBlank(href)) {
        return null;
      }
      return relativePath(href);
    };
    BrowserDomAdapter.prototype.resetBaseElement = function() {
      baseElement = null;
    };
    BrowserDomAdapter.prototype.getUserAgent = function() {
      return window.navigator.userAgent;
    };
    BrowserDomAdapter.prototype.setData = function(element, name, value) {
      this.setAttribute(element, 'data-' + name, value);
    };
    BrowserDomAdapter.prototype.getData = function(element, name) {
      return this.getAttribute(element, 'data-' + name);
    };
    BrowserDomAdapter.prototype.getComputedStyle = function(element) {
      return getComputedStyle(element);
    };
    BrowserDomAdapter.prototype.setGlobalVar = function(path, value) {
      lang_1.setValueOnPath(lang_1.global, path, value);
    };
    BrowserDomAdapter.prototype.requestAnimationFrame = function(callback) {
      return window.requestAnimationFrame(callback);
    };
    BrowserDomAdapter.prototype.cancelAnimationFrame = function(id) {
      window.cancelAnimationFrame(id);
    };
    BrowserDomAdapter.prototype.performanceNow = function() {
      if (lang_1.isPresent(window.performance) && lang_1.isPresent(window.performance.now)) {
        return window.performance.now();
      } else {
        return lang_1.DateWrapper.toMillis(lang_1.DateWrapper.now());
      }
    };
    return BrowserDomAdapter;
  }(generic_browser_adapter_1.GenericBrowserDomAdapter));
  exports.BrowserDomAdapter = BrowserDomAdapter;
  var baseElement = null;
  function getBaseElementHref() {
    if (lang_1.isBlank(baseElement)) {
      baseElement = document.querySelector('base');
      if (lang_1.isBlank(baseElement)) {
        return null;
      }
    }
    return baseElement.getAttribute('href');
  }
  var urlParsingNode = null;
  function relativePath(url) {
    if (lang_1.isBlank(urlParsingNode)) {
      urlParsingNode = document.createElement("a");
    }
    urlParsingNode.setAttribute('href', url);
    return (urlParsingNode.pathname.charAt(0) === '/') ? urlParsingNode.pathname : '/' + urlParsingNode.pathname;
  }
  return module.exports;
});

$__System.registerDynamic("8a", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports["default"] = function(instance, Constructor) {
    if (!(instance instanceof Constructor)) {
      throw new TypeError("Cannot call a class as a function");
    }
  };
  exports.__esModule = true;
  return module.exports;
});

$__System.registerDynamic("246", ["9c", "247", "248"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var metadata_1 = $__require('247');
  var forward_ref_1 = $__require('248');
  var AttributeMetadata = (function(_super) {
    __extends(AttributeMetadata, _super);
    function AttributeMetadata(attributeName) {
      _super.call(this);
      this.attributeName = attributeName;
    }
    Object.defineProperty(AttributeMetadata.prototype, "token", {
      get: function() {
        return this;
      },
      enumerable: true,
      configurable: true
    });
    AttributeMetadata.prototype.toString = function() {
      return "@Attribute(" + lang_1.stringify(this.attributeName) + ")";
    };
    return AttributeMetadata;
  }(metadata_1.DependencyMetadata));
  exports.AttributeMetadata = AttributeMetadata;
  var QueryMetadata = (function(_super) {
    __extends(QueryMetadata, _super);
    function QueryMetadata(_selector, _a) {
      var _b = _a === void 0 ? {} : _a,
          _c = _b.descendants,
          descendants = _c === void 0 ? false : _c,
          _d = _b.first,
          first = _d === void 0 ? false : _d,
          _e = _b.read,
          read = _e === void 0 ? null : _e;
      _super.call(this);
      this._selector = _selector;
      this.descendants = descendants;
      this.first = first;
      this.read = read;
    }
    Object.defineProperty(QueryMetadata.prototype, "isViewQuery", {
      get: function() {
        return false;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryMetadata.prototype, "selector", {
      get: function() {
        return forward_ref_1.resolveForwardRef(this._selector);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryMetadata.prototype, "isVarBindingQuery", {
      get: function() {
        return lang_1.isString(this.selector);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryMetadata.prototype, "varBindings", {
      get: function() {
        return this.selector.split(',');
      },
      enumerable: true,
      configurable: true
    });
    QueryMetadata.prototype.toString = function() {
      return "@Query(" + lang_1.stringify(this.selector) + ")";
    };
    return QueryMetadata;
  }(metadata_1.DependencyMetadata));
  exports.QueryMetadata = QueryMetadata;
  var ContentChildrenMetadata = (function(_super) {
    __extends(ContentChildrenMetadata, _super);
    function ContentChildrenMetadata(_selector, _a) {
      var _b = _a === void 0 ? {} : _a,
          _c = _b.descendants,
          descendants = _c === void 0 ? false : _c,
          _d = _b.read,
          read = _d === void 0 ? null : _d;
      _super.call(this, _selector, {
        descendants: descendants,
        read: read
      });
    }
    return ContentChildrenMetadata;
  }(QueryMetadata));
  exports.ContentChildrenMetadata = ContentChildrenMetadata;
  var ContentChildMetadata = (function(_super) {
    __extends(ContentChildMetadata, _super);
    function ContentChildMetadata(_selector, _a) {
      var _b = (_a === void 0 ? {} : _a).read,
          read = _b === void 0 ? null : _b;
      _super.call(this, _selector, {
        descendants: true,
        first: true,
        read: read
      });
    }
    return ContentChildMetadata;
  }(QueryMetadata));
  exports.ContentChildMetadata = ContentChildMetadata;
  var ViewQueryMetadata = (function(_super) {
    __extends(ViewQueryMetadata, _super);
    function ViewQueryMetadata(_selector, _a) {
      var _b = _a === void 0 ? {} : _a,
          _c = _b.descendants,
          descendants = _c === void 0 ? false : _c,
          _d = _b.first,
          first = _d === void 0 ? false : _d,
          _e = _b.read,
          read = _e === void 0 ? null : _e;
      _super.call(this, _selector, {
        descendants: descendants,
        first: first,
        read: read
      });
    }
    Object.defineProperty(ViewQueryMetadata.prototype, "isViewQuery", {
      get: function() {
        return true;
      },
      enumerable: true,
      configurable: true
    });
    ViewQueryMetadata.prototype.toString = function() {
      return "@ViewQuery(" + lang_1.stringify(this.selector) + ")";
    };
    return ViewQueryMetadata;
  }(QueryMetadata));
  exports.ViewQueryMetadata = ViewQueryMetadata;
  var ViewChildrenMetadata = (function(_super) {
    __extends(ViewChildrenMetadata, _super);
    function ViewChildrenMetadata(_selector, _a) {
      var _b = (_a === void 0 ? {} : _a).read,
          read = _b === void 0 ? null : _b;
      _super.call(this, _selector, {
        descendants: true,
        read: read
      });
    }
    return ViewChildrenMetadata;
  }(ViewQueryMetadata));
  exports.ViewChildrenMetadata = ViewChildrenMetadata;
  var ViewChildMetadata = (function(_super) {
    __extends(ViewChildMetadata, _super);
    function ViewChildMetadata(_selector, _a) {
      var _b = (_a === void 0 ? {} : _a).read,
          read = _b === void 0 ? null : _b;
      _super.call(this, _selector, {
        descendants: true,
        first: true,
        read: read
      });
    }
    return ViewChildMetadata;
  }(ViewQueryMetadata));
  exports.ViewChildMetadata = ViewChildMetadata;
  return module.exports;
});

$__System.registerDynamic("249", ["9c", "247", "24a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var metadata_1 = $__require('247');
  var constants_1 = $__require('24a');
  var DirectiveMetadata = (function(_super) {
    __extends(DirectiveMetadata, _super);
    function DirectiveMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          selector = _b.selector,
          inputs = _b.inputs,
          outputs = _b.outputs,
          properties = _b.properties,
          events = _b.events,
          host = _b.host,
          bindings = _b.bindings,
          providers = _b.providers,
          exportAs = _b.exportAs,
          queries = _b.queries;
      _super.call(this);
      this.selector = selector;
      this._inputs = inputs;
      this._properties = properties;
      this._outputs = outputs;
      this._events = events;
      this.host = host;
      this.exportAs = exportAs;
      this.queries = queries;
      this._providers = providers;
      this._bindings = bindings;
    }
    Object.defineProperty(DirectiveMetadata.prototype, "inputs", {
      get: function() {
        return lang_1.isPresent(this._properties) && this._properties.length > 0 ? this._properties : this._inputs;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DirectiveMetadata.prototype, "properties", {
      get: function() {
        return this.inputs;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DirectiveMetadata.prototype, "outputs", {
      get: function() {
        return lang_1.isPresent(this._events) && this._events.length > 0 ? this._events : this._outputs;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DirectiveMetadata.prototype, "events", {
      get: function() {
        return this.outputs;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DirectiveMetadata.prototype, "providers", {
      get: function() {
        return lang_1.isPresent(this._bindings) && this._bindings.length > 0 ? this._bindings : this._providers;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DirectiveMetadata.prototype, "bindings", {
      get: function() {
        return this.providers;
      },
      enumerable: true,
      configurable: true
    });
    return DirectiveMetadata;
  }(metadata_1.InjectableMetadata));
  exports.DirectiveMetadata = DirectiveMetadata;
  var ComponentMetadata = (function(_super) {
    __extends(ComponentMetadata, _super);
    function ComponentMetadata(_a) {
      var _b = _a === void 0 ? {} : _a,
          selector = _b.selector,
          inputs = _b.inputs,
          outputs = _b.outputs,
          properties = _b.properties,
          events = _b.events,
          host = _b.host,
          exportAs = _b.exportAs,
          moduleId = _b.moduleId,
          bindings = _b.bindings,
          providers = _b.providers,
          viewBindings = _b.viewBindings,
          viewProviders = _b.viewProviders,
          _c = _b.changeDetection,
          changeDetection = _c === void 0 ? constants_1.ChangeDetectionStrategy.Default : _c,
          queries = _b.queries,
          templateUrl = _b.templateUrl,
          template = _b.template,
          styleUrls = _b.styleUrls,
          styles = _b.styles,
          directives = _b.directives,
          pipes = _b.pipes,
          encapsulation = _b.encapsulation;
      _super.call(this, {
        selector: selector,
        inputs: inputs,
        outputs: outputs,
        properties: properties,
        events: events,
        host: host,
        exportAs: exportAs,
        bindings: bindings,
        providers: providers,
        queries: queries
      });
      this.changeDetection = changeDetection;
      this._viewProviders = viewProviders;
      this._viewBindings = viewBindings;
      this.templateUrl = templateUrl;
      this.template = template;
      this.styleUrls = styleUrls;
      this.styles = styles;
      this.directives = directives;
      this.pipes = pipes;
      this.encapsulation = encapsulation;
      this.moduleId = moduleId;
    }
    Object.defineProperty(ComponentMetadata.prototype, "viewProviders", {
      get: function() {
        return lang_1.isPresent(this._viewBindings) && this._viewBindings.length > 0 ? this._viewBindings : this._viewProviders;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentMetadata.prototype, "viewBindings", {
      get: function() {
        return this.viewProviders;
      },
      enumerable: true,
      configurable: true
    });
    return ComponentMetadata;
  }(DirectiveMetadata));
  exports.ComponentMetadata = ComponentMetadata;
  var PipeMetadata = (function(_super) {
    __extends(PipeMetadata, _super);
    function PipeMetadata(_a) {
      var name = _a.name,
          pure = _a.pure;
      _super.call(this);
      this.name = name;
      this._pure = pure;
    }
    Object.defineProperty(PipeMetadata.prototype, "pure", {
      get: function() {
        return lang_1.isPresent(this._pure) ? this._pure : true;
      },
      enumerable: true,
      configurable: true
    });
    return PipeMetadata;
  }(metadata_1.InjectableMetadata));
  exports.PipeMetadata = PipeMetadata;
  var InputMetadata = (function() {
    function InputMetadata(bindingPropertyName) {
      this.bindingPropertyName = bindingPropertyName;
    }
    return InputMetadata;
  }());
  exports.InputMetadata = InputMetadata;
  var OutputMetadata = (function() {
    function OutputMetadata(bindingPropertyName) {
      this.bindingPropertyName = bindingPropertyName;
    }
    return OutputMetadata;
  }());
  exports.OutputMetadata = OutputMetadata;
  var HostBindingMetadata = (function() {
    function HostBindingMetadata(hostPropertyName) {
      this.hostPropertyName = hostPropertyName;
    }
    return HostBindingMetadata;
  }());
  exports.HostBindingMetadata = HostBindingMetadata;
  var HostListenerMetadata = (function() {
    function HostListenerMetadata(eventName, args) {
      this.eventName = eventName;
      this.args = args;
    }
    return HostListenerMetadata;
  }());
  exports.HostListenerMetadata = HostListenerMetadata;
  return module.exports;
});

$__System.registerDynamic("24b", ["246", "249", "24c", "24d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var di_1 = $__require('246');
  exports.QueryMetadata = di_1.QueryMetadata;
  exports.ContentChildrenMetadata = di_1.ContentChildrenMetadata;
  exports.ContentChildMetadata = di_1.ContentChildMetadata;
  exports.ViewChildrenMetadata = di_1.ViewChildrenMetadata;
  exports.ViewQueryMetadata = di_1.ViewQueryMetadata;
  exports.ViewChildMetadata = di_1.ViewChildMetadata;
  exports.AttributeMetadata = di_1.AttributeMetadata;
  var directives_1 = $__require('249');
  exports.ComponentMetadata = directives_1.ComponentMetadata;
  exports.DirectiveMetadata = directives_1.DirectiveMetadata;
  exports.PipeMetadata = directives_1.PipeMetadata;
  exports.InputMetadata = directives_1.InputMetadata;
  exports.OutputMetadata = directives_1.OutputMetadata;
  exports.HostBindingMetadata = directives_1.HostBindingMetadata;
  exports.HostListenerMetadata = directives_1.HostListenerMetadata;
  var view_1 = $__require('24c');
  exports.ViewMetadata = view_1.ViewMetadata;
  exports.ViewEncapsulation = view_1.ViewEncapsulation;
  var di_2 = $__require('246');
  var directives_2 = $__require('249');
  var view_2 = $__require('24c');
  var decorators_1 = $__require('24d');
  exports.Component = decorators_1.makeDecorator(directives_2.ComponentMetadata, function(fn) {
    return fn.View = View;
  });
  exports.Directive = decorators_1.makeDecorator(directives_2.DirectiveMetadata);
  var View = decorators_1.makeDecorator(view_2.ViewMetadata, function(fn) {
    return fn.View = View;
  });
  exports.Attribute = decorators_1.makeParamDecorator(di_2.AttributeMetadata);
  exports.Query = decorators_1.makeParamDecorator(di_2.QueryMetadata);
  exports.ContentChildren = decorators_1.makePropDecorator(di_2.ContentChildrenMetadata);
  exports.ContentChild = decorators_1.makePropDecorator(di_2.ContentChildMetadata);
  exports.ViewChildren = decorators_1.makePropDecorator(di_2.ViewChildrenMetadata);
  exports.ViewChild = decorators_1.makePropDecorator(di_2.ViewChildMetadata);
  exports.ViewQuery = decorators_1.makeParamDecorator(di_2.ViewQueryMetadata);
  exports.Pipe = decorators_1.makeDecorator(directives_2.PipeMetadata);
  exports.Input = decorators_1.makePropDecorator(directives_2.InputMetadata);
  exports.Output = decorators_1.makePropDecorator(directives_2.OutputMetadata);
  exports.HostBinding = decorators_1.makePropDecorator(directives_2.HostBindingMetadata);
  exports.HostListener = decorators_1.makePropDecorator(directives_2.HostListenerMetadata);
  return module.exports;
});

$__System.registerDynamic("24e", ["24d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var decorators_1 = $__require('24d');
  exports.Class = decorators_1.Class;
  return module.exports;
});

$__System.registerDynamic("24f", ["250"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ng_zone_1 = $__require('250');
  exports.NgZone = ng_zone_1.NgZone;
  exports.NgZoneError = ng_zone_1.NgZoneError;
  return module.exports;
});

$__System.registerDynamic("251", ["252"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var api_1 = $__require('252');
  exports.RootRenderer = api_1.RootRenderer;
  exports.Renderer = api_1.Renderer;
  exports.RenderComponentType = api_1.RenderComponentType;
  return module.exports;
});

$__System.registerDynamic("253", ["254", "9c", "255"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('254');
  var lang_1 = $__require('9c');
  var async_1 = $__require('255');
  var QueryList = (function() {
    function QueryList() {
      this._dirty = true;
      this._results = [];
      this._emitter = new async_1.EventEmitter();
    }
    Object.defineProperty(QueryList.prototype, "changes", {
      get: function() {
        return this._emitter;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryList.prototype, "length", {
      get: function() {
        return this._results.length;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryList.prototype, "first", {
      get: function() {
        return collection_1.ListWrapper.first(this._results);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(QueryList.prototype, "last", {
      get: function() {
        return collection_1.ListWrapper.last(this._results);
      },
      enumerable: true,
      configurable: true
    });
    QueryList.prototype.map = function(fn) {
      return this._results.map(fn);
    };
    QueryList.prototype.filter = function(fn) {
      return this._results.filter(fn);
    };
    QueryList.prototype.reduce = function(fn, init) {
      return this._results.reduce(fn, init);
    };
    QueryList.prototype.forEach = function(fn) {
      this._results.forEach(fn);
    };
    QueryList.prototype.toArray = function() {
      return collection_1.ListWrapper.clone(this._results);
    };
    QueryList.prototype[lang_1.getSymbolIterator()] = function() {
      return this._results[lang_1.getSymbolIterator()]();
    };
    QueryList.prototype.toString = function() {
      return this._results.toString();
    };
    QueryList.prototype.reset = function(res) {
      this._results = collection_1.ListWrapper.flatten(res);
      this._dirty = false;
    };
    QueryList.prototype.notifyOnChanges = function() {
      this._emitter.emit(this);
    };
    QueryList.prototype.setDirty = function() {
      this._dirty = true;
    };
    Object.defineProperty(QueryList.prototype, "dirty", {
      get: function() {
        return this._dirty;
      },
      enumerable: true,
      configurable: true
    });
    return QueryList;
  }());
  exports.QueryList = QueryList;
  return module.exports;
});

$__System.registerDynamic("256", ["257", "253", "258", "259", "25a", "25b", "25c", "25d", "25e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var component_resolver_1 = $__require('257');
  exports.ComponentResolver = component_resolver_1.ComponentResolver;
  var query_list_1 = $__require('253');
  exports.QueryList = query_list_1.QueryList;
  var dynamic_component_loader_1 = $__require('258');
  exports.DynamicComponentLoader = dynamic_component_loader_1.DynamicComponentLoader;
  var element_ref_1 = $__require('259');
  exports.ElementRef = element_ref_1.ElementRef;
  var template_ref_1 = $__require('25a');
  exports.TemplateRef = template_ref_1.TemplateRef;
  var view_ref_1 = $__require('25b');
  exports.EmbeddedViewRef = view_ref_1.EmbeddedViewRef;
  exports.ViewRef = view_ref_1.ViewRef;
  var view_container_ref_1 = $__require('25c');
  exports.ViewContainerRef = view_container_ref_1.ViewContainerRef;
  var component_factory_1 = $__require('25d');
  exports.ComponentRef = component_factory_1.ComponentRef;
  exports.ComponentFactory = component_factory_1.ComponentFactory;
  var exceptions_1 = $__require('25e');
  exports.ExpressionChangedAfterItHasBeenCheckedException = exceptions_1.ExpressionChangedAfterItHasBeenCheckedException;
  return module.exports;
});

$__System.registerDynamic("25f", ["260"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var change_detection_1 = $__require('260');
  exports.ChangeDetectionStrategy = change_detection_1.ChangeDetectionStrategy;
  exports.ChangeDetectorRef = change_detection_1.ChangeDetectorRef;
  exports.WrappedValue = change_detection_1.WrappedValue;
  exports.SimpleChange = change_detection_1.SimpleChange;
  exports.DefaultIterableDiffer = change_detection_1.DefaultIterableDiffer;
  exports.IterableDiffers = change_detection_1.IterableDiffers;
  exports.KeyValueDiffers = change_detection_1.KeyValueDiffers;
  exports.CollectionChangeRecord = change_detection_1.CollectionChangeRecord;
  exports.KeyValueChangeRecord = change_detection_1.KeyValueChangeRecord;
  return module.exports;
});

$__System.registerDynamic("261", ["262"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var di_1 = $__require('262');
  exports.PLATFORM_DIRECTIVES = new di_1.OpaqueToken("Platform Directives");
  exports.PLATFORM_PIPES = new di_1.OpaqueToken("Platform Pipes");
  return module.exports;
});

$__System.registerDynamic("263", ["264", "265", "266", "267", "268"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var console_1 = $__require('264');
  var reflection_1 = $__require('265');
  var reflector_reader_1 = $__require('266');
  var testability_1 = $__require('267');
  var application_ref_1 = $__require('268');
  function _reflector() {
    return reflection_1.reflector;
  }
  var __unused;
  exports.PLATFORM_COMMON_PROVIDERS = [application_ref_1.PLATFORM_CORE_PROVIDERS, {
    provide: reflection_1.Reflector,
    useFactory: _reflector,
    deps: []
  }, {
    provide: reflector_reader_1.ReflectorReader,
    useExisting: reflection_1.Reflector
  }, testability_1.TestabilityRegistry, console_1.Console];
  return module.exports;
});

$__System.registerDynamic("269", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var NgZoneError = (function() {
    function NgZoneError(error, stackTrace) {
      this.error = error;
      this.stackTrace = stackTrace;
    }
    return NgZoneError;
  }());
  exports.NgZoneError = NgZoneError;
  var NgZoneImpl = (function() {
    function NgZoneImpl(_a) {
      var _this = this;
      var trace = _a.trace,
          onEnter = _a.onEnter,
          onLeave = _a.onLeave,
          setMicrotask = _a.setMicrotask,
          setMacrotask = _a.setMacrotask,
          onError = _a.onError;
      this.onEnter = onEnter;
      this.onLeave = onLeave;
      this.setMicrotask = setMicrotask;
      this.setMacrotask = setMacrotask;
      this.onError = onError;
      if (Zone) {
        this.outer = this.inner = Zone.current;
        if (Zone['wtfZoneSpec']) {
          this.inner = this.inner.fork(Zone['wtfZoneSpec']);
        }
        if (trace && Zone['longStackTraceZoneSpec']) {
          this.inner = this.inner.fork(Zone['longStackTraceZoneSpec']);
        }
        this.inner = this.inner.fork({
          name: 'angular',
          properties: {'isAngularZone': true},
          onInvokeTask: function(delegate, current, target, task, applyThis, applyArgs) {
            try {
              _this.onEnter();
              return delegate.invokeTask(target, task, applyThis, applyArgs);
            } finally {
              _this.onLeave();
            }
          },
          onInvoke: function(delegate, current, target, callback, applyThis, applyArgs, source) {
            try {
              _this.onEnter();
              return delegate.invoke(target, callback, applyThis, applyArgs, source);
            } finally {
              _this.onLeave();
            }
          },
          onHasTask: function(delegate, current, target, hasTaskState) {
            delegate.hasTask(target, hasTaskState);
            if (current == target) {
              if (hasTaskState.change == 'microTask') {
                _this.setMicrotask(hasTaskState.microTask);
              } else if (hasTaskState.change == 'macroTask') {
                _this.setMacrotask(hasTaskState.macroTask);
              }
            }
          },
          onHandleError: function(delegate, current, target, error) {
            delegate.handleError(target, error);
            _this.onError(new NgZoneError(error, error.stack));
            return false;
          }
        });
      } else {
        throw new Error('Angular requires Zone.js polyfill.');
      }
    }
    NgZoneImpl.isInAngularZone = function() {
      return Zone.current.get('isAngularZone') === true;
    };
    NgZoneImpl.prototype.runInner = function(fn) {
      return this.inner.run(fn);
    };
    ;
    NgZoneImpl.prototype.runInnerGuarded = function(fn) {
      return this.inner.runGuarded(fn);
    };
    ;
    NgZoneImpl.prototype.runOuter = function(fn) {
      return this.outer.run(fn);
    };
    ;
    return NgZoneImpl;
  }());
  exports.NgZoneImpl = NgZoneImpl;
  return module.exports;
});

$__System.registerDynamic("250", ["255", "269", "a9", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var async_1 = $__require('255');
    var ng_zone_impl_1 = $__require('269');
    var exceptions_1 = $__require('a9');
    var ng_zone_impl_2 = $__require('269');
    exports.NgZoneError = ng_zone_impl_2.NgZoneError;
    var NgZone = (function() {
      function NgZone(_a) {
        var _this = this;
        var _b = _a.enableLongStackTrace,
            enableLongStackTrace = _b === void 0 ? false : _b;
        this._hasPendingMicrotasks = false;
        this._hasPendingMacrotasks = false;
        this._isStable = true;
        this._nesting = 0;
        this._onUnstable = new async_1.EventEmitter(false);
        this._onMicrotaskEmpty = new async_1.EventEmitter(false);
        this._onStable = new async_1.EventEmitter(false);
        this._onErrorEvents = new async_1.EventEmitter(false);
        this._zoneImpl = new ng_zone_impl_1.NgZoneImpl({
          trace: enableLongStackTrace,
          onEnter: function() {
            _this._nesting++;
            if (_this._isStable) {
              _this._isStable = false;
              _this._onUnstable.emit(null);
            }
          },
          onLeave: function() {
            _this._nesting--;
            _this._checkStable();
          },
          setMicrotask: function(hasMicrotasks) {
            _this._hasPendingMicrotasks = hasMicrotasks;
            _this._checkStable();
          },
          setMacrotask: function(hasMacrotasks) {
            _this._hasPendingMacrotasks = hasMacrotasks;
          },
          onError: function(error) {
            return _this._onErrorEvents.emit(error);
          }
        });
      }
      NgZone.isInAngularZone = function() {
        return ng_zone_impl_1.NgZoneImpl.isInAngularZone();
      };
      NgZone.assertInAngularZone = function() {
        if (!ng_zone_impl_1.NgZoneImpl.isInAngularZone()) {
          throw new exceptions_1.BaseException('Expected to be in Angular Zone, but it is not!');
        }
      };
      NgZone.assertNotInAngularZone = function() {
        if (ng_zone_impl_1.NgZoneImpl.isInAngularZone()) {
          throw new exceptions_1.BaseException('Expected to not be in Angular Zone, but it is!');
        }
      };
      NgZone.prototype._checkStable = function() {
        var _this = this;
        if (this._nesting == 0) {
          if (!this._hasPendingMicrotasks && !this._isStable) {
            try {
              this._nesting++;
              this._onMicrotaskEmpty.emit(null);
            } finally {
              this._nesting--;
              if (!this._hasPendingMicrotasks) {
                try {
                  this.runOutsideAngular(function() {
                    return _this._onStable.emit(null);
                  });
                } finally {
                  this._isStable = true;
                }
              }
            }
          }
        }
      };
      ;
      Object.defineProperty(NgZone.prototype, "onUnstable", {
        get: function() {
          return this._onUnstable;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(NgZone.prototype, "onMicrotaskEmpty", {
        get: function() {
          return this._onMicrotaskEmpty;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(NgZone.prototype, "onStable", {
        get: function() {
          return this._onStable;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(NgZone.prototype, "onError", {
        get: function() {
          return this._onErrorEvents;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(NgZone.prototype, "hasPendingMicrotasks", {
        get: function() {
          return this._hasPendingMicrotasks;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(NgZone.prototype, "hasPendingMacrotasks", {
        get: function() {
          return this._hasPendingMacrotasks;
        },
        enumerable: true,
        configurable: true
      });
      NgZone.prototype.run = function(fn) {
        return this._zoneImpl.runInner(fn);
      };
      NgZone.prototype.runGuarded = function(fn) {
        return this._zoneImpl.runInnerGuarded(fn);
      };
      NgZone.prototype.runOutsideAngular = function(fn) {
        return this._zoneImpl.runOuter(fn);
      };
      return NgZone;
    }());
    exports.NgZone = NgZone;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("267", ["254", "9c", "a9", "250", "255", "26a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('254');
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var ng_zone_1 = $__require('250');
  var async_1 = $__require('255');
  var decorators_1 = $__require('26a');
  var Testability = (function() {
    function Testability(_ngZone) {
      this._ngZone = _ngZone;
      this._pendingCount = 0;
      this._isZoneStable = true;
      this._didWork = false;
      this._callbacks = [];
      this._watchAngularEvents();
    }
    Testability.prototype._watchAngularEvents = function() {
      var _this = this;
      async_1.ObservableWrapper.subscribe(this._ngZone.onUnstable, function(_) {
        _this._didWork = true;
        _this._isZoneStable = false;
      });
      this._ngZone.runOutsideAngular(function() {
        async_1.ObservableWrapper.subscribe(_this._ngZone.onStable, function(_) {
          ng_zone_1.NgZone.assertNotInAngularZone();
          lang_1.scheduleMicroTask(function() {
            _this._isZoneStable = true;
            _this._runCallbacksIfReady();
          });
        });
      });
    };
    Testability.prototype.increasePendingRequestCount = function() {
      this._pendingCount += 1;
      this._didWork = true;
      return this._pendingCount;
    };
    Testability.prototype.decreasePendingRequestCount = function() {
      this._pendingCount -= 1;
      if (this._pendingCount < 0) {
        throw new exceptions_1.BaseException('pending async requests below zero');
      }
      this._runCallbacksIfReady();
      return this._pendingCount;
    };
    Testability.prototype.isStable = function() {
      return this._isZoneStable && this._pendingCount == 0 && !this._ngZone.hasPendingMacrotasks;
    };
    Testability.prototype._runCallbacksIfReady = function() {
      var _this = this;
      if (this.isStable()) {
        lang_1.scheduleMicroTask(function() {
          while (_this._callbacks.length !== 0) {
            (_this._callbacks.pop())(_this._didWork);
          }
          _this._didWork = false;
        });
      } else {
        this._didWork = true;
      }
    };
    Testability.prototype.whenStable = function(callback) {
      this._callbacks.push(callback);
      this._runCallbacksIfReady();
    };
    Testability.prototype.getPendingRequestCount = function() {
      return this._pendingCount;
    };
    Testability.prototype.findBindings = function(using, provider, exactMatch) {
      return [];
    };
    Testability.prototype.findProviders = function(using, provider, exactMatch) {
      return [];
    };
    Testability.decorators = [{type: decorators_1.Injectable}];
    Testability.ctorParameters = [{type: ng_zone_1.NgZone}];
    return Testability;
  }());
  exports.Testability = Testability;
  var TestabilityRegistry = (function() {
    function TestabilityRegistry() {
      this._applications = new collection_1.Map();
      _testabilityGetter.addToWindow(this);
    }
    TestabilityRegistry.prototype.registerApplication = function(token, testability) {
      this._applications.set(token, testability);
    };
    TestabilityRegistry.prototype.getTestability = function(elem) {
      return this._applications.get(elem);
    };
    TestabilityRegistry.prototype.getAllTestabilities = function() {
      return collection_1.MapWrapper.values(this._applications);
    };
    TestabilityRegistry.prototype.getAllRootElements = function() {
      return collection_1.MapWrapper.keys(this._applications);
    };
    TestabilityRegistry.prototype.findTestabilityInTree = function(elem, findInAncestors) {
      if (findInAncestors === void 0) {
        findInAncestors = true;
      }
      return _testabilityGetter.findTestabilityInTree(this, elem, findInAncestors);
    };
    TestabilityRegistry.decorators = [{type: decorators_1.Injectable}];
    TestabilityRegistry.ctorParameters = [];
    return TestabilityRegistry;
  }());
  exports.TestabilityRegistry = TestabilityRegistry;
  var _NoopGetTestability = (function() {
    function _NoopGetTestability() {}
    _NoopGetTestability.prototype.addToWindow = function(registry) {};
    _NoopGetTestability.prototype.findTestabilityInTree = function(registry, elem, findInAncestors) {
      return null;
    };
    return _NoopGetTestability;
  }());
  function setTestabilityGetter(getter) {
    _testabilityGetter = getter;
  }
  exports.setTestabilityGetter = setTestabilityGetter;
  var _testabilityGetter = new _NoopGetTestability();
  return module.exports;
});

$__System.registerDynamic("268", ["250", "9c", "262", "26b", "255", "254", "267", "257", "a9", "264", "26c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var ng_zone_1 = $__require('250');
  var lang_1 = $__require('9c');
  var di_1 = $__require('262');
  var application_tokens_1 = $__require('26b');
  var async_1 = $__require('255');
  var collection_1 = $__require('254');
  var testability_1 = $__require('267');
  var component_resolver_1 = $__require('257');
  var exceptions_1 = $__require('a9');
  var console_1 = $__require('264');
  var profile_1 = $__require('26c');
  function createNgZone() {
    return new ng_zone_1.NgZone({enableLongStackTrace: lang_1.assertionsEnabled()});
  }
  exports.createNgZone = createNgZone;
  var _platform;
  var _inPlatformCreate = false;
  function createPlatform(injector) {
    if (_inPlatformCreate) {
      throw new exceptions_1.BaseException('Already creating a platform...');
    }
    if (lang_1.isPresent(_platform) && !_platform.disposed) {
      throw new exceptions_1.BaseException("There can be only one platform. Destroy the previous one to create a new one.");
    }
    lang_1.lockMode();
    _inPlatformCreate = true;
    try {
      _platform = injector.get(PlatformRef);
    } finally {
      _inPlatformCreate = false;
    }
    return _platform;
  }
  exports.createPlatform = createPlatform;
  function assertPlatform(requiredToken) {
    var platform = getPlatform();
    if (lang_1.isBlank(platform)) {
      throw new exceptions_1.BaseException('Not platform exists!');
    }
    if (lang_1.isPresent(platform) && lang_1.isBlank(platform.injector.get(requiredToken, null))) {
      throw new exceptions_1.BaseException('A platform with a different configuration has been created. Please destroy it first.');
    }
    return platform;
  }
  exports.assertPlatform = assertPlatform;
  function disposePlatform() {
    if (lang_1.isPresent(_platform) && !_platform.disposed) {
      _platform.dispose();
    }
  }
  exports.disposePlatform = disposePlatform;
  function getPlatform() {
    return lang_1.isPresent(_platform) && !_platform.disposed ? _platform : null;
  }
  exports.getPlatform = getPlatform;
  function coreBootstrap(injector, componentFactory) {
    var appRef = injector.get(ApplicationRef);
    return appRef.bootstrap(componentFactory);
  }
  exports.coreBootstrap = coreBootstrap;
  function coreLoadAndBootstrap(injector, componentType) {
    var appRef = injector.get(ApplicationRef);
    return appRef.run(function() {
      var componentResolver = injector.get(component_resolver_1.ComponentResolver);
      return async_1.PromiseWrapper.all([componentResolver.resolveComponent(componentType), appRef.waitForAsyncInitializers()]).then(function(arr) {
        return appRef.bootstrap(arr[0]);
      });
    });
  }
  exports.coreLoadAndBootstrap = coreLoadAndBootstrap;
  var PlatformRef = (function() {
    function PlatformRef() {}
    Object.defineProperty(PlatformRef.prototype, "injector", {
      get: function() {
        throw exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(PlatformRef.prototype, "disposed", {
      get: function() {
        throw exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return PlatformRef;
  }());
  exports.PlatformRef = PlatformRef;
  var PlatformRef_ = (function(_super) {
    __extends(PlatformRef_, _super);
    function PlatformRef_(_injector) {
      _super.call(this);
      this._injector = _injector;
      this._applications = [];
      this._disposeListeners = [];
      this._disposed = false;
      if (!_inPlatformCreate) {
        throw new exceptions_1.BaseException('Platforms have to be created via `createPlatform`!');
      }
      var inits = _injector.get(application_tokens_1.PLATFORM_INITIALIZER, null);
      if (lang_1.isPresent(inits))
        inits.forEach(function(init) {
          return init();
        });
    }
    PlatformRef_.prototype.registerDisposeListener = function(dispose) {
      this._disposeListeners.push(dispose);
    };
    Object.defineProperty(PlatformRef_.prototype, "injector", {
      get: function() {
        return this._injector;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(PlatformRef_.prototype, "disposed", {
      get: function() {
        return this._disposed;
      },
      enumerable: true,
      configurable: true
    });
    PlatformRef_.prototype.addApplication = function(appRef) {
      this._applications.push(appRef);
    };
    PlatformRef_.prototype.dispose = function() {
      collection_1.ListWrapper.clone(this._applications).forEach(function(app) {
        return app.dispose();
      });
      this._disposeListeners.forEach(function(dispose) {
        return dispose();
      });
      this._disposed = true;
    };
    PlatformRef_.prototype._applicationDisposed = function(app) {
      collection_1.ListWrapper.remove(this._applications, app);
    };
    PlatformRef_.decorators = [{type: di_1.Injectable}];
    PlatformRef_.ctorParameters = [{type: di_1.Injector}];
    return PlatformRef_;
  }(PlatformRef));
  exports.PlatformRef_ = PlatformRef_;
  var ApplicationRef = (function() {
    function ApplicationRef() {}
    Object.defineProperty(ApplicationRef.prototype, "injector", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ApplicationRef.prototype, "zone", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ApplicationRef.prototype, "componentTypes", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    return ApplicationRef;
  }());
  exports.ApplicationRef = ApplicationRef;
  var ApplicationRef_ = (function(_super) {
    __extends(ApplicationRef_, _super);
    function ApplicationRef_(_platform, _zone, _injector) {
      var _this = this;
      _super.call(this);
      this._platform = _platform;
      this._zone = _zone;
      this._injector = _injector;
      this._bootstrapListeners = [];
      this._disposeListeners = [];
      this._rootComponents = [];
      this._rootComponentTypes = [];
      this._changeDetectorRefs = [];
      this._runningTick = false;
      this._enforceNoNewChanges = false;
      var zone = _injector.get(ng_zone_1.NgZone);
      this._enforceNoNewChanges = lang_1.assertionsEnabled();
      zone.run(function() {
        _this._exceptionHandler = _injector.get(exceptions_1.ExceptionHandler);
      });
      this._asyncInitDonePromise = this.run(function() {
        var inits = _injector.get(application_tokens_1.APP_INITIALIZER, null);
        var asyncInitResults = [];
        var asyncInitDonePromise;
        if (lang_1.isPresent(inits)) {
          for (var i = 0; i < inits.length; i++) {
            var initResult = inits[i]();
            if (lang_1.isPromise(initResult)) {
              asyncInitResults.push(initResult);
            }
          }
        }
        if (asyncInitResults.length > 0) {
          asyncInitDonePromise = async_1.PromiseWrapper.all(asyncInitResults).then(function(_) {
            return _this._asyncInitDone = true;
          });
          _this._asyncInitDone = false;
        } else {
          _this._asyncInitDone = true;
          asyncInitDonePromise = async_1.PromiseWrapper.resolve(true);
        }
        return asyncInitDonePromise;
      });
      async_1.ObservableWrapper.subscribe(zone.onError, function(error) {
        _this._exceptionHandler.call(error.error, error.stackTrace);
      });
      async_1.ObservableWrapper.subscribe(this._zone.onMicrotaskEmpty, function(_) {
        _this._zone.run(function() {
          _this.tick();
        });
      });
    }
    ApplicationRef_.prototype.registerBootstrapListener = function(listener) {
      this._bootstrapListeners.push(listener);
    };
    ApplicationRef_.prototype.registerDisposeListener = function(dispose) {
      this._disposeListeners.push(dispose);
    };
    ApplicationRef_.prototype.registerChangeDetector = function(changeDetector) {
      this._changeDetectorRefs.push(changeDetector);
    };
    ApplicationRef_.prototype.unregisterChangeDetector = function(changeDetector) {
      collection_1.ListWrapper.remove(this._changeDetectorRefs, changeDetector);
    };
    ApplicationRef_.prototype.waitForAsyncInitializers = function() {
      return this._asyncInitDonePromise;
    };
    ApplicationRef_.prototype.run = function(callback) {
      var _this = this;
      var zone = this.injector.get(ng_zone_1.NgZone);
      var result;
      var completer = async_1.PromiseWrapper.completer();
      zone.run(function() {
        try {
          result = callback();
          if (lang_1.isPromise(result)) {
            async_1.PromiseWrapper.then(result, function(ref) {
              completer.resolve(ref);
            }, function(err, stackTrace) {
              completer.reject(err, stackTrace);
              _this._exceptionHandler.call(err, stackTrace);
            });
          }
        } catch (e) {
          _this._exceptionHandler.call(e, e.stack);
          throw e;
        }
      });
      return lang_1.isPromise(result) ? completer.promise : result;
    };
    ApplicationRef_.prototype.bootstrap = function(componentFactory) {
      var _this = this;
      if (!this._asyncInitDone) {
        throw new exceptions_1.BaseException('Cannot bootstrap as there are still asynchronous initializers running. Wait for them using waitForAsyncInitializers().');
      }
      return this.run(function() {
        _this._rootComponentTypes.push(componentFactory.componentType);
        var compRef = componentFactory.create(_this._injector, [], componentFactory.selector);
        compRef.onDestroy(function() {
          _this._unloadComponent(compRef);
        });
        var testability = compRef.injector.get(testability_1.Testability, null);
        if (lang_1.isPresent(testability)) {
          compRef.injector.get(testability_1.TestabilityRegistry).registerApplication(compRef.location.nativeElement, testability);
        }
        _this._loadComponent(compRef);
        var c = _this._injector.get(console_1.Console);
        if (lang_1.assertionsEnabled()) {
          c.log("Angular 2 is running in the development mode. Call enableProdMode() to enable the production mode.");
        }
        return compRef;
      });
    };
    ApplicationRef_.prototype._loadComponent = function(componentRef) {
      this._changeDetectorRefs.push(componentRef.changeDetectorRef);
      this.tick();
      this._rootComponents.push(componentRef);
      this._bootstrapListeners.forEach(function(listener) {
        return listener(componentRef);
      });
    };
    ApplicationRef_.prototype._unloadComponent = function(componentRef) {
      if (!collection_1.ListWrapper.contains(this._rootComponents, componentRef)) {
        return;
      }
      this.unregisterChangeDetector(componentRef.changeDetectorRef);
      collection_1.ListWrapper.remove(this._rootComponents, componentRef);
    };
    Object.defineProperty(ApplicationRef_.prototype, "injector", {
      get: function() {
        return this._injector;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ApplicationRef_.prototype, "zone", {
      get: function() {
        return this._zone;
      },
      enumerable: true,
      configurable: true
    });
    ApplicationRef_.prototype.tick = function() {
      if (this._runningTick) {
        throw new exceptions_1.BaseException("ApplicationRef.tick is called recursively");
      }
      var s = ApplicationRef_._tickScope();
      try {
        this._runningTick = true;
        this._changeDetectorRefs.forEach(function(detector) {
          return detector.detectChanges();
        });
        if (this._enforceNoNewChanges) {
          this._changeDetectorRefs.forEach(function(detector) {
            return detector.checkNoChanges();
          });
        }
      } finally {
        this._runningTick = false;
        profile_1.wtfLeave(s);
      }
    };
    ApplicationRef_.prototype.dispose = function() {
      collection_1.ListWrapper.clone(this._rootComponents).forEach(function(ref) {
        return ref.destroy();
      });
      this._disposeListeners.forEach(function(dispose) {
        return dispose();
      });
      this._platform._applicationDisposed(this);
    };
    Object.defineProperty(ApplicationRef_.prototype, "componentTypes", {
      get: function() {
        return this._rootComponentTypes;
      },
      enumerable: true,
      configurable: true
    });
    ApplicationRef_._tickScope = profile_1.wtfCreateScope('ApplicationRef#tick()');
    ApplicationRef_.decorators = [{type: di_1.Injectable}];
    ApplicationRef_.ctorParameters = [{type: PlatformRef_}, {type: ng_zone_1.NgZone}, {type: di_1.Injector}];
    return ApplicationRef_;
  }(ApplicationRef));
  exports.ApplicationRef_ = ApplicationRef_;
  exports.PLATFORM_CORE_PROVIDERS = [PlatformRef_, ({
    provide: PlatformRef,
    useExisting: PlatformRef_
  })];
  exports.APPLICATION_CORE_PROVIDERS = [{
    provide: ng_zone_1.NgZone,
    useFactory: createNgZone,
    deps: []
  }, ApplicationRef_, {
    provide: ApplicationRef,
    useExisting: ApplicationRef_
  }];
  return module.exports;
});

$__System.registerDynamic("258", ["257", "9c", "26d", "26a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var component_resolver_1 = $__require('257');
  var lang_1 = $__require('9c');
  var reflective_injector_1 = $__require('26d');
  var decorators_1 = $__require('26a');
  var DynamicComponentLoader = (function() {
    function DynamicComponentLoader() {}
    return DynamicComponentLoader;
  }());
  exports.DynamicComponentLoader = DynamicComponentLoader;
  var DynamicComponentLoader_ = (function(_super) {
    __extends(DynamicComponentLoader_, _super);
    function DynamicComponentLoader_(_compiler) {
      _super.call(this);
      this._compiler = _compiler;
    }
    DynamicComponentLoader_.prototype.loadAsRoot = function(type, overrideSelectorOrNode, injector, onDispose, projectableNodes) {
      return this._compiler.resolveComponent(type).then(function(componentFactory) {
        var componentRef = componentFactory.create(injector, projectableNodes, lang_1.isPresent(overrideSelectorOrNode) ? overrideSelectorOrNode : componentFactory.selector);
        if (lang_1.isPresent(onDispose)) {
          componentRef.onDestroy(onDispose);
        }
        return componentRef;
      });
    };
    DynamicComponentLoader_.prototype.loadNextToLocation = function(type, location, providers, projectableNodes) {
      if (providers === void 0) {
        providers = null;
      }
      if (projectableNodes === void 0) {
        projectableNodes = null;
      }
      return this._compiler.resolveComponent(type).then(function(componentFactory) {
        var contextInjector = location.parentInjector;
        var childInjector = lang_1.isPresent(providers) && providers.length > 0 ? reflective_injector_1.ReflectiveInjector.fromResolvedProviders(providers, contextInjector) : contextInjector;
        return location.createComponent(componentFactory, location.length, childInjector, projectableNodes);
      });
    };
    DynamicComponentLoader_.decorators = [{type: decorators_1.Injectable}];
    DynamicComponentLoader_.ctorParameters = [{type: component_resolver_1.ComponentResolver}];
    return DynamicComponentLoader_;
  }(DynamicComponentLoader));
  exports.DynamicComponentLoader_ = DynamicComponentLoader_;
  return module.exports;
});

$__System.registerDynamic("26e", ["26b", "268", "260", "26f", "257", "258"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var application_tokens_1 = $__require('26b');
  var application_ref_1 = $__require('268');
  var change_detection_1 = $__require('260');
  var view_utils_1 = $__require('26f');
  var component_resolver_1 = $__require('257');
  var dynamic_component_loader_1 = $__require('258');
  var __unused;
  exports.APPLICATION_COMMON_PROVIDERS = [application_ref_1.APPLICATION_CORE_PROVIDERS, {
    provide: component_resolver_1.ComponentResolver,
    useClass: component_resolver_1.ReflectorComponentResolver
  }, application_tokens_1.APP_ID_RANDOM_PROVIDER, view_utils_1.ViewUtils, {
    provide: change_detection_1.IterableDiffers,
    useValue: change_detection_1.defaultIterableDiffers
  }, {
    provide: change_detection_1.KeyValueDiffers,
    useValue: change_detection_1.defaultKeyValueDiffers
  }, {
    provide: dynamic_component_loader_1.DynamicComponentLoader,
    useClass: dynamic_component_loader_1.DynamicComponentLoader_
  }];
  return module.exports;
});

$__System.registerDynamic("270", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(LifecycleHooks) {
    LifecycleHooks[LifecycleHooks["OnInit"] = 0] = "OnInit";
    LifecycleHooks[LifecycleHooks["OnDestroy"] = 1] = "OnDestroy";
    LifecycleHooks[LifecycleHooks["DoCheck"] = 2] = "DoCheck";
    LifecycleHooks[LifecycleHooks["OnChanges"] = 3] = "OnChanges";
    LifecycleHooks[LifecycleHooks["AfterContentInit"] = 4] = "AfterContentInit";
    LifecycleHooks[LifecycleHooks["AfterContentChecked"] = 5] = "AfterContentChecked";
    LifecycleHooks[LifecycleHooks["AfterViewInit"] = 6] = "AfterViewInit";
    LifecycleHooks[LifecycleHooks["AfterViewChecked"] = 7] = "AfterViewChecked";
  })(exports.LifecycleHooks || (exports.LifecycleHooks = {}));
  var LifecycleHooks = exports.LifecycleHooks;
  exports.LIFECYCLE_HOOKS_VALUES = [LifecycleHooks.OnInit, LifecycleHooks.OnDestroy, LifecycleHooks.DoCheck, LifecycleHooks.OnChanges, LifecycleHooks.AfterContentInit, LifecycleHooks.AfterContentChecked, LifecycleHooks.AfterViewInit, LifecycleHooks.AfterViewChecked];
  return module.exports;
});

$__System.registerDynamic("25d", ["9c", "a9", "26f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var view_utils_1 = $__require('26f');
  var ComponentRef = (function() {
    function ComponentRef() {}
    Object.defineProperty(ComponentRef.prototype, "location", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentRef.prototype, "injector", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentRef.prototype, "instance", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ComponentRef.prototype, "hostView", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ComponentRef.prototype, "changeDetectorRef", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentRef.prototype, "componentType", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return ComponentRef;
  }());
  exports.ComponentRef = ComponentRef;
  var ComponentRef_ = (function(_super) {
    __extends(ComponentRef_, _super);
    function ComponentRef_(_hostElement, _componentType) {
      _super.call(this);
      this._hostElement = _hostElement;
      this._componentType = _componentType;
    }
    Object.defineProperty(ComponentRef_.prototype, "location", {
      get: function() {
        return this._hostElement.elementRef;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentRef_.prototype, "injector", {
      get: function() {
        return this._hostElement.injector;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ComponentRef_.prototype, "instance", {
      get: function() {
        return this._hostElement.component;
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ComponentRef_.prototype, "hostView", {
      get: function() {
        return this._hostElement.parentView.ref;
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ComponentRef_.prototype, "changeDetectorRef", {
      get: function() {
        return this._hostElement.parentView.ref;
      },
      enumerable: true,
      configurable: true
    });
    ;
    Object.defineProperty(ComponentRef_.prototype, "componentType", {
      get: function() {
        return this._componentType;
      },
      enumerable: true,
      configurable: true
    });
    ComponentRef_.prototype.destroy = function() {
      this._hostElement.parentView.destroy();
    };
    ComponentRef_.prototype.onDestroy = function(callback) {
      this.hostView.onDestroy(callback);
    };
    return ComponentRef_;
  }(ComponentRef));
  exports.ComponentRef_ = ComponentRef_;
  var EMPTY_CONTEXT = new Object();
  var ComponentFactory = (function() {
    function ComponentFactory(selector, _viewFactory, _componentType) {
      this.selector = selector;
      this._viewFactory = _viewFactory;
      this._componentType = _componentType;
    }
    Object.defineProperty(ComponentFactory.prototype, "componentType", {
      get: function() {
        return this._componentType;
      },
      enumerable: true,
      configurable: true
    });
    ComponentFactory.prototype.create = function(injector, projectableNodes, rootSelectorOrNode) {
      if (projectableNodes === void 0) {
        projectableNodes = null;
      }
      if (rootSelectorOrNode === void 0) {
        rootSelectorOrNode = null;
      }
      var vu = injector.get(view_utils_1.ViewUtils);
      if (lang_1.isBlank(projectableNodes)) {
        projectableNodes = [];
      }
      var hostView = this._viewFactory(vu, injector, null);
      var hostElement = hostView.create(EMPTY_CONTEXT, projectableNodes, rootSelectorOrNode);
      return new ComponentRef_(hostElement, this._componentType);
    };
    return ComponentFactory;
  }());
  exports.ComponentFactory = ComponentFactory;
  return module.exports;
});

$__System.registerDynamic("257", ["9c", "a9", "255", "265", "25d", "26a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var async_1 = $__require('255');
  var reflection_1 = $__require('265');
  var component_factory_1 = $__require('25d');
  var decorators_1 = $__require('26a');
  var ComponentResolver = (function() {
    function ComponentResolver() {}
    return ComponentResolver;
  }());
  exports.ComponentResolver = ComponentResolver;
  function _isComponentFactory(type) {
    return type instanceof component_factory_1.ComponentFactory;
  }
  var ReflectorComponentResolver = (function(_super) {
    __extends(ReflectorComponentResolver, _super);
    function ReflectorComponentResolver() {
      _super.apply(this, arguments);
    }
    ReflectorComponentResolver.prototype.resolveComponent = function(componentType) {
      var metadatas = reflection_1.reflector.annotations(componentType);
      var componentFactory = metadatas.find(_isComponentFactory);
      if (lang_1.isBlank(componentFactory)) {
        throw new exceptions_1.BaseException("No precompiled component " + lang_1.stringify(componentType) + " found");
      }
      return async_1.PromiseWrapper.resolve(componentFactory);
    };
    ReflectorComponentResolver.prototype.clearCache = function() {};
    ReflectorComponentResolver.decorators = [{type: decorators_1.Injectable}];
    return ReflectorComponentResolver;
  }(ComponentResolver));
  exports.ReflectorComponentResolver = ReflectorComponentResolver;
  return module.exports;
});

$__System.registerDynamic("271", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var PromiseCompleter = (function() {
    function PromiseCompleter() {
      var _this = this;
      this.promise = new Promise(function(res, rej) {
        _this.resolve = res;
        _this.reject = rej;
      });
    }
    return PromiseCompleter;
  }());
  exports.PromiseCompleter = PromiseCompleter;
  var PromiseWrapper = (function() {
    function PromiseWrapper() {}
    PromiseWrapper.resolve = function(obj) {
      return Promise.resolve(obj);
    };
    PromiseWrapper.reject = function(obj, _) {
      return Promise.reject(obj);
    };
    PromiseWrapper.catchError = function(promise, onError) {
      return promise.catch(onError);
    };
    PromiseWrapper.all = function(promises) {
      if (promises.length == 0)
        return Promise.resolve([]);
      return Promise.all(promises);
    };
    PromiseWrapper.then = function(promise, success, rejection) {
      return promise.then(success, rejection);
    };
    PromiseWrapper.wrap = function(computation) {
      return new Promise(function(res, rej) {
        try {
          res(computation());
        } catch (e) {
          rej(e);
        }
      });
    };
    PromiseWrapper.scheduleMicrotask = function(computation) {
      PromiseWrapper.then(PromiseWrapper.resolve(null), computation, function(_) {});
    };
    PromiseWrapper.isPromise = function(obj) {
      return obj instanceof Promise;
    };
    PromiseWrapper.completer = function() {
      return new PromiseCompleter();
    };
    return PromiseWrapper;
  }());
  exports.PromiseWrapper = PromiseWrapper;
  return module.exports;
});

$__System.registerDynamic("272", ["273"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var Subscription_1 = $__require('273');
  var SubjectSubscription = (function(_super) {
    __extends(SubjectSubscription, _super);
    function SubjectSubscription(subject, observer) {
      _super.call(this);
      this.subject = subject;
      this.observer = observer;
      this.isUnsubscribed = false;
    }
    SubjectSubscription.prototype.unsubscribe = function() {
      if (this.isUnsubscribed) {
        return;
      }
      this.isUnsubscribed = true;
      var subject = this.subject;
      var observers = subject.observers;
      this.subject = null;
      if (!observers || observers.length === 0 || subject.isUnsubscribed) {
        return;
      }
      var subscriberIndex = observers.indexOf(this.observer);
      if (subscriberIndex !== -1) {
        observers.splice(subscriberIndex, 1);
      }
    };
    return SubjectSubscription;
  }(Subscription_1.Subscription));
  exports.SubjectSubscription = SubjectSubscription;
  return module.exports;
});

$__System.registerDynamic("274", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function throwError(e) {
    throw e;
  }
  exports.throwError = throwError;
  return module.exports;
});

$__System.registerDynamic("275", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var ObjectUnsubscribedError = (function(_super) {
    __extends(ObjectUnsubscribedError, _super);
    function ObjectUnsubscribedError() {
      _super.call(this, 'object unsubscribed');
      this.name = 'ObjectUnsubscribedError';
    }
    return ObjectUnsubscribedError;
  }(Error));
  exports.ObjectUnsubscribedError = ObjectUnsubscribedError;
  return module.exports;
});

$__System.registerDynamic("33", ["36", "276", "273", "272", "277", "274", "275"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var Observable_1 = $__require('36');
  var Subscriber_1 = $__require('276');
  var Subscription_1 = $__require('273');
  var SubjectSubscription_1 = $__require('272');
  var rxSubscriber_1 = $__require('277');
  var throwError_1 = $__require('274');
  var ObjectUnsubscribedError_1 = $__require('275');
  var Subject = (function(_super) {
    __extends(Subject, _super);
    function Subject(destination, source) {
      _super.call(this);
      this.destination = destination;
      this.source = source;
      this.observers = [];
      this.isUnsubscribed = false;
      this.isStopped = false;
      this.hasErrored = false;
      this.dispatching = false;
      this.hasCompleted = false;
      this.source = source;
    }
    Subject.prototype.lift = function(operator) {
      var subject = new Subject(this.destination || this, this);
      subject.operator = operator;
      return subject;
    };
    Subject.prototype.add = function(subscription) {
      return Subscription_1.Subscription.prototype.add.call(this, subscription);
    };
    Subject.prototype.remove = function(subscription) {
      Subscription_1.Subscription.prototype.remove.call(this, subscription);
    };
    Subject.prototype.unsubscribe = function() {
      Subscription_1.Subscription.prototype.unsubscribe.call(this);
    };
    Subject.prototype._subscribe = function(subscriber) {
      if (this.source) {
        return this.source.subscribe(subscriber);
      } else {
        if (subscriber.isUnsubscribed) {
          return;
        } else if (this.hasErrored) {
          return subscriber.error(this.errorValue);
        } else if (this.hasCompleted) {
          return subscriber.complete();
        }
        this.throwIfUnsubscribed();
        var subscription = new SubjectSubscription_1.SubjectSubscription(this, subscriber);
        this.observers.push(subscriber);
        return subscription;
      }
    };
    Subject.prototype._unsubscribe = function() {
      this.source = null;
      this.isStopped = true;
      this.observers = null;
      this.destination = null;
    };
    Subject.prototype.next = function(value) {
      this.throwIfUnsubscribed();
      if (this.isStopped) {
        return;
      }
      this.dispatching = true;
      this._next(value);
      this.dispatching = false;
      if (this.hasErrored) {
        this._error(this.errorValue);
      } else if (this.hasCompleted) {
        this._complete();
      }
    };
    Subject.prototype.error = function(err) {
      this.throwIfUnsubscribed();
      if (this.isStopped) {
        return;
      }
      this.isStopped = true;
      this.hasErrored = true;
      this.errorValue = err;
      if (this.dispatching) {
        return;
      }
      this._error(err);
    };
    Subject.prototype.complete = function() {
      this.throwIfUnsubscribed();
      if (this.isStopped) {
        return;
      }
      this.isStopped = true;
      this.hasCompleted = true;
      if (this.dispatching) {
        return;
      }
      this._complete();
    };
    Subject.prototype.asObservable = function() {
      var observable = new SubjectObservable(this);
      return observable;
    };
    Subject.prototype._next = function(value) {
      if (this.destination) {
        this.destination.next(value);
      } else {
        this._finalNext(value);
      }
    };
    Subject.prototype._finalNext = function(value) {
      var index = -1;
      var observers = this.observers.slice(0);
      var len = observers.length;
      while (++index < len) {
        observers[index].next(value);
      }
    };
    Subject.prototype._error = function(err) {
      if (this.destination) {
        this.destination.error(err);
      } else {
        this._finalError(err);
      }
    };
    Subject.prototype._finalError = function(err) {
      var index = -1;
      var observers = this.observers;
      this.observers = null;
      this.isUnsubscribed = true;
      if (observers) {
        var len = observers.length;
        while (++index < len) {
          observers[index].error(err);
        }
      }
      this.isUnsubscribed = false;
      this.unsubscribe();
    };
    Subject.prototype._complete = function() {
      if (this.destination) {
        this.destination.complete();
      } else {
        this._finalComplete();
      }
    };
    Subject.prototype._finalComplete = function() {
      var index = -1;
      var observers = this.observers;
      this.observers = null;
      this.isUnsubscribed = true;
      if (observers) {
        var len = observers.length;
        while (++index < len) {
          observers[index].complete();
        }
      }
      this.isUnsubscribed = false;
      this.unsubscribe();
    };
    Subject.prototype.throwIfUnsubscribed = function() {
      if (this.isUnsubscribed) {
        throwError_1.throwError(new ObjectUnsubscribedError_1.ObjectUnsubscribedError());
      }
    };
    Subject.prototype[rxSubscriber_1.$$rxSubscriber] = function() {
      return new Subscriber_1.Subscriber(this);
    };
    Subject.create = function(destination, source) {
      return new Subject(destination, source);
    };
    return Subject;
  }(Observable_1.Observable));
  exports.Subject = Subject;
  var SubjectObservable = (function(_super) {
    __extends(SubjectObservable, _super);
    function SubjectObservable(source) {
      _super.call(this);
      this.source = source;
    }
    return SubjectObservable;
  }(Observable_1.Observable));
  return module.exports;
});

$__System.registerDynamic("34", ["278", "36"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var root_1 = $__require('278');
  var Observable_1 = $__require('36');
  var PromiseObservable = (function(_super) {
    __extends(PromiseObservable, _super);
    function PromiseObservable(promise, scheduler) {
      if (scheduler === void 0) {
        scheduler = null;
      }
      _super.call(this);
      this.promise = promise;
      this.scheduler = scheduler;
    }
    PromiseObservable.create = function(promise, scheduler) {
      if (scheduler === void 0) {
        scheduler = null;
      }
      return new PromiseObservable(promise, scheduler);
    };
    PromiseObservable.prototype._subscribe = function(subscriber) {
      var _this = this;
      var promise = this.promise;
      var scheduler = this.scheduler;
      if (scheduler == null) {
        if (this._isScalar) {
          if (!subscriber.isUnsubscribed) {
            subscriber.next(this.value);
            subscriber.complete();
          }
        } else {
          promise.then(function(value) {
            _this.value = value;
            _this._isScalar = true;
            if (!subscriber.isUnsubscribed) {
              subscriber.next(value);
              subscriber.complete();
            }
          }, function(err) {
            if (!subscriber.isUnsubscribed) {
              subscriber.error(err);
            }
          }).then(null, function(err) {
            root_1.root.setTimeout(function() {
              throw err;
            });
          });
        }
      } else {
        if (this._isScalar) {
          if (!subscriber.isUnsubscribed) {
            return scheduler.schedule(dispatchNext, 0, {
              value: this.value,
              subscriber: subscriber
            });
          }
        } else {
          promise.then(function(value) {
            _this.value = value;
            _this._isScalar = true;
            if (!subscriber.isUnsubscribed) {
              subscriber.add(scheduler.schedule(dispatchNext, 0, {
                value: value,
                subscriber: subscriber
              }));
            }
          }, function(err) {
            if (!subscriber.isUnsubscribed) {
              subscriber.add(scheduler.schedule(dispatchError, 0, {
                err: err,
                subscriber: subscriber
              }));
            }
          }).then(null, function(err) {
            root_1.root.setTimeout(function() {
              throw err;
            });
          });
        }
      }
    };
    return PromiseObservable;
  }(Observable_1.Observable));
  exports.PromiseObservable = PromiseObservable;
  function dispatchNext(arg) {
    var value = arg.value,
        subscriber = arg.subscriber;
    if (!subscriber.isUnsubscribed) {
      subscriber.next(value);
      subscriber.complete();
    }
  }
  function dispatchError(arg) {
    var err = arg.err,
        subscriber = arg.subscriber;
    if (!subscriber.isUnsubscribed) {
      subscriber.error(err);
    }
  }
  return module.exports;
});

$__System.registerDynamic("35", ["278"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var root_1 = $__require('278');
  function toPromise(PromiseCtor) {
    var _this = this;
    if (!PromiseCtor) {
      if (root_1.root.Rx && root_1.root.Rx.config && root_1.root.Rx.config.Promise) {
        PromiseCtor = root_1.root.Rx.config.Promise;
      } else if (root_1.root.Promise) {
        PromiseCtor = root_1.root.Promise;
      }
    }
    if (!PromiseCtor) {
      throw new Error('no Promise impl found');
    }
    return new PromiseCtor(function(resolve, reject) {
      var value;
      _this.subscribe(function(x) {
        return value = x;
      }, function(err) {
        return reject(err);
      }, function() {
        return resolve(value);
      });
    });
  }
  exports.toPromise = toPromise;
  return module.exports;
});

$__System.registerDynamic("279", ["278"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var root_1 = $__require('278');
  var Symbol = root_1.root.Symbol;
  if (typeof Symbol === 'function') {
    if (Symbol.observable) {
      exports.$$observable = Symbol.observable;
    } else {
      if (typeof Symbol.for === 'function') {
        exports.$$observable = Symbol.for('observable');
      } else {
        exports.$$observable = Symbol('observable');
      }
      Symbol.observable = exports.$$observable;
    }
  } else {
    exports.$$observable = '@@observable';
  }
  return module.exports;
});

$__System.registerDynamic("27a", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.isArray = Array.isArray || (function(x) {
    return x && typeof x.length === 'number';
  });
  return module.exports;
});

$__System.registerDynamic("27b", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function isObject(x) {
    return x != null && typeof x === 'object';
  }
  exports.isObject = isObject;
  return module.exports;
});

$__System.registerDynamic("27c", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function isFunction(x) {
    return typeof x === 'function';
  }
  exports.isFunction = isFunction;
  return module.exports;
});

$__System.registerDynamic("27d", ["27e"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var errorObject_1 = $__require('27e');
  var tryCatchTarget;
  function tryCatcher() {
    try {
      return tryCatchTarget.apply(this, arguments);
    } catch (e) {
      errorObject_1.errorObject.e = e;
      return errorObject_1.errorObject;
    }
  }
  function tryCatch(fn) {
    tryCatchTarget = fn;
    return tryCatcher;
  }
  exports.tryCatch = tryCatch;
  ;
  return module.exports;
});

$__System.registerDynamic("27e", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.errorObject = {e: {}};
  return module.exports;
});

$__System.registerDynamic("27f", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var UnsubscriptionError = (function(_super) {
    __extends(UnsubscriptionError, _super);
    function UnsubscriptionError(errors) {
      _super.call(this);
      this.errors = errors;
      this.name = 'UnsubscriptionError';
      this.message = errors ? errors.length + " errors occurred during unsubscription:\n" + errors.map(function(err, i) {
        return ((i + 1) + ") " + err.toString());
      }).join('\n') : '';
    }
    return UnsubscriptionError;
  }(Error));
  exports.UnsubscriptionError = UnsubscriptionError;
  return module.exports;
});

$__System.registerDynamic("273", ["27a", "27b", "27c", "27d", "27e", "27f", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var isArray_1 = $__require('27a');
    var isObject_1 = $__require('27b');
    var isFunction_1 = $__require('27c');
    var tryCatch_1 = $__require('27d');
    var errorObject_1 = $__require('27e');
    var UnsubscriptionError_1 = $__require('27f');
    var Subscription = (function() {
      function Subscription(unsubscribe) {
        this.isUnsubscribed = false;
        if (unsubscribe) {
          this._unsubscribe = unsubscribe;
        }
      }
      Subscription.prototype.unsubscribe = function() {
        var hasErrors = false;
        var errors;
        if (this.isUnsubscribed) {
          return;
        }
        this.isUnsubscribed = true;
        var _a = this,
            _unsubscribe = _a._unsubscribe,
            _subscriptions = _a._subscriptions;
        this._subscriptions = null;
        if (isFunction_1.isFunction(_unsubscribe)) {
          var trial = tryCatch_1.tryCatch(_unsubscribe).call(this);
          if (trial === errorObject_1.errorObject) {
            hasErrors = true;
            (errors = errors || []).push(errorObject_1.errorObject.e);
          }
        }
        if (isArray_1.isArray(_subscriptions)) {
          var index = -1;
          var len = _subscriptions.length;
          while (++index < len) {
            var sub = _subscriptions[index];
            if (isObject_1.isObject(sub)) {
              var trial = tryCatch_1.tryCatch(sub.unsubscribe).call(sub);
              if (trial === errorObject_1.errorObject) {
                hasErrors = true;
                errors = errors || [];
                var err = errorObject_1.errorObject.e;
                if (err instanceof UnsubscriptionError_1.UnsubscriptionError) {
                  errors = errors.concat(err.errors);
                } else {
                  errors.push(err);
                }
              }
            }
          }
        }
        if (hasErrors) {
          throw new UnsubscriptionError_1.UnsubscriptionError(errors);
        }
      };
      Subscription.prototype.add = function(teardown) {
        if (!teardown || (teardown === this) || (teardown === Subscription.EMPTY)) {
          return;
        }
        var sub = teardown;
        switch (typeof teardown) {
          case 'function':
            sub = new Subscription(teardown);
          case 'object':
            if (sub.isUnsubscribed || typeof sub.unsubscribe !== 'function') {
              break;
            } else if (this.isUnsubscribed) {
              sub.unsubscribe();
            } else {
              (this._subscriptions || (this._subscriptions = [])).push(sub);
            }
            break;
          default:
            throw new Error('Unrecognized teardown ' + teardown + ' added to Subscription.');
        }
        return sub;
      };
      Subscription.prototype.remove = function(subscription) {
        if (subscription == null || (subscription === this) || (subscription === Subscription.EMPTY)) {
          return;
        }
        var subscriptions = this._subscriptions;
        if (subscriptions) {
          var subscriptionIndex = subscriptions.indexOf(subscription);
          if (subscriptionIndex !== -1) {
            subscriptions.splice(subscriptionIndex, 1);
          }
        }
      };
      Subscription.EMPTY = (function(empty) {
        empty.isUnsubscribed = true;
        return empty;
      }(new Subscription()));
      return Subscription;
    }());
    exports.Subscription = Subscription;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("280", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  exports.empty = {
    isUnsubscribed: true,
    next: function(value) {},
    error: function(err) {
      throw err;
    },
    complete: function() {}
  };
  return module.exports;
});

$__System.registerDynamic("276", ["27c", "273", "277", "280"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var isFunction_1 = $__require('27c');
  var Subscription_1 = $__require('273');
  var rxSubscriber_1 = $__require('277');
  var Observer_1 = $__require('280');
  var Subscriber = (function(_super) {
    __extends(Subscriber, _super);
    function Subscriber(destinationOrNext, error, complete) {
      _super.call(this);
      this.syncErrorValue = null;
      this.syncErrorThrown = false;
      this.syncErrorThrowable = false;
      this.isStopped = false;
      switch (arguments.length) {
        case 0:
          this.destination = Observer_1.empty;
          break;
        case 1:
          if (!destinationOrNext) {
            this.destination = Observer_1.empty;
            break;
          }
          if (typeof destinationOrNext === 'object') {
            if (destinationOrNext instanceof Subscriber) {
              this.destination = destinationOrNext;
              this.destination.add(this);
            } else {
              this.syncErrorThrowable = true;
              this.destination = new SafeSubscriber(this, destinationOrNext);
            }
            break;
          }
        default:
          this.syncErrorThrowable = true;
          this.destination = new SafeSubscriber(this, destinationOrNext, error, complete);
          break;
      }
    }
    Subscriber.create = function(next, error, complete) {
      var subscriber = new Subscriber(next, error, complete);
      subscriber.syncErrorThrowable = false;
      return subscriber;
    };
    Subscriber.prototype.next = function(value) {
      if (!this.isStopped) {
        this._next(value);
      }
    };
    Subscriber.prototype.error = function(err) {
      if (!this.isStopped) {
        this.isStopped = true;
        this._error(err);
      }
    };
    Subscriber.prototype.complete = function() {
      if (!this.isStopped) {
        this.isStopped = true;
        this._complete();
      }
    };
    Subscriber.prototype.unsubscribe = function() {
      if (this.isUnsubscribed) {
        return;
      }
      this.isStopped = true;
      _super.prototype.unsubscribe.call(this);
    };
    Subscriber.prototype._next = function(value) {
      this.destination.next(value);
    };
    Subscriber.prototype._error = function(err) {
      this.destination.error(err);
      this.unsubscribe();
    };
    Subscriber.prototype._complete = function() {
      this.destination.complete();
      this.unsubscribe();
    };
    Subscriber.prototype[rxSubscriber_1.$$rxSubscriber] = function() {
      return this;
    };
    return Subscriber;
  }(Subscription_1.Subscription));
  exports.Subscriber = Subscriber;
  var SafeSubscriber = (function(_super) {
    __extends(SafeSubscriber, _super);
    function SafeSubscriber(_parent, observerOrNext, error, complete) {
      _super.call(this);
      this._parent = _parent;
      var next;
      var context = this;
      if (isFunction_1.isFunction(observerOrNext)) {
        next = observerOrNext;
      } else if (observerOrNext) {
        context = observerOrNext;
        next = observerOrNext.next;
        error = observerOrNext.error;
        complete = observerOrNext.complete;
        if (isFunction_1.isFunction(context.unsubscribe)) {
          this.add(context.unsubscribe.bind(context));
        }
        context.unsubscribe = this.unsubscribe.bind(this);
      }
      this._context = context;
      this._next = next;
      this._error = error;
      this._complete = complete;
    }
    SafeSubscriber.prototype.next = function(value) {
      if (!this.isStopped && this._next) {
        var _parent = this._parent;
        if (!_parent.syncErrorThrowable) {
          this.__tryOrUnsub(this._next, value);
        } else if (this.__tryOrSetError(_parent, this._next, value)) {
          this.unsubscribe();
        }
      }
    };
    SafeSubscriber.prototype.error = function(err) {
      if (!this.isStopped) {
        var _parent = this._parent;
        if (this._error) {
          if (!_parent.syncErrorThrowable) {
            this.__tryOrUnsub(this._error, err);
            this.unsubscribe();
          } else {
            this.__tryOrSetError(_parent, this._error, err);
            this.unsubscribe();
          }
        } else if (!_parent.syncErrorThrowable) {
          this.unsubscribe();
          throw err;
        } else {
          _parent.syncErrorValue = err;
          _parent.syncErrorThrown = true;
          this.unsubscribe();
        }
      }
    };
    SafeSubscriber.prototype.complete = function() {
      if (!this.isStopped) {
        var _parent = this._parent;
        if (this._complete) {
          if (!_parent.syncErrorThrowable) {
            this.__tryOrUnsub(this._complete);
            this.unsubscribe();
          } else {
            this.__tryOrSetError(_parent, this._complete);
            this.unsubscribe();
          }
        } else {
          this.unsubscribe();
        }
      }
    };
    SafeSubscriber.prototype.__tryOrUnsub = function(fn, value) {
      try {
        fn.call(this._context, value);
      } catch (err) {
        this.unsubscribe();
        throw err;
      }
    };
    SafeSubscriber.prototype.__tryOrSetError = function(parent, fn, value) {
      try {
        fn.call(this._context, value);
      } catch (err) {
        parent.syncErrorValue = err;
        parent.syncErrorThrown = true;
        return true;
      }
      return false;
    };
    SafeSubscriber.prototype._unsubscribe = function() {
      var _parent = this._parent;
      this._context = null;
      this._parent = null;
      _parent.unsubscribe();
    };
    return SafeSubscriber;
  }(Subscriber));
  return module.exports;
});

$__System.registerDynamic("278", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var objectTypes = {
    'boolean': false,
    'function': true,
    'object': true,
    'number': false,
    'string': false,
    'undefined': false
  };
  exports.root = (objectTypes[typeof self] && self) || (objectTypes[typeof window] && window);
  var freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports;
  var freeModule = objectTypes[typeof module] && module && !module.nodeType && module;
  var freeGlobal = objectTypes[typeof global] && global;
  if (freeGlobal && (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal)) {
    exports.root = freeGlobal;
  }
  return module.exports;
});

$__System.registerDynamic("277", ["278"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var root_1 = $__require('278');
  var Symbol = root_1.root.Symbol;
  exports.$$rxSubscriber = (typeof Symbol === 'function' && typeof Symbol.for === 'function') ? Symbol.for('rxSubscriber') : '@@rxSubscriber';
  return module.exports;
});

$__System.registerDynamic("281", ["276", "277"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var Subscriber_1 = $__require('276');
  var rxSubscriber_1 = $__require('277');
  function toSubscriber(nextOrObserver, error, complete) {
    if (nextOrObserver && typeof nextOrObserver === 'object') {
      if (nextOrObserver instanceof Subscriber_1.Subscriber) {
        return nextOrObserver;
      } else if (typeof nextOrObserver[rxSubscriber_1.$$rxSubscriber] === 'function') {
        return nextOrObserver[rxSubscriber_1.$$rxSubscriber]();
      }
    }
    return new Subscriber_1.Subscriber(nextOrObserver, error, complete);
  }
  exports.toSubscriber = toSubscriber;
  return module.exports;
});

$__System.registerDynamic("36", ["278", "279", "281"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var root_1 = $__require('278');
  var observable_1 = $__require('279');
  var toSubscriber_1 = $__require('281');
  var Observable = (function() {
    function Observable(subscribe) {
      this._isScalar = false;
      if (subscribe) {
        this._subscribe = subscribe;
      }
    }
    Observable.prototype.lift = function(operator) {
      var observable = new Observable();
      observable.source = this;
      observable.operator = operator;
      return observable;
    };
    Observable.prototype.subscribe = function(observerOrNext, error, complete) {
      var operator = this.operator;
      var sink = toSubscriber_1.toSubscriber(observerOrNext, error, complete);
      sink.add(operator ? operator.call(sink, this) : this._subscribe(sink));
      if (sink.syncErrorThrowable) {
        sink.syncErrorThrowable = false;
        if (sink.syncErrorThrown) {
          throw sink.syncErrorValue;
        }
      }
      return sink;
    };
    Observable.prototype.forEach = function(next, PromiseCtor) {
      var _this = this;
      if (!PromiseCtor) {
        if (root_1.root.Rx && root_1.root.Rx.config && root_1.root.Rx.config.Promise) {
          PromiseCtor = root_1.root.Rx.config.Promise;
        } else if (root_1.root.Promise) {
          PromiseCtor = root_1.root.Promise;
        }
      }
      if (!PromiseCtor) {
        throw new Error('no Promise impl found');
      }
      return new PromiseCtor(function(resolve, reject) {
        var subscription = _this.subscribe(function(value) {
          if (subscription) {
            try {
              next(value);
            } catch (err) {
              reject(err);
              subscription.unsubscribe();
            }
          } else {
            next(value);
          }
        }, reject, resolve);
      });
    };
    Observable.prototype._subscribe = function(subscriber) {
      return this.source.subscribe(subscriber);
    };
    Observable.prototype[observable_1.$$observable] = function() {
      return this;
    };
    Observable.create = function(subscribe) {
      return new Observable(subscribe);
    };
    return Observable;
  }());
  exports.Observable = Observable;
  return module.exports;
});

$__System.registerDynamic("255", ["9c", "271", "33", "34", "35", "36"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var promise_1 = $__require('271');
  exports.PromiseWrapper = promise_1.PromiseWrapper;
  exports.PromiseCompleter = promise_1.PromiseCompleter;
  var Subject_1 = $__require('33');
  var PromiseObservable_1 = $__require('34');
  var toPromise_1 = $__require('35');
  var Observable_1 = $__require('36');
  exports.Observable = Observable_1.Observable;
  var Subject_2 = $__require('33');
  exports.Subject = Subject_2.Subject;
  var TimerWrapper = (function() {
    function TimerWrapper() {}
    TimerWrapper.setTimeout = function(fn, millis) {
      return lang_1.global.setTimeout(fn, millis);
    };
    TimerWrapper.clearTimeout = function(id) {
      lang_1.global.clearTimeout(id);
    };
    TimerWrapper.setInterval = function(fn, millis) {
      return lang_1.global.setInterval(fn, millis);
    };
    TimerWrapper.clearInterval = function(id) {
      lang_1.global.clearInterval(id);
    };
    return TimerWrapper;
  }());
  exports.TimerWrapper = TimerWrapper;
  var ObservableWrapper = (function() {
    function ObservableWrapper() {}
    ObservableWrapper.subscribe = function(emitter, onNext, onError, onComplete) {
      if (onComplete === void 0) {
        onComplete = function() {};
      }
      onError = (typeof onError === "function") && onError || lang_1.noop;
      onComplete = (typeof onComplete === "function") && onComplete || lang_1.noop;
      return emitter.subscribe({
        next: onNext,
        error: onError,
        complete: onComplete
      });
    };
    ObservableWrapper.isObservable = function(obs) {
      return !!obs.subscribe;
    };
    ObservableWrapper.hasSubscribers = function(obs) {
      return obs.observers.length > 0;
    };
    ObservableWrapper.dispose = function(subscription) {
      subscription.unsubscribe();
    };
    ObservableWrapper.callNext = function(emitter, value) {
      emitter.next(value);
    };
    ObservableWrapper.callEmit = function(emitter, value) {
      emitter.emit(value);
    };
    ObservableWrapper.callError = function(emitter, error) {
      emitter.error(error);
    };
    ObservableWrapper.callComplete = function(emitter) {
      emitter.complete();
    };
    ObservableWrapper.fromPromise = function(promise) {
      return PromiseObservable_1.PromiseObservable.create(promise);
    };
    ObservableWrapper.toPromise = function(obj) {
      return toPromise_1.toPromise.call(obj);
    };
    return ObservableWrapper;
  }());
  exports.ObservableWrapper = ObservableWrapper;
  var EventEmitter = (function(_super) {
    __extends(EventEmitter, _super);
    function EventEmitter(isAsync) {
      if (isAsync === void 0) {
        isAsync = true;
      }
      _super.call(this);
      this._isAsync = isAsync;
    }
    EventEmitter.prototype.emit = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.next = function(value) {
      _super.prototype.next.call(this, value);
    };
    EventEmitter.prototype.subscribe = function(generatorOrNext, error, complete) {
      var schedulerFn;
      var errorFn = function(err) {
        return null;
      };
      var completeFn = function() {
        return null;
      };
      if (generatorOrNext && typeof generatorOrNext === 'object') {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext.next(value);
          });
        } : function(value) {
          generatorOrNext.next(value);
        };
        if (generatorOrNext.error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return generatorOrNext.error(err);
            });
          } : function(err) {
            generatorOrNext.error(err);
          };
        }
        if (generatorOrNext.complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return generatorOrNext.complete();
            });
          } : function() {
            generatorOrNext.complete();
          };
        }
      } else {
        schedulerFn = this._isAsync ? function(value) {
          setTimeout(function() {
            return generatorOrNext(value);
          });
        } : function(value) {
          generatorOrNext(value);
        };
        if (error) {
          errorFn = this._isAsync ? function(err) {
            setTimeout(function() {
              return error(err);
            });
          } : function(err) {
            error(err);
          };
        }
        if (complete) {
          completeFn = this._isAsync ? function() {
            setTimeout(function() {
              return complete();
            });
          } : function() {
            complete();
          };
        }
      }
      return _super.prototype.subscribe.call(this, schedulerFn, errorFn, completeFn);
    };
    return EventEmitter;
  }(Subject_1.Subject));
  exports.EventEmitter = EventEmitter;
  return module.exports;
});

$__System.registerDynamic("25b", ["a9", "24a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var exceptions_1 = $__require('a9');
  var constants_1 = $__require('24a');
  var ViewRef = (function() {
    function ViewRef() {}
    Object.defineProperty(ViewRef.prototype, "destroyed", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return ViewRef;
  }());
  exports.ViewRef = ViewRef;
  var EmbeddedViewRef = (function(_super) {
    __extends(EmbeddedViewRef, _super);
    function EmbeddedViewRef() {
      _super.apply(this, arguments);
    }
    Object.defineProperty(EmbeddedViewRef.prototype, "context", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(EmbeddedViewRef.prototype, "rootNodes", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    return EmbeddedViewRef;
  }(ViewRef));
  exports.EmbeddedViewRef = EmbeddedViewRef;
  var ViewRef_ = (function() {
    function ViewRef_(_view) {
      this._view = _view;
      this._view = _view;
    }
    Object.defineProperty(ViewRef_.prototype, "internalView", {
      get: function() {
        return this._view;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewRef_.prototype, "rootNodes", {
      get: function() {
        return this._view.flatRootNodes;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewRef_.prototype, "context", {
      get: function() {
        return this._view.context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewRef_.prototype, "destroyed", {
      get: function() {
        return this._view.destroyed;
      },
      enumerable: true,
      configurable: true
    });
    ViewRef_.prototype.markForCheck = function() {
      this._view.markPathToRootAsCheckOnce();
    };
    ViewRef_.prototype.detach = function() {
      this._view.cdMode = constants_1.ChangeDetectionStrategy.Detached;
    };
    ViewRef_.prototype.detectChanges = function() {
      this._view.detectChanges(false);
    };
    ViewRef_.prototype.checkNoChanges = function() {
      this._view.detectChanges(true);
    };
    ViewRef_.prototype.reattach = function() {
      this._view.cdMode = constants_1.ChangeDetectionStrategy.CheckAlways;
      this.markForCheck();
    };
    ViewRef_.prototype.onDestroy = function(callback) {
      this._view.disposables.push(callback);
    };
    ViewRef_.prototype.destroy = function() {
      this._view.destroy();
    };
    return ViewRef_;
  }());
  exports.ViewRef_ = ViewRef_;
  return module.exports;
});

$__System.registerDynamic("282", ["283"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var injector_1 = $__require('283');
  var _UNDEFINED = new Object();
  var ElementInjector = (function(_super) {
    __extends(ElementInjector, _super);
    function ElementInjector(_view, _nodeIndex) {
      _super.call(this);
      this._view = _view;
      this._nodeIndex = _nodeIndex;
    }
    ElementInjector.prototype.get = function(token, notFoundValue) {
      if (notFoundValue === void 0) {
        notFoundValue = injector_1.THROW_IF_NOT_FOUND;
      }
      var result = _UNDEFINED;
      if (result === _UNDEFINED) {
        result = this._view.injectorGet(token, this._nodeIndex, _UNDEFINED);
      }
      if (result === _UNDEFINED) {
        result = this._view.parentInjector.get(token, notFoundValue);
      }
      return result;
    };
    return ElementInjector;
  }(injector_1.Injector));
  exports.ElementInjector = ElementInjector;
  return module.exports;
});

$__System.registerDynamic("284", ["254", "285", "9c", "255", "25b", "286", "26f", "260", "26c", "25e", "287", "282"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var collection_1 = $__require('254');
  var element_1 = $__require('285');
  var lang_1 = $__require('9c');
  var async_1 = $__require('255');
  var view_ref_1 = $__require('25b');
  var view_type_1 = $__require('286');
  var view_utils_1 = $__require('26f');
  var change_detection_1 = $__require('260');
  var profile_1 = $__require('26c');
  var exceptions_1 = $__require('25e');
  var debug_context_1 = $__require('287');
  var element_injector_1 = $__require('282');
  var _scope_check = profile_1.wtfCreateScope("AppView#check(ascii id)");
  var AppView = (function() {
    function AppView(clazz, componentType, type, viewUtils, parentInjector, declarationAppElement, cdMode) {
      this.clazz = clazz;
      this.componentType = componentType;
      this.type = type;
      this.viewUtils = viewUtils;
      this.parentInjector = parentInjector;
      this.declarationAppElement = declarationAppElement;
      this.cdMode = cdMode;
      this.contentChildren = [];
      this.viewChildren = [];
      this.viewContainerElement = null;
      this.cdState = change_detection_1.ChangeDetectorState.NeverChecked;
      this.destroyed = false;
      this.ref = new view_ref_1.ViewRef_(this);
      if (type === view_type_1.ViewType.COMPONENT || type === view_type_1.ViewType.HOST) {
        this.renderer = viewUtils.renderComponent(componentType);
      } else {
        this.renderer = declarationAppElement.parentView.renderer;
      }
    }
    AppView.prototype.create = function(context, givenProjectableNodes, rootSelectorOrNode) {
      this.context = context;
      var projectableNodes;
      switch (this.type) {
        case view_type_1.ViewType.COMPONENT:
          projectableNodes = view_utils_1.ensureSlotCount(givenProjectableNodes, this.componentType.slotCount);
          break;
        case view_type_1.ViewType.EMBEDDED:
          projectableNodes = this.declarationAppElement.parentView.projectableNodes;
          break;
        case view_type_1.ViewType.HOST:
          projectableNodes = givenProjectableNodes;
          break;
      }
      this._hasExternalHostElement = lang_1.isPresent(rootSelectorOrNode);
      this.projectableNodes = projectableNodes;
      return this.createInternal(rootSelectorOrNode);
    };
    AppView.prototype.createInternal = function(rootSelectorOrNode) {
      return null;
    };
    AppView.prototype.init = function(rootNodesOrAppElements, allNodes, disposables, subscriptions) {
      this.rootNodesOrAppElements = rootNodesOrAppElements;
      this.allNodes = allNodes;
      this.disposables = disposables;
      this.subscriptions = subscriptions;
      if (this.type === view_type_1.ViewType.COMPONENT) {
        this.declarationAppElement.parentView.viewChildren.push(this);
        this.dirtyParentQueriesInternal();
      }
    };
    AppView.prototype.selectOrCreateHostElement = function(elementName, rootSelectorOrNode, debugInfo) {
      var hostElement;
      if (lang_1.isPresent(rootSelectorOrNode)) {
        hostElement = this.renderer.selectRootElement(rootSelectorOrNode, debugInfo);
      } else {
        hostElement = this.renderer.createElement(null, elementName, debugInfo);
      }
      return hostElement;
    };
    AppView.prototype.injectorGet = function(token, nodeIndex, notFoundResult) {
      return this.injectorGetInternal(token, nodeIndex, notFoundResult);
    };
    AppView.prototype.injectorGetInternal = function(token, nodeIndex, notFoundResult) {
      return notFoundResult;
    };
    AppView.prototype.injector = function(nodeIndex) {
      if (lang_1.isPresent(nodeIndex)) {
        return new element_injector_1.ElementInjector(this, nodeIndex);
      } else {
        return this.parentInjector;
      }
    };
    AppView.prototype.destroy = function() {
      if (this._hasExternalHostElement) {
        this.renderer.detachView(this.flatRootNodes);
      } else if (lang_1.isPresent(this.viewContainerElement)) {
        this.viewContainerElement.detachView(this.viewContainerElement.nestedViews.indexOf(this));
      }
      this._destroyRecurse();
    };
    AppView.prototype._destroyRecurse = function() {
      if (this.destroyed) {
        return;
      }
      var children = this.contentChildren;
      for (var i = 0; i < children.length; i++) {
        children[i]._destroyRecurse();
      }
      children = this.viewChildren;
      for (var i = 0; i < children.length; i++) {
        children[i]._destroyRecurse();
      }
      this.destroyLocal();
      this.destroyed = true;
    };
    AppView.prototype.destroyLocal = function() {
      var hostElement = this.type === view_type_1.ViewType.COMPONENT ? this.declarationAppElement.nativeElement : null;
      for (var i = 0; i < this.disposables.length; i++) {
        this.disposables[i]();
      }
      for (var i = 0; i < this.subscriptions.length; i++) {
        async_1.ObservableWrapper.dispose(this.subscriptions[i]);
      }
      this.destroyInternal();
      if (this._hasExternalHostElement) {
        this.renderer.detachView(this.flatRootNodes);
      } else if (lang_1.isPresent(this.viewContainerElement)) {
        this.viewContainerElement.detachView(this.viewContainerElement.nestedViews.indexOf(this));
      } else {
        this.dirtyParentQueriesInternal();
      }
      this.renderer.destroyView(hostElement, this.allNodes);
    };
    AppView.prototype.destroyInternal = function() {};
    Object.defineProperty(AppView.prototype, "changeDetectorRef", {
      get: function() {
        return this.ref;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AppView.prototype, "parent", {
      get: function() {
        return lang_1.isPresent(this.declarationAppElement) ? this.declarationAppElement.parentView : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AppView.prototype, "flatRootNodes", {
      get: function() {
        return view_utils_1.flattenNestedViewRenderNodes(this.rootNodesOrAppElements);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AppView.prototype, "lastRootNode", {
      get: function() {
        var lastNode = this.rootNodesOrAppElements.length > 0 ? this.rootNodesOrAppElements[this.rootNodesOrAppElements.length - 1] : null;
        return _findLastRenderNode(lastNode);
      },
      enumerable: true,
      configurable: true
    });
    AppView.prototype.dirtyParentQueriesInternal = function() {};
    AppView.prototype.detectChanges = function(throwOnChange) {
      var s = _scope_check(this.clazz);
      if (this.cdMode === change_detection_1.ChangeDetectionStrategy.Detached || this.cdMode === change_detection_1.ChangeDetectionStrategy.Checked || this.cdState === change_detection_1.ChangeDetectorState.Errored)
        return;
      if (this.destroyed) {
        this.throwDestroyedError('detectChanges');
      }
      this.detectChangesInternal(throwOnChange);
      if (this.cdMode === change_detection_1.ChangeDetectionStrategy.CheckOnce)
        this.cdMode = change_detection_1.ChangeDetectionStrategy.Checked;
      this.cdState = change_detection_1.ChangeDetectorState.CheckedBefore;
      profile_1.wtfLeave(s);
    };
    AppView.prototype.detectChangesInternal = function(throwOnChange) {
      this.detectContentChildrenChanges(throwOnChange);
      this.detectViewChildrenChanges(throwOnChange);
    };
    AppView.prototype.detectContentChildrenChanges = function(throwOnChange) {
      for (var i = 0; i < this.contentChildren.length; ++i) {
        this.contentChildren[i].detectChanges(throwOnChange);
      }
    };
    AppView.prototype.detectViewChildrenChanges = function(throwOnChange) {
      for (var i = 0; i < this.viewChildren.length; ++i) {
        this.viewChildren[i].detectChanges(throwOnChange);
      }
    };
    AppView.prototype.addToContentChildren = function(renderAppElement) {
      renderAppElement.parentView.contentChildren.push(this);
      this.viewContainerElement = renderAppElement;
      this.dirtyParentQueriesInternal();
    };
    AppView.prototype.removeFromContentChildren = function(renderAppElement) {
      collection_1.ListWrapper.remove(renderAppElement.parentView.contentChildren, this);
      this.dirtyParentQueriesInternal();
      this.viewContainerElement = null;
    };
    AppView.prototype.markAsCheckOnce = function() {
      this.cdMode = change_detection_1.ChangeDetectionStrategy.CheckOnce;
    };
    AppView.prototype.markPathToRootAsCheckOnce = function() {
      var c = this;
      while (lang_1.isPresent(c) && c.cdMode !== change_detection_1.ChangeDetectionStrategy.Detached) {
        if (c.cdMode === change_detection_1.ChangeDetectionStrategy.Checked) {
          c.cdMode = change_detection_1.ChangeDetectionStrategy.CheckOnce;
        }
        var parentEl = c.type === view_type_1.ViewType.COMPONENT ? c.declarationAppElement : c.viewContainerElement;
        c = lang_1.isPresent(parentEl) ? parentEl.parentView : null;
      }
    };
    AppView.prototype.eventHandler = function(cb) {
      return cb;
    };
    AppView.prototype.throwDestroyedError = function(details) {
      throw new exceptions_1.ViewDestroyedException(details);
    };
    return AppView;
  }());
  exports.AppView = AppView;
  var DebugAppView = (function(_super) {
    __extends(DebugAppView, _super);
    function DebugAppView(clazz, componentType, type, viewUtils, parentInjector, declarationAppElement, cdMode, staticNodeDebugInfos) {
      _super.call(this, clazz, componentType, type, viewUtils, parentInjector, declarationAppElement, cdMode);
      this.staticNodeDebugInfos = staticNodeDebugInfos;
      this._currentDebugContext = null;
    }
    DebugAppView.prototype.create = function(context, givenProjectableNodes, rootSelectorOrNode) {
      this._resetDebug();
      try {
        return _super.prototype.create.call(this, context, givenProjectableNodes, rootSelectorOrNode);
      } catch (e) {
        this._rethrowWithContext(e, e.stack);
        throw e;
      }
    };
    DebugAppView.prototype.injectorGet = function(token, nodeIndex, notFoundResult) {
      this._resetDebug();
      try {
        return _super.prototype.injectorGet.call(this, token, nodeIndex, notFoundResult);
      } catch (e) {
        this._rethrowWithContext(e, e.stack);
        throw e;
      }
    };
    DebugAppView.prototype.destroyLocal = function() {
      this._resetDebug();
      try {
        _super.prototype.destroyLocal.call(this);
      } catch (e) {
        this._rethrowWithContext(e, e.stack);
        throw e;
      }
    };
    DebugAppView.prototype.detectChanges = function(throwOnChange) {
      this._resetDebug();
      try {
        _super.prototype.detectChanges.call(this, throwOnChange);
      } catch (e) {
        this._rethrowWithContext(e, e.stack);
        throw e;
      }
    };
    DebugAppView.prototype._resetDebug = function() {
      this._currentDebugContext = null;
    };
    DebugAppView.prototype.debug = function(nodeIndex, rowNum, colNum) {
      return this._currentDebugContext = new debug_context_1.DebugContext(this, nodeIndex, rowNum, colNum);
    };
    DebugAppView.prototype._rethrowWithContext = function(e, stack) {
      if (!(e instanceof exceptions_1.ViewWrappedException)) {
        if (!(e instanceof exceptions_1.ExpressionChangedAfterItHasBeenCheckedException)) {
          this.cdState = change_detection_1.ChangeDetectorState.Errored;
        }
        if (lang_1.isPresent(this._currentDebugContext)) {
          throw new exceptions_1.ViewWrappedException(e, stack, this._currentDebugContext);
        }
      }
    };
    DebugAppView.prototype.eventHandler = function(cb) {
      var _this = this;
      var superHandler = _super.prototype.eventHandler.call(this, cb);
      return function(event) {
        _this._resetDebug();
        try {
          return superHandler(event);
        } catch (e) {
          _this._rethrowWithContext(e, e.stack);
          throw e;
        }
      };
    };
    return DebugAppView;
  }(AppView));
  exports.DebugAppView = DebugAppView;
  function _findLastRenderNode(node) {
    var lastNode;
    if (node instanceof element_1.AppElement) {
      var appEl = node;
      lastNode = appEl.nativeElement;
      if (lang_1.isPresent(appEl.nestedViews)) {
        for (var i = appEl.nestedViews.length - 1; i >= 0; i--) {
          var nestedView = appEl.nestedViews[i];
          if (nestedView.rootNodesOrAppElements.length > 0) {
            lastNode = _findLastRenderNode(nestedView.rootNodesOrAppElements[nestedView.rootNodesOrAppElements.length - 1]);
          }
        }
      }
    } else {
      lastNode = node;
    }
    return lastNode;
  }
  return module.exports;
});

$__System.registerDynamic("288", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(SecurityContext) {
    SecurityContext[SecurityContext["NONE"] = 0] = "NONE";
    SecurityContext[SecurityContext["HTML"] = 1] = "HTML";
    SecurityContext[SecurityContext["STYLE"] = 2] = "STYLE";
    SecurityContext[SecurityContext["SCRIPT"] = 3] = "SCRIPT";
    SecurityContext[SecurityContext["URL"] = 4] = "URL";
    SecurityContext[SecurityContext["RESOURCE_URL"] = 5] = "RESOURCE_URL";
  })(exports.SecurityContext || (exports.SecurityContext = {}));
  var SecurityContext = exports.SecurityContext;
  var SanitizationService = (function() {
    function SanitizationService() {}
    return SanitizationService;
  }());
  exports.SanitizationService = SanitizationService;
  return module.exports;
});

$__System.registerDynamic("259", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ElementRef = (function() {
    function ElementRef(nativeElement) {
      this.nativeElement = nativeElement;
    }
    return ElementRef;
  }());
  exports.ElementRef = ElementRef;
  return module.exports;
});

$__System.registerDynamic("289", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var trace;
  var events;
  function detectWTF() {
    var wtf = lang_1.global['wtf'];
    if (wtf) {
      trace = wtf['trace'];
      if (trace) {
        events = trace['events'];
        return true;
      }
    }
    return false;
  }
  exports.detectWTF = detectWTF;
  function createScope(signature, flags) {
    if (flags === void 0) {
      flags = null;
    }
    return events.createScope(signature, flags);
  }
  exports.createScope = createScope;
  function leave(scope, returnValue) {
    trace.leaveScope(scope, returnValue);
    return returnValue;
  }
  exports.leave = leave;
  function startTimeRange(rangeType, action) {
    return trace.beginTimeRange(rangeType, action);
  }
  exports.startTimeRange = startTimeRange;
  function endTimeRange(range) {
    trace.endTimeRange(range);
  }
  exports.endTimeRange = endTimeRange;
  return module.exports;
});

$__System.registerDynamic("26c", ["289"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var impl = $__require('289');
  exports.wtfEnabled = impl.detectWTF();
  function noopScope(arg0, arg1) {
    return null;
  }
  exports.wtfCreateScope = exports.wtfEnabled ? impl.createScope : function(signature, flags) {
    return noopScope;
  };
  exports.wtfLeave = exports.wtfEnabled ? impl.leave : function(s, r) {
    return r;
  };
  exports.wtfStartTimeRange = exports.wtfEnabled ? impl.startTimeRange : function(rangeType, action) {
    return null;
  };
  exports.wtfEndTimeRange = exports.wtfEnabled ? impl.endTimeRange : function(r) {
    return null;
  };
  return module.exports;
});

$__System.registerDynamic("25c", ["254", "a9", "9c", "26c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('254');
  var exceptions_1 = $__require('a9');
  var lang_1 = $__require('9c');
  var profile_1 = $__require('26c');
  var ViewContainerRef = (function() {
    function ViewContainerRef() {}
    Object.defineProperty(ViewContainerRef.prototype, "element", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef.prototype, "injector", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef.prototype, "parentInjector", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef.prototype, "length", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    ;
    return ViewContainerRef;
  }());
  exports.ViewContainerRef = ViewContainerRef;
  var ViewContainerRef_ = (function() {
    function ViewContainerRef_(_element) {
      this._element = _element;
      this._createComponentInContainerScope = profile_1.wtfCreateScope('ViewContainerRef#createComponent()');
      this._insertScope = profile_1.wtfCreateScope('ViewContainerRef#insert()');
      this._removeScope = profile_1.wtfCreateScope('ViewContainerRef#remove()');
      this._detachScope = profile_1.wtfCreateScope('ViewContainerRef#detach()');
    }
    ViewContainerRef_.prototype.get = function(index) {
      return this._element.nestedViews[index].ref;
    };
    Object.defineProperty(ViewContainerRef_.prototype, "length", {
      get: function() {
        var views = this._element.nestedViews;
        return lang_1.isPresent(views) ? views.length : 0;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef_.prototype, "element", {
      get: function() {
        return this._element.elementRef;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef_.prototype, "injector", {
      get: function() {
        return this._element.injector;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(ViewContainerRef_.prototype, "parentInjector", {
      get: function() {
        return this._element.parentInjector;
      },
      enumerable: true,
      configurable: true
    });
    ViewContainerRef_.prototype.createEmbeddedView = function(templateRef, context, index) {
      if (context === void 0) {
        context = null;
      }
      if (index === void 0) {
        index = -1;
      }
      var viewRef = templateRef.createEmbeddedView(context);
      this.insert(viewRef, index);
      return viewRef;
    };
    ViewContainerRef_.prototype.createComponent = function(componentFactory, index, injector, projectableNodes) {
      if (index === void 0) {
        index = -1;
      }
      if (injector === void 0) {
        injector = null;
      }
      if (projectableNodes === void 0) {
        projectableNodes = null;
      }
      var s = this._createComponentInContainerScope();
      var contextInjector = lang_1.isPresent(injector) ? injector : this._element.parentInjector;
      var componentRef = componentFactory.create(contextInjector, projectableNodes);
      this.insert(componentRef.hostView, index);
      return profile_1.wtfLeave(s, componentRef);
    };
    ViewContainerRef_.prototype.insert = function(viewRef, index) {
      if (index === void 0) {
        index = -1;
      }
      var s = this._insertScope();
      if (index == -1)
        index = this.length;
      var viewRef_ = viewRef;
      this._element.attachView(viewRef_.internalView, index);
      return profile_1.wtfLeave(s, viewRef_);
    };
    ViewContainerRef_.prototype.indexOf = function(viewRef) {
      return collection_1.ListWrapper.indexOf(this._element.nestedViews, viewRef.internalView);
    };
    ViewContainerRef_.prototype.remove = function(index) {
      if (index === void 0) {
        index = -1;
      }
      var s = this._removeScope();
      if (index == -1)
        index = this.length - 1;
      var view = this._element.detachView(index);
      view.destroy();
      profile_1.wtfLeave(s);
    };
    ViewContainerRef_.prototype.detach = function(index) {
      if (index === void 0) {
        index = -1;
      }
      var s = this._detachScope();
      if (index == -1)
        index = this.length - 1;
      var view = this._element.detachView(index);
      return profile_1.wtfLeave(s, view.ref);
    };
    ViewContainerRef_.prototype.clear = function() {
      for (var i = this.length - 1; i >= 0; i--) {
        this.remove(i);
      }
    };
    return ViewContainerRef_;
  }());
  exports.ViewContainerRef_ = ViewContainerRef_;
  return module.exports;
});

$__System.registerDynamic("285", ["9c", "254", "a9", "286", "259", "25c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var exceptions_1 = $__require('a9');
  var view_type_1 = $__require('286');
  var element_ref_1 = $__require('259');
  var view_container_ref_1 = $__require('25c');
  var AppElement = (function() {
    function AppElement(index, parentIndex, parentView, nativeElement) {
      this.index = index;
      this.parentIndex = parentIndex;
      this.parentView = parentView;
      this.nativeElement = nativeElement;
      this.nestedViews = null;
      this.componentView = null;
    }
    Object.defineProperty(AppElement.prototype, "elementRef", {
      get: function() {
        return new element_ref_1.ElementRef(this.nativeElement);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AppElement.prototype, "vcRef", {
      get: function() {
        return new view_container_ref_1.ViewContainerRef_(this);
      },
      enumerable: true,
      configurable: true
    });
    AppElement.prototype.initComponent = function(component, componentConstructorViewQueries, view) {
      this.component = component;
      this.componentConstructorViewQueries = componentConstructorViewQueries;
      this.componentView = view;
    };
    Object.defineProperty(AppElement.prototype, "parentInjector", {
      get: function() {
        return this.parentView.injector(this.parentIndex);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(AppElement.prototype, "injector", {
      get: function() {
        return this.parentView.injector(this.index);
      },
      enumerable: true,
      configurable: true
    });
    AppElement.prototype.mapNestedViews = function(nestedViewClass, callback) {
      var result = [];
      if (lang_1.isPresent(this.nestedViews)) {
        this.nestedViews.forEach(function(nestedView) {
          if (nestedView.clazz === nestedViewClass) {
            result.push(callback(nestedView));
          }
        });
      }
      return result;
    };
    AppElement.prototype.attachView = function(view, viewIndex) {
      if (view.type === view_type_1.ViewType.COMPONENT) {
        throw new exceptions_1.BaseException("Component views can't be moved!");
      }
      var nestedViews = this.nestedViews;
      if (nestedViews == null) {
        nestedViews = [];
        this.nestedViews = nestedViews;
      }
      collection_1.ListWrapper.insert(nestedViews, viewIndex, view);
      var refRenderNode;
      if (viewIndex > 0) {
        var prevView = nestedViews[viewIndex - 1];
        refRenderNode = prevView.lastRootNode;
      } else {
        refRenderNode = this.nativeElement;
      }
      if (lang_1.isPresent(refRenderNode)) {
        view.renderer.attachViewAfter(refRenderNode, view.flatRootNodes);
      }
      view.addToContentChildren(this);
    };
    AppElement.prototype.detachView = function(viewIndex) {
      var view = collection_1.ListWrapper.removeAt(this.nestedViews, viewIndex);
      if (view.type === view_type_1.ViewType.COMPONENT) {
        throw new exceptions_1.BaseException("Component views can't be moved!");
      }
      view.renderer.detachView(view.flatRootNodes);
      view.removeFromContentChildren(this);
      return view;
    };
    return AppElement;
  }());
  exports.AppElement = AppElement;
  return module.exports;
});

$__System.registerDynamic("25e", ["a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var exceptions_1 = $__require('a9');
  var ExpressionChangedAfterItHasBeenCheckedException = (function(_super) {
    __extends(ExpressionChangedAfterItHasBeenCheckedException, _super);
    function ExpressionChangedAfterItHasBeenCheckedException(oldValue, currValue, context) {
      _super.call(this, "Expression has changed after it was checked. " + ("Previous value: '" + oldValue + "'. Current value: '" + currValue + "'"));
    }
    return ExpressionChangedAfterItHasBeenCheckedException;
  }(exceptions_1.BaseException));
  exports.ExpressionChangedAfterItHasBeenCheckedException = ExpressionChangedAfterItHasBeenCheckedException;
  var ViewWrappedException = (function(_super) {
    __extends(ViewWrappedException, _super);
    function ViewWrappedException(originalException, originalStack, context) {
      _super.call(this, "Error in " + context.source, originalException, originalStack, context);
    }
    return ViewWrappedException;
  }(exceptions_1.WrappedException));
  exports.ViewWrappedException = ViewWrappedException;
  var ViewDestroyedException = (function(_super) {
    __extends(ViewDestroyedException, _super);
    function ViewDestroyedException(details) {
      _super.call(this, "Attempt to use a destroyed view: " + details);
    }
    return ViewDestroyedException;
  }(exceptions_1.BaseException));
  exports.ViewDestroyedException = ViewDestroyedException;
  return module.exports;
});

$__System.registerDynamic("28a", ["9c", "a9", "254", "262"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var collection_1 = $__require('254');
  var di_1 = $__require('262');
  var IterableDiffers = (function() {
    function IterableDiffers(factories) {
      this.factories = factories;
    }
    IterableDiffers.create = function(factories, parent) {
      if (lang_1.isPresent(parent)) {
        var copied = collection_1.ListWrapper.clone(parent.factories);
        factories = factories.concat(copied);
        return new IterableDiffers(factories);
      } else {
        return new IterableDiffers(factories);
      }
    };
    IterableDiffers.extend = function(factories) {
      return new di_1.Provider(IterableDiffers, {
        useFactory: function(parent) {
          if (lang_1.isBlank(parent)) {
            throw new exceptions_1.BaseException('Cannot extend IterableDiffers without a parent injector');
          }
          return IterableDiffers.create(factories, parent);
        },
        deps: [[IterableDiffers, new di_1.SkipSelfMetadata(), new di_1.OptionalMetadata()]]
      });
    };
    IterableDiffers.prototype.find = function(iterable) {
      var factory = this.factories.find(function(f) {
        return f.supports(iterable);
      });
      if (lang_1.isPresent(factory)) {
        return factory;
      } else {
        throw new exceptions_1.BaseException("Cannot find a differ supporting object '" + iterable + "' of type '" + lang_1.getTypeNameForDebugging(iterable) + "'");
      }
    };
    return IterableDiffers;
  }());
  exports.IterableDiffers = IterableDiffers;
  return module.exports;
});

$__System.registerDynamic("28b", ["a9", "254", "9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var exceptions_1 = $__require('a9');
  var collection_1 = $__require('254');
  var lang_1 = $__require('9c');
  var DefaultIterableDifferFactory = (function() {
    function DefaultIterableDifferFactory() {}
    DefaultIterableDifferFactory.prototype.supports = function(obj) {
      return collection_1.isListLikeIterable(obj);
    };
    DefaultIterableDifferFactory.prototype.create = function(cdRef, trackByFn) {
      return new DefaultIterableDiffer(trackByFn);
    };
    return DefaultIterableDifferFactory;
  }());
  exports.DefaultIterableDifferFactory = DefaultIterableDifferFactory;
  var trackByIdentity = function(index, item) {
    return item;
  };
  var DefaultIterableDiffer = (function() {
    function DefaultIterableDiffer(_trackByFn) {
      this._trackByFn = _trackByFn;
      this._length = null;
      this._collection = null;
      this._linkedRecords = null;
      this._unlinkedRecords = null;
      this._previousItHead = null;
      this._itHead = null;
      this._itTail = null;
      this._additionsHead = null;
      this._additionsTail = null;
      this._movesHead = null;
      this._movesTail = null;
      this._removalsHead = null;
      this._removalsTail = null;
      this._identityChangesHead = null;
      this._identityChangesTail = null;
      this._trackByFn = lang_1.isPresent(this._trackByFn) ? this._trackByFn : trackByIdentity;
    }
    Object.defineProperty(DefaultIterableDiffer.prototype, "collection", {
      get: function() {
        return this._collection;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DefaultIterableDiffer.prototype, "length", {
      get: function() {
        return this._length;
      },
      enumerable: true,
      configurable: true
    });
    DefaultIterableDiffer.prototype.forEachItem = function(fn) {
      var record;
      for (record = this._itHead; record !== null; record = record._next) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.forEachPreviousItem = function(fn) {
      var record;
      for (record = this._previousItHead; record !== null; record = record._nextPrevious) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.forEachAddedItem = function(fn) {
      var record;
      for (record = this._additionsHead; record !== null; record = record._nextAdded) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.forEachMovedItem = function(fn) {
      var record;
      for (record = this._movesHead; record !== null; record = record._nextMoved) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.forEachRemovedItem = function(fn) {
      var record;
      for (record = this._removalsHead; record !== null; record = record._nextRemoved) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.forEachIdentityChange = function(fn) {
      var record;
      for (record = this._identityChangesHead; record !== null; record = record._nextIdentityChange) {
        fn(record);
      }
    };
    DefaultIterableDiffer.prototype.diff = function(collection) {
      if (lang_1.isBlank(collection))
        collection = [];
      if (!collection_1.isListLikeIterable(collection)) {
        throw new exceptions_1.BaseException("Error trying to diff '" + collection + "'");
      }
      if (this.check(collection)) {
        return this;
      } else {
        return null;
      }
    };
    DefaultIterableDiffer.prototype.onDestroy = function() {};
    DefaultIterableDiffer.prototype.check = function(collection) {
      var _this = this;
      this._reset();
      var record = this._itHead;
      var mayBeDirty = false;
      var index;
      var item;
      var itemTrackBy;
      if (lang_1.isArray(collection)) {
        var list = collection;
        this._length = collection.length;
        for (index = 0; index < this._length; index++) {
          item = list[index];
          itemTrackBy = this._trackByFn(index, item);
          if (record === null || !lang_1.looseIdentical(record.trackById, itemTrackBy)) {
            record = this._mismatch(record, item, itemTrackBy, index);
            mayBeDirty = true;
          } else {
            if (mayBeDirty) {
              record = this._verifyReinsertion(record, item, itemTrackBy, index);
            }
            if (!lang_1.looseIdentical(record.item, item))
              this._addIdentityChange(record, item);
          }
          record = record._next;
        }
      } else {
        index = 0;
        collection_1.iterateListLike(collection, function(item) {
          itemTrackBy = _this._trackByFn(index, item);
          if (record === null || !lang_1.looseIdentical(record.trackById, itemTrackBy)) {
            record = _this._mismatch(record, item, itemTrackBy, index);
            mayBeDirty = true;
          } else {
            if (mayBeDirty) {
              record = _this._verifyReinsertion(record, item, itemTrackBy, index);
            }
            if (!lang_1.looseIdentical(record.item, item))
              _this._addIdentityChange(record, item);
          }
          record = record._next;
          index++;
        });
        this._length = index;
      }
      this._truncate(record);
      this._collection = collection;
      return this.isDirty;
    };
    Object.defineProperty(DefaultIterableDiffer.prototype, "isDirty", {
      get: function() {
        return this._additionsHead !== null || this._movesHead !== null || this._removalsHead !== null || this._identityChangesHead !== null;
      },
      enumerable: true,
      configurable: true
    });
    DefaultIterableDiffer.prototype._reset = function() {
      if (this.isDirty) {
        var record;
        var nextRecord;
        for (record = this._previousItHead = this._itHead; record !== null; record = record._next) {
          record._nextPrevious = record._next;
        }
        for (record = this._additionsHead; record !== null; record = record._nextAdded) {
          record.previousIndex = record.currentIndex;
        }
        this._additionsHead = this._additionsTail = null;
        for (record = this._movesHead; record !== null; record = nextRecord) {
          record.previousIndex = record.currentIndex;
          nextRecord = record._nextMoved;
        }
        this._movesHead = this._movesTail = null;
        this._removalsHead = this._removalsTail = null;
        this._identityChangesHead = this._identityChangesTail = null;
      }
    };
    DefaultIterableDiffer.prototype._mismatch = function(record, item, itemTrackBy, index) {
      var previousRecord;
      if (record === null) {
        previousRecord = this._itTail;
      } else {
        previousRecord = record._prev;
        this._remove(record);
      }
      record = this._linkedRecords === null ? null : this._linkedRecords.get(itemTrackBy, index);
      if (record !== null) {
        if (!lang_1.looseIdentical(record.item, item))
          this._addIdentityChange(record, item);
        this._moveAfter(record, previousRecord, index);
      } else {
        record = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy);
        if (record !== null) {
          if (!lang_1.looseIdentical(record.item, item))
            this._addIdentityChange(record, item);
          this._reinsertAfter(record, previousRecord, index);
        } else {
          record = this._addAfter(new CollectionChangeRecord(item, itemTrackBy), previousRecord, index);
        }
      }
      return record;
    };
    DefaultIterableDiffer.prototype._verifyReinsertion = function(record, item, itemTrackBy, index) {
      var reinsertRecord = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy);
      if (reinsertRecord !== null) {
        record = this._reinsertAfter(reinsertRecord, record._prev, index);
      } else if (record.currentIndex != index) {
        record.currentIndex = index;
        this._addToMoves(record, index);
      }
      return record;
    };
    DefaultIterableDiffer.prototype._truncate = function(record) {
      while (record !== null) {
        var nextRecord = record._next;
        this._addToRemovals(this._unlink(record));
        record = nextRecord;
      }
      if (this._unlinkedRecords !== null) {
        this._unlinkedRecords.clear();
      }
      if (this._additionsTail !== null) {
        this._additionsTail._nextAdded = null;
      }
      if (this._movesTail !== null) {
        this._movesTail._nextMoved = null;
      }
      if (this._itTail !== null) {
        this._itTail._next = null;
      }
      if (this._removalsTail !== null) {
        this._removalsTail._nextRemoved = null;
      }
      if (this._identityChangesTail !== null) {
        this._identityChangesTail._nextIdentityChange = null;
      }
    };
    DefaultIterableDiffer.prototype._reinsertAfter = function(record, prevRecord, index) {
      if (this._unlinkedRecords !== null) {
        this._unlinkedRecords.remove(record);
      }
      var prev = record._prevRemoved;
      var next = record._nextRemoved;
      if (prev === null) {
        this._removalsHead = next;
      } else {
        prev._nextRemoved = next;
      }
      if (next === null) {
        this._removalsTail = prev;
      } else {
        next._prevRemoved = prev;
      }
      this._insertAfter(record, prevRecord, index);
      this._addToMoves(record, index);
      return record;
    };
    DefaultIterableDiffer.prototype._moveAfter = function(record, prevRecord, index) {
      this._unlink(record);
      this._insertAfter(record, prevRecord, index);
      this._addToMoves(record, index);
      return record;
    };
    DefaultIterableDiffer.prototype._addAfter = function(record, prevRecord, index) {
      this._insertAfter(record, prevRecord, index);
      if (this._additionsTail === null) {
        this._additionsTail = this._additionsHead = record;
      } else {
        this._additionsTail = this._additionsTail._nextAdded = record;
      }
      return record;
    };
    DefaultIterableDiffer.prototype._insertAfter = function(record, prevRecord, index) {
      var next = prevRecord === null ? this._itHead : prevRecord._next;
      record._next = next;
      record._prev = prevRecord;
      if (next === null) {
        this._itTail = record;
      } else {
        next._prev = record;
      }
      if (prevRecord === null) {
        this._itHead = record;
      } else {
        prevRecord._next = record;
      }
      if (this._linkedRecords === null) {
        this._linkedRecords = new _DuplicateMap();
      }
      this._linkedRecords.put(record);
      record.currentIndex = index;
      return record;
    };
    DefaultIterableDiffer.prototype._remove = function(record) {
      return this._addToRemovals(this._unlink(record));
    };
    DefaultIterableDiffer.prototype._unlink = function(record) {
      if (this._linkedRecords !== null) {
        this._linkedRecords.remove(record);
      }
      var prev = record._prev;
      var next = record._next;
      if (prev === null) {
        this._itHead = next;
      } else {
        prev._next = next;
      }
      if (next === null) {
        this._itTail = prev;
      } else {
        next._prev = prev;
      }
      return record;
    };
    DefaultIterableDiffer.prototype._addToMoves = function(record, toIndex) {
      if (record.previousIndex === toIndex) {
        return record;
      }
      if (this._movesTail === null) {
        this._movesTail = this._movesHead = record;
      } else {
        this._movesTail = this._movesTail._nextMoved = record;
      }
      return record;
    };
    DefaultIterableDiffer.prototype._addToRemovals = function(record) {
      if (this._unlinkedRecords === null) {
        this._unlinkedRecords = new _DuplicateMap();
      }
      this._unlinkedRecords.put(record);
      record.currentIndex = null;
      record._nextRemoved = null;
      if (this._removalsTail === null) {
        this._removalsTail = this._removalsHead = record;
        record._prevRemoved = null;
      } else {
        record._prevRemoved = this._removalsTail;
        this._removalsTail = this._removalsTail._nextRemoved = record;
      }
      return record;
    };
    DefaultIterableDiffer.prototype._addIdentityChange = function(record, item) {
      record.item = item;
      if (this._identityChangesTail === null) {
        this._identityChangesTail = this._identityChangesHead = record;
      } else {
        this._identityChangesTail = this._identityChangesTail._nextIdentityChange = record;
      }
      return record;
    };
    DefaultIterableDiffer.prototype.toString = function() {
      var list = [];
      this.forEachItem(function(record) {
        return list.push(record);
      });
      var previous = [];
      this.forEachPreviousItem(function(record) {
        return previous.push(record);
      });
      var additions = [];
      this.forEachAddedItem(function(record) {
        return additions.push(record);
      });
      var moves = [];
      this.forEachMovedItem(function(record) {
        return moves.push(record);
      });
      var removals = [];
      this.forEachRemovedItem(function(record) {
        return removals.push(record);
      });
      var identityChanges = [];
      this.forEachIdentityChange(function(record) {
        return identityChanges.push(record);
      });
      return "collection: " + list.join(', ') + "\n" + "previous: " + previous.join(', ') + "\n" + "additions: " + additions.join(', ') + "\n" + "moves: " + moves.join(', ') + "\n" + "removals: " + removals.join(', ') + "\n" + "identityChanges: " + identityChanges.join(', ') + "\n";
    };
    return DefaultIterableDiffer;
  }());
  exports.DefaultIterableDiffer = DefaultIterableDiffer;
  var CollectionChangeRecord = (function() {
    function CollectionChangeRecord(item, trackById) {
      this.item = item;
      this.trackById = trackById;
      this.currentIndex = null;
      this.previousIndex = null;
      this._nextPrevious = null;
      this._prev = null;
      this._next = null;
      this._prevDup = null;
      this._nextDup = null;
      this._prevRemoved = null;
      this._nextRemoved = null;
      this._nextAdded = null;
      this._nextMoved = null;
      this._nextIdentityChange = null;
    }
    CollectionChangeRecord.prototype.toString = function() {
      return this.previousIndex === this.currentIndex ? lang_1.stringify(this.item) : lang_1.stringify(this.item) + '[' + lang_1.stringify(this.previousIndex) + '->' + lang_1.stringify(this.currentIndex) + ']';
    };
    return CollectionChangeRecord;
  }());
  exports.CollectionChangeRecord = CollectionChangeRecord;
  var _DuplicateItemRecordList = (function() {
    function _DuplicateItemRecordList() {
      this._head = null;
      this._tail = null;
    }
    _DuplicateItemRecordList.prototype.add = function(record) {
      if (this._head === null) {
        this._head = this._tail = record;
        record._nextDup = null;
        record._prevDup = null;
      } else {
        this._tail._nextDup = record;
        record._prevDup = this._tail;
        record._nextDup = null;
        this._tail = record;
      }
    };
    _DuplicateItemRecordList.prototype.get = function(trackById, afterIndex) {
      var record;
      for (record = this._head; record !== null; record = record._nextDup) {
        if ((afterIndex === null || afterIndex < record.currentIndex) && lang_1.looseIdentical(record.trackById, trackById)) {
          return record;
        }
      }
      return null;
    };
    _DuplicateItemRecordList.prototype.remove = function(record) {
      var prev = record._prevDup;
      var next = record._nextDup;
      if (prev === null) {
        this._head = next;
      } else {
        prev._nextDup = next;
      }
      if (next === null) {
        this._tail = prev;
      } else {
        next._prevDup = prev;
      }
      return this._head === null;
    };
    return _DuplicateItemRecordList;
  }());
  var _DuplicateMap = (function() {
    function _DuplicateMap() {
      this.map = new Map();
    }
    _DuplicateMap.prototype.put = function(record) {
      var key = lang_1.getMapKey(record.trackById);
      var duplicates = this.map.get(key);
      if (!lang_1.isPresent(duplicates)) {
        duplicates = new _DuplicateItemRecordList();
        this.map.set(key, duplicates);
      }
      duplicates.add(record);
    };
    _DuplicateMap.prototype.get = function(trackById, afterIndex) {
      if (afterIndex === void 0) {
        afterIndex = null;
      }
      var key = lang_1.getMapKey(trackById);
      var recordList = this.map.get(key);
      return lang_1.isBlank(recordList) ? null : recordList.get(trackById, afterIndex);
    };
    _DuplicateMap.prototype.remove = function(record) {
      var key = lang_1.getMapKey(record.trackById);
      var recordList = this.map.get(key);
      if (recordList.remove(record)) {
        this.map.delete(key);
      }
      return record;
    };
    Object.defineProperty(_DuplicateMap.prototype, "isEmpty", {
      get: function() {
        return this.map.size === 0;
      },
      enumerable: true,
      configurable: true
    });
    _DuplicateMap.prototype.clear = function() {
      this.map.clear();
    };
    _DuplicateMap.prototype.toString = function() {
      return '_DuplicateMap(' + lang_1.stringify(this.map) + ')';
    };
    return _DuplicateMap;
  }());
  return module.exports;
});

$__System.registerDynamic("28c", ["9c", "a9", "254", "262"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var collection_1 = $__require('254');
  var di_1 = $__require('262');
  var KeyValueDiffers = (function() {
    function KeyValueDiffers(factories) {
      this.factories = factories;
    }
    KeyValueDiffers.create = function(factories, parent) {
      if (lang_1.isPresent(parent)) {
        var copied = collection_1.ListWrapper.clone(parent.factories);
        factories = factories.concat(copied);
        return new KeyValueDiffers(factories);
      } else {
        return new KeyValueDiffers(factories);
      }
    };
    KeyValueDiffers.extend = function(factories) {
      return new di_1.Provider(KeyValueDiffers, {
        useFactory: function(parent) {
          if (lang_1.isBlank(parent)) {
            throw new exceptions_1.BaseException('Cannot extend KeyValueDiffers without a parent injector');
          }
          return KeyValueDiffers.create(factories, parent);
        },
        deps: [[KeyValueDiffers, new di_1.SkipSelfMetadata(), new di_1.OptionalMetadata()]]
      });
    };
    KeyValueDiffers.prototype.find = function(kv) {
      var factory = this.factories.find(function(f) {
        return f.supports(kv);
      });
      if (lang_1.isPresent(factory)) {
        return factory;
      } else {
        throw new exceptions_1.BaseException("Cannot find a differ supporting object '" + kv + "'");
      }
    };
    return KeyValueDiffers;
  }());
  exports.KeyValueDiffers = KeyValueDiffers;
  return module.exports;
});

$__System.registerDynamic("28d", ["254", "9c", "a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var collection_1 = $__require('254');
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var DefaultKeyValueDifferFactory = (function() {
    function DefaultKeyValueDifferFactory() {}
    DefaultKeyValueDifferFactory.prototype.supports = function(obj) {
      return obj instanceof Map || lang_1.isJsObject(obj);
    };
    DefaultKeyValueDifferFactory.prototype.create = function(cdRef) {
      return new DefaultKeyValueDiffer();
    };
    return DefaultKeyValueDifferFactory;
  }());
  exports.DefaultKeyValueDifferFactory = DefaultKeyValueDifferFactory;
  var DefaultKeyValueDiffer = (function() {
    function DefaultKeyValueDiffer() {
      this._records = new Map();
      this._mapHead = null;
      this._previousMapHead = null;
      this._changesHead = null;
      this._changesTail = null;
      this._additionsHead = null;
      this._additionsTail = null;
      this._removalsHead = null;
      this._removalsTail = null;
    }
    Object.defineProperty(DefaultKeyValueDiffer.prototype, "isDirty", {
      get: function() {
        return this._additionsHead !== null || this._changesHead !== null || this._removalsHead !== null;
      },
      enumerable: true,
      configurable: true
    });
    DefaultKeyValueDiffer.prototype.forEachItem = function(fn) {
      var record;
      for (record = this._mapHead; record !== null; record = record._next) {
        fn(record);
      }
    };
    DefaultKeyValueDiffer.prototype.forEachPreviousItem = function(fn) {
      var record;
      for (record = this._previousMapHead; record !== null; record = record._nextPrevious) {
        fn(record);
      }
    };
    DefaultKeyValueDiffer.prototype.forEachChangedItem = function(fn) {
      var record;
      for (record = this._changesHead; record !== null; record = record._nextChanged) {
        fn(record);
      }
    };
    DefaultKeyValueDiffer.prototype.forEachAddedItem = function(fn) {
      var record;
      for (record = this._additionsHead; record !== null; record = record._nextAdded) {
        fn(record);
      }
    };
    DefaultKeyValueDiffer.prototype.forEachRemovedItem = function(fn) {
      var record;
      for (record = this._removalsHead; record !== null; record = record._nextRemoved) {
        fn(record);
      }
    };
    DefaultKeyValueDiffer.prototype.diff = function(map) {
      if (lang_1.isBlank(map))
        map = collection_1.MapWrapper.createFromPairs([]);
      if (!(map instanceof Map || lang_1.isJsObject(map))) {
        throw new exceptions_1.BaseException("Error trying to diff '" + map + "'");
      }
      if (this.check(map)) {
        return this;
      } else {
        return null;
      }
    };
    DefaultKeyValueDiffer.prototype.onDestroy = function() {};
    DefaultKeyValueDiffer.prototype.check = function(map) {
      var _this = this;
      this._reset();
      var records = this._records;
      var oldSeqRecord = this._mapHead;
      var lastOldSeqRecord = null;
      var lastNewSeqRecord = null;
      var seqChanged = false;
      this._forEach(map, function(value, key) {
        var newSeqRecord;
        if (oldSeqRecord !== null && key === oldSeqRecord.key) {
          newSeqRecord = oldSeqRecord;
          if (!lang_1.looseIdentical(value, oldSeqRecord.currentValue)) {
            oldSeqRecord.previousValue = oldSeqRecord.currentValue;
            oldSeqRecord.currentValue = value;
            _this._addToChanges(oldSeqRecord);
          }
        } else {
          seqChanged = true;
          if (oldSeqRecord !== null) {
            oldSeqRecord._next = null;
            _this._removeFromSeq(lastOldSeqRecord, oldSeqRecord);
            _this._addToRemovals(oldSeqRecord);
          }
          if (records.has(key)) {
            newSeqRecord = records.get(key);
          } else {
            newSeqRecord = new KeyValueChangeRecord(key);
            records.set(key, newSeqRecord);
            newSeqRecord.currentValue = value;
            _this._addToAdditions(newSeqRecord);
          }
        }
        if (seqChanged) {
          if (_this._isInRemovals(newSeqRecord)) {
            _this._removeFromRemovals(newSeqRecord);
          }
          if (lastNewSeqRecord == null) {
            _this._mapHead = newSeqRecord;
          } else {
            lastNewSeqRecord._next = newSeqRecord;
          }
        }
        lastOldSeqRecord = oldSeqRecord;
        lastNewSeqRecord = newSeqRecord;
        oldSeqRecord = oldSeqRecord === null ? null : oldSeqRecord._next;
      });
      this._truncate(lastOldSeqRecord, oldSeqRecord);
      return this.isDirty;
    };
    DefaultKeyValueDiffer.prototype._reset = function() {
      if (this.isDirty) {
        var record;
        for (record = this._previousMapHead = this._mapHead; record !== null; record = record._next) {
          record._nextPrevious = record._next;
        }
        for (record = this._changesHead; record !== null; record = record._nextChanged) {
          record.previousValue = record.currentValue;
        }
        for (record = this._additionsHead; record != null; record = record._nextAdded) {
          record.previousValue = record.currentValue;
        }
        this._changesHead = this._changesTail = null;
        this._additionsHead = this._additionsTail = null;
        this._removalsHead = this._removalsTail = null;
      }
    };
    DefaultKeyValueDiffer.prototype._truncate = function(lastRecord, record) {
      while (record !== null) {
        if (lastRecord === null) {
          this._mapHead = null;
        } else {
          lastRecord._next = null;
        }
        var nextRecord = record._next;
        this._addToRemovals(record);
        lastRecord = record;
        record = nextRecord;
      }
      for (var rec = this._removalsHead; rec !== null; rec = rec._nextRemoved) {
        rec.previousValue = rec.currentValue;
        rec.currentValue = null;
        this._records.delete(rec.key);
      }
    };
    DefaultKeyValueDiffer.prototype._isInRemovals = function(record) {
      return record === this._removalsHead || record._nextRemoved !== null || record._prevRemoved !== null;
    };
    DefaultKeyValueDiffer.prototype._addToRemovals = function(record) {
      if (this._removalsHead === null) {
        this._removalsHead = this._removalsTail = record;
      } else {
        this._removalsTail._nextRemoved = record;
        record._prevRemoved = this._removalsTail;
        this._removalsTail = record;
      }
    };
    DefaultKeyValueDiffer.prototype._removeFromSeq = function(prev, record) {
      var next = record._next;
      if (prev === null) {
        this._mapHead = next;
      } else {
        prev._next = next;
      }
    };
    DefaultKeyValueDiffer.prototype._removeFromRemovals = function(record) {
      var prev = record._prevRemoved;
      var next = record._nextRemoved;
      if (prev === null) {
        this._removalsHead = next;
      } else {
        prev._nextRemoved = next;
      }
      if (next === null) {
        this._removalsTail = prev;
      } else {
        next._prevRemoved = prev;
      }
      record._prevRemoved = record._nextRemoved = null;
    };
    DefaultKeyValueDiffer.prototype._addToAdditions = function(record) {
      if (this._additionsHead === null) {
        this._additionsHead = this._additionsTail = record;
      } else {
        this._additionsTail._nextAdded = record;
        this._additionsTail = record;
      }
    };
    DefaultKeyValueDiffer.prototype._addToChanges = function(record) {
      if (this._changesHead === null) {
        this._changesHead = this._changesTail = record;
      } else {
        this._changesTail._nextChanged = record;
        this._changesTail = record;
      }
    };
    DefaultKeyValueDiffer.prototype.toString = function() {
      var items = [];
      var previous = [];
      var changes = [];
      var additions = [];
      var removals = [];
      var record;
      for (record = this._mapHead; record !== null; record = record._next) {
        items.push(lang_1.stringify(record));
      }
      for (record = this._previousMapHead; record !== null; record = record._nextPrevious) {
        previous.push(lang_1.stringify(record));
      }
      for (record = this._changesHead; record !== null; record = record._nextChanged) {
        changes.push(lang_1.stringify(record));
      }
      for (record = this._additionsHead; record !== null; record = record._nextAdded) {
        additions.push(lang_1.stringify(record));
      }
      for (record = this._removalsHead; record !== null; record = record._nextRemoved) {
        removals.push(lang_1.stringify(record));
      }
      return "map: " + items.join(', ') + "\n" + "previous: " + previous.join(', ') + "\n" + "additions: " + additions.join(', ') + "\n" + "changes: " + changes.join(', ') + "\n" + "removals: " + removals.join(', ') + "\n";
    };
    DefaultKeyValueDiffer.prototype._forEach = function(obj, fn) {
      if (obj instanceof Map) {
        obj.forEach(fn);
      } else {
        collection_1.StringMapWrapper.forEach(obj, fn);
      }
    };
    return DefaultKeyValueDiffer;
  }());
  exports.DefaultKeyValueDiffer = DefaultKeyValueDiffer;
  var KeyValueChangeRecord = (function() {
    function KeyValueChangeRecord(key) {
      this.key = key;
      this.previousValue = null;
      this.currentValue = null;
      this._nextPrevious = null;
      this._next = null;
      this._nextAdded = null;
      this._nextRemoved = null;
      this._prevRemoved = null;
      this._nextChanged = null;
    }
    KeyValueChangeRecord.prototype.toString = function() {
      return lang_1.looseIdentical(this.previousValue, this.currentValue) ? lang_1.stringify(this.key) : (lang_1.stringify(this.key) + '[' + lang_1.stringify(this.previousValue) + '->' + lang_1.stringify(this.currentValue) + ']');
    };
    return KeyValueChangeRecord;
  }());
  exports.KeyValueChangeRecord = KeyValueChangeRecord;
  return module.exports;
});

$__System.registerDynamic("24a", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  (function(ChangeDetectorState) {
    ChangeDetectorState[ChangeDetectorState["NeverChecked"] = 0] = "NeverChecked";
    ChangeDetectorState[ChangeDetectorState["CheckedBefore"] = 1] = "CheckedBefore";
    ChangeDetectorState[ChangeDetectorState["Errored"] = 2] = "Errored";
  })(exports.ChangeDetectorState || (exports.ChangeDetectorState = {}));
  var ChangeDetectorState = exports.ChangeDetectorState;
  (function(ChangeDetectionStrategy) {
    ChangeDetectionStrategy[ChangeDetectionStrategy["CheckOnce"] = 0] = "CheckOnce";
    ChangeDetectionStrategy[ChangeDetectionStrategy["Checked"] = 1] = "Checked";
    ChangeDetectionStrategy[ChangeDetectionStrategy["CheckAlways"] = 2] = "CheckAlways";
    ChangeDetectionStrategy[ChangeDetectionStrategy["Detached"] = 3] = "Detached";
    ChangeDetectionStrategy[ChangeDetectionStrategy["OnPush"] = 4] = "OnPush";
    ChangeDetectionStrategy[ChangeDetectionStrategy["Default"] = 5] = "Default";
  })(exports.ChangeDetectionStrategy || (exports.ChangeDetectionStrategy = {}));
  var ChangeDetectionStrategy = exports.ChangeDetectionStrategy;
  exports.CHANGE_DETECTION_STRATEGY_VALUES = [ChangeDetectionStrategy.CheckOnce, ChangeDetectionStrategy.Checked, ChangeDetectionStrategy.CheckAlways, ChangeDetectionStrategy.Detached, ChangeDetectionStrategy.OnPush, ChangeDetectionStrategy.Default];
  exports.CHANGE_DETECTOR_STATE_VALUES = [ChangeDetectorState.NeverChecked, ChangeDetectorState.CheckedBefore, ChangeDetectorState.Errored];
  function isDefaultChangeDetectionStrategy(changeDetectionStrategy) {
    return lang_1.isBlank(changeDetectionStrategy) || changeDetectionStrategy === ChangeDetectionStrategy.Default;
  }
  exports.isDefaultChangeDetectionStrategy = isDefaultChangeDetectionStrategy;
  return module.exports;
});

$__System.registerDynamic("28e", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ChangeDetectorRef = (function() {
    function ChangeDetectorRef() {}
    return ChangeDetectorRef;
  }());
  exports.ChangeDetectorRef = ChangeDetectorRef;
  return module.exports;
});

$__System.registerDynamic("260", ["28a", "28b", "28c", "28d", "24a", "28e", "28f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var iterable_differs_1 = $__require('28a');
  var default_iterable_differ_1 = $__require('28b');
  var keyvalue_differs_1 = $__require('28c');
  var default_keyvalue_differ_1 = $__require('28d');
  var default_keyvalue_differ_2 = $__require('28d');
  exports.DefaultKeyValueDifferFactory = default_keyvalue_differ_2.DefaultKeyValueDifferFactory;
  exports.KeyValueChangeRecord = default_keyvalue_differ_2.KeyValueChangeRecord;
  var default_iterable_differ_2 = $__require('28b');
  exports.DefaultIterableDifferFactory = default_iterable_differ_2.DefaultIterableDifferFactory;
  exports.CollectionChangeRecord = default_iterable_differ_2.CollectionChangeRecord;
  var constants_1 = $__require('24a');
  exports.ChangeDetectionStrategy = constants_1.ChangeDetectionStrategy;
  exports.CHANGE_DETECTION_STRATEGY_VALUES = constants_1.CHANGE_DETECTION_STRATEGY_VALUES;
  exports.ChangeDetectorState = constants_1.ChangeDetectorState;
  exports.CHANGE_DETECTOR_STATE_VALUES = constants_1.CHANGE_DETECTOR_STATE_VALUES;
  exports.isDefaultChangeDetectionStrategy = constants_1.isDefaultChangeDetectionStrategy;
  var change_detector_ref_1 = $__require('28e');
  exports.ChangeDetectorRef = change_detector_ref_1.ChangeDetectorRef;
  var iterable_differs_2 = $__require('28a');
  exports.IterableDiffers = iterable_differs_2.IterableDiffers;
  var keyvalue_differs_2 = $__require('28c');
  exports.KeyValueDiffers = keyvalue_differs_2.KeyValueDiffers;
  var default_iterable_differ_3 = $__require('28b');
  exports.DefaultIterableDiffer = default_iterable_differ_3.DefaultIterableDiffer;
  var change_detection_util_1 = $__require('28f');
  exports.WrappedValue = change_detection_util_1.WrappedValue;
  exports.ValueUnwrapper = change_detection_util_1.ValueUnwrapper;
  exports.SimpleChange = change_detection_util_1.SimpleChange;
  exports.devModeEqual = change_detection_util_1.devModeEqual;
  exports.looseIdentical = change_detection_util_1.looseIdentical;
  exports.uninitialized = change_detection_util_1.uninitialized;
  exports.keyValDiff = [new default_keyvalue_differ_1.DefaultKeyValueDifferFactory()];
  exports.iterableDiff = [new default_iterable_differ_1.DefaultIterableDifferFactory()];
  exports.defaultIterableDiffers = new iterable_differs_1.IterableDiffers(exports.iterableDiff);
  exports.defaultKeyValueDiffers = new keyvalue_differs_1.KeyValueDiffers(exports.keyValDiff);
  return module.exports;
});

$__System.registerDynamic("283", ["a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var exceptions_1 = $__require('a9');
  var _THROW_IF_NOT_FOUND = new Object();
  exports.THROW_IF_NOT_FOUND = _THROW_IF_NOT_FOUND;
  var Injector = (function() {
    function Injector() {}
    Injector.prototype.get = function(token, notFoundValue) {
      return exceptions_1.unimplemented();
    };
    Injector.THROW_IF_NOT_FOUND = _THROW_IF_NOT_FOUND;
    return Injector;
  }());
  exports.Injector = Injector;
  return module.exports;
});

$__System.registerDynamic("26d", ["254", "290", "291", "a9", "292", "247", "283", "22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    var collection_1 = $__require('254');
    var reflective_provider_1 = $__require('290');
    var reflective_exceptions_1 = $__require('291');
    var exceptions_1 = $__require('a9');
    var reflective_key_1 = $__require('292');
    var metadata_1 = $__require('247');
    var injector_1 = $__require('283');
    var __unused;
    var _MAX_CONSTRUCTION_COUNTER = 10;
    var UNDEFINED = new Object();
    var ReflectiveProtoInjectorInlineStrategy = (function() {
      function ReflectiveProtoInjectorInlineStrategy(protoEI, providers) {
        this.provider0 = null;
        this.provider1 = null;
        this.provider2 = null;
        this.provider3 = null;
        this.provider4 = null;
        this.provider5 = null;
        this.provider6 = null;
        this.provider7 = null;
        this.provider8 = null;
        this.provider9 = null;
        this.keyId0 = null;
        this.keyId1 = null;
        this.keyId2 = null;
        this.keyId3 = null;
        this.keyId4 = null;
        this.keyId5 = null;
        this.keyId6 = null;
        this.keyId7 = null;
        this.keyId8 = null;
        this.keyId9 = null;
        var length = providers.length;
        if (length > 0) {
          this.provider0 = providers[0];
          this.keyId0 = providers[0].key.id;
        }
        if (length > 1) {
          this.provider1 = providers[1];
          this.keyId1 = providers[1].key.id;
        }
        if (length > 2) {
          this.provider2 = providers[2];
          this.keyId2 = providers[2].key.id;
        }
        if (length > 3) {
          this.provider3 = providers[3];
          this.keyId3 = providers[3].key.id;
        }
        if (length > 4) {
          this.provider4 = providers[4];
          this.keyId4 = providers[4].key.id;
        }
        if (length > 5) {
          this.provider5 = providers[5];
          this.keyId5 = providers[5].key.id;
        }
        if (length > 6) {
          this.provider6 = providers[6];
          this.keyId6 = providers[6].key.id;
        }
        if (length > 7) {
          this.provider7 = providers[7];
          this.keyId7 = providers[7].key.id;
        }
        if (length > 8) {
          this.provider8 = providers[8];
          this.keyId8 = providers[8].key.id;
        }
        if (length > 9) {
          this.provider9 = providers[9];
          this.keyId9 = providers[9].key.id;
        }
      }
      ReflectiveProtoInjectorInlineStrategy.prototype.getProviderAtIndex = function(index) {
        if (index == 0)
          return this.provider0;
        if (index == 1)
          return this.provider1;
        if (index == 2)
          return this.provider2;
        if (index == 3)
          return this.provider3;
        if (index == 4)
          return this.provider4;
        if (index == 5)
          return this.provider5;
        if (index == 6)
          return this.provider6;
        if (index == 7)
          return this.provider7;
        if (index == 8)
          return this.provider8;
        if (index == 9)
          return this.provider9;
        throw new reflective_exceptions_1.OutOfBoundsError(index);
      };
      ReflectiveProtoInjectorInlineStrategy.prototype.createInjectorStrategy = function(injector) {
        return new ReflectiveInjectorInlineStrategy(injector, this);
      };
      return ReflectiveProtoInjectorInlineStrategy;
    }());
    exports.ReflectiveProtoInjectorInlineStrategy = ReflectiveProtoInjectorInlineStrategy;
    var ReflectiveProtoInjectorDynamicStrategy = (function() {
      function ReflectiveProtoInjectorDynamicStrategy(protoInj, providers) {
        this.providers = providers;
        var len = providers.length;
        this.keyIds = collection_1.ListWrapper.createFixedSize(len);
        for (var i = 0; i < len; i++) {
          this.keyIds[i] = providers[i].key.id;
        }
      }
      ReflectiveProtoInjectorDynamicStrategy.prototype.getProviderAtIndex = function(index) {
        if (index < 0 || index >= this.providers.length) {
          throw new reflective_exceptions_1.OutOfBoundsError(index);
        }
        return this.providers[index];
      };
      ReflectiveProtoInjectorDynamicStrategy.prototype.createInjectorStrategy = function(ei) {
        return new ReflectiveInjectorDynamicStrategy(this, ei);
      };
      return ReflectiveProtoInjectorDynamicStrategy;
    }());
    exports.ReflectiveProtoInjectorDynamicStrategy = ReflectiveProtoInjectorDynamicStrategy;
    var ReflectiveProtoInjector = (function() {
      function ReflectiveProtoInjector(providers) {
        this.numberOfProviders = providers.length;
        this._strategy = providers.length > _MAX_CONSTRUCTION_COUNTER ? new ReflectiveProtoInjectorDynamicStrategy(this, providers) : new ReflectiveProtoInjectorInlineStrategy(this, providers);
      }
      ReflectiveProtoInjector.fromResolvedProviders = function(providers) {
        return new ReflectiveProtoInjector(providers);
      };
      ReflectiveProtoInjector.prototype.getProviderAtIndex = function(index) {
        return this._strategy.getProviderAtIndex(index);
      };
      return ReflectiveProtoInjector;
    }());
    exports.ReflectiveProtoInjector = ReflectiveProtoInjector;
    var ReflectiveInjectorInlineStrategy = (function() {
      function ReflectiveInjectorInlineStrategy(injector, protoStrategy) {
        this.injector = injector;
        this.protoStrategy = protoStrategy;
        this.obj0 = UNDEFINED;
        this.obj1 = UNDEFINED;
        this.obj2 = UNDEFINED;
        this.obj3 = UNDEFINED;
        this.obj4 = UNDEFINED;
        this.obj5 = UNDEFINED;
        this.obj6 = UNDEFINED;
        this.obj7 = UNDEFINED;
        this.obj8 = UNDEFINED;
        this.obj9 = UNDEFINED;
      }
      ReflectiveInjectorInlineStrategy.prototype.resetConstructionCounter = function() {
        this.injector._constructionCounter = 0;
      };
      ReflectiveInjectorInlineStrategy.prototype.instantiateProvider = function(provider) {
        return this.injector._new(provider);
      };
      ReflectiveInjectorInlineStrategy.prototype.getObjByKeyId = function(keyId) {
        var p = this.protoStrategy;
        var inj = this.injector;
        if (p.keyId0 === keyId) {
          if (this.obj0 === UNDEFINED) {
            this.obj0 = inj._new(p.provider0);
          }
          return this.obj0;
        }
        if (p.keyId1 === keyId) {
          if (this.obj1 === UNDEFINED) {
            this.obj1 = inj._new(p.provider1);
          }
          return this.obj1;
        }
        if (p.keyId2 === keyId) {
          if (this.obj2 === UNDEFINED) {
            this.obj2 = inj._new(p.provider2);
          }
          return this.obj2;
        }
        if (p.keyId3 === keyId) {
          if (this.obj3 === UNDEFINED) {
            this.obj3 = inj._new(p.provider3);
          }
          return this.obj3;
        }
        if (p.keyId4 === keyId) {
          if (this.obj4 === UNDEFINED) {
            this.obj4 = inj._new(p.provider4);
          }
          return this.obj4;
        }
        if (p.keyId5 === keyId) {
          if (this.obj5 === UNDEFINED) {
            this.obj5 = inj._new(p.provider5);
          }
          return this.obj5;
        }
        if (p.keyId6 === keyId) {
          if (this.obj6 === UNDEFINED) {
            this.obj6 = inj._new(p.provider6);
          }
          return this.obj6;
        }
        if (p.keyId7 === keyId) {
          if (this.obj7 === UNDEFINED) {
            this.obj7 = inj._new(p.provider7);
          }
          return this.obj7;
        }
        if (p.keyId8 === keyId) {
          if (this.obj8 === UNDEFINED) {
            this.obj8 = inj._new(p.provider8);
          }
          return this.obj8;
        }
        if (p.keyId9 === keyId) {
          if (this.obj9 === UNDEFINED) {
            this.obj9 = inj._new(p.provider9);
          }
          return this.obj9;
        }
        return UNDEFINED;
      };
      ReflectiveInjectorInlineStrategy.prototype.getObjAtIndex = function(index) {
        if (index == 0)
          return this.obj0;
        if (index == 1)
          return this.obj1;
        if (index == 2)
          return this.obj2;
        if (index == 3)
          return this.obj3;
        if (index == 4)
          return this.obj4;
        if (index == 5)
          return this.obj5;
        if (index == 6)
          return this.obj6;
        if (index == 7)
          return this.obj7;
        if (index == 8)
          return this.obj8;
        if (index == 9)
          return this.obj9;
        throw new reflective_exceptions_1.OutOfBoundsError(index);
      };
      ReflectiveInjectorInlineStrategy.prototype.getMaxNumberOfObjects = function() {
        return _MAX_CONSTRUCTION_COUNTER;
      };
      return ReflectiveInjectorInlineStrategy;
    }());
    exports.ReflectiveInjectorInlineStrategy = ReflectiveInjectorInlineStrategy;
    var ReflectiveInjectorDynamicStrategy = (function() {
      function ReflectiveInjectorDynamicStrategy(protoStrategy, injector) {
        this.protoStrategy = protoStrategy;
        this.injector = injector;
        this.objs = collection_1.ListWrapper.createFixedSize(protoStrategy.providers.length);
        collection_1.ListWrapper.fill(this.objs, UNDEFINED);
      }
      ReflectiveInjectorDynamicStrategy.prototype.resetConstructionCounter = function() {
        this.injector._constructionCounter = 0;
      };
      ReflectiveInjectorDynamicStrategy.prototype.instantiateProvider = function(provider) {
        return this.injector._new(provider);
      };
      ReflectiveInjectorDynamicStrategy.prototype.getObjByKeyId = function(keyId) {
        var p = this.protoStrategy;
        for (var i = 0; i < p.keyIds.length; i++) {
          if (p.keyIds[i] === keyId) {
            if (this.objs[i] === UNDEFINED) {
              this.objs[i] = this.injector._new(p.providers[i]);
            }
            return this.objs[i];
          }
        }
        return UNDEFINED;
      };
      ReflectiveInjectorDynamicStrategy.prototype.getObjAtIndex = function(index) {
        if (index < 0 || index >= this.objs.length) {
          throw new reflective_exceptions_1.OutOfBoundsError(index);
        }
        return this.objs[index];
      };
      ReflectiveInjectorDynamicStrategy.prototype.getMaxNumberOfObjects = function() {
        return this.objs.length;
      };
      return ReflectiveInjectorDynamicStrategy;
    }());
    exports.ReflectiveInjectorDynamicStrategy = ReflectiveInjectorDynamicStrategy;
    var ReflectiveInjector = (function() {
      function ReflectiveInjector() {}
      ReflectiveInjector.resolve = function(providers) {
        return reflective_provider_1.resolveReflectiveProviders(providers);
      };
      ReflectiveInjector.resolveAndCreate = function(providers, parent) {
        if (parent === void 0) {
          parent = null;
        }
        var ResolvedReflectiveProviders = ReflectiveInjector.resolve(providers);
        return ReflectiveInjector.fromResolvedProviders(ResolvedReflectiveProviders, parent);
      };
      ReflectiveInjector.fromResolvedProviders = function(providers, parent) {
        if (parent === void 0) {
          parent = null;
        }
        return new ReflectiveInjector_(ReflectiveProtoInjector.fromResolvedProviders(providers), parent);
      };
      ReflectiveInjector.fromResolvedBindings = function(providers) {
        return ReflectiveInjector.fromResolvedProviders(providers);
      };
      Object.defineProperty(ReflectiveInjector.prototype, "parent", {
        get: function() {
          return exceptions_1.unimplemented();
        },
        enumerable: true,
        configurable: true
      });
      ReflectiveInjector.prototype.debugContext = function() {
        return null;
      };
      ReflectiveInjector.prototype.resolveAndCreateChild = function(providers) {
        return exceptions_1.unimplemented();
      };
      ReflectiveInjector.prototype.createChildFromResolved = function(providers) {
        return exceptions_1.unimplemented();
      };
      ReflectiveInjector.prototype.resolveAndInstantiate = function(provider) {
        return exceptions_1.unimplemented();
      };
      ReflectiveInjector.prototype.instantiateResolved = function(provider) {
        return exceptions_1.unimplemented();
      };
      return ReflectiveInjector;
    }());
    exports.ReflectiveInjector = ReflectiveInjector;
    var ReflectiveInjector_ = (function() {
      function ReflectiveInjector_(_proto, _parent, _debugContext) {
        if (_parent === void 0) {
          _parent = null;
        }
        if (_debugContext === void 0) {
          _debugContext = null;
        }
        this._debugContext = _debugContext;
        this._constructionCounter = 0;
        this._proto = _proto;
        this._parent = _parent;
        this._strategy = _proto._strategy.createInjectorStrategy(this);
      }
      ReflectiveInjector_.prototype.debugContext = function() {
        return this._debugContext();
      };
      ReflectiveInjector_.prototype.get = function(token, notFoundValue) {
        if (notFoundValue === void 0) {
          notFoundValue = injector_1.THROW_IF_NOT_FOUND;
        }
        return this._getByKey(reflective_key_1.ReflectiveKey.get(token), null, null, notFoundValue);
      };
      ReflectiveInjector_.prototype.getAt = function(index) {
        return this._strategy.getObjAtIndex(index);
      };
      Object.defineProperty(ReflectiveInjector_.prototype, "parent", {
        get: function() {
          return this._parent;
        },
        enumerable: true,
        configurable: true
      });
      Object.defineProperty(ReflectiveInjector_.prototype, "internalStrategy", {
        get: function() {
          return this._strategy;
        },
        enumerable: true,
        configurable: true
      });
      ReflectiveInjector_.prototype.resolveAndCreateChild = function(providers) {
        var ResolvedReflectiveProviders = ReflectiveInjector.resolve(providers);
        return this.createChildFromResolved(ResolvedReflectiveProviders);
      };
      ReflectiveInjector_.prototype.createChildFromResolved = function(providers) {
        var proto = new ReflectiveProtoInjector(providers);
        var inj = new ReflectiveInjector_(proto);
        inj._parent = this;
        return inj;
      };
      ReflectiveInjector_.prototype.resolveAndInstantiate = function(provider) {
        return this.instantiateResolved(ReflectiveInjector.resolve([provider])[0]);
      };
      ReflectiveInjector_.prototype.instantiateResolved = function(provider) {
        return this._instantiateProvider(provider);
      };
      ReflectiveInjector_.prototype._new = function(provider) {
        if (this._constructionCounter++ > this._strategy.getMaxNumberOfObjects()) {
          throw new reflective_exceptions_1.CyclicDependencyError(this, provider.key);
        }
        return this._instantiateProvider(provider);
      };
      ReflectiveInjector_.prototype._instantiateProvider = function(provider) {
        if (provider.multiProvider) {
          var res = collection_1.ListWrapper.createFixedSize(provider.resolvedFactories.length);
          for (var i = 0; i < provider.resolvedFactories.length; ++i) {
            res[i] = this._instantiate(provider, provider.resolvedFactories[i]);
          }
          return res;
        } else {
          return this._instantiate(provider, provider.resolvedFactories[0]);
        }
      };
      ReflectiveInjector_.prototype._instantiate = function(provider, ResolvedReflectiveFactory) {
        var factory = ResolvedReflectiveFactory.factory;
        var deps = ResolvedReflectiveFactory.dependencies;
        var length = deps.length;
        var d0;
        var d1;
        var d2;
        var d3;
        var d4;
        var d5;
        var d6;
        var d7;
        var d8;
        var d9;
        var d10;
        var d11;
        var d12;
        var d13;
        var d14;
        var d15;
        var d16;
        var d17;
        var d18;
        var d19;
        try {
          d0 = length > 0 ? this._getByReflectiveDependency(provider, deps[0]) : null;
          d1 = length > 1 ? this._getByReflectiveDependency(provider, deps[1]) : null;
          d2 = length > 2 ? this._getByReflectiveDependency(provider, deps[2]) : null;
          d3 = length > 3 ? this._getByReflectiveDependency(provider, deps[3]) : null;
          d4 = length > 4 ? this._getByReflectiveDependency(provider, deps[4]) : null;
          d5 = length > 5 ? this._getByReflectiveDependency(provider, deps[5]) : null;
          d6 = length > 6 ? this._getByReflectiveDependency(provider, deps[6]) : null;
          d7 = length > 7 ? this._getByReflectiveDependency(provider, deps[7]) : null;
          d8 = length > 8 ? this._getByReflectiveDependency(provider, deps[8]) : null;
          d9 = length > 9 ? this._getByReflectiveDependency(provider, deps[9]) : null;
          d10 = length > 10 ? this._getByReflectiveDependency(provider, deps[10]) : null;
          d11 = length > 11 ? this._getByReflectiveDependency(provider, deps[11]) : null;
          d12 = length > 12 ? this._getByReflectiveDependency(provider, deps[12]) : null;
          d13 = length > 13 ? this._getByReflectiveDependency(provider, deps[13]) : null;
          d14 = length > 14 ? this._getByReflectiveDependency(provider, deps[14]) : null;
          d15 = length > 15 ? this._getByReflectiveDependency(provider, deps[15]) : null;
          d16 = length > 16 ? this._getByReflectiveDependency(provider, deps[16]) : null;
          d17 = length > 17 ? this._getByReflectiveDependency(provider, deps[17]) : null;
          d18 = length > 18 ? this._getByReflectiveDependency(provider, deps[18]) : null;
          d19 = length > 19 ? this._getByReflectiveDependency(provider, deps[19]) : null;
        } catch (e) {
          if (e instanceof reflective_exceptions_1.AbstractProviderError || e instanceof reflective_exceptions_1.InstantiationError) {
            e.addKey(this, provider.key);
          }
          throw e;
        }
        var obj;
        try {
          switch (length) {
            case 0:
              obj = factory();
              break;
            case 1:
              obj = factory(d0);
              break;
            case 2:
              obj = factory(d0, d1);
              break;
            case 3:
              obj = factory(d0, d1, d2);
              break;
            case 4:
              obj = factory(d0, d1, d2, d3);
              break;
            case 5:
              obj = factory(d0, d1, d2, d3, d4);
              break;
            case 6:
              obj = factory(d0, d1, d2, d3, d4, d5);
              break;
            case 7:
              obj = factory(d0, d1, d2, d3, d4, d5, d6);
              break;
            case 8:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7);
              break;
            case 9:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8);
              break;
            case 10:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9);
              break;
            case 11:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10);
              break;
            case 12:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11);
              break;
            case 13:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12);
              break;
            case 14:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13);
              break;
            case 15:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14);
              break;
            case 16:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14, d15);
              break;
            case 17:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14, d15, d16);
              break;
            case 18:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14, d15, d16, d17);
              break;
            case 19:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14, d15, d16, d17, d18);
              break;
            case 20:
              obj = factory(d0, d1, d2, d3, d4, d5, d6, d7, d8, d9, d10, d11, d12, d13, d14, d15, d16, d17, d18, d19);
              break;
            default:
              throw new exceptions_1.BaseException("Cannot instantiate '" + provider.key.displayName + "' because it has more than 20 dependencies");
          }
        } catch (e) {
          throw new reflective_exceptions_1.InstantiationError(this, e, e.stack, provider.key);
        }
        return obj;
      };
      ReflectiveInjector_.prototype._getByReflectiveDependency = function(provider, dep) {
        return this._getByKey(dep.key, dep.lowerBoundVisibility, dep.upperBoundVisibility, dep.optional ? null : injector_1.THROW_IF_NOT_FOUND);
      };
      ReflectiveInjector_.prototype._getByKey = function(key, lowerBoundVisibility, upperBoundVisibility, notFoundValue) {
        if (key === INJECTOR_KEY) {
          return this;
        }
        if (upperBoundVisibility instanceof metadata_1.SelfMetadata) {
          return this._getByKeySelf(key, notFoundValue);
        } else {
          return this._getByKeyDefault(key, notFoundValue, lowerBoundVisibility);
        }
      };
      ReflectiveInjector_.prototype._throwOrNull = function(key, notFoundValue) {
        if (notFoundValue !== injector_1.THROW_IF_NOT_FOUND) {
          return notFoundValue;
        } else {
          throw new reflective_exceptions_1.NoProviderError(this, key);
        }
      };
      ReflectiveInjector_.prototype._getByKeySelf = function(key, notFoundValue) {
        var obj = this._strategy.getObjByKeyId(key.id);
        return (obj !== UNDEFINED) ? obj : this._throwOrNull(key, notFoundValue);
      };
      ReflectiveInjector_.prototype._getByKeyDefault = function(key, notFoundValue, lowerBoundVisibility) {
        var inj;
        if (lowerBoundVisibility instanceof metadata_1.SkipSelfMetadata) {
          inj = this._parent;
        } else {
          inj = this;
        }
        while (inj instanceof ReflectiveInjector_) {
          var inj_ = inj;
          var obj = inj_._strategy.getObjByKeyId(key.id);
          if (obj !== UNDEFINED)
            return obj;
          inj = inj_._parent;
        }
        if (inj !== null) {
          return inj.get(key.token, notFoundValue);
        } else {
          return this._throwOrNull(key, notFoundValue);
        }
      };
      Object.defineProperty(ReflectiveInjector_.prototype, "displayName", {
        get: function() {
          return "ReflectiveInjector(providers: [" + _mapProviders(this, function(b) {
            return (" \"" + b.key.displayName + "\" ");
          }).join(", ") + "])";
        },
        enumerable: true,
        configurable: true
      });
      ReflectiveInjector_.prototype.toString = function() {
        return this.displayName;
      };
      return ReflectiveInjector_;
    }());
    exports.ReflectiveInjector_ = ReflectiveInjector_;
    var INJECTOR_KEY = reflective_key_1.ReflectiveKey.get(injector_1.Injector);
    function _mapProviders(injector, fn) {
      var res = [];
      for (var i = 0; i < injector._proto.numberOfProviders; ++i) {
        res.push(fn(injector._proto.getProviderAtIndex(i)));
      }
      return res;
    }
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("266", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var ReflectorReader = (function() {
    function ReflectorReader() {}
    return ReflectorReader;
  }());
  exports.ReflectorReader = ReflectorReader;
  return module.exports;
});

$__System.registerDynamic("293", ["9c", "a9", "254", "266"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var collection_1 = $__require('254');
  var reflector_reader_1 = $__require('266');
  var ReflectionInfo = (function() {
    function ReflectionInfo(annotations, parameters, factory, interfaces, propMetadata) {
      this.annotations = annotations;
      this.parameters = parameters;
      this.factory = factory;
      this.interfaces = interfaces;
      this.propMetadata = propMetadata;
    }
    return ReflectionInfo;
  }());
  exports.ReflectionInfo = ReflectionInfo;
  var Reflector = (function(_super) {
    __extends(Reflector, _super);
    function Reflector(reflectionCapabilities) {
      _super.call(this);
      this._injectableInfo = new collection_1.Map();
      this._getters = new collection_1.Map();
      this._setters = new collection_1.Map();
      this._methods = new collection_1.Map();
      this._usedKeys = null;
      this.reflectionCapabilities = reflectionCapabilities;
    }
    Reflector.prototype.isReflectionEnabled = function() {
      return this.reflectionCapabilities.isReflectionEnabled();
    };
    Reflector.prototype.trackUsage = function() {
      this._usedKeys = new collection_1.Set();
    };
    Reflector.prototype.listUnusedKeys = function() {
      var _this = this;
      if (this._usedKeys == null) {
        throw new exceptions_1.BaseException('Usage tracking is disabled');
      }
      var allTypes = collection_1.MapWrapper.keys(this._injectableInfo);
      return allTypes.filter(function(key) {
        return !collection_1.SetWrapper.has(_this._usedKeys, key);
      });
    };
    Reflector.prototype.registerFunction = function(func, funcInfo) {
      this._injectableInfo.set(func, funcInfo);
    };
    Reflector.prototype.registerType = function(type, typeInfo) {
      this._injectableInfo.set(type, typeInfo);
    };
    Reflector.prototype.registerGetters = function(getters) {
      _mergeMaps(this._getters, getters);
    };
    Reflector.prototype.registerSetters = function(setters) {
      _mergeMaps(this._setters, setters);
    };
    Reflector.prototype.registerMethods = function(methods) {
      _mergeMaps(this._methods, methods);
    };
    Reflector.prototype.factory = function(type) {
      if (this._containsReflectionInfo(type)) {
        var res = this._getReflectionInfo(type).factory;
        return lang_1.isPresent(res) ? res : null;
      } else {
        return this.reflectionCapabilities.factory(type);
      }
    };
    Reflector.prototype.parameters = function(typeOrFunc) {
      if (this._injectableInfo.has(typeOrFunc)) {
        var res = this._getReflectionInfo(typeOrFunc).parameters;
        return lang_1.isPresent(res) ? res : [];
      } else {
        return this.reflectionCapabilities.parameters(typeOrFunc);
      }
    };
    Reflector.prototype.annotations = function(typeOrFunc) {
      if (this._injectableInfo.has(typeOrFunc)) {
        var res = this._getReflectionInfo(typeOrFunc).annotations;
        return lang_1.isPresent(res) ? res : [];
      } else {
        return this.reflectionCapabilities.annotations(typeOrFunc);
      }
    };
    Reflector.prototype.propMetadata = function(typeOrFunc) {
      if (this._injectableInfo.has(typeOrFunc)) {
        var res = this._getReflectionInfo(typeOrFunc).propMetadata;
        return lang_1.isPresent(res) ? res : {};
      } else {
        return this.reflectionCapabilities.propMetadata(typeOrFunc);
      }
    };
    Reflector.prototype.interfaces = function(type) {
      if (this._injectableInfo.has(type)) {
        var res = this._getReflectionInfo(type).interfaces;
        return lang_1.isPresent(res) ? res : [];
      } else {
        return this.reflectionCapabilities.interfaces(type);
      }
    };
    Reflector.prototype.getter = function(name) {
      if (this._getters.has(name)) {
        return this._getters.get(name);
      } else {
        return this.reflectionCapabilities.getter(name);
      }
    };
    Reflector.prototype.setter = function(name) {
      if (this._setters.has(name)) {
        return this._setters.get(name);
      } else {
        return this.reflectionCapabilities.setter(name);
      }
    };
    Reflector.prototype.method = function(name) {
      if (this._methods.has(name)) {
        return this._methods.get(name);
      } else {
        return this.reflectionCapabilities.method(name);
      }
    };
    Reflector.prototype._getReflectionInfo = function(typeOrFunc) {
      if (lang_1.isPresent(this._usedKeys)) {
        this._usedKeys.add(typeOrFunc);
      }
      return this._injectableInfo.get(typeOrFunc);
    };
    Reflector.prototype._containsReflectionInfo = function(typeOrFunc) {
      return this._injectableInfo.has(typeOrFunc);
    };
    Reflector.prototype.importUri = function(type) {
      return this.reflectionCapabilities.importUri(type);
    };
    return Reflector;
  }(reflector_reader_1.ReflectorReader));
  exports.Reflector = Reflector;
  function _mergeMaps(target, config) {
    collection_1.StringMapWrapper.forEach(config, function(v, k) {
      return target.set(k, v);
    });
  }
  return module.exports;
});

$__System.registerDynamic("265", ["293", "294"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var reflector_1 = $__require('293');
  var reflector_2 = $__require('293');
  exports.Reflector = reflector_2.Reflector;
  exports.ReflectionInfo = reflector_2.ReflectionInfo;
  var reflection_capabilities_1 = $__require('294');
  exports.reflector = new reflector_1.Reflector(new reflection_capabilities_1.ReflectionCapabilities());
  return module.exports;
});

$__System.registerDynamic("290", ["9c", "254", "265", "292", "247", "291", "248", "295", "296"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var reflection_1 = $__require('265');
  var reflective_key_1 = $__require('292');
  var metadata_1 = $__require('247');
  var reflective_exceptions_1 = $__require('291');
  var forward_ref_1 = $__require('248');
  var provider_1 = $__require('295');
  var provider_util_1 = $__require('296');
  var ReflectiveDependency = (function() {
    function ReflectiveDependency(key, optional, lowerBoundVisibility, upperBoundVisibility, properties) {
      this.key = key;
      this.optional = optional;
      this.lowerBoundVisibility = lowerBoundVisibility;
      this.upperBoundVisibility = upperBoundVisibility;
      this.properties = properties;
    }
    ReflectiveDependency.fromKey = function(key) {
      return new ReflectiveDependency(key, false, null, null, []);
    };
    return ReflectiveDependency;
  }());
  exports.ReflectiveDependency = ReflectiveDependency;
  var _EMPTY_LIST = [];
  var ResolvedReflectiveProvider_ = (function() {
    function ResolvedReflectiveProvider_(key, resolvedFactories, multiProvider) {
      this.key = key;
      this.resolvedFactories = resolvedFactories;
      this.multiProvider = multiProvider;
    }
    Object.defineProperty(ResolvedReflectiveProvider_.prototype, "resolvedFactory", {
      get: function() {
        return this.resolvedFactories[0];
      },
      enumerable: true,
      configurable: true
    });
    return ResolvedReflectiveProvider_;
  }());
  exports.ResolvedReflectiveProvider_ = ResolvedReflectiveProvider_;
  var ResolvedReflectiveFactory = (function() {
    function ResolvedReflectiveFactory(factory, dependencies) {
      this.factory = factory;
      this.dependencies = dependencies;
    }
    return ResolvedReflectiveFactory;
  }());
  exports.ResolvedReflectiveFactory = ResolvedReflectiveFactory;
  function resolveReflectiveFactory(provider) {
    var factoryFn;
    var resolvedDeps;
    if (lang_1.isPresent(provider.useClass)) {
      var useClass = forward_ref_1.resolveForwardRef(provider.useClass);
      factoryFn = reflection_1.reflector.factory(useClass);
      resolvedDeps = _dependenciesFor(useClass);
    } else if (lang_1.isPresent(provider.useExisting)) {
      factoryFn = function(aliasInstance) {
        return aliasInstance;
      };
      resolvedDeps = [ReflectiveDependency.fromKey(reflective_key_1.ReflectiveKey.get(provider.useExisting))];
    } else if (lang_1.isPresent(provider.useFactory)) {
      factoryFn = provider.useFactory;
      resolvedDeps = constructDependencies(provider.useFactory, provider.dependencies);
    } else {
      factoryFn = function() {
        return provider.useValue;
      };
      resolvedDeps = _EMPTY_LIST;
    }
    return new ResolvedReflectiveFactory(factoryFn, resolvedDeps);
  }
  exports.resolveReflectiveFactory = resolveReflectiveFactory;
  function resolveReflectiveProvider(provider) {
    return new ResolvedReflectiveProvider_(reflective_key_1.ReflectiveKey.get(provider.token), [resolveReflectiveFactory(provider)], provider.multi);
  }
  exports.resolveReflectiveProvider = resolveReflectiveProvider;
  function resolveReflectiveProviders(providers) {
    var normalized = _normalizeProviders(providers, []);
    var resolved = normalized.map(resolveReflectiveProvider);
    return collection_1.MapWrapper.values(mergeResolvedReflectiveProviders(resolved, new Map()));
  }
  exports.resolveReflectiveProviders = resolveReflectiveProviders;
  function mergeResolvedReflectiveProviders(providers, normalizedProvidersMap) {
    for (var i = 0; i < providers.length; i++) {
      var provider = providers[i];
      var existing = normalizedProvidersMap.get(provider.key.id);
      if (lang_1.isPresent(existing)) {
        if (provider.multiProvider !== existing.multiProvider) {
          throw new reflective_exceptions_1.MixingMultiProvidersWithRegularProvidersError(existing, provider);
        }
        if (provider.multiProvider) {
          for (var j = 0; j < provider.resolvedFactories.length; j++) {
            existing.resolvedFactories.push(provider.resolvedFactories[j]);
          }
        } else {
          normalizedProvidersMap.set(provider.key.id, provider);
        }
      } else {
        var resolvedProvider;
        if (provider.multiProvider) {
          resolvedProvider = new ResolvedReflectiveProvider_(provider.key, collection_1.ListWrapper.clone(provider.resolvedFactories), provider.multiProvider);
        } else {
          resolvedProvider = provider;
        }
        normalizedProvidersMap.set(provider.key.id, resolvedProvider);
      }
    }
    return normalizedProvidersMap;
  }
  exports.mergeResolvedReflectiveProviders = mergeResolvedReflectiveProviders;
  function _normalizeProviders(providers, res) {
    providers.forEach(function(b) {
      if (b instanceof lang_1.Type) {
        res.push(provider_1.provide(b, {useClass: b}));
      } else if (b instanceof provider_1.Provider) {
        res.push(b);
      } else if (provider_util_1.isProviderLiteral(b)) {
        res.push(provider_util_1.createProvider(b));
      } else if (b instanceof Array) {
        _normalizeProviders(b, res);
      } else if (b instanceof provider_1.ProviderBuilder) {
        throw new reflective_exceptions_1.InvalidProviderError(b.token);
      } else {
        throw new reflective_exceptions_1.InvalidProviderError(b);
      }
    });
    return res;
  }
  function constructDependencies(typeOrFunc, dependencies) {
    if (lang_1.isBlank(dependencies)) {
      return _dependenciesFor(typeOrFunc);
    } else {
      var params = dependencies.map(function(t) {
        return [t];
      });
      return dependencies.map(function(t) {
        return _extractToken(typeOrFunc, t, params);
      });
    }
  }
  exports.constructDependencies = constructDependencies;
  function _dependenciesFor(typeOrFunc) {
    var params = reflection_1.reflector.parameters(typeOrFunc);
    if (lang_1.isBlank(params))
      return [];
    if (params.some(lang_1.isBlank)) {
      throw new reflective_exceptions_1.NoAnnotationError(typeOrFunc, params);
    }
    return params.map(function(p) {
      return _extractToken(typeOrFunc, p, params);
    });
  }
  function _extractToken(typeOrFunc, metadata, params) {
    var depProps = [];
    var token = null;
    var optional = false;
    if (!lang_1.isArray(metadata)) {
      if (metadata instanceof metadata_1.InjectMetadata) {
        return _createDependency(metadata.token, optional, null, null, depProps);
      } else {
        return _createDependency(metadata, optional, null, null, depProps);
      }
    }
    var lowerBoundVisibility = null;
    var upperBoundVisibility = null;
    for (var i = 0; i < metadata.length; ++i) {
      var paramMetadata = metadata[i];
      if (paramMetadata instanceof lang_1.Type) {
        token = paramMetadata;
      } else if (paramMetadata instanceof metadata_1.InjectMetadata) {
        token = paramMetadata.token;
      } else if (paramMetadata instanceof metadata_1.OptionalMetadata) {
        optional = true;
      } else if (paramMetadata instanceof metadata_1.SelfMetadata) {
        upperBoundVisibility = paramMetadata;
      } else if (paramMetadata instanceof metadata_1.HostMetadata) {
        upperBoundVisibility = paramMetadata;
      } else if (paramMetadata instanceof metadata_1.SkipSelfMetadata) {
        lowerBoundVisibility = paramMetadata;
      } else if (paramMetadata instanceof metadata_1.DependencyMetadata) {
        if (lang_1.isPresent(paramMetadata.token)) {
          token = paramMetadata.token;
        }
        depProps.push(paramMetadata);
      }
    }
    token = forward_ref_1.resolveForwardRef(token);
    if (lang_1.isPresent(token)) {
      return _createDependency(token, optional, lowerBoundVisibility, upperBoundVisibility, depProps);
    } else {
      throw new reflective_exceptions_1.NoAnnotationError(typeOrFunc, params);
    }
  }
  function _createDependency(token, optional, lowerBoundVisibility, upperBoundVisibility, depProps) {
    return new ReflectiveDependency(reflective_key_1.ReflectiveKey.get(token), optional, lowerBoundVisibility, upperBoundVisibility, depProps);
  }
  return module.exports;
});

$__System.registerDynamic("248", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  function forwardRef(forwardRefFn) {
    forwardRefFn.__forward_ref__ = forwardRef;
    forwardRefFn.toString = function() {
      return lang_1.stringify(this());
    };
    return forwardRefFn;
  }
  exports.forwardRef = forwardRef;
  function resolveForwardRef(type) {
    if (lang_1.isFunction(type) && type.hasOwnProperty('__forward_ref__') && type.__forward_ref__ === forwardRef) {
      return type();
    } else {
      return type;
    }
  }
  exports.resolveForwardRef = resolveForwardRef;
  return module.exports;
});

$__System.registerDynamic("292", ["9c", "a9", "248"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var forward_ref_1 = $__require('248');
  var ReflectiveKey = (function() {
    function ReflectiveKey(token, id) {
      this.token = token;
      this.id = id;
      if (lang_1.isBlank(token)) {
        throw new exceptions_1.BaseException('Token must be defined!');
      }
    }
    Object.defineProperty(ReflectiveKey.prototype, "displayName", {
      get: function() {
        return lang_1.stringify(this.token);
      },
      enumerable: true,
      configurable: true
    });
    ReflectiveKey.get = function(token) {
      return _globalKeyRegistry.get(forward_ref_1.resolveForwardRef(token));
    };
    Object.defineProperty(ReflectiveKey, "numberOfKeys", {
      get: function() {
        return _globalKeyRegistry.numberOfKeys;
      },
      enumerable: true,
      configurable: true
    });
    return ReflectiveKey;
  }());
  exports.ReflectiveKey = ReflectiveKey;
  var KeyRegistry = (function() {
    function KeyRegistry() {
      this._allKeys = new Map();
    }
    KeyRegistry.prototype.get = function(token) {
      if (token instanceof ReflectiveKey)
        return token;
      if (this._allKeys.has(token)) {
        return this._allKeys.get(token);
      }
      var newKey = new ReflectiveKey(token, ReflectiveKey.numberOfKeys);
      this._allKeys.set(token, newKey);
      return newKey;
    };
    Object.defineProperty(KeyRegistry.prototype, "numberOfKeys", {
      get: function() {
        return this._allKeys.size;
      },
      enumerable: true,
      configurable: true
    });
    return KeyRegistry;
  }());
  exports.KeyRegistry = KeyRegistry;
  var _globalKeyRegistry = new KeyRegistry();
  return module.exports;
});

$__System.registerDynamic("291", ["254", "9c", "a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var collection_1 = $__require('254');
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  function findFirstClosedCycle(keys) {
    var res = [];
    for (var i = 0; i < keys.length; ++i) {
      if (collection_1.ListWrapper.contains(res, keys[i])) {
        res.push(keys[i]);
        return res;
      } else {
        res.push(keys[i]);
      }
    }
    return res;
  }
  function constructResolvingPath(keys) {
    if (keys.length > 1) {
      var reversed = findFirstClosedCycle(collection_1.ListWrapper.reversed(keys));
      var tokenStrs = reversed.map(function(k) {
        return lang_1.stringify(k.token);
      });
      return " (" + tokenStrs.join(' -> ') + ")";
    } else {
      return "";
    }
  }
  var AbstractProviderError = (function(_super) {
    __extends(AbstractProviderError, _super);
    function AbstractProviderError(injector, key, constructResolvingMessage) {
      _super.call(this, "DI Exception");
      this.keys = [key];
      this.injectors = [injector];
      this.constructResolvingMessage = constructResolvingMessage;
      this.message = this.constructResolvingMessage(this.keys);
    }
    AbstractProviderError.prototype.addKey = function(injector, key) {
      this.injectors.push(injector);
      this.keys.push(key);
      this.message = this.constructResolvingMessage(this.keys);
    };
    Object.defineProperty(AbstractProviderError.prototype, "context", {
      get: function() {
        return this.injectors[this.injectors.length - 1].debugContext();
      },
      enumerable: true,
      configurable: true
    });
    return AbstractProviderError;
  }(exceptions_1.BaseException));
  exports.AbstractProviderError = AbstractProviderError;
  var NoProviderError = (function(_super) {
    __extends(NoProviderError, _super);
    function NoProviderError(injector, key) {
      _super.call(this, injector, key, function(keys) {
        var first = lang_1.stringify(collection_1.ListWrapper.first(keys).token);
        return "No provider for " + first + "!" + constructResolvingPath(keys);
      });
    }
    return NoProviderError;
  }(AbstractProviderError));
  exports.NoProviderError = NoProviderError;
  var CyclicDependencyError = (function(_super) {
    __extends(CyclicDependencyError, _super);
    function CyclicDependencyError(injector, key) {
      _super.call(this, injector, key, function(keys) {
        return "Cannot instantiate cyclic dependency!" + constructResolvingPath(keys);
      });
    }
    return CyclicDependencyError;
  }(AbstractProviderError));
  exports.CyclicDependencyError = CyclicDependencyError;
  var InstantiationError = (function(_super) {
    __extends(InstantiationError, _super);
    function InstantiationError(injector, originalException, originalStack, key) {
      _super.call(this, "DI Exception", originalException, originalStack, null);
      this.keys = [key];
      this.injectors = [injector];
    }
    InstantiationError.prototype.addKey = function(injector, key) {
      this.injectors.push(injector);
      this.keys.push(key);
    };
    Object.defineProperty(InstantiationError.prototype, "wrapperMessage", {
      get: function() {
        var first = lang_1.stringify(collection_1.ListWrapper.first(this.keys).token);
        return "Error during instantiation of " + first + "!" + constructResolvingPath(this.keys) + ".";
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(InstantiationError.prototype, "causeKey", {
      get: function() {
        return this.keys[0];
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(InstantiationError.prototype, "context", {
      get: function() {
        return this.injectors[this.injectors.length - 1].debugContext();
      },
      enumerable: true,
      configurable: true
    });
    return InstantiationError;
  }(exceptions_1.WrappedException));
  exports.InstantiationError = InstantiationError;
  var InvalidProviderError = (function(_super) {
    __extends(InvalidProviderError, _super);
    function InvalidProviderError(provider) {
      _super.call(this, "Invalid provider - only instances of Provider and Type are allowed, got: " + provider.toString());
    }
    return InvalidProviderError;
  }(exceptions_1.BaseException));
  exports.InvalidProviderError = InvalidProviderError;
  var NoAnnotationError = (function(_super) {
    __extends(NoAnnotationError, _super);
    function NoAnnotationError(typeOrFunc, params) {
      _super.call(this, NoAnnotationError._genMessage(typeOrFunc, params));
    }
    NoAnnotationError._genMessage = function(typeOrFunc, params) {
      var signature = [];
      for (var i = 0,
          ii = params.length; i < ii; i++) {
        var parameter = params[i];
        if (lang_1.isBlank(parameter) || parameter.length == 0) {
          signature.push('?');
        } else {
          signature.push(parameter.map(lang_1.stringify).join(' '));
        }
      }
      return "Cannot resolve all parameters for '" + lang_1.stringify(typeOrFunc) + "'(" + signature.join(', ') + "). " + "Make sure that all the parameters are decorated with Inject or have valid type annotations and that '" + lang_1.stringify(typeOrFunc) + "' is decorated with Injectable.";
    };
    return NoAnnotationError;
  }(exceptions_1.BaseException));
  exports.NoAnnotationError = NoAnnotationError;
  var OutOfBoundsError = (function(_super) {
    __extends(OutOfBoundsError, _super);
    function OutOfBoundsError(index) {
      _super.call(this, "Index " + index + " is out-of-bounds.");
    }
    return OutOfBoundsError;
  }(exceptions_1.BaseException));
  exports.OutOfBoundsError = OutOfBoundsError;
  var MixingMultiProvidersWithRegularProvidersError = (function(_super) {
    __extends(MixingMultiProvidersWithRegularProvidersError, _super);
    function MixingMultiProvidersWithRegularProvidersError(provider1, provider2) {
      _super.call(this, "Cannot mix multi providers and regular providers, got: " + provider1.toString() + " " + provider2.toString());
    }
    return MixingMultiProvidersWithRegularProvidersError;
  }(exceptions_1.BaseException));
  exports.MixingMultiProvidersWithRegularProvidersError = MixingMultiProvidersWithRegularProvidersError;
  return module.exports;
});

$__System.registerDynamic("297", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var OpaqueToken = (function() {
    function OpaqueToken(_desc) {
      this._desc = _desc;
    }
    OpaqueToken.prototype.toString = function() {
      return "Token " + this._desc;
    };
    return OpaqueToken;
  }());
  exports.OpaqueToken = OpaqueToken;
  return module.exports;
});

$__System.registerDynamic("262", ["247", "26a", "248", "283", "26d", "295", "290", "292", "291", "297"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  var metadata_1 = $__require('247');
  exports.InjectMetadata = metadata_1.InjectMetadata;
  exports.OptionalMetadata = metadata_1.OptionalMetadata;
  exports.InjectableMetadata = metadata_1.InjectableMetadata;
  exports.SelfMetadata = metadata_1.SelfMetadata;
  exports.HostMetadata = metadata_1.HostMetadata;
  exports.SkipSelfMetadata = metadata_1.SkipSelfMetadata;
  exports.DependencyMetadata = metadata_1.DependencyMetadata;
  __export($__require('26a'));
  var forward_ref_1 = $__require('248');
  exports.forwardRef = forward_ref_1.forwardRef;
  exports.resolveForwardRef = forward_ref_1.resolveForwardRef;
  var injector_1 = $__require('283');
  exports.Injector = injector_1.Injector;
  var reflective_injector_1 = $__require('26d');
  exports.ReflectiveInjector = reflective_injector_1.ReflectiveInjector;
  var provider_1 = $__require('295');
  exports.Binding = provider_1.Binding;
  exports.ProviderBuilder = provider_1.ProviderBuilder;
  exports.bind = provider_1.bind;
  exports.Provider = provider_1.Provider;
  exports.provide = provider_1.provide;
  var reflective_provider_1 = $__require('290');
  exports.ResolvedReflectiveFactory = reflective_provider_1.ResolvedReflectiveFactory;
  exports.ReflectiveDependency = reflective_provider_1.ReflectiveDependency;
  var reflective_key_1 = $__require('292');
  exports.ReflectiveKey = reflective_key_1.ReflectiveKey;
  var reflective_exceptions_1 = $__require('291');
  exports.NoProviderError = reflective_exceptions_1.NoProviderError;
  exports.AbstractProviderError = reflective_exceptions_1.AbstractProviderError;
  exports.CyclicDependencyError = reflective_exceptions_1.CyclicDependencyError;
  exports.InstantiationError = reflective_exceptions_1.InstantiationError;
  exports.InvalidProviderError = reflective_exceptions_1.InvalidProviderError;
  exports.NoAnnotationError = reflective_exceptions_1.NoAnnotationError;
  exports.OutOfBoundsError = reflective_exceptions_1.OutOfBoundsError;
  var opaque_token_1 = $__require('297');
  exports.OpaqueToken = opaque_token_1.OpaqueToken;
  return module.exports;
});

$__System.registerDynamic("26b", ["262", "9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var di_1 = $__require('262');
  var lang_1 = $__require('9c');
  exports.APP_ID = new di_1.OpaqueToken('AppId');
  function _appIdRandomProviderFactory() {
    return "" + _randomChar() + _randomChar() + _randomChar();
  }
  exports.APP_ID_RANDOM_PROVIDER = {
    provide: exports.APP_ID,
    useFactory: _appIdRandomProviderFactory,
    deps: []
  };
  function _randomChar() {
    return lang_1.StringWrapper.fromCharCode(97 + lang_1.Math.floor(lang_1.Math.random() * 25));
  }
  exports.PLATFORM_INITIALIZER = new di_1.OpaqueToken("Platform Initializer");
  exports.APP_INITIALIZER = new di_1.OpaqueToken("Application Initializer");
  exports.PACKAGE_ROOT_URL = new di_1.OpaqueToken("Application Packages Root URL");
  return module.exports;
});

$__System.registerDynamic("26f", ["288", "9c", "254", "a9", "285", "25e", "260", "252", "26b", "26a", "28f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var security_1 = $__require('288');
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var exceptions_1 = $__require('a9');
  var element_1 = $__require('285');
  var exceptions_2 = $__require('25e');
  var change_detection_1 = $__require('260');
  var api_1 = $__require('252');
  var application_tokens_1 = $__require('26b');
  var decorators_1 = $__require('26a');
  var change_detection_util_1 = $__require('28f');
  var ViewUtils = (function() {
    function ViewUtils(_renderer, _appId, sanitizer) {
      this._renderer = _renderer;
      this._appId = _appId;
      this._nextCompTypeId = 0;
      this.sanitizer = sanitizer;
    }
    ViewUtils.prototype.createRenderComponentType = function(templateUrl, slotCount, encapsulation, styles) {
      return new api_1.RenderComponentType(this._appId + "-" + this._nextCompTypeId++, templateUrl, slotCount, encapsulation, styles);
    };
    ViewUtils.prototype.renderComponent = function(renderComponentType) {
      return this._renderer.renderComponent(renderComponentType);
    };
    ViewUtils.decorators = [{type: decorators_1.Injectable}];
    ViewUtils.ctorParameters = [{type: api_1.RootRenderer}, {
      type: undefined,
      decorators: [{
        type: decorators_1.Inject,
        args: [application_tokens_1.APP_ID]
      }]
    }, {type: security_1.SanitizationService}];
    return ViewUtils;
  }());
  exports.ViewUtils = ViewUtils;
  function flattenNestedViewRenderNodes(nodes) {
    return _flattenNestedViewRenderNodes(nodes, []);
  }
  exports.flattenNestedViewRenderNodes = flattenNestedViewRenderNodes;
  function _flattenNestedViewRenderNodes(nodes, renderNodes) {
    for (var i = 0; i < nodes.length; i++) {
      var node = nodes[i];
      if (node instanceof element_1.AppElement) {
        var appEl = node;
        renderNodes.push(appEl.nativeElement);
        if (lang_1.isPresent(appEl.nestedViews)) {
          for (var k = 0; k < appEl.nestedViews.length; k++) {
            _flattenNestedViewRenderNodes(appEl.nestedViews[k].rootNodesOrAppElements, renderNodes);
          }
        }
      } else {
        renderNodes.push(node);
      }
    }
    return renderNodes;
  }
  var EMPTY_ARR = [];
  function ensureSlotCount(projectableNodes, expectedSlotCount) {
    var res;
    if (lang_1.isBlank(projectableNodes)) {
      res = EMPTY_ARR;
    } else if (projectableNodes.length < expectedSlotCount) {
      var givenSlotCount = projectableNodes.length;
      res = collection_1.ListWrapper.createFixedSize(expectedSlotCount);
      for (var i = 0; i < expectedSlotCount; i++) {
        res[i] = (i < givenSlotCount) ? projectableNodes[i] : EMPTY_ARR;
      }
    } else {
      res = projectableNodes;
    }
    return res;
  }
  exports.ensureSlotCount = ensureSlotCount;
  exports.MAX_INTERPOLATION_VALUES = 9;
  function interpolate(valueCount, c0, a1, c1, a2, c2, a3, c3, a4, c4, a5, c5, a6, c6, a7, c7, a8, c8, a9, c9) {
    switch (valueCount) {
      case 1:
        return c0 + _toStringWithNull(a1) + c1;
      case 2:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2;
      case 3:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3;
      case 4:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4;
      case 5:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5;
      case 6:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6;
      case 7:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7;
      case 8:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7 + _toStringWithNull(a8) + c8;
      case 9:
        return c0 + _toStringWithNull(a1) + c1 + _toStringWithNull(a2) + c2 + _toStringWithNull(a3) + c3 + _toStringWithNull(a4) + c4 + _toStringWithNull(a5) + c5 + _toStringWithNull(a6) + c6 + _toStringWithNull(a7) + c7 + _toStringWithNull(a8) + c8 + _toStringWithNull(a9) + c9;
      default:
        throw new exceptions_1.BaseException("Does not support more than 9 expressions");
    }
  }
  exports.interpolate = interpolate;
  function _toStringWithNull(v) {
    return v != null ? v.toString() : '';
  }
  function checkBinding(throwOnChange, oldValue, newValue) {
    if (throwOnChange) {
      if (!change_detection_1.devModeEqual(oldValue, newValue)) {
        throw new exceptions_2.ExpressionChangedAfterItHasBeenCheckedException(oldValue, newValue, null);
      }
      return false;
    } else {
      return !lang_1.looseIdentical(oldValue, newValue);
    }
  }
  exports.checkBinding = checkBinding;
  function arrayLooseIdentical(a, b) {
    if (a.length != b.length)
      return false;
    for (var i = 0; i < a.length; ++i) {
      if (!lang_1.looseIdentical(a[i], b[i]))
        return false;
    }
    return true;
  }
  exports.arrayLooseIdentical = arrayLooseIdentical;
  function mapLooseIdentical(m1, m2) {
    var k1 = collection_1.StringMapWrapper.keys(m1);
    var k2 = collection_1.StringMapWrapper.keys(m2);
    if (k1.length != k2.length) {
      return false;
    }
    var key;
    for (var i = 0; i < k1.length; i++) {
      key = k1[i];
      if (!lang_1.looseIdentical(m1[key], m2[key])) {
        return false;
      }
    }
    return true;
  }
  exports.mapLooseIdentical = mapLooseIdentical;
  function castByValue(input, value) {
    return input;
  }
  exports.castByValue = castByValue;
  exports.EMPTY_ARRAY = [];
  exports.EMPTY_MAP = {};
  function pureProxy1(fn) {
    var result;
    var v0;
    v0 = change_detection_util_1.uninitialized;
    return function(p0) {
      if (!lang_1.looseIdentical(v0, p0)) {
        v0 = p0;
        result = fn(p0);
      }
      return result;
    };
  }
  exports.pureProxy1 = pureProxy1;
  function pureProxy2(fn) {
    var result;
    var v0,
        v1;
    v0 = v1 = change_detection_util_1.uninitialized;
    return function(p0, p1) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1)) {
        v0 = p0;
        v1 = p1;
        result = fn(p0, p1);
      }
      return result;
    };
  }
  exports.pureProxy2 = pureProxy2;
  function pureProxy3(fn) {
    var result;
    var v0,
        v1,
        v2;
    v0 = v1 = v2 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        result = fn(p0, p1, p2);
      }
      return result;
    };
  }
  exports.pureProxy3 = pureProxy3;
  function pureProxy4(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3;
    v0 = v1 = v2 = v3 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        result = fn(p0, p1, p2, p3);
      }
      return result;
    };
  }
  exports.pureProxy4 = pureProxy4;
  function pureProxy5(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4;
    v0 = v1 = v2 = v3 = v4 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        result = fn(p0, p1, p2, p3, p4);
      }
      return result;
    };
  }
  exports.pureProxy5 = pureProxy5;
  function pureProxy6(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4,
        v5;
    v0 = v1 = v2 = v3 = v4 = v5 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4, p5) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4) || !lang_1.looseIdentical(v5, p5)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        v5 = p5;
        result = fn(p0, p1, p2, p3, p4, p5);
      }
      return result;
    };
  }
  exports.pureProxy6 = pureProxy6;
  function pureProxy7(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4,
        v5,
        v6;
    v0 = v1 = v2 = v3 = v4 = v5 = v6 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4, p5, p6) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4) || !lang_1.looseIdentical(v5, p5) || !lang_1.looseIdentical(v6, p6)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        v5 = p5;
        v6 = p6;
        result = fn(p0, p1, p2, p3, p4, p5, p6);
      }
      return result;
    };
  }
  exports.pureProxy7 = pureProxy7;
  function pureProxy8(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4,
        v5,
        v6,
        v7;
    v0 = v1 = v2 = v3 = v4 = v5 = v6 = v7 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4, p5, p6, p7) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4) || !lang_1.looseIdentical(v5, p5) || !lang_1.looseIdentical(v6, p6) || !lang_1.looseIdentical(v7, p7)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        v5 = p5;
        v6 = p6;
        v7 = p7;
        result = fn(p0, p1, p2, p3, p4, p5, p6, p7);
      }
      return result;
    };
  }
  exports.pureProxy8 = pureProxy8;
  function pureProxy9(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4,
        v5,
        v6,
        v7,
        v8;
    v0 = v1 = v2 = v3 = v4 = v5 = v6 = v7 = v8 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4, p5, p6, p7, p8) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4) || !lang_1.looseIdentical(v5, p5) || !lang_1.looseIdentical(v6, p6) || !lang_1.looseIdentical(v7, p7) || !lang_1.looseIdentical(v8, p8)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        v5 = p5;
        v6 = p6;
        v7 = p7;
        v8 = p8;
        result = fn(p0, p1, p2, p3, p4, p5, p6, p7, p8);
      }
      return result;
    };
  }
  exports.pureProxy9 = pureProxy9;
  function pureProxy10(fn) {
    var result;
    var v0,
        v1,
        v2,
        v3,
        v4,
        v5,
        v6,
        v7,
        v8,
        v9;
    v0 = v1 = v2 = v3 = v4 = v5 = v6 = v7 = v8 = v9 = change_detection_util_1.uninitialized;
    return function(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9) {
      if (!lang_1.looseIdentical(v0, p0) || !lang_1.looseIdentical(v1, p1) || !lang_1.looseIdentical(v2, p2) || !lang_1.looseIdentical(v3, p3) || !lang_1.looseIdentical(v4, p4) || !lang_1.looseIdentical(v5, p5) || !lang_1.looseIdentical(v6, p6) || !lang_1.looseIdentical(v7, p7) || !lang_1.looseIdentical(v8, p8) || !lang_1.looseIdentical(v9, p9)) {
        v0 = p0;
        v1 = p1;
        v2 = p2;
        v3 = p3;
        v4 = p4;
        v5 = p5;
        v6 = p6;
        v7 = p7;
        v8 = p8;
        v9 = p9;
        result = fn(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9);
      }
      return result;
    };
  }
  exports.pureProxy10 = pureProxy10;
  return module.exports;
});

$__System.registerDynamic("298", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  var process = module.exports = {};
  var queue = [];
  var draining = false;
  var currentQueue;
  var queueIndex = -1;
  function cleanUpNextTick() {
    draining = false;
    if (currentQueue.length) {
      queue = currentQueue.concat(queue);
    } else {
      queueIndex = -1;
    }
    if (queue.length) {
      drainQueue();
    }
  }
  function drainQueue() {
    if (draining) {
      return;
    }
    var timeout = setTimeout(cleanUpNextTick);
    draining = true;
    var len = queue.length;
    while (len) {
      currentQueue = queue;
      queue = [];
      while (++queueIndex < len) {
        if (currentQueue) {
          currentQueue[queueIndex].run();
        }
      }
      queueIndex = -1;
      len = queue.length;
    }
    currentQueue = null;
    draining = false;
    clearTimeout(timeout);
  }
  process.nextTick = function(fun) {
    var args = new Array(arguments.length - 1);
    if (arguments.length > 1) {
      for (var i = 1; i < arguments.length; i++) {
        args[i - 1] = arguments[i];
      }
    }
    queue.push(new Item(fun, args));
    if (queue.length === 1 && !draining) {
      setTimeout(drainQueue, 0);
    }
  };
  function Item(fun, array) {
    this.fun = fun;
    this.array = array;
  }
  Item.prototype.run = function() {
    this.fun.apply(null, this.array);
  };
  process.title = 'browser';
  process.browser = true;
  process.env = {};
  process.argv = [];
  process.version = '';
  process.versions = {};
  function noop() {}
  process.on = noop;
  process.addListener = noop;
  process.once = noop;
  process.off = noop;
  process.removeListener = noop;
  process.removeAllListeners = noop;
  process.emit = noop;
  process.binding = function(name) {
    throw new Error('process.binding is not supported');
  };
  process.cwd = function() {
    return '/';
  };
  process.chdir = function(dir) {
    throw new Error('process.chdir is not supported');
  };
  process.umask = function() {
    return 0;
  };
  return module.exports;
});

$__System.registerDynamic("299", ["298"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('298');
  return module.exports;
});

$__System.registerDynamic("29a", ["299"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__System._nodeRequire ? process : $__require('299');
  return module.exports;
});

$__System.registerDynamic("22", ["29a"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('29a');
  return module.exports;
});

$__System.registerDynamic("24c", ["22"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(process) {
    "use strict";
    (function(ViewEncapsulation) {
      ViewEncapsulation[ViewEncapsulation["Emulated"] = 0] = "Emulated";
      ViewEncapsulation[ViewEncapsulation["Native"] = 1] = "Native";
      ViewEncapsulation[ViewEncapsulation["None"] = 2] = "None";
    })(exports.ViewEncapsulation || (exports.ViewEncapsulation = {}));
    var ViewEncapsulation = exports.ViewEncapsulation;
    exports.VIEW_ENCAPSULATION_VALUES = [ViewEncapsulation.Emulated, ViewEncapsulation.Native, ViewEncapsulation.None];
    var ViewMetadata = (function() {
      function ViewMetadata(_a) {
        var _b = _a === void 0 ? {} : _a,
            templateUrl = _b.templateUrl,
            template = _b.template,
            directives = _b.directives,
            pipes = _b.pipes,
            encapsulation = _b.encapsulation,
            styles = _b.styles,
            styleUrls = _b.styleUrls;
        this.templateUrl = templateUrl;
        this.template = template;
        this.styleUrls = styleUrls;
        this.styles = styles;
        this.directives = directives;
        this.pipes = pipes;
        this.encapsulation = encapsulation;
      }
      return ViewMetadata;
    }());
    exports.ViewMetadata = ViewMetadata;
  })($__require('22'));
  return module.exports;
});

$__System.registerDynamic("286", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  (function(ViewType) {
    ViewType[ViewType["HOST"] = 0] = "HOST";
    ViewType[ViewType["COMPONENT"] = 1] = "COMPONENT";
    ViewType[ViewType["EMBEDDED"] = 2] = "EMBEDDED";
  })(exports.ViewType || (exports.ViewType = {}));
  var ViewType = exports.ViewType;
  return module.exports;
});

$__System.registerDynamic("287", ["9c", "254", "286"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var view_type_1 = $__require('286');
  var StaticNodeDebugInfo = (function() {
    function StaticNodeDebugInfo(providerTokens, componentToken, refTokens) {
      this.providerTokens = providerTokens;
      this.componentToken = componentToken;
      this.refTokens = refTokens;
    }
    return StaticNodeDebugInfo;
  }());
  exports.StaticNodeDebugInfo = StaticNodeDebugInfo;
  var DebugContext = (function() {
    function DebugContext(_view, _nodeIndex, _tplRow, _tplCol) {
      this._view = _view;
      this._nodeIndex = _nodeIndex;
      this._tplRow = _tplRow;
      this._tplCol = _tplCol;
    }
    Object.defineProperty(DebugContext.prototype, "_staticNodeInfo", {
      get: function() {
        return lang_1.isPresent(this._nodeIndex) ? this._view.staticNodeDebugInfos[this._nodeIndex] : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "context", {
      get: function() {
        return this._view.context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "component", {
      get: function() {
        var staticNodeInfo = this._staticNodeInfo;
        if (lang_1.isPresent(staticNodeInfo) && lang_1.isPresent(staticNodeInfo.componentToken)) {
          return this.injector.get(staticNodeInfo.componentToken);
        }
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "componentRenderElement", {
      get: function() {
        var componentView = this._view;
        while (lang_1.isPresent(componentView.declarationAppElement) && componentView.type !== view_type_1.ViewType.COMPONENT) {
          componentView = componentView.declarationAppElement.parentView;
        }
        return lang_1.isPresent(componentView.declarationAppElement) ? componentView.declarationAppElement.nativeElement : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "injector", {
      get: function() {
        return this._view.injector(this._nodeIndex);
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "renderNode", {
      get: function() {
        if (lang_1.isPresent(this._nodeIndex) && lang_1.isPresent(this._view.allNodes)) {
          return this._view.allNodes[this._nodeIndex];
        } else {
          return null;
        }
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "providerTokens", {
      get: function() {
        var staticNodeInfo = this._staticNodeInfo;
        return lang_1.isPresent(staticNodeInfo) ? staticNodeInfo.providerTokens : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "source", {
      get: function() {
        return this._view.componentType.templateUrl + ":" + this._tplRow + ":" + this._tplCol;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugContext.prototype, "references", {
      get: function() {
        var _this = this;
        var varValues = {};
        var staticNodeInfo = this._staticNodeInfo;
        if (lang_1.isPresent(staticNodeInfo)) {
          var refs = staticNodeInfo.refTokens;
          collection_1.StringMapWrapper.forEach(refs, function(refToken, refName) {
            var varValue;
            if (lang_1.isBlank(refToken)) {
              varValue = lang_1.isPresent(_this._view.allNodes) ? _this._view.allNodes[_this._nodeIndex] : null;
            } else {
              varValue = _this._view.injectorGet(refToken, _this._nodeIndex, null);
            }
            varValues[refName] = varValue;
          });
        }
        return varValues;
      },
      enumerable: true,
      configurable: true
    });
    return DebugContext;
  }());
  exports.DebugContext = DebugContext;
  return module.exports;
});

$__System.registerDynamic("28f", ["9c", "254"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var lang_2 = $__require('9c');
  exports.looseIdentical = lang_2.looseIdentical;
  exports.uninitialized = new Object();
  function devModeEqual(a, b) {
    if (collection_1.isListLikeIterable(a) && collection_1.isListLikeIterable(b)) {
      return collection_1.areIterablesEqual(a, b, devModeEqual);
    } else if (!collection_1.isListLikeIterable(a) && !lang_1.isPrimitive(a) && !collection_1.isListLikeIterable(b) && !lang_1.isPrimitive(b)) {
      return true;
    } else {
      return lang_1.looseIdentical(a, b);
    }
  }
  exports.devModeEqual = devModeEqual;
  var WrappedValue = (function() {
    function WrappedValue(wrapped) {
      this.wrapped = wrapped;
    }
    WrappedValue.wrap = function(value) {
      return new WrappedValue(value);
    };
    return WrappedValue;
  }());
  exports.WrappedValue = WrappedValue;
  var ValueUnwrapper = (function() {
    function ValueUnwrapper() {
      this.hasWrappedValue = false;
    }
    ValueUnwrapper.prototype.unwrap = function(value) {
      if (value instanceof WrappedValue) {
        this.hasWrappedValue = true;
        return value.wrapped;
      }
      return value;
    };
    ValueUnwrapper.prototype.reset = function() {
      this.hasWrappedValue = false;
    };
    return ValueUnwrapper;
  }());
  exports.ValueUnwrapper = ValueUnwrapper;
  var SimpleChange = (function() {
    function SimpleChange(previousValue, currentValue) {
      this.previousValue = previousValue;
      this.currentValue = currentValue;
    }
    SimpleChange.prototype.isFirstChange = function() {
      return this.previousValue === exports.uninitialized;
    };
    return SimpleChange;
  }());
  exports.SimpleChange = SimpleChange;
  return module.exports;
});

$__System.registerDynamic("252", ["a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var exceptions_1 = $__require('a9');
  var RenderComponentType = (function() {
    function RenderComponentType(id, templateUrl, slotCount, encapsulation, styles) {
      this.id = id;
      this.templateUrl = templateUrl;
      this.slotCount = slotCount;
      this.encapsulation = encapsulation;
      this.styles = styles;
    }
    return RenderComponentType;
  }());
  exports.RenderComponentType = RenderComponentType;
  var RenderDebugInfo = (function() {
    function RenderDebugInfo() {}
    Object.defineProperty(RenderDebugInfo.prototype, "injector", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderDebugInfo.prototype, "component", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderDebugInfo.prototype, "providerTokens", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderDebugInfo.prototype, "references", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderDebugInfo.prototype, "context", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(RenderDebugInfo.prototype, "source", {
      get: function() {
        return exceptions_1.unimplemented();
      },
      enumerable: true,
      configurable: true
    });
    return RenderDebugInfo;
  }());
  exports.RenderDebugInfo = RenderDebugInfo;
  var Renderer = (function() {
    function Renderer() {}
    return Renderer;
  }());
  exports.Renderer = Renderer;
  var RootRenderer = (function() {
    function RootRenderer() {}
    return RootRenderer;
  }());
  exports.RootRenderer = RootRenderer;
  return module.exports;
});

$__System.registerDynamic("25a", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var EMPTY_CONTEXT = new Object();
  var TemplateRef = (function() {
    function TemplateRef() {}
    Object.defineProperty(TemplateRef.prototype, "elementRef", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    return TemplateRef;
  }());
  exports.TemplateRef = TemplateRef;
  var TemplateRef_ = (function(_super) {
    __extends(TemplateRef_, _super);
    function TemplateRef_(_appElement, _viewFactory) {
      _super.call(this);
      this._appElement = _appElement;
      this._viewFactory = _viewFactory;
    }
    TemplateRef_.prototype.createEmbeddedView = function(context) {
      var view = this._viewFactory(this._appElement.parentView.viewUtils, this._appElement.parentInjector, this._appElement);
      if (lang_1.isBlank(context)) {
        context = EMPTY_CONTEXT;
      }
      view.create(context, null, null);
      return view.ref;
    };
    Object.defineProperty(TemplateRef_.prototype, "elementRef", {
      get: function() {
        return this._appElement.elementRef;
      },
      enumerable: true,
      configurable: true
    });
    return TemplateRef_;
  }(TemplateRef));
  exports.TemplateRef_ = TemplateRef_;
  return module.exports;
});

$__System.registerDynamic("29b", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function wtfInit() {}
  exports.wtfInit = wtfInit;
  return module.exports;
});

$__System.registerDynamic("294", ["9c", "a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var ReflectionCapabilities = (function() {
    function ReflectionCapabilities(reflect) {
      this._reflect = lang_1.isPresent(reflect) ? reflect : lang_1.global.Reflect;
    }
    ReflectionCapabilities.prototype.isReflectionEnabled = function() {
      return true;
    };
    ReflectionCapabilities.prototype.factory = function(t) {
      switch (t.length) {
        case 0:
          return function() {
            return new t();
          };
        case 1:
          return function(a1) {
            return new t(a1);
          };
        case 2:
          return function(a1, a2) {
            return new t(a1, a2);
          };
        case 3:
          return function(a1, a2, a3) {
            return new t(a1, a2, a3);
          };
        case 4:
          return function(a1, a2, a3, a4) {
            return new t(a1, a2, a3, a4);
          };
        case 5:
          return function(a1, a2, a3, a4, a5) {
            return new t(a1, a2, a3, a4, a5);
          };
        case 6:
          return function(a1, a2, a3, a4, a5, a6) {
            return new t(a1, a2, a3, a4, a5, a6);
          };
        case 7:
          return function(a1, a2, a3, a4, a5, a6, a7) {
            return new t(a1, a2, a3, a4, a5, a6, a7);
          };
        case 8:
          return function(a1, a2, a3, a4, a5, a6, a7, a8) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8);
          };
        case 9:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9);
          };
        case 10:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10);
          };
        case 11:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11);
          };
        case 12:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12);
          };
        case 13:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13);
          };
        case 14:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14);
          };
        case 15:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15);
          };
        case 16:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16);
          };
        case 17:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17);
          };
        case 18:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18);
          };
        case 19:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19);
          };
        case 20:
          return function(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19, a20) {
            return new t(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18, a19, a20);
          };
      }
      ;
      throw new Error("Cannot create a factory for '" + lang_1.stringify(t) + "' because its constructor has more than 20 arguments");
    };
    ReflectionCapabilities.prototype._zipTypesAndAnnotations = function(paramTypes, paramAnnotations) {
      var result;
      if (typeof paramTypes === 'undefined') {
        result = new Array(paramAnnotations.length);
      } else {
        result = new Array(paramTypes.length);
      }
      for (var i = 0; i < result.length; i++) {
        if (typeof paramTypes === 'undefined') {
          result[i] = [];
        } else if (paramTypes[i] != Object) {
          result[i] = [paramTypes[i]];
        } else {
          result[i] = [];
        }
        if (lang_1.isPresent(paramAnnotations) && lang_1.isPresent(paramAnnotations[i])) {
          result[i] = result[i].concat(paramAnnotations[i]);
        }
      }
      return result;
    };
    ReflectionCapabilities.prototype.parameters = function(typeOrFunc) {
      if (lang_1.isPresent(typeOrFunc.parameters)) {
        return typeOrFunc.parameters;
      }
      if (lang_1.isPresent(typeOrFunc.ctorParameters)) {
        var ctorParameters = typeOrFunc.ctorParameters;
        var paramTypes_1 = ctorParameters.map(function(ctorParam) {
          return ctorParam && ctorParam.type;
        });
        var paramAnnotations_1 = ctorParameters.map(function(ctorParam) {
          return ctorParam && convertTsickleDecoratorIntoMetadata(ctorParam.decorators);
        });
        return this._zipTypesAndAnnotations(paramTypes_1, paramAnnotations_1);
      }
      if (lang_1.isPresent(this._reflect) && lang_1.isPresent(this._reflect.getMetadata)) {
        var paramAnnotations = this._reflect.getMetadata('parameters', typeOrFunc);
        var paramTypes = this._reflect.getMetadata('design:paramtypes', typeOrFunc);
        if (lang_1.isPresent(paramTypes) || lang_1.isPresent(paramAnnotations)) {
          return this._zipTypesAndAnnotations(paramTypes, paramAnnotations);
        }
      }
      var parameters = new Array(typeOrFunc.length);
      parameters.fill(undefined);
      return parameters;
    };
    ReflectionCapabilities.prototype.annotations = function(typeOrFunc) {
      if (lang_1.isPresent(typeOrFunc.annotations)) {
        var annotations = typeOrFunc.annotations;
        if (lang_1.isFunction(annotations) && annotations.annotations) {
          annotations = annotations.annotations;
        }
        return annotations;
      }
      if (lang_1.isPresent(typeOrFunc.decorators)) {
        return convertTsickleDecoratorIntoMetadata(typeOrFunc.decorators);
      }
      if (lang_1.isPresent(this._reflect) && lang_1.isPresent(this._reflect.getMetadata)) {
        var annotations = this._reflect.getMetadata('annotations', typeOrFunc);
        if (lang_1.isPresent(annotations))
          return annotations;
      }
      return [];
    };
    ReflectionCapabilities.prototype.propMetadata = function(typeOrFunc) {
      if (lang_1.isPresent(typeOrFunc.propMetadata)) {
        var propMetadata = typeOrFunc.propMetadata;
        if (lang_1.isFunction(propMetadata) && propMetadata.propMetadata) {
          propMetadata = propMetadata.propMetadata;
        }
        return propMetadata;
      }
      if (lang_1.isPresent(typeOrFunc.propDecorators)) {
        var propDecorators_1 = typeOrFunc.propDecorators;
        var propMetadata_1 = {};
        Object.keys(propDecorators_1).forEach(function(prop) {
          propMetadata_1[prop] = convertTsickleDecoratorIntoMetadata(propDecorators_1[prop]);
        });
        return propMetadata_1;
      }
      if (lang_1.isPresent(this._reflect) && lang_1.isPresent(this._reflect.getMetadata)) {
        var propMetadata = this._reflect.getMetadata('propMetadata', typeOrFunc);
        if (lang_1.isPresent(propMetadata))
          return propMetadata;
      }
      return {};
    };
    ReflectionCapabilities.prototype.interfaces = function(type) {
      throw new exceptions_1.BaseException("JavaScript does not support interfaces");
    };
    ReflectionCapabilities.prototype.getter = function(name) {
      return new Function('o', 'return o.' + name + ';');
    };
    ReflectionCapabilities.prototype.setter = function(name) {
      return new Function('o', 'v', 'return o.' + name + ' = v;');
    };
    ReflectionCapabilities.prototype.method = function(name) {
      var functionBody = "if (!o." + name + ") throw new Error('\"" + name + "\" is undefined');\n        return o." + name + ".apply(o, args);";
      return new Function('o', 'args', functionBody);
    };
    ReflectionCapabilities.prototype.importUri = function(type) {
      return "./" + lang_1.stringify(type);
    };
    return ReflectionCapabilities;
  }());
  exports.ReflectionCapabilities = ReflectionCapabilities;
  function convertTsickleDecoratorIntoMetadata(decoratorInvocations) {
    if (!decoratorInvocations) {
      return [];
    }
    return decoratorInvocations.map(function(decoratorInvocation) {
      var decoratorType = decoratorInvocation.type;
      var annotationCls = decoratorType.annotationCls;
      var annotationArgs = decoratorInvocation.args ? decoratorInvocation.args : [];
      var annotation = Object.create(annotationCls.prototype);
      annotationCls.apply(annotation, annotationArgs);
      return annotation;
    });
  }
  return module.exports;
});

$__System.registerDynamic("29c", ["9c", "254"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var collection_1 = $__require('254');
  var EventListener = (function() {
    function EventListener(name, callback) {
      this.name = name;
      this.callback = callback;
    }
    ;
    return EventListener;
  }());
  exports.EventListener = EventListener;
  var DebugNode = (function() {
    function DebugNode(nativeNode, parent, _debugInfo) {
      this._debugInfo = _debugInfo;
      this.nativeNode = nativeNode;
      if (lang_1.isPresent(parent) && parent instanceof DebugElement) {
        parent.addChild(this);
      } else {
        this.parent = null;
      }
      this.listeners = [];
    }
    Object.defineProperty(DebugNode.prototype, "injector", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.injector : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugNode.prototype, "componentInstance", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.component : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugNode.prototype, "context", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.context : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugNode.prototype, "references", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.references : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugNode.prototype, "providerTokens", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.providerTokens : null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(DebugNode.prototype, "source", {
      get: function() {
        return lang_1.isPresent(this._debugInfo) ? this._debugInfo.source : null;
      },
      enumerable: true,
      configurable: true
    });
    DebugNode.prototype.inject = function(token) {
      return this.injector.get(token);
    };
    return DebugNode;
  }());
  exports.DebugNode = DebugNode;
  var DebugElement = (function(_super) {
    __extends(DebugElement, _super);
    function DebugElement(nativeNode, parent, _debugInfo) {
      _super.call(this, nativeNode, parent, _debugInfo);
      this.properties = {};
      this.attributes = {};
      this.childNodes = [];
      this.nativeElement = nativeNode;
    }
    DebugElement.prototype.addChild = function(child) {
      if (lang_1.isPresent(child)) {
        this.childNodes.push(child);
        child.parent = this;
      }
    };
    DebugElement.prototype.removeChild = function(child) {
      var childIndex = this.childNodes.indexOf(child);
      if (childIndex !== -1) {
        child.parent = null;
        this.childNodes.splice(childIndex, 1);
      }
    };
    DebugElement.prototype.insertChildrenAfter = function(child, newChildren) {
      var siblingIndex = this.childNodes.indexOf(child);
      if (siblingIndex !== -1) {
        var previousChildren = this.childNodes.slice(0, siblingIndex + 1);
        var nextChildren = this.childNodes.slice(siblingIndex + 1);
        this.childNodes = collection_1.ListWrapper.concat(collection_1.ListWrapper.concat(previousChildren, newChildren), nextChildren);
        for (var i = 0; i < newChildren.length; ++i) {
          var newChild = newChildren[i];
          if (lang_1.isPresent(newChild.parent)) {
            newChild.parent.removeChild(newChild);
          }
          newChild.parent = this;
        }
      }
    };
    DebugElement.prototype.query = function(predicate) {
      var results = this.queryAll(predicate);
      return results.length > 0 ? results[0] : null;
    };
    DebugElement.prototype.queryAll = function(predicate) {
      var matches = [];
      _queryElementChildren(this, predicate, matches);
      return matches;
    };
    DebugElement.prototype.queryAllNodes = function(predicate) {
      var matches = [];
      _queryNodeChildren(this, predicate, matches);
      return matches;
    };
    Object.defineProperty(DebugElement.prototype, "children", {
      get: function() {
        var children = [];
        this.childNodes.forEach(function(node) {
          if (node instanceof DebugElement) {
            children.push(node);
          }
        });
        return children;
      },
      enumerable: true,
      configurable: true
    });
    DebugElement.prototype.triggerEventHandler = function(eventName, eventObj) {
      this.listeners.forEach(function(listener) {
        if (listener.name == eventName) {
          listener.callback(eventObj);
        }
      });
    };
    return DebugElement;
  }(DebugNode));
  exports.DebugElement = DebugElement;
  function asNativeElements(debugEls) {
    return debugEls.map(function(el) {
      return el.nativeElement;
    });
  }
  exports.asNativeElements = asNativeElements;
  function _queryElementChildren(element, predicate, matches) {
    element.childNodes.forEach(function(node) {
      if (node instanceof DebugElement) {
        if (predicate(node)) {
          matches.push(node);
        }
        _queryElementChildren(node, predicate, matches);
      }
    });
  }
  function _queryNodeChildren(parentNode, predicate, matches) {
    if (parentNode instanceof DebugElement) {
      parentNode.childNodes.forEach(function(node) {
        if (predicate(node)) {
          matches.push(node);
        }
        if (node instanceof DebugElement) {
          _queryNodeChildren(node, predicate, matches);
        }
      });
    }
  }
  var _nativeNodeToDebugNode = new Map();
  function getDebugNode(nativeNode) {
    return _nativeNodeToDebugNode.get(nativeNode);
  }
  exports.getDebugNode = getDebugNode;
  function getAllDebugNodes() {
    return collection_1.MapWrapper.values(_nativeNodeToDebugNode);
  }
  exports.getAllDebugNodes = getAllDebugNodes;
  function indexDebugNode(node) {
    _nativeNodeToDebugNode.set(node.nativeNode, node);
  }
  exports.indexDebugNode = indexDebugNode;
  function removeDebugNodeFromIndex(node) {
    _nativeNodeToDebugNode.delete(node.nativeNode);
  }
  exports.removeDebugNodeFromIndex = removeDebugNodeFromIndex;
  return module.exports;
});

$__System.registerDynamic("29d", ["9c", "29c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var debug_node_1 = $__require('29c');
  var DebugDomRootRenderer = (function() {
    function DebugDomRootRenderer(_delegate) {
      this._delegate = _delegate;
    }
    DebugDomRootRenderer.prototype.renderComponent = function(componentProto) {
      return new DebugDomRenderer(this._delegate.renderComponent(componentProto));
    };
    return DebugDomRootRenderer;
  }());
  exports.DebugDomRootRenderer = DebugDomRootRenderer;
  var DebugDomRenderer = (function() {
    function DebugDomRenderer(_delegate) {
      this._delegate = _delegate;
    }
    DebugDomRenderer.prototype.selectRootElement = function(selectorOrNode, debugInfo) {
      var nativeEl = this._delegate.selectRootElement(selectorOrNode, debugInfo);
      var debugEl = new debug_node_1.DebugElement(nativeEl, null, debugInfo);
      debug_node_1.indexDebugNode(debugEl);
      return nativeEl;
    };
    DebugDomRenderer.prototype.createElement = function(parentElement, name, debugInfo) {
      var nativeEl = this._delegate.createElement(parentElement, name, debugInfo);
      var debugEl = new debug_node_1.DebugElement(nativeEl, debug_node_1.getDebugNode(parentElement), debugInfo);
      debugEl.name = name;
      debug_node_1.indexDebugNode(debugEl);
      return nativeEl;
    };
    DebugDomRenderer.prototype.createViewRoot = function(hostElement) {
      return this._delegate.createViewRoot(hostElement);
    };
    DebugDomRenderer.prototype.createTemplateAnchor = function(parentElement, debugInfo) {
      var comment = this._delegate.createTemplateAnchor(parentElement, debugInfo);
      var debugEl = new debug_node_1.DebugNode(comment, debug_node_1.getDebugNode(parentElement), debugInfo);
      debug_node_1.indexDebugNode(debugEl);
      return comment;
    };
    DebugDomRenderer.prototype.createText = function(parentElement, value, debugInfo) {
      var text = this._delegate.createText(parentElement, value, debugInfo);
      var debugEl = new debug_node_1.DebugNode(text, debug_node_1.getDebugNode(parentElement), debugInfo);
      debug_node_1.indexDebugNode(debugEl);
      return text;
    };
    DebugDomRenderer.prototype.projectNodes = function(parentElement, nodes) {
      var debugParent = debug_node_1.getDebugNode(parentElement);
      if (lang_1.isPresent(debugParent) && debugParent instanceof debug_node_1.DebugElement) {
        var debugElement_1 = debugParent;
        nodes.forEach(function(node) {
          debugElement_1.addChild(debug_node_1.getDebugNode(node));
        });
      }
      this._delegate.projectNodes(parentElement, nodes);
    };
    DebugDomRenderer.prototype.attachViewAfter = function(node, viewRootNodes) {
      var debugNode = debug_node_1.getDebugNode(node);
      if (lang_1.isPresent(debugNode)) {
        var debugParent = debugNode.parent;
        if (viewRootNodes.length > 0 && lang_1.isPresent(debugParent)) {
          var debugViewRootNodes = [];
          viewRootNodes.forEach(function(rootNode) {
            return debugViewRootNodes.push(debug_node_1.getDebugNode(rootNode));
          });
          debugParent.insertChildrenAfter(debugNode, debugViewRootNodes);
        }
      }
      this._delegate.attachViewAfter(node, viewRootNodes);
    };
    DebugDomRenderer.prototype.detachView = function(viewRootNodes) {
      viewRootNodes.forEach(function(node) {
        var debugNode = debug_node_1.getDebugNode(node);
        if (lang_1.isPresent(debugNode) && lang_1.isPresent(debugNode.parent)) {
          debugNode.parent.removeChild(debugNode);
        }
      });
      this._delegate.detachView(viewRootNodes);
    };
    DebugDomRenderer.prototype.destroyView = function(hostElement, viewAllNodes) {
      viewAllNodes.forEach(function(node) {
        debug_node_1.removeDebugNodeFromIndex(debug_node_1.getDebugNode(node));
      });
      this._delegate.destroyView(hostElement, viewAllNodes);
    };
    DebugDomRenderer.prototype.listen = function(renderElement, name, callback) {
      var debugEl = debug_node_1.getDebugNode(renderElement);
      if (lang_1.isPresent(debugEl)) {
        debugEl.listeners.push(new debug_node_1.EventListener(name, callback));
      }
      return this._delegate.listen(renderElement, name, callback);
    };
    DebugDomRenderer.prototype.listenGlobal = function(target, name, callback) {
      return this._delegate.listenGlobal(target, name, callback);
    };
    DebugDomRenderer.prototype.setElementProperty = function(renderElement, propertyName, propertyValue) {
      var debugEl = debug_node_1.getDebugNode(renderElement);
      if (lang_1.isPresent(debugEl) && debugEl instanceof debug_node_1.DebugElement) {
        debugEl.properties[propertyName] = propertyValue;
      }
      this._delegate.setElementProperty(renderElement, propertyName, propertyValue);
    };
    DebugDomRenderer.prototype.setElementAttribute = function(renderElement, attributeName, attributeValue) {
      var debugEl = debug_node_1.getDebugNode(renderElement);
      if (lang_1.isPresent(debugEl) && debugEl instanceof debug_node_1.DebugElement) {
        debugEl.attributes[attributeName] = attributeValue;
      }
      this._delegate.setElementAttribute(renderElement, attributeName, attributeValue);
    };
    DebugDomRenderer.prototype.setBindingDebugInfo = function(renderElement, propertyName, propertyValue) {
      this._delegate.setBindingDebugInfo(renderElement, propertyName, propertyValue);
    };
    DebugDomRenderer.prototype.setElementClass = function(renderElement, className, isAdd) {
      this._delegate.setElementClass(renderElement, className, isAdd);
    };
    DebugDomRenderer.prototype.setElementStyle = function(renderElement, styleName, styleValue) {
      this._delegate.setElementStyle(renderElement, styleName, styleValue);
    };
    DebugDomRenderer.prototype.invokeElementMethod = function(renderElement, methodName, args) {
      this._delegate.invokeElementMethod(renderElement, methodName, args);
    };
    DebugDomRenderer.prototype.setText = function(renderNode, text) {
      this._delegate.setText(renderNode, text);
    };
    return DebugDomRenderer;
  }());
  exports.DebugDomRenderer = DebugDomRenderer;
  return module.exports;
});

$__System.registerDynamic("29e", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var BaseWrappedException = (function(_super) {
    __extends(BaseWrappedException, _super);
    function BaseWrappedException(message) {
      _super.call(this, message);
    }
    Object.defineProperty(BaseWrappedException.prototype, "wrapperMessage", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "wrapperStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalException", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "originalStack", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "context", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(BaseWrappedException.prototype, "message", {
      get: function() {
        return '';
      },
      enumerable: true,
      configurable: true
    });
    return BaseWrappedException;
  }(Error));
  exports.BaseWrappedException = BaseWrappedException;
  return module.exports;
});

$__System.registerDynamic("254", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  exports.Map = lang_1.global.Map;
  exports.Set = lang_1.global.Set;
  var createMapFromPairs = (function() {
    try {
      if (new exports.Map([[1, 2]]).size === 1) {
        return function createMapFromPairs(pairs) {
          return new exports.Map(pairs);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromPairs(pairs) {
      var map = new exports.Map();
      for (var i = 0; i < pairs.length; i++) {
        var pair = pairs[i];
        map.set(pair[0], pair[1]);
      }
      return map;
    };
  })();
  var createMapFromMap = (function() {
    try {
      if (new exports.Map(new exports.Map())) {
        return function createMapFromMap(m) {
          return new exports.Map(m);
        };
      }
    } catch (e) {}
    return function createMapAndPopulateFromMap(m) {
      var map = new exports.Map();
      m.forEach(function(v, k) {
        map.set(k, v);
      });
      return map;
    };
  })();
  var _clearValues = (function() {
    if ((new exports.Map()).keys().next) {
      return function _clearValues(m) {
        var keyIterator = m.keys();
        var k;
        while (!((k = keyIterator.next()).done)) {
          m.set(k.value, null);
        }
      };
    } else {
      return function _clearValuesWithForeEach(m) {
        m.forEach(function(v, k) {
          m.set(k, null);
        });
      };
    }
  })();
  var _arrayFromMap = (function() {
    try {
      if ((new exports.Map()).values().next) {
        return function createArrayFromMap(m, getValues) {
          return getValues ? Array.from(m.values()) : Array.from(m.keys());
        };
      }
    } catch (e) {}
    return function createArrayFromMapWithForeach(m, getValues) {
      var res = ListWrapper.createFixedSize(m.size),
          i = 0;
      m.forEach(function(v, k) {
        res[i] = getValues ? v : k;
        i++;
      });
      return res;
    };
  })();
  var MapWrapper = (function() {
    function MapWrapper() {}
    MapWrapper.clone = function(m) {
      return createMapFromMap(m);
    };
    MapWrapper.createFromStringMap = function(stringMap) {
      var result = new exports.Map();
      for (var prop in stringMap) {
        result.set(prop, stringMap[prop]);
      }
      return result;
    };
    MapWrapper.toStringMap = function(m) {
      var r = {};
      m.forEach(function(v, k) {
        return r[k] = v;
      });
      return r;
    };
    MapWrapper.createFromPairs = function(pairs) {
      return createMapFromPairs(pairs);
    };
    MapWrapper.clearValues = function(m) {
      _clearValues(m);
    };
    MapWrapper.iterable = function(m) {
      return m;
    };
    MapWrapper.keys = function(m) {
      return _arrayFromMap(m, false);
    };
    MapWrapper.values = function(m) {
      return _arrayFromMap(m, true);
    };
    return MapWrapper;
  }());
  exports.MapWrapper = MapWrapper;
  var StringMapWrapper = (function() {
    function StringMapWrapper() {}
    StringMapWrapper.create = function() {
      return {};
    };
    StringMapWrapper.contains = function(map, key) {
      return map.hasOwnProperty(key);
    };
    StringMapWrapper.get = function(map, key) {
      return map.hasOwnProperty(key) ? map[key] : undefined;
    };
    StringMapWrapper.set = function(map, key, value) {
      map[key] = value;
    };
    StringMapWrapper.keys = function(map) {
      return Object.keys(map);
    };
    StringMapWrapper.values = function(map) {
      return Object.keys(map).reduce(function(r, a) {
        r.push(map[a]);
        return r;
      }, []);
    };
    StringMapWrapper.isEmpty = function(map) {
      for (var prop in map) {
        return false;
      }
      return true;
    };
    StringMapWrapper.delete = function(map, key) {
      delete map[key];
    };
    StringMapWrapper.forEach = function(map, callback) {
      for (var prop in map) {
        if (map.hasOwnProperty(prop)) {
          callback(map[prop], prop);
        }
      }
    };
    StringMapWrapper.merge = function(m1, m2) {
      var m = {};
      for (var attr in m1) {
        if (m1.hasOwnProperty(attr)) {
          m[attr] = m1[attr];
        }
      }
      for (var attr in m2) {
        if (m2.hasOwnProperty(attr)) {
          m[attr] = m2[attr];
        }
      }
      return m;
    };
    StringMapWrapper.equals = function(m1, m2) {
      var k1 = Object.keys(m1);
      var k2 = Object.keys(m2);
      if (k1.length != k2.length) {
        return false;
      }
      var key;
      for (var i = 0; i < k1.length; i++) {
        key = k1[i];
        if (m1[key] !== m2[key]) {
          return false;
        }
      }
      return true;
    };
    return StringMapWrapper;
  }());
  exports.StringMapWrapper = StringMapWrapper;
  var ListWrapper = (function() {
    function ListWrapper() {}
    ListWrapper.createFixedSize = function(size) {
      return new Array(size);
    };
    ListWrapper.createGrowableSize = function(size) {
      return new Array(size);
    };
    ListWrapper.clone = function(array) {
      return array.slice(0);
    };
    ListWrapper.forEachWithIndex = function(array, fn) {
      for (var i = 0; i < array.length; i++) {
        fn(array[i], i);
      }
    };
    ListWrapper.first = function(array) {
      if (!array)
        return null;
      return array[0];
    };
    ListWrapper.last = function(array) {
      if (!array || array.length == 0)
        return null;
      return array[array.length - 1];
    };
    ListWrapper.indexOf = function(array, value, startIndex) {
      if (startIndex === void 0) {
        startIndex = 0;
      }
      return array.indexOf(value, startIndex);
    };
    ListWrapper.contains = function(list, el) {
      return list.indexOf(el) !== -1;
    };
    ListWrapper.reversed = function(array) {
      var a = ListWrapper.clone(array);
      return a.reverse();
    };
    ListWrapper.concat = function(a, b) {
      return a.concat(b);
    };
    ListWrapper.insert = function(list, index, value) {
      list.splice(index, 0, value);
    };
    ListWrapper.removeAt = function(list, index) {
      var res = list[index];
      list.splice(index, 1);
      return res;
    };
    ListWrapper.removeAll = function(list, items) {
      for (var i = 0; i < items.length; ++i) {
        var index = list.indexOf(items[i]);
        list.splice(index, 1);
      }
    };
    ListWrapper.remove = function(list, el) {
      var index = list.indexOf(el);
      if (index > -1) {
        list.splice(index, 1);
        return true;
      }
      return false;
    };
    ListWrapper.clear = function(list) {
      list.length = 0;
    };
    ListWrapper.isEmpty = function(list) {
      return list.length == 0;
    };
    ListWrapper.fill = function(list, value, start, end) {
      if (start === void 0) {
        start = 0;
      }
      if (end === void 0) {
        end = null;
      }
      list.fill(value, start, end === null ? list.length : end);
    };
    ListWrapper.equals = function(a, b) {
      if (a.length != b.length)
        return false;
      for (var i = 0; i < a.length; ++i) {
        if (a[i] !== b[i])
          return false;
      }
      return true;
    };
    ListWrapper.slice = function(l, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return l.slice(from, to === null ? undefined : to);
    };
    ListWrapper.splice = function(l, from, length) {
      return l.splice(from, length);
    };
    ListWrapper.sort = function(l, compareFn) {
      if (lang_1.isPresent(compareFn)) {
        l.sort(compareFn);
      } else {
        l.sort();
      }
    };
    ListWrapper.toString = function(l) {
      return l.toString();
    };
    ListWrapper.toJSON = function(l) {
      return JSON.stringify(l);
    };
    ListWrapper.maximum = function(list, predicate) {
      if (list.length == 0) {
        return null;
      }
      var solution = null;
      var maxValue = -Infinity;
      for (var index = 0; index < list.length; index++) {
        var candidate = list[index];
        if (lang_1.isBlank(candidate)) {
          continue;
        }
        var candidateValue = predicate(candidate);
        if (candidateValue > maxValue) {
          solution = candidate;
          maxValue = candidateValue;
        }
      }
      return solution;
    };
    ListWrapper.flatten = function(list) {
      var target = [];
      _flattenArray(list, target);
      return target;
    };
    ListWrapper.addAll = function(list, source) {
      for (var i = 0; i < source.length; i++) {
        list.push(source[i]);
      }
    };
    return ListWrapper;
  }());
  exports.ListWrapper = ListWrapper;
  function _flattenArray(source, target) {
    if (lang_1.isPresent(source)) {
      for (var i = 0; i < source.length; i++) {
        var item = source[i];
        if (lang_1.isArray(item)) {
          _flattenArray(item, target);
        } else {
          target.push(item);
        }
      }
    }
    return target;
  }
  function isListLikeIterable(obj) {
    if (!lang_1.isJsObject(obj))
      return false;
    return lang_1.isArray(obj) || (!(obj instanceof exports.Map) && lang_1.getSymbolIterator() in obj);
  }
  exports.isListLikeIterable = isListLikeIterable;
  function areIterablesEqual(a, b, comparator) {
    var iterator1 = a[lang_1.getSymbolIterator()]();
    var iterator2 = b[lang_1.getSymbolIterator()]();
    while (true) {
      var item1 = iterator1.next();
      var item2 = iterator2.next();
      if (item1.done && item2.done)
        return true;
      if (item1.done || item2.done)
        return false;
      if (!comparator(item1.value, item2.value))
        return false;
    }
  }
  exports.areIterablesEqual = areIterablesEqual;
  function iterateListLike(obj, fn) {
    if (lang_1.isArray(obj)) {
      for (var i = 0; i < obj.length; i++) {
        fn(obj[i]);
      }
    } else {
      var iterator = obj[lang_1.getSymbolIterator()]();
      var item;
      while (!((item = iterator.next()).done)) {
        fn(item.value);
      }
    }
  }
  exports.iterateListLike = iterateListLike;
  var createSetFromList = (function() {
    var test = new exports.Set([1, 2, 3]);
    if (test.size === 3) {
      return function createSetFromList(lst) {
        return new exports.Set(lst);
      };
    } else {
      return function createSetAndPopulateFromList(lst) {
        var res = new exports.Set(lst);
        if (res.size !== lst.length) {
          for (var i = 0; i < lst.length; i++) {
            res.add(lst[i]);
          }
        }
        return res;
      };
    }
  })();
  var SetWrapper = (function() {
    function SetWrapper() {}
    SetWrapper.createFromList = function(lst) {
      return createSetFromList(lst);
    };
    SetWrapper.has = function(s, key) {
      return s.has(key);
    };
    SetWrapper.delete = function(m, k) {
      m.delete(k);
    };
    return SetWrapper;
  }());
  exports.SetWrapper = SetWrapper;
  return module.exports;
});

$__System.registerDynamic("29f", ["9c", "29e", "254"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var base_wrapped_exception_1 = $__require('29e');
  var collection_1 = $__require('254');
  var _ArrayLogger = (function() {
    function _ArrayLogger() {
      this.res = [];
    }
    _ArrayLogger.prototype.log = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logError = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroup = function(s) {
      this.res.push(s);
    };
    _ArrayLogger.prototype.logGroupEnd = function() {};
    ;
    return _ArrayLogger;
  }());
  var ExceptionHandler = (function() {
    function ExceptionHandler(_logger, _rethrowException) {
      if (_rethrowException === void 0) {
        _rethrowException = true;
      }
      this._logger = _logger;
      this._rethrowException = _rethrowException;
    }
    ExceptionHandler.exceptionToString = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var l = new _ArrayLogger();
      var e = new ExceptionHandler(l, false);
      e.call(exception, stackTrace, reason);
      return l.res.join("\n");
    };
    ExceptionHandler.prototype.call = function(exception, stackTrace, reason) {
      if (stackTrace === void 0) {
        stackTrace = null;
      }
      if (reason === void 0) {
        reason = null;
      }
      var originalException = this._findOriginalException(exception);
      var originalStack = this._findOriginalStack(exception);
      var context = this._findContext(exception);
      this._logger.logGroup("EXCEPTION: " + this._extractMessage(exception));
      if (lang_1.isPresent(stackTrace) && lang_1.isBlank(originalStack)) {
        this._logger.logError("STACKTRACE:");
        this._logger.logError(this._longStackTrace(stackTrace));
      }
      if (lang_1.isPresent(reason)) {
        this._logger.logError("REASON: " + reason);
      }
      if (lang_1.isPresent(originalException)) {
        this._logger.logError("ORIGINAL EXCEPTION: " + this._extractMessage(originalException));
      }
      if (lang_1.isPresent(originalStack)) {
        this._logger.logError("ORIGINAL STACKTRACE:");
        this._logger.logError(this._longStackTrace(originalStack));
      }
      if (lang_1.isPresent(context)) {
        this._logger.logError("ERROR CONTEXT:");
        this._logger.logError(context);
      }
      this._logger.logGroupEnd();
      if (this._rethrowException)
        throw exception;
    };
    ExceptionHandler.prototype._extractMessage = function(exception) {
      return exception instanceof base_wrapped_exception_1.BaseWrappedException ? exception.wrapperMessage : exception.toString();
    };
    ExceptionHandler.prototype._longStackTrace = function(stackTrace) {
      return collection_1.isListLikeIterable(stackTrace) ? stackTrace.join("\n\n-----async gap-----\n") : stackTrace.toString();
    };
    ExceptionHandler.prototype._findContext = function(exception) {
      try {
        if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
          return null;
        return lang_1.isPresent(exception.context) ? exception.context : this._findContext(exception.originalException);
      } catch (e) {
        return null;
      }
    };
    ExceptionHandler.prototype._findOriginalException = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception.originalException;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
      }
      return e;
    };
    ExceptionHandler.prototype._findOriginalStack = function(exception) {
      if (!(exception instanceof base_wrapped_exception_1.BaseWrappedException))
        return null;
      var e = exception;
      var stack = exception.originalStack;
      while (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
        e = e.originalException;
        if (e instanceof base_wrapped_exception_1.BaseWrappedException && lang_1.isPresent(e.originalException)) {
          stack = e.originalStack;
        }
      }
      return stack;
    };
    return ExceptionHandler;
  }());
  exports.ExceptionHandler = ExceptionHandler;
  return module.exports;
});

$__System.registerDynamic("a9", ["29e", "29f"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var base_wrapped_exception_1 = $__require('29e');
  var exception_handler_1 = $__require('29f');
  var exception_handler_2 = $__require('29f');
  exports.ExceptionHandler = exception_handler_2.ExceptionHandler;
  var BaseException = (function(_super) {
    __extends(BaseException, _super);
    function BaseException(message) {
      if (message === void 0) {
        message = "--";
      }
      _super.call(this, message);
      this.message = message;
      this.stack = (new Error(message)).stack;
    }
    BaseException.prototype.toString = function() {
      return this.message;
    };
    return BaseException;
  }(Error));
  exports.BaseException = BaseException;
  var WrappedException = (function(_super) {
    __extends(WrappedException, _super);
    function WrappedException(_wrapperMessage, _originalException, _originalStack, _context) {
      _super.call(this, _wrapperMessage);
      this._wrapperMessage = _wrapperMessage;
      this._originalException = _originalException;
      this._originalStack = _originalStack;
      this._context = _context;
      this._wrapperStack = (new Error(_wrapperMessage)).stack;
    }
    Object.defineProperty(WrappedException.prototype, "wrapperMessage", {
      get: function() {
        return this._wrapperMessage;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "wrapperStack", {
      get: function() {
        return this._wrapperStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalException", {
      get: function() {
        return this._originalException;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "originalStack", {
      get: function() {
        return this._originalStack;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "context", {
      get: function() {
        return this._context;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(WrappedException.prototype, "message", {
      get: function() {
        return exception_handler_1.ExceptionHandler.exceptionToString(this);
      },
      enumerable: true,
      configurable: true
    });
    WrappedException.prototype.toString = function() {
      return this.message;
    };
    return WrappedException;
  }(base_wrapped_exception_1.BaseWrappedException));
  exports.WrappedException = WrappedException;
  function makeTypeError(message) {
    return new TypeError(message);
  }
  exports.makeTypeError = makeTypeError;
  function unimplemented() {
    throw new BaseException('unimplemented');
  }
  exports.unimplemented = unimplemented;
  return module.exports;
});

$__System.registerDynamic("295", ["9c", "a9"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var lang_1 = $__require('9c');
  var exceptions_1 = $__require('a9');
  var Provider = (function() {
    function Provider(token, _a) {
      var useClass = _a.useClass,
          useValue = _a.useValue,
          useExisting = _a.useExisting,
          useFactory = _a.useFactory,
          deps = _a.deps,
          multi = _a.multi;
      this.token = token;
      this.useClass = useClass;
      this.useValue = useValue;
      this.useExisting = useExisting;
      this.useFactory = useFactory;
      this.dependencies = deps;
      this._multi = multi;
    }
    Object.defineProperty(Provider.prototype, "multi", {
      get: function() {
        return lang_1.normalizeBool(this._multi);
      },
      enumerable: true,
      configurable: true
    });
    return Provider;
  }());
  exports.Provider = Provider;
  var Binding = (function(_super) {
    __extends(Binding, _super);
    function Binding(token, _a) {
      var toClass = _a.toClass,
          toValue = _a.toValue,
          toAlias = _a.toAlias,
          toFactory = _a.toFactory,
          deps = _a.deps,
          multi = _a.multi;
      _super.call(this, token, {
        useClass: toClass,
        useValue: toValue,
        useExisting: toAlias,
        useFactory: toFactory,
        deps: deps,
        multi: multi
      });
    }
    Object.defineProperty(Binding.prototype, "toClass", {
      get: function() {
        return this.useClass;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(Binding.prototype, "toAlias", {
      get: function() {
        return this.useExisting;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(Binding.prototype, "toFactory", {
      get: function() {
        return this.useFactory;
      },
      enumerable: true,
      configurable: true
    });
    Object.defineProperty(Binding.prototype, "toValue", {
      get: function() {
        return this.useValue;
      },
      enumerable: true,
      configurable: true
    });
    return Binding;
  }(Provider));
  exports.Binding = Binding;
  function bind(token) {
    return new ProviderBuilder(token);
  }
  exports.bind = bind;
  var ProviderBuilder = (function() {
    function ProviderBuilder(token) {
      this.token = token;
    }
    ProviderBuilder.prototype.toClass = function(type) {
      if (!lang_1.isType(type)) {
        throw new exceptions_1.BaseException("Trying to create a class provider but \"" + lang_1.stringify(type) + "\" is not a class!");
      }
      return new Provider(this.token, {useClass: type});
    };
    ProviderBuilder.prototype.toValue = function(value) {
      return new Provider(this.token, {useValue: value});
    };
    ProviderBuilder.prototype.toAlias = function(aliasToken) {
      if (lang_1.isBlank(aliasToken)) {
        throw new exceptions_1.BaseException("Can not alias " + lang_1.stringify(this.token) + " to a blank value!");
      }
      return new Provider(this.token, {useExisting: aliasToken});
    };
    ProviderBuilder.prototype.toFactory = function(factory, dependencies) {
      if (!lang_1.isFunction(factory)) {
        throw new exceptions_1.BaseException("Trying to create a factory provider but \"" + lang_1.stringify(factory) + "\" is not a function!");
      }
      return new Provider(this.token, {
        useFactory: factory,
        deps: dependencies
      });
    };
    return ProviderBuilder;
  }());
  exports.ProviderBuilder = ProviderBuilder;
  function provide(token, _a) {
    var useClass = _a.useClass,
        useValue = _a.useValue,
        useExisting = _a.useExisting,
        useFactory = _a.useFactory,
        deps = _a.deps,
        multi = _a.multi;
    return new Provider(token, {
      useClass: useClass,
      useValue: useValue,
      useExisting: useExisting,
      useFactory: useFactory,
      deps: deps,
      multi: multi
    });
  }
  exports.provide = provide;
  return module.exports;
});

$__System.registerDynamic("296", ["295"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var provider_1 = $__require('295');
  function isProviderLiteral(obj) {
    return obj && typeof obj == 'object' && obj.provide;
  }
  exports.isProviderLiteral = isProviderLiteral;
  function createProvider(obj) {
    return new provider_1.Provider(obj.provide, obj);
  }
  exports.createProvider = createProvider;
  return module.exports;
});

$__System.registerDynamic("247", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var InjectMetadata = (function() {
    function InjectMetadata(token) {
      this.token = token;
    }
    InjectMetadata.prototype.toString = function() {
      return "@Inject(" + lang_1.stringify(this.token) + ")";
    };
    return InjectMetadata;
  }());
  exports.InjectMetadata = InjectMetadata;
  var OptionalMetadata = (function() {
    function OptionalMetadata() {}
    OptionalMetadata.prototype.toString = function() {
      return "@Optional()";
    };
    return OptionalMetadata;
  }());
  exports.OptionalMetadata = OptionalMetadata;
  var DependencyMetadata = (function() {
    function DependencyMetadata() {}
    Object.defineProperty(DependencyMetadata.prototype, "token", {
      get: function() {
        return null;
      },
      enumerable: true,
      configurable: true
    });
    return DependencyMetadata;
  }());
  exports.DependencyMetadata = DependencyMetadata;
  var InjectableMetadata = (function() {
    function InjectableMetadata() {}
    return InjectableMetadata;
  }());
  exports.InjectableMetadata = InjectableMetadata;
  var SelfMetadata = (function() {
    function SelfMetadata() {}
    SelfMetadata.prototype.toString = function() {
      return "@Self()";
    };
    return SelfMetadata;
  }());
  exports.SelfMetadata = SelfMetadata;
  var SkipSelfMetadata = (function() {
    function SkipSelfMetadata() {}
    SkipSelfMetadata.prototype.toString = function() {
      return "@SkipSelf()";
    };
    return SkipSelfMetadata;
  }());
  exports.SkipSelfMetadata = SkipSelfMetadata;
  var HostMetadata = (function() {
    function HostMetadata() {}
    HostMetadata.prototype.toString = function() {
      return "@Host()";
    };
    return HostMetadata;
  }());
  exports.HostMetadata = HostMetadata;
  return module.exports;
});

$__System.registerDynamic("9c", [], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var __extends = (this && this.__extends) || function(d, b) {
    for (var p in b)
      if (b.hasOwnProperty(p))
        d[p] = b[p];
    function __() {
      this.constructor = d;
    }
    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var globalScope;
  if (typeof window === 'undefined') {
    if (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope) {
      globalScope = self;
    } else {
      globalScope = global;
    }
  } else {
    globalScope = window;
  }
  function scheduleMicroTask(fn) {
    Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
  }
  exports.scheduleMicroTask = scheduleMicroTask;
  exports.IS_DART = false;
  var _global = globalScope;
  exports.global = _global;
  exports.Type = Function;
  function getTypeNameForDebugging(type) {
    if (type['name']) {
      return type['name'];
    }
    return typeof type;
  }
  exports.getTypeNameForDebugging = getTypeNameForDebugging;
  exports.Math = _global.Math;
  exports.Date = _global.Date;
  var _devMode = true;
  var _modeLocked = false;
  function lockMode() {
    _modeLocked = true;
  }
  exports.lockMode = lockMode;
  function enableProdMode() {
    if (_modeLocked) {
      throw 'Cannot enable prod mode after platform setup.';
    }
    _devMode = false;
  }
  exports.enableProdMode = enableProdMode;
  function assertionsEnabled() {
    return _devMode;
  }
  exports.assertionsEnabled = assertionsEnabled;
  _global.assert = function assert(condition) {};
  function isPresent(obj) {
    return obj !== undefined && obj !== null;
  }
  exports.isPresent = isPresent;
  function isBlank(obj) {
    return obj === undefined || obj === null;
  }
  exports.isBlank = isBlank;
  function isBoolean(obj) {
    return typeof obj === "boolean";
  }
  exports.isBoolean = isBoolean;
  function isNumber(obj) {
    return typeof obj === "number";
  }
  exports.isNumber = isNumber;
  function isString(obj) {
    return typeof obj === "string";
  }
  exports.isString = isString;
  function isFunction(obj) {
    return typeof obj === "function";
  }
  exports.isFunction = isFunction;
  function isType(obj) {
    return isFunction(obj);
  }
  exports.isType = isType;
  function isStringMap(obj) {
    return typeof obj === 'object' && obj !== null;
  }
  exports.isStringMap = isStringMap;
  var STRING_MAP_PROTO = Object.getPrototypeOf({});
  function isStrictStringMap(obj) {
    return isStringMap(obj) && Object.getPrototypeOf(obj) === STRING_MAP_PROTO;
  }
  exports.isStrictStringMap = isStrictStringMap;
  function isPromise(obj) {
    return obj instanceof _global.Promise;
  }
  exports.isPromise = isPromise;
  function isArray(obj) {
    return Array.isArray(obj);
  }
  exports.isArray = isArray;
  function isDate(obj) {
    return obj instanceof exports.Date && !isNaN(obj.valueOf());
  }
  exports.isDate = isDate;
  function noop() {}
  exports.noop = noop;
  function stringify(token) {
    if (typeof token === 'string') {
      return token;
    }
    if (token === undefined || token === null) {
      return '' + token;
    }
    if (token.name) {
      return token.name;
    }
    if (token.overriddenName) {
      return token.overriddenName;
    }
    var res = token.toString();
    var newLineIndex = res.indexOf("\n");
    return (newLineIndex === -1) ? res : res.substring(0, newLineIndex);
  }
  exports.stringify = stringify;
  function serializeEnum(val) {
    return val;
  }
  exports.serializeEnum = serializeEnum;
  function deserializeEnum(val, values) {
    return val;
  }
  exports.deserializeEnum = deserializeEnum;
  function resolveEnumToken(enumValue, val) {
    return enumValue[val];
  }
  exports.resolveEnumToken = resolveEnumToken;
  var StringWrapper = (function() {
    function StringWrapper() {}
    StringWrapper.fromCharCode = function(code) {
      return String.fromCharCode(code);
    };
    StringWrapper.charCodeAt = function(s, index) {
      return s.charCodeAt(index);
    };
    StringWrapper.split = function(s, regExp) {
      return s.split(regExp);
    };
    StringWrapper.equals = function(s, s2) {
      return s === s2;
    };
    StringWrapper.stripLeft = function(s, charVal) {
      if (s && s.length) {
        var pos = 0;
        for (var i = 0; i < s.length; i++) {
          if (s[i] != charVal)
            break;
          pos++;
        }
        s = s.substring(pos);
      }
      return s;
    };
    StringWrapper.stripRight = function(s, charVal) {
      if (s && s.length) {
        var pos = s.length;
        for (var i = s.length - 1; i >= 0; i--) {
          if (s[i] != charVal)
            break;
          pos--;
        }
        s = s.substring(0, pos);
      }
      return s;
    };
    StringWrapper.replace = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.replaceAll = function(s, from, replace) {
      return s.replace(from, replace);
    };
    StringWrapper.slice = function(s, from, to) {
      if (from === void 0) {
        from = 0;
      }
      if (to === void 0) {
        to = null;
      }
      return s.slice(from, to === null ? undefined : to);
    };
    StringWrapper.replaceAllMapped = function(s, from, cb) {
      return s.replace(from, function() {
        var matches = [];
        for (var _i = 0; _i < arguments.length; _i++) {
          matches[_i - 0] = arguments[_i];
        }
        matches.splice(-2, 2);
        return cb(matches);
      });
    };
    StringWrapper.contains = function(s, substr) {
      return s.indexOf(substr) != -1;
    };
    StringWrapper.compare = function(a, b) {
      if (a < b) {
        return -1;
      } else if (a > b) {
        return 1;
      } else {
        return 0;
      }
    };
    return StringWrapper;
  }());
  exports.StringWrapper = StringWrapper;
  var StringJoiner = (function() {
    function StringJoiner(parts) {
      if (parts === void 0) {
        parts = [];
      }
      this.parts = parts;
    }
    StringJoiner.prototype.add = function(part) {
      this.parts.push(part);
    };
    StringJoiner.prototype.toString = function() {
      return this.parts.join("");
    };
    return StringJoiner;
  }());
  exports.StringJoiner = StringJoiner;
  var NumberParseError = (function(_super) {
    __extends(NumberParseError, _super);
    function NumberParseError(message) {
      _super.call(this);
      this.message = message;
    }
    NumberParseError.prototype.toString = function() {
      return this.message;
    };
    return NumberParseError;
  }(Error));
  exports.NumberParseError = NumberParseError;
  var NumberWrapper = (function() {
    function NumberWrapper() {}
    NumberWrapper.toFixed = function(n, fractionDigits) {
      return n.toFixed(fractionDigits);
    };
    NumberWrapper.equal = function(a, b) {
      return a === b;
    };
    NumberWrapper.parseIntAutoRadix = function(text) {
      var result = parseInt(text);
      if (isNaN(result)) {
        throw new NumberParseError("Invalid integer literal when parsing " + text);
      }
      return result;
    };
    NumberWrapper.parseInt = function(text, radix) {
      if (radix == 10) {
        if (/^(\-|\+)?[0-9]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else if (radix == 16) {
        if (/^(\-|\+)?[0-9ABCDEFabcdef]+$/.test(text)) {
          return parseInt(text, radix);
        }
      } else {
        var result = parseInt(text, radix);
        if (!isNaN(result)) {
          return result;
        }
      }
      throw new NumberParseError("Invalid integer literal when parsing " + text + " in base " + radix);
    };
    NumberWrapper.parseFloat = function(text) {
      return parseFloat(text);
    };
    Object.defineProperty(NumberWrapper, "NaN", {
      get: function() {
        return NaN;
      },
      enumerable: true,
      configurable: true
    });
    NumberWrapper.isNaN = function(value) {
      return isNaN(value);
    };
    NumberWrapper.isInteger = function(value) {
      return Number.isInteger(value);
    };
    return NumberWrapper;
  }());
  exports.NumberWrapper = NumberWrapper;
  exports.RegExp = _global.RegExp;
  var RegExpWrapper = (function() {
    function RegExpWrapper() {}
    RegExpWrapper.create = function(regExpStr, flags) {
      if (flags === void 0) {
        flags = '';
      }
      flags = flags.replace(/g/g, '');
      return new _global.RegExp(regExpStr, flags + 'g');
    };
    RegExpWrapper.firstMatch = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.exec(input);
    };
    RegExpWrapper.test = function(regExp, input) {
      regExp.lastIndex = 0;
      return regExp.test(input);
    };
    RegExpWrapper.matcher = function(regExp, input) {
      regExp.lastIndex = 0;
      return {
        re: regExp,
        input: input
      };
    };
    RegExpWrapper.replaceAll = function(regExp, input, replace) {
      var c = regExp.exec(input);
      var res = '';
      regExp.lastIndex = 0;
      var prev = 0;
      while (c) {
        res += input.substring(prev, c.index);
        res += replace(c);
        prev = c.index + c[0].length;
        regExp.lastIndex = prev;
        c = regExp.exec(input);
      }
      res += input.substring(prev);
      return res;
    };
    return RegExpWrapper;
  }());
  exports.RegExpWrapper = RegExpWrapper;
  var RegExpMatcherWrapper = (function() {
    function RegExpMatcherWrapper() {}
    RegExpMatcherWrapper.next = function(matcher) {
      return matcher.re.exec(matcher.input);
    };
    return RegExpMatcherWrapper;
  }());
  exports.RegExpMatcherWrapper = RegExpMatcherWrapper;
  var FunctionWrapper = (function() {
    function FunctionWrapper() {}
    FunctionWrapper.apply = function(fn, posArgs) {
      return fn.apply(null, posArgs);
    };
    return FunctionWrapper;
  }());
  exports.FunctionWrapper = FunctionWrapper;
  function looseIdentical(a, b) {
    return a === b || typeof a === "number" && typeof b === "number" && isNaN(a) && isNaN(b);
  }
  exports.looseIdentical = looseIdentical;
  function getMapKey(value) {
    return value;
  }
  exports.getMapKey = getMapKey;
  function normalizeBlank(obj) {
    return isBlank(obj) ? null : obj;
  }
  exports.normalizeBlank = normalizeBlank;
  function normalizeBool(obj) {
    return isBlank(obj) ? false : obj;
  }
  exports.normalizeBool = normalizeBool;
  function isJsObject(o) {
    return o !== null && (typeof o === "function" || typeof o === "object");
  }
  exports.isJsObject = isJsObject;
  function print(obj) {
    console.log(obj);
  }
  exports.print = print;
  function warn(obj) {
    console.warn(obj);
  }
  exports.warn = warn;
  var Json = (function() {
    function Json() {}
    Json.parse = function(s) {
      return _global.JSON.parse(s);
    };
    Json.stringify = function(data) {
      return _global.JSON.stringify(data, null, 2);
    };
    return Json;
  }());
  exports.Json = Json;
  var DateWrapper = (function() {
    function DateWrapper() {}
    DateWrapper.create = function(year, month, day, hour, minutes, seconds, milliseconds) {
      if (month === void 0) {
        month = 1;
      }
      if (day === void 0) {
        day = 1;
      }
      if (hour === void 0) {
        hour = 0;
      }
      if (minutes === void 0) {
        minutes = 0;
      }
      if (seconds === void 0) {
        seconds = 0;
      }
      if (milliseconds === void 0) {
        milliseconds = 0;
      }
      return new exports.Date(year, month - 1, day, hour, minutes, seconds, milliseconds);
    };
    DateWrapper.fromISOString = function(str) {
      return new exports.Date(str);
    };
    DateWrapper.fromMillis = function(ms) {
      return new exports.Date(ms);
    };
    DateWrapper.toMillis = function(date) {
      return date.getTime();
    };
    DateWrapper.now = function() {
      return new exports.Date();
    };
    DateWrapper.toJson = function(date) {
      return date.toJSON();
    };
    return DateWrapper;
  }());
  exports.DateWrapper = DateWrapper;
  function setValueOnPath(global, path, value) {
    var parts = path.split('.');
    var obj = global;
    while (parts.length > 1) {
      var name = parts.shift();
      if (obj.hasOwnProperty(name) && isPresent(obj[name])) {
        obj = obj[name];
      } else {
        obj = obj[name] = {};
      }
    }
    if (obj === undefined || obj === null) {
      obj = {};
    }
    obj[parts.shift()] = value;
  }
  exports.setValueOnPath = setValueOnPath;
  var _symbolIterator = null;
  function getSymbolIterator() {
    if (isBlank(_symbolIterator)) {
      if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
        _symbolIterator = Symbol.iterator;
      } else {
        var keys = Object.getOwnPropertyNames(Map.prototype);
        for (var i = 0; i < keys.length; ++i) {
          var key = keys[i];
          if (key !== 'entries' && key !== 'size' && Map.prototype[key] === Map.prototype['entries']) {
            _symbolIterator = key;
          }
        }
      }
    }
    return _symbolIterator;
  }
  exports.getSymbolIterator = getSymbolIterator;
  function evalExpression(sourceUrl, expr, declarations, vars) {
    var fnBody = declarations + "\nreturn " + expr + "\n//# sourceURL=" + sourceUrl;
    var fnArgNames = [];
    var fnArgValues = [];
    for (var argName in vars) {
      fnArgNames.push(argName);
      fnArgValues.push(vars[argName]);
    }
    return new (Function.bind.apply(Function, [void 0].concat(fnArgNames.concat(fnBody))))().apply(void 0, fnArgValues);
  }
  exports.evalExpression = evalExpression;
  function isPrimitive(obj) {
    return !isJsObject(obj);
  }
  exports.isPrimitive = isPrimitive;
  function hasConstructor(value, type) {
    return value.constructor === type;
  }
  exports.hasConstructor = hasConstructor;
  function bitWiseOr(values) {
    return values.reduce(function(a, b) {
      return a | b;
    });
  }
  exports.bitWiseOr = bitWiseOr;
  function bitWiseAnd(values) {
    return values.reduce(function(a, b) {
      return a & b;
    });
  }
  exports.bitWiseAnd = bitWiseAnd;
  function escape(s) {
    return _global.encodeURI(s);
  }
  exports.escape = escape;
  return module.exports;
});

$__System.registerDynamic("24d", ["9c"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var _nextClassId = 0;
  function extractAnnotation(annotation) {
    if (lang_1.isFunction(annotation) && annotation.hasOwnProperty('annotation')) {
      annotation = annotation.annotation;
    }
    return annotation;
  }
  function applyParams(fnOrArray, key) {
    if (fnOrArray === Object || fnOrArray === String || fnOrArray === Function || fnOrArray === Number || fnOrArray === Array) {
      throw new Error("Can not use native " + lang_1.stringify(fnOrArray) + " as constructor");
    }
    if (lang_1.isFunction(fnOrArray)) {
      return fnOrArray;
    } else if (fnOrArray instanceof Array) {
      var annotations = fnOrArray;
      var fn = fnOrArray[fnOrArray.length - 1];
      if (!lang_1.isFunction(fn)) {
        throw new Error("Last position of Class method array must be Function in key " + key + " was '" + lang_1.stringify(fn) + "'");
      }
      var annoLength = annotations.length - 1;
      if (annoLength != fn.length) {
        throw new Error("Number of annotations (" + annoLength + ") does not match number of arguments (" + fn.length + ") in the function: " + lang_1.stringify(fn));
      }
      var paramsAnnotations = [];
      for (var i = 0,
          ii = annotations.length - 1; i < ii; i++) {
        var paramAnnotations = [];
        paramsAnnotations.push(paramAnnotations);
        var annotation = annotations[i];
        if (annotation instanceof Array) {
          for (var j = 0; j < annotation.length; j++) {
            paramAnnotations.push(extractAnnotation(annotation[j]));
          }
        } else if (lang_1.isFunction(annotation)) {
          paramAnnotations.push(extractAnnotation(annotation));
        } else {
          paramAnnotations.push(annotation);
        }
      }
      Reflect.defineMetadata('parameters', paramsAnnotations, fn);
      return fn;
    } else {
      throw new Error("Only Function or Array is supported in Class definition for key '" + key + "' is '" + lang_1.stringify(fnOrArray) + "'");
    }
  }
  function Class(clsDef) {
    var constructor = applyParams(clsDef.hasOwnProperty('constructor') ? clsDef.constructor : undefined, 'constructor');
    var proto = constructor.prototype;
    if (clsDef.hasOwnProperty('extends')) {
      if (lang_1.isFunction(clsDef.extends)) {
        constructor.prototype = proto = Object.create(clsDef.extends.prototype);
      } else {
        throw new Error("Class definition 'extends' property must be a constructor function was: " + lang_1.stringify(clsDef.extends));
      }
    }
    for (var key in clsDef) {
      if (key != 'extends' && key != 'prototype' && clsDef.hasOwnProperty(key)) {
        proto[key] = applyParams(clsDef[key], key);
      }
    }
    if (this && this.annotations instanceof Array) {
      Reflect.defineMetadata('annotations', this.annotations, constructor);
    }
    if (!constructor['name']) {
      constructor['overriddenName'] = "class" + _nextClassId++;
    }
    return constructor;
  }
  exports.Class = Class;
  var Reflect = lang_1.global.Reflect;
  (function checkReflect() {
    if (!(Reflect && Reflect.getMetadata)) {
      throw 'reflect-metadata shim is required when using class decorators';
    }
  })();
  function makeDecorator(annotationCls, chainFn) {
    if (chainFn === void 0) {
      chainFn = null;
    }
    function DecoratorFactory(objOrType) {
      var annotationInstance = new annotationCls(objOrType);
      if (this instanceof annotationCls) {
        return annotationInstance;
      } else {
        var chainAnnotation = lang_1.isFunction(this) && this.annotations instanceof Array ? this.annotations : [];
        chainAnnotation.push(annotationInstance);
        var TypeDecorator = function TypeDecorator(cls) {
          var annotations = Reflect.getOwnMetadata('annotations', cls);
          annotations = annotations || [];
          annotations.push(annotationInstance);
          Reflect.defineMetadata('annotations', annotations, cls);
          return cls;
        };
        TypeDecorator.annotations = chainAnnotation;
        TypeDecorator.Class = Class;
        if (chainFn)
          chainFn(TypeDecorator);
        return TypeDecorator;
      }
    }
    DecoratorFactory.prototype = Object.create(annotationCls.prototype);
    DecoratorFactory.annotationCls = annotationCls;
    return DecoratorFactory;
  }
  exports.makeDecorator = makeDecorator;
  function makeParamDecorator(annotationCls) {
    function ParamDecoratorFactory() {
      var args = [];
      for (var _i = 0; _i < arguments.length; _i++) {
        args[_i - 0] = arguments[_i];
      }
      var annotationInstance = Object.create(annotationCls.prototype);
      annotationCls.apply(annotationInstance, args);
      if (this instanceof annotationCls) {
        return annotationInstance;
      } else {
        ParamDecorator.annotation = annotationInstance;
        return ParamDecorator;
      }
      function ParamDecorator(cls, unusedKey, index) {
        var parameters = Reflect.getMetadata('parameters', cls);
        parameters = parameters || [];
        while (parameters.length <= index) {
          parameters.push(null);
        }
        parameters[index] = parameters[index] || [];
        var annotationsForParam = parameters[index];
        annotationsForParam.push(annotationInstance);
        Reflect.defineMetadata('parameters', parameters, cls);
        return cls;
      }
    }
    ParamDecoratorFactory.prototype = Object.create(annotationCls.prototype);
    ParamDecoratorFactory.annotationCls = annotationCls;
    return ParamDecoratorFactory;
  }
  exports.makeParamDecorator = makeParamDecorator;
  function makePropDecorator(annotationCls) {
    function PropDecoratorFactory() {
      var args = [];
      for (var _i = 0; _i < arguments.length; _i++) {
        args[_i - 0] = arguments[_i];
      }
      var decoratorInstance = Object.create(annotationCls.prototype);
      annotationCls.apply(decoratorInstance, args);
      if (this instanceof annotationCls) {
        return decoratorInstance;
      } else {
        return function PropDecorator(target, name) {
          var meta = Reflect.getOwnMetadata('propMetadata', target.constructor);
          meta = meta || {};
          meta[name] = meta[name] || [];
          meta[name].unshift(decoratorInstance);
          Reflect.defineMetadata('propMetadata', meta, target.constructor);
        };
      }
    }
    PropDecoratorFactory.prototype = Object.create(annotationCls.prototype);
    PropDecoratorFactory.annotationCls = annotationCls;
    return PropDecoratorFactory;
  }
  exports.makePropDecorator = makePropDecorator;
  return module.exports;
});

$__System.registerDynamic("26a", ["247", "24d"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var metadata_1 = $__require('247');
  var decorators_1 = $__require('24d');
  exports.Inject = decorators_1.makeParamDecorator(metadata_1.InjectMetadata);
  exports.Optional = decorators_1.makeParamDecorator(metadata_1.OptionalMetadata);
  exports.Injectable = decorators_1.makeDecorator(metadata_1.InjectableMetadata);
  exports.Self = decorators_1.makeParamDecorator(metadata_1.SelfMetadata);
  exports.Host = decorators_1.makeParamDecorator(metadata_1.HostMetadata);
  exports.SkipSelf = decorators_1.makeParamDecorator(metadata_1.SkipSelfMetadata);
  return module.exports;
});

$__System.registerDynamic("264", ["9c", "26a"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var lang_1 = $__require('9c');
  var decorators_1 = $__require('26a');
  var _warnImpl = lang_1.warn;
  var Console = (function() {
    function Console() {}
    Console.prototype.log = function(message) {
      lang_1.print(message);
    };
    Console.prototype.warn = function(message) {
      _warnImpl(message);
    };
    Console.decorators = [{type: decorators_1.Injectable}];
    return Console;
  }());
  exports.Console = Console;
  return module.exports;
});

$__System.registerDynamic("2a0", ["24a", "288", "290", "270", "266", "257", "285", "284", "286", "26f", "24c", "287", "28f", "252", "25a", "29b", "294", "24d", "29d", "296", "264"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  var constants = $__require('24a');
  var security = $__require('288');
  var reflective_provider = $__require('290');
  var lifecycle_hooks = $__require('270');
  var reflector_reader = $__require('266');
  var component_resolver = $__require('257');
  var element = $__require('285');
  var view = $__require('284');
  var view_type = $__require('286');
  var view_utils = $__require('26f');
  var metadata_view = $__require('24c');
  var debug_context = $__require('287');
  var change_detection_util = $__require('28f');
  var api = $__require('252');
  var template_ref = $__require('25a');
  var wtf_init = $__require('29b');
  var reflection_capabilities = $__require('294');
  var decorators = $__require('24d');
  var debug = $__require('29d');
  var provider_util = $__require('296');
  var console = $__require('264');
  exports.__core_private__ = {
    isDefaultChangeDetectionStrategy: constants.isDefaultChangeDetectionStrategy,
    ChangeDetectorState: constants.ChangeDetectorState,
    CHANGE_DETECTION_STRATEGY_VALUES: constants.CHANGE_DETECTION_STRATEGY_VALUES,
    constructDependencies: reflective_provider.constructDependencies,
    LifecycleHooks: lifecycle_hooks.LifecycleHooks,
    LIFECYCLE_HOOKS_VALUES: lifecycle_hooks.LIFECYCLE_HOOKS_VALUES,
    ReflectorReader: reflector_reader.ReflectorReader,
    ReflectorComponentResolver: component_resolver.ReflectorComponentResolver,
    AppElement: element.AppElement,
    AppView: view.AppView,
    DebugAppView: view.DebugAppView,
    ViewType: view_type.ViewType,
    MAX_INTERPOLATION_VALUES: view_utils.MAX_INTERPOLATION_VALUES,
    checkBinding: view_utils.checkBinding,
    flattenNestedViewRenderNodes: view_utils.flattenNestedViewRenderNodes,
    interpolate: view_utils.interpolate,
    ViewUtils: view_utils.ViewUtils,
    VIEW_ENCAPSULATION_VALUES: metadata_view.VIEW_ENCAPSULATION_VALUES,
    DebugContext: debug_context.DebugContext,
    StaticNodeDebugInfo: debug_context.StaticNodeDebugInfo,
    devModeEqual: change_detection_util.devModeEqual,
    uninitialized: change_detection_util.uninitialized,
    ValueUnwrapper: change_detection_util.ValueUnwrapper,
    RenderDebugInfo: api.RenderDebugInfo,
    SecurityContext: security.SecurityContext,
    SanitizationService: security.SanitizationService,
    TemplateRef_: template_ref.TemplateRef_,
    wtfInit: wtf_init.wtfInit,
    ReflectionCapabilities: reflection_capabilities.ReflectionCapabilities,
    makeDecorator: decorators.makeDecorator,
    DebugDomRootRenderer: debug.DebugDomRootRenderer,
    createProvider: provider_util.createProvider,
    isProviderLiteral: provider_util.isProviderLiteral,
    EMPTY_ARRAY: view_utils.EMPTY_ARRAY,
    EMPTY_MAP: view_utils.EMPTY_MAP,
    pureProxy1: view_utils.pureProxy1,
    pureProxy2: view_utils.pureProxy2,
    pureProxy3: view_utils.pureProxy3,
    pureProxy4: view_utils.pureProxy4,
    pureProxy5: view_utils.pureProxy5,
    pureProxy6: view_utils.pureProxy6,
    pureProxy7: view_utils.pureProxy7,
    pureProxy8: view_utils.pureProxy8,
    pureProxy9: view_utils.pureProxy9,
    pureProxy10: view_utils.pureProxy10,
    castByValue: view_utils.castByValue,
    Console: console.Console
  };
  return module.exports;
});

$__System.registerDynamic("2a1", ["24b", "24e", "262", "268", "26b", "24f", "251", "256", "29c", "267", "25f", "261", "263", "26e", "265", "26c", "9c", "255", "a9", "2a0"], true, function($__require, exports, module) {
  "use strict";
  ;
  var define,
      global = this,
      GLOBAL = this;
  function __export(m) {
    for (var p in m)
      if (!exports.hasOwnProperty(p))
        exports[p] = m[p];
  }
  __export($__require('24b'));
  __export($__require('24e'));
  __export($__require('262'));
  var application_ref_1 = $__require('268');
  exports.createPlatform = application_ref_1.createPlatform;
  exports.assertPlatform = application_ref_1.assertPlatform;
  exports.disposePlatform = application_ref_1.disposePlatform;
  exports.getPlatform = application_ref_1.getPlatform;
  exports.coreBootstrap = application_ref_1.coreBootstrap;
  exports.coreLoadAndBootstrap = application_ref_1.coreLoadAndBootstrap;
  exports.createNgZone = application_ref_1.createNgZone;
  exports.PlatformRef = application_ref_1.PlatformRef;
  exports.ApplicationRef = application_ref_1.ApplicationRef;
  var application_tokens_1 = $__require('26b');
  exports.APP_ID = application_tokens_1.APP_ID;
  exports.APP_INITIALIZER = application_tokens_1.APP_INITIALIZER;
  exports.PACKAGE_ROOT_URL = application_tokens_1.PACKAGE_ROOT_URL;
  exports.PLATFORM_INITIALIZER = application_tokens_1.PLATFORM_INITIALIZER;
  __export($__require('24f'));
  __export($__require('251'));
  __export($__require('256'));
  var debug_node_1 = $__require('29c');
  exports.DebugElement = debug_node_1.DebugElement;
  exports.DebugNode = debug_node_1.DebugNode;
  exports.asNativeElements = debug_node_1.asNativeElements;
  exports.getDebugNode = debug_node_1.getDebugNode;
  __export($__require('267'));
  __export($__require('25f'));
  __export($__require('261'));
  __export($__require('263'));
  __export($__require('26e'));
  __export($__require('265'));
  var profile_1 = $__require('26c');
  exports.wtfCreateScope = profile_1.wtfCreateScope;
  exports.wtfLeave = profile_1.wtfLeave;
  exports.wtfStartTimeRange = profile_1.wtfStartTimeRange;
  exports.wtfEndTimeRange = profile_1.wtfEndTimeRange;
  var lang_1 = $__require('9c');
  exports.Type = lang_1.Type;
  exports.enableProdMode = lang_1.enableProdMode;
  var async_1 = $__require('255');
  exports.EventEmitter = async_1.EventEmitter;
  var exceptions_1 = $__require('a9');
  exports.ExceptionHandler = exceptions_1.ExceptionHandler;
  exports.WrappedException = exceptions_1.WrappedException;
  exports.BaseException = exceptions_1.BaseException;
  __export($__require('2a0'));
  return module.exports;
});

$__System.registerDynamic("11", ["2a1"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('2a1');
  return module.exports;
});

$__System.register('2a2', ['11', '8a'], function (_export) {
  var EventEmitter, _classCallCheck, RedocEventsService;

  return {
    setters: [function (_) {
      EventEmitter = _.EventEmitter;
    }, function (_a) {
      _classCallCheck = _a['default'];
    }],
    execute: function () {
      'use strict';

      RedocEventsService = function RedocEventsService() {
        _classCallCheck(this, RedocEventsService);

        this.bootstrapped = new EventEmitter();
        this.samplesLanguageChanged = new EventEmitter();
      };

      _export('RedocEventsService', RedocEventsService);
    }
  };
});
$__System.register('227', ['11', '89', '8a', '5e', '9c', '2a2'], function (_export) {
  var Injectable, EventEmitter, _createClass, _classCallCheck, BrowserDomAdapter, global, RedocEventsService, Hash;

  return {
    setters: [function (_2) {
      Injectable = _2.Injectable;
      EventEmitter = _2.EventEmitter;
    }, function (_) {
      _createClass = _['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }, function (_c) {
      global = _c.global;
    }, function (_a2) {
      RedocEventsService = _a2.RedocEventsService;
    }],
    execute: function () {
      'use strict';

      Hash = (function () {
        function Hash(dom, events) {
          var _this = this;

          _classCallCheck(this, _Hash);

          this.changed = new EventEmitter();
          this.dom = dom;
          this.bind();

          events.bootstrapped.subscribe(function () {
            return _this.changed.next(_this.hash);
          });
        }

        _createClass(Hash, [{
          key: 'bind',
          value: function bind() {
            var _this2 = this;

            this._cancel = this.dom.onAndCancel(global, 'hashchange', function (evt) {
              _this2.changed.next(_this2.hash);
              evt.preventDefault();
            });
          }
        }, {
          key: 'unbind',
          value: function unbind() {
            this._cancel();
          }
        }, {
          key: 'hash',
          get: function get() {
            return this.dom.getLocation().hash;
          }
        }]);

        var _Hash = Hash;
        Hash = Injectable()(Hash) || Hash;
        Hash = Reflect.metadata('parameters', [[BrowserDomAdapter], [RedocEventsService]])(Hash) || Hash;
        return Hash;
      })();

      _export('Hash', Hash);
    }
  };
});
$__System.register('86', ['225', '226', '227', '242', '2a2'], function (_export) {
  'use strict';

  return {
    setters: [function (_2) {
      var _exportObj = {};

      for (var _key3 in _2) {
        if (_key3 !== 'default') _exportObj[_key3] = _2[_key3];
      }

      _export(_exportObj);
    }, function (_3) {
      var _exportObj2 = {};

      for (var _key4 in _3) {
        if (_key4 !== 'default') _exportObj2[_key4] = _3[_key4];
      }

      _export(_exportObj2);
    }, function (_4) {
      var _exportObj3 = {};

      for (var _key5 in _4) {
        if (_key5 !== 'default') _exportObj3[_key5] = _4[_key5];
      }

      _export(_exportObj3);
    }, function (_) {
      var _exportObj4 = {};

      for (var _key2 in _) {
        if (_key2 !== 'default') _exportObj4[_key2] = _[_key2];
      }

      _export(_exportObj4);
    }, function (_a2) {
      var _exportObj5 = {};

      for (var _key in _a2) {
        if (_key !== 'default') _exportObj5[_key] = _a2[_key];
      }

      _export(_exportObj5);
    }],
    execute: function () {}
  };
});
$__System.registerDynamic("2a3", [], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  ;
  (function() {
    var parents = function(node, ps) {
      if (node.parentNode === null) {
        return ps;
      }
      return parents(node.parentNode, ps.concat([node]));
    };
    var style = function(node, prop) {
      return getComputedStyle(node, null).getPropertyValue(prop);
    };
    var overflow = function(node) {
      return style(node, "overflow") + style(node, "overflow-y") + style(node, "overflow-x");
    };
    var scroll = function(node) {
      return (/(auto|scroll)/).test(overflow(node));
    };
    var scrollParent = function(node) {
      if (!(node instanceof HTMLElement)) {
        return;
      }
      var ps = parents(node.parentNode, []);
      for (var i = 0; i < ps.length; i += 1) {
        if (scroll(ps[i])) {
          return ps[i];
        }
      }
      return window;
    };
    if (typeof module === "object" && module !== null) {
      module.exports = scrollParent;
    } else {
      window.Scrollparent = scrollParent;
    }
  })();
  return module.exports;
});

$__System.registerDynamic("2a4", ["2a3"], true, function($__require, exports, module) {
  ;
  var define,
      global = this,
      GLOBAL = this;
  module.exports = $__require('2a3');
  return module.exports;
});

$__System.register("2a5", [], function() { return { setters: [], execute: function() {} } });

$__System.register('2a6', ['11', '83', '84', '85', '86', '87', '88', '89', '90', '93', '8a', '5e', '8b', 'a0', 'ab', '2a4', '2a5'], function (_export) {
  var provide, enableProdMode, ElementRef, bootstrap, ApiInfo, RedocComponent, BaseComponent, OptionsService, RedocEventsService, _get, _inherits, _createClass, StickySidebar, SchemaManager, _classCallCheck, BrowserDomAdapter, ApiLogo, MethodsList, SideMenu, detectScollParent, dom, _modeLocked, Redoc;

  return {
    setters: [function (_4) {
      provide = _4.provide;
      enableProdMode = _4.enableProdMode;
      ElementRef = _4.ElementRef;
    }, function (_5) {
      bootstrap = _5.bootstrap;
    }, function (_7) {
      ApiInfo = _7.ApiInfo;
    }, function (_6) {
      RedocComponent = _6.RedocComponent;
      BaseComponent = _6.BaseComponent;
    }, function (_10) {
      OptionsService = _10.OptionsService;
      RedocEventsService = _10.RedocEventsService;
    }, function (_) {
      _get = _['default'];
    }, function (_2) {
      _inherits = _2['default'];
    }, function (_3) {
      _createClass = _3['default'];
    }, function (_8) {
      StickySidebar = _8.StickySidebar;
    }, function (_9) {
      SchemaManager = _9['default'];
    }, function (_a) {
      _classCallCheck = _a['default'];
    }, function (_e) {
      BrowserDomAdapter = _e.BrowserDomAdapter;
    }, function (_b) {
      ApiLogo = _b.ApiLogo;
    }, function (_a0) {
      MethodsList = _a0.MethodsList;
    }, function (_ab) {
      SideMenu = _ab.SideMenu;
    }, function (_a4) {
      detectScollParent = _a4['default'];
    }, function (_a5) {}],
    execute: function () {
      'use strict';

      dom = new BrowserDomAdapter();
      _modeLocked = false;

      Redoc = (function (_BaseComponent) {
        _inherits(Redoc, _BaseComponent);

        function Redoc(schemaMgr, optionsMgr, elementRef, events) {
          _classCallCheck(this, _Redoc);

          _get(Object.getPrototypeOf(_Redoc.prototype), 'constructor', this).call(this, schemaMgr);
          this.element = elementRef.nativeElement;
          //parse options (top level component doesn't support inputs)
          optionsMgr.parseOptions(this.element);
          optionsMgr.options.$scrollParent = detectScollParent(this.element);
          this.options = optionsMgr.options;
          this.events = events;
        }

        _createClass(Redoc, [{
          key: 'ngAfterViewInit',
          value: function ngAfterViewInit() {
            var _this = this;

            setTimeout(function () {
              _this.events.bootstrapped.next();
            });
          }
        }], [{
          key: 'showLoadingAnimation',
          value: function showLoadingAnimation() {
            var elem = dom.query('redoc');
            dom.addClass(elem, 'loading');
          }
        }, {
          key: 'hideLoadingAnimation',
          value: function hideLoadingAnimation() {
            var redocEl = dom.query('redoc');
            dom.addClass(redocEl, 'loading-remove');
            setTimeout(function () {
              dom.removeClass(redocEl, 'loading-remove');
              dom.removeClass(redocEl, 'loading');
            }, 400);
          }
        }, {
          key: 'init',
          value: function init(specUrl, options) {
            var optionsService = new OptionsService(dom);
            optionsService.options = options;
            optionsService.options.specUrl = optionsService.options.specUrl || specUrl;
            var providers = [provide(OptionsService, { useValue: optionsService })];

            if (Redoc.appRef) {
              Redoc.destroy();
            }
            Redoc.showLoadingAnimation();
            return SchemaManager.instance().load(specUrl).then(function () {
              if (!_modeLocked && !optionsService.options.debugMode) {
                enableProdMode();
                _modeLocked = true;
              }
              return bootstrap(Redoc, providers);
            }).then(function (appRef) {
              Redoc.hideLoadingAnimation();
              Redoc.appRef = appRef;
              console.log('ReDoc bootstrapped!');
            }, function (error) {
              console.log(error);
              throw error;
            });
          }
        }, {
          key: 'autoInit',
          value: function autoInit() {
            var specUrlAttributeName = 'spec-url';
            var redocEl = dom.query('redoc');
            if (!redocEl) return;
            if (dom.hasAttribute(redocEl, specUrlAttributeName)) {
              var url = dom.getAttribute(redocEl, specUrlAttributeName);
              Redoc.init(url);
            }
          }
        }, {
          key: 'destroy',
          value: function destroy() {
            var el = dom.query('redoc');
            var elClone = undefined;
            var parent = undefined;
            var nextSibling = undefined;
            if (el) {
              parent = el.parentElement;
              nextSibling = el.nextElementSibling;
            }

            elClone = el.cloneNode(false);

            if (Redoc.appRef) {
              Redoc.appRef.destroy();
              Redoc.appRef = null;

              // Redoc destroy removes host element, so need to restore it
              elClone.innerHTML = 'Loading...';
              parent && parent.insertBefore(elClone, nextSibling);
            }
          }
        }]);

        var _Redoc = Redoc;
        Redoc = Reflect.metadata('parameters', [[SchemaManager], [OptionsService], [ElementRef], [RedocEventsService]])(Redoc) || Redoc;
        Redoc = RedocComponent({
          selector: 'redoc',
          providers: [SchemaManager, BrowserDomAdapter, RedocEventsService],
          template: '\n    <div class="redoc-wrap">\n      <div class="menu-content" sticky-sidebar [scrollParent]="options.$scrollParent" [scrollYOffset]="options.scrollYOffset">\n          <api-logo> </api-logo>\n          <side-menu> </side-menu>\n      </div>\n      <div id="api-content">\n        <api-info> </api-info>\n        <methods-list> </methods-list>\n        <footer>\n          <div class="powered-by-badge">\n            <a href="https://github.com/Rebilly/ReDoc" title="Swagger-generated API Reference Documentation" target="_blank">\n              Powered by <strong>ReDoc</strong>\n            </a>\n          </div>\n        </footer>\n      </div>\n    </div>\n  ',
          styles: ['\n    :host{display:block;box-sizing:border-box;-webkit-tap-highlight-color:transparent;-moz-tap-highlight-color:transparent;-ms-tap-highlight-color:transparent;-o-tap-highlight-color:transparent;tap-highlight-color:transparent;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-smoothing:antialiased;-webkit-osx-font-smoothing:grayscale;-moz-osx-font-smoothing:grayscale;osx-font-smoothing:grayscale;-webkit-text-size-adjust:100%;-moz-text-size-adjust:100%;text-size-adjust:100%;-webkit-text-shadow:1px 1px 1px rgba(0,0,0,0.004);-ms-text-shadow:1px 1px 1px rgba(0,0,0,0.004);text-shadow:1px 1px 1px rgba(0,0,0,0.004);text-rendering:optimizeSpeed !important;font-smooth:always;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;text-size-adjust:100%}.redoc-wrap{position:relative;font-family:Roboto,sans-serif;font-size:14px;line-height:1.55em;color:#263238}side-menu{display:block;box-sizing:border-box}methods-list{display:block;overflow:hidden}api-info,.side-bar{display:block;padding:10px 0}api-info{padding:40px}api-logo{display:block;text-align:center}@media (max-width: 1000px){api-logo{display:none}}[sticky-sidebar]{width:260px;background-color:#FAFAFA;overflow-y:auto;overflow-x:hidden}@media (max-width: 1000px){[sticky-sidebar]{z-index:1;width:100%;bottom:auto !important}}#api-content{margin-left:260px;position:relative}@media (max-width: 1000px){#api-content{padding-top:3em;margin-left:0}}#api-content:before{content:"";background:#263238;height:100%;width:40%;top:0;right:0;position:absolute;z-index:-1}@media (max-width: 1100px){#api-content:before{display:none}}:host h1{margin-top:0;font-family:Montserrat,sans-serif;color:#0033a0;font-weight:400}:host h2{margin-top:0;font-family:Montserrat,sans-serif;color:#0033a0;font-weight:400}:host h3{margin-top:0;font-family:Montserrat,sans-serif;color:#0033a0;font-weight:400}:host h4{margin-top:0;font-family:Montserrat,sans-serif;color:#0033a0;font-weight:400}:host h5{margin-top:0;font-family:Montserrat,sans-serif;color:#0033a0;font-weight:400}:host h1{font-size:1.85714em}:host h2{font-size:1.57143em}:host h3{font-size:1.28571em}:host h4{font-size:1.14286em}:host h5{font-size:0.929em}:host p{font-family:Roboto,sans-serif;font-weight:300;margin:0;margin-bottom:1em;line-height:1.55em}:host a{text-decoration:none;color:#0033a0}:host p>code{color:#e53935;border:1px solid rgba(38,50,56,0.1)}footer{text-align:right;padding:10px;font-size:15px;background-color:white}footer strong{font-size:18px;color:#0033a0}:host .redoc-markdown-block pre{font-family:Courier, monospace;white-space:pre-wrap;background-color:rgba(38,50,56,0.04);padding:12px 14px 15px 14px;overflow-x:auto;line-height:normal;border-radius:2px;border:1px solid rgba(38,50,56,0.1)}:host .redoc-markdown-block pre code{background-color:transparent}:host .redoc-markdown-block pre code:before,:host .redoc-markdown-block pre code:after{content:none}:host .redoc-markdown-block code{font-family:Courier, monospace;background-color:rgba(38,50,56,0.04);padding:0.1em 0 0.2em 0;font-size:1em;border-radius:2px}:host .redoc-markdown-block code:before,:host .redoc-markdown-block code:after{letter-spacing:-0.2em;content:"\\00a0"}:host .redoc-markdown-block p:last-of-type{margin-bottom:0}:host .redoc-markdown-block blockquote{margin:0;margin-bottom:1em;padding:0 15px;color:#777;border-left:4px solid #ddd}:host .redoc-markdown-block img{max-width:100%;box-sizing:content-box}:host .redoc-markdown-block ul,:host .redoc-markdown-block ol{padding-left:2em;margin:0;margin-bottom:1em}:host .redoc-markdown-block table{display:block;width:100%;overflow:auto;word-break:normal;word-break:keep-all;border-collapse:collapse;border-spacing:0;margin-top:0.5em;margin-bottom:0.5em}:host .redoc-markdown-block table tr{background-color:#fff;border-top:1px solid #ccc}:host .redoc-markdown-block table tr:nth-child(2n){background-color:#f8f8f8}:host .redoc-markdown-block table th,:host .redoc-markdown-block table td{padding:6px 13px;border:1px solid #ddd}:host .redoc-markdown-block table th{text-align:left;font-weight:bold}\n  '],
          directives: [ApiInfo, ApiLogo, MethodsList, SideMenu, StickySidebar]
        })(Redoc) || Redoc;
        return Redoc;
      })(BaseComponent);

      _export('Redoc', Redoc);
    }
  };
});
$__System.register('97', ['2', '84', '94', '96', '8b', '8d', '8e', '8c', '9e', '9d', 'ab', 'a0', '2a6'], function (_export) {
  'use strict';

  return {
    setters: [function (_4) {
      var _exportObj = {};

      for (var _key12 in _4) {
        if (_key12 !== 'default') _exportObj[_key12] = _4[_key12];
      }

      _export(_exportObj);
    }, function (_) {
      var _exportObj2 = {};

      for (var _key in _) {
        if (_key !== 'default') _exportObj2[_key] = _[_key];
      }

      _export(_exportObj2);
    }, function (_2) {
      var _exportObj3 = {};

      for (var _key7 in _2) {
        if (_key7 !== 'default') _exportObj3[_key7] = _2[_key7];
      }

      _export(_exportObj3);
    }, function (_3) {
      var _exportObj4 = {};

      for (var _key8 in _3) {
        if (_key8 !== 'default') _exportObj4[_key8] = _3[_key8];
      }

      _export(_exportObj4);
    }, function (_b) {
      var _exportObj5 = {};

      for (var _key2 in _b) {
        if (_key2 !== 'default') _exportObj5[_key2] = _b[_key2];
      }

      _export(_exportObj5);
    }, function (_d) {
      var _exportObj6 = {};

      for (var _key3 in _d) {
        if (_key3 !== 'default') _exportObj6[_key3] = _d[_key3];
      }

      _export(_exportObj6);
    }, function (_e) {
      var _exportObj7 = {};

      for (var _key4 in _e) {
        if (_key4 !== 'default') _exportObj7[_key4] = _e[_key4];
      }

      _export(_exportObj7);
    }, function (_c) {
      var _exportObj8 = {};

      for (var _key5 in _c) {
        if (_key5 !== 'default') _exportObj8[_key5] = _c[_key5];
      }

      _export(_exportObj8);
    }, function (_e2) {
      var _exportObj9 = {};

      for (var _key6 in _e2) {
        if (_key6 !== 'default') _exportObj9[_key6] = _e2[_key6];
      }

      _export(_exportObj9);
    }, function (_d2) {
      var _exportObj10 = {};

      for (var _key9 in _d2) {
        if (_key9 !== 'default') _exportObj10[_key9] = _d2[_key9];
      }

      _export(_exportObj10);
    }, function (_ab) {
      var _exportObj11 = {};

      for (var _key10 in _ab) {
        if (_key10 !== 'default') _exportObj11[_key10] = _ab[_key10];
      }

      _export(_exportObj11);
    }, function (_a0) {
      var _exportObj12 = {};

      for (var _key11 in _a0) {
        if (_key11 !== 'default') _exportObj12[_key11] = _a0[_key11];
      }

      _export(_exportObj12);
    }, function (_a6) {
      var _exportObj13 = {};

      for (var _key13 in _a6) {
        if (_key13 !== 'default') _exportObj13[_key13] = _a6[_key13];
      }

      _export(_exportObj13);
    }],
    execute: function () {}
  };
});
$__System.register('1', ['97'], function (_export) {
  'use strict';

  var Redoc, init;
  return {
    setters: [function (_) {
      Redoc = _.Redoc;
    }],
    execute: function () {
      init = Redoc.init;

      _export('init', init);

      window.Redoc = Redoc;
      Redoc.autoInit();
    }
  };
});
$__System.register('npm:prismjs@1.3.0/themes/prism-dark.css!github:systemjs/plugin-css@0.1.18.js', [], false, function() {});
$__System.register('npm:hint.css@2.2.1/hint.base.css!github:systemjs/plugin-css@0.1.18.js', [], false, function() {});
$__System.register('github:Robdel12/DropKick@2.1.7/build/css/dropkick.css!github:systemjs/plugin-css@0.1.18.js', [], false, function() {});
$__System.register('.tmp/lib/components/Redoc/redoc-loading-styles.css!github:systemjs/plugin-css@0.1.18.js', [], false, function() {});
(function(c){if (typeof document == 'undefined') return; var d=document,a='appendChild',i='styleSheet',s=d.createElement('style');s.type='text/css';d.getElementsByTagName('head')[0][a](s);s[i]?s[i].cssText=c:s[a](d.createTextNode(c));})
("code[class*=language-],pre[class*=language-]{color:#fff;text-shadow:0 -.1em .2em #000;font-family:Consolas,Monaco,'Andale Mono','Ubuntu Mono',monospace;direction:ltr;text-align:left;white-space:pre;word-spacing:normal;word-break:normal;word-wrap:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-hyphens:none;-moz-hyphens:none;-ms-hyphens:none;hyphens:none}@media print{code[class*=language-],pre[class*=language-]{text-shadow:none}}:not(pre)>code[class*=language-],pre[class*=language-]{background:#4c3f33}pre[class*=language-]{padding:1em;margin:.5em 0;overflow:auto;border:.3em solid #7a6651;border-radius:.5em;box-shadow:1px 1px .5em #000 inset}:not(pre)>code[class*=language-]{padding:.15em .2em .05em;border-radius:.3em;border:.13em solid #7a6651;box-shadow:1px 1px .3em -.1em #000 inset}.token.cdata,.token.comment,.token.doctype,.token.prolog{color:#997f66}.token.punctuation{opacity:.7}.namespace{opacity:.7}.token.boolean,.token.constant,.token.number,.token.property,.token.symbol,.token.tag{color:#d1939e}.token.attr-name,.token.builtin,.token.char,.token.inserted,.token.selector,.token.string{color:#bce051}.language-css .token.string,.style .token.string,.token.entity,.token.operator,.token.url,.token.variable{color:#f4b73d}.token.atrule,.token.attr-value,.token.keyword{color:#d1939e}.token.important,.token.regex{color:#e90}.token.bold,.token.important{font-weight:700}.token.italic{font-style:italic}.token.entity{cursor:help}.token.deleted{color:red}/*! Hint.css (base version) - v2.2.1 - 2016-03-26\n* http://kushagragour.in/lab/hint/\n* Copyright (c) 2016 Kushagra Gour; Licensed  */[data-hint]{position:relative;display:inline-block}[data-hint]:after,[data-hint]:before{position:absolute;-webkit-transform:translate3d(0,0,0);-moz-transform:translate3d(0,0,0);transform:translate3d(0,0,0);visibility:hidden;opacity:0;z-index:1000000;pointer-events:none;-webkit-transition:.3s ease;-moz-transition:.3s ease;transition:.3s ease;-webkit-transition-delay:0s;-moz-transition-delay:0s;transition-delay:0s}[data-hint]:hover:after,[data-hint]:hover:before{visibility:visible;opacity:1}[data-hint]:hover:after,[data-hint]:hover:before{-webkit-transition-delay:.1s;-moz-transition-delay:.1s;transition-delay:.1s}[data-hint]:before{content:'';position:absolute;background:0 0;border:6px solid transparent;z-index:1000001}[data-hint]:after{content:attr(data-hint);background:#383838;color:#fff;padding:8px 10px;font-size:12px;font-family:\"Helvetica Neue\",Helvetica,Arial,sans-serif;line-height:12px;white-space:nowrap}[data-hint='']:after,[data-hint='']:before{display:none!important}.hint--top-left:before{border-top-color:#383838}.hint--top-right:before{border-top-color:#383838}.hint--top:before{border-top-color:#383838}.hint--bottom-left:before{border-bottom-color:#383838}.hint--bottom-right:before{border-bottom-color:#383838}.hint--bottom:before{border-bottom-color:#383838}.hint--left:before{border-left-color:#383838}.hint--right:before{border-right-color:#383838}.hint--top:before{margin-bottom:-11px}.hint--top:after,.hint--top:before{bottom:100%;left:50%}.hint--top:before{left:calc(50% - 6px)}.hint--top:after{-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);transform:translateX(-50%)}.hint--top:focus:before,.hint--top:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--top:focus:after,.hint--top:hover:after{-webkit-transform:translateX(-50%) translateY(-8px);-moz-transform:translateX(-50%) translateY(-8px);transform:translateX(-50%) translateY(-8px)}.hint--bottom:before{margin-top:-11px}.hint--bottom:after,.hint--bottom:before{top:100%;left:50%}.hint--bottom:before{left:calc(50% - 6px)}.hint--bottom:after{-webkit-transform:translateX(-50%);-moz-transform:translateX(-50%);transform:translateX(-50%)}.hint--bottom:focus:before,.hint--bottom:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--bottom:focus:after,.hint--bottom:hover:after{-webkit-transform:translateX(-50%) translateY(8px);-moz-transform:translateX(-50%) translateY(8px);transform:translateX(-50%) translateY(8px)}.hint--right:before{margin-left:-11px;margin-bottom:-6px}.hint--right:after{margin-bottom:-14px}.hint--right:after,.hint--right:before{left:100%;bottom:50%}.hint--right:focus:before,.hint--right:hover:before{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.hint--right:focus:after,.hint--right:hover:after{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.hint--left:before{margin-right:-11px;margin-bottom:-6px}.hint--left:after{margin-bottom:-14px}.hint--left:after,.hint--left:before{right:100%;bottom:50%}.hint--left:focus:before,.hint--left:hover:before{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--left:focus:after,.hint--left:hover:after{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--top-left:before{margin-bottom:-11px}.hint--top-left:after,.hint--top-left:before{bottom:100%;left:50%}.hint--top-left:before{left:calc(50% - 6px)}.hint--top-left:after{-webkit-transform:translateX(-100%);-moz-transform:translateX(-100%);transform:translateX(-100%)}.hint--top-left:after{margin-left:12px}.hint--top-left:focus:before,.hint--top-left:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--top-left:focus:after,.hint--top-left:hover:after{-webkit-transform:translateX(-100%) translateY(-8px);-moz-transform:translateX(-100%) translateY(-8px);transform:translateX(-100%) translateY(-8px)}.hint--top-right:before{margin-bottom:-11px}.hint--top-right:after,.hint--top-right:before{bottom:100%;left:50%}.hint--top-right:before{left:calc(50% - 6px)}.hint--top-right:after{-webkit-transform:translateX(0);-moz-transform:translateX(0);transform:translateX(0)}.hint--top-right:after{margin-left:-12px}.hint--top-right:focus:before,.hint--top-right:hover:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--top-right:focus:after,.hint--top-right:hover:after{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--bottom-left:before{margin-top:-11px}.hint--bottom-left:after,.hint--bottom-left:before{top:100%;left:50%}.hint--bottom-left:before{left:calc(50% - 6px)}.hint--bottom-left:after{-webkit-transform:translateX(-100%);-moz-transform:translateX(-100%);transform:translateX(-100%)}.hint--bottom-left:after{margin-left:12px}.hint--bottom-left:focus:before,.hint--bottom-left:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--bottom-left:focus:after,.hint--bottom-left:hover:after{-webkit-transform:translateX(-100%) translateY(8px);-moz-transform:translateX(-100%) translateY(8px);transform:translateX(-100%) translateY(8px)}.hint--bottom-right:before{margin-top:-11px}.hint--bottom-right:after,.hint--bottom-right:before{top:100%;left:50%}.hint--bottom-right:before{left:calc(50% - 6px)}.hint--bottom-right:after{-webkit-transform:translateX(0);-moz-transform:translateX(0);transform:translateX(0)}.hint--bottom-right:after{margin-left:-12px}.hint--bottom-right:focus:before,.hint--bottom-right:hover:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--bottom-right:focus:after,.hint--bottom-right:hover:after{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--large:after,.hint--medium:after,.hint--small:after{white-space:normal;line-height:1.4em}.hint--small:after{width:80px}.hint--medium:after{width:150px}.hint--large:after{width:300px}.hint--always:after,.hint--always:before{opacity:1;visibility:visible}.hint--always.hint--top:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--top:after{-webkit-transform:translateX(-50%) translateY(-8px);-moz-transform:translateX(-50%) translateY(-8px);transform:translateX(-50%) translateY(-8px)}.hint--always.hint--top-left:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--top-left:after{-webkit-transform:translateX(-100%) translateY(-8px);-moz-transform:translateX(-100%) translateY(-8px);transform:translateX(-100%) translateY(-8px)}.hint--always.hint--top-right:before{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--top-right:after{-webkit-transform:translateY(-8px);-moz-transform:translateY(-8px);transform:translateY(-8px)}.hint--always.hint--bottom:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--bottom:after{-webkit-transform:translateX(-50%) translateY(8px);-moz-transform:translateX(-50%) translateY(8px);transform:translateX(-50%) translateY(8px)}.hint--always.hint--bottom-left:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--bottom-left:after{-webkit-transform:translateX(-100%) translateY(8px);-moz-transform:translateX(-100%) translateY(8px);transform:translateX(-100%) translateY(8px)}.hint--always.hint--bottom-right:before{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--bottom-right:after{-webkit-transform:translateY(8px);-moz-transform:translateY(8px);transform:translateY(8px)}.hint--always.hint--left:before{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--always.hint--left:after{-webkit-transform:translateX(-8px);-moz-transform:translateX(-8px);transform:translateX(-8px)}.hint--always.hint--right:before{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.hint--always.hint--right:after{-webkit-transform:translateX(8px);-moz-transform:translateX(8px);transform:translateX(8px)}.dk-select,.dk-select *,.dk-select :after,.dk-select :before,.dk-select-multi,.dk-select-multi *,.dk-select-multi :after,.dk-select-multi :before{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dk-select,.dk-select-multi{position:relative;display:inline-block;vertical-align:middle;line-height:1.5em;width:200px;cursor:pointer}.dk-selected{width:100%;white-space:nowrap;overflow:hidden;position:relative;background-color:#fff;border:1px solid #CCC;border-radius:.4em;padding:0 1.5em 0 .5em;-o-text-overflow:ellipsis;text-overflow:ellipsis}.dk-selected:after,.dk-selected:before{content:'';display:block;position:absolute;right:0}.dk-selected:before{top:50%;border:solid transparent;border-width:.25em .25em 0;border-top-color:#CCC;margin:-.125em .5em 0 0}.dk-selected:after{top:0;height:100%;border-left:1px solid #CCC;margin:0 1.5em 0 0}.dk-selected-disabled{color:#BBB}.dk-select .dk-select-options{position:absolute;display:none;left:0;right:0}.dk-select-open-up .dk-select-options{border-radius:.4em .4em 0 0;margin-bottom:-1px;bottom:100%}.dk-select-open-down .dk-select-options{border-radius:0 0 .4em .4em;margin-top:-1px;top:100%}.dk-select-multi .dk-select-options{max-height:10em}.dk-select-options{background-color:#fff;border:1px solid #CCC;border-radius:.4em;list-style:none;margin:0;max-height:10.5em;min-width:100%;overflow-x:hidden;overflow-y:auto;padding:.25em 0;width:auto;z-index:100}.dk-option-selected{background-color:#3297fd;color:#fff}.dk-select-options-highlight .dk-option-selected{background-color:transparent;color:inherit}.dk-option{padding:0 .5em}.dk-select-options .dk-option-highlight{background-color:#3297fd;color:#fff}.dk-select-options .dk-option-disabled{color:#BBB;background-color:transparent}.dk-optgroup{border:solid #CCC;border-width:1px 0;padding:.25em 0;margin-top:.25em}.dk-optgroup+.dk-option{margin-top:.25em}.dk-optgroup+.dk-optgroup{border-top-width:0;margin-top:0}.dk-optgroup:nth-child(2){padding-top:0;border-top:none;margin-top:0}.dk-optgroup:last-child{border-bottom-width:0;margin-bottom:0;padding-bottom:0}.dk-optgroup-label{padding:0 .5em .25em;font-weight:700;width:100%}.dk-optgroup-options{list-style:none;padding-left:0}.dk-optgroup-options li{padding-left:1.2em}.dk-select-open-up .dk-selected{border-top-left-radius:0;border-top-right-radius:0;border-color:#3297fd}.dk-select-open-down .dk-selected{border-bottom-left-radius:0;border-bottom-right-radius:0;border-color:#3297fd}.dk-select-open-down .dk-selected:before,.dk-select-open-up .dk-selected:before{border-width:0 .25em .25em;border-bottom-color:#3297fd}.dk-select-open-down .dk-selected:after,.dk-select-open-up .dk-selected:after{border-left-color:#3297fd}.dk-select-multi:focus .dk-select-options,.dk-select-open-down .dk-select-options,.dk-select-open-up .dk-select-options{display:block;border-color:#3297fd}.dk-select-multi:focus,.dk-select-multi:hover{outline:0}.dk-selected:focus,.dk-selected:hover{outline:0;border-color:#3297fd}.dk-selected:focus:before,.dk-selected:hover:before{border-top-color:#3297fd}.dk-selected:focus:after,.dk-selected:hover:after{border-left-color:#3297fd}.dk-select-disabled{opacity:.6;color:#BBB;cursor:not-allowed}.dk-select-disabled .dk-selected:focus,.dk-select-disabled .dk-selected:hover{border-color:inherit}.dk-select-disabled .dk-selected:focus:before,.dk-select-disabled .dk-selected:hover:before{border-top-color:inherit}.dk-select-disabled .dk-selected:focus:after,.dk-select-disabled .dk-selected:hover:after{border-left-color:inherit}select[data-dkcacheid]{display:none}redoc.loading{position:relative;display:block;min-height:350px}@keyframes move{0%{transform:translateY(10px)}25%{transform:translateY(0)}50%{transform:translateY(10px)}75%{transform:translateY(20px)}100%{transform:translateY(10px)}}redoc.loading:before{font-family:Montserrat;content:\"Loading...\";font-size:28px;text-align:center;padding-top:40px;color:#0033a0;font-weight:700;display:block;position:absolute;top:0;bottom:0;left:0;right:0;background-color:#fff;z-index:9999;opacity:1;transition:all .6s ease-out;animation:2s move linear infinite}redoc.loading-remove:before{opacity:0}");
})
(function(factory) {
  if (typeof define == 'function' && define.amd)
    define([], factory);
  else if (typeof module == 'object' && module.exports && typeof require == 'function')
    module.exports = factory();
  else
    factory();
});

//# sourceMappingURL=redoc.js.map
