angular-l10n
Version:
An Angular library to translate messages, dates and numbers
50 lines • 1.22 kB
JavaScript
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,extraRequire,uselessCode} checked by tsc
*/
import { Injectable, Injector } from '@angular/core';
/**
* Allows to get the dependencies at the root level.
*/
export class InjectorRef {
/**
* @param {?} injector
*/
constructor(injector) {
this.injector = injector;
/**
* TranslationService instances.
*/
this.translations = [];
InjectorRef.injector = this.injector;
}
/**
* @template T
* @param {?} token
* @param {?=} notFoundValue
* @return {?}
*/
static get(token, notFoundValue) {
return InjectorRef.injector.get(token, notFoundValue);
}
}
InjectorRef.injector = Injector.NULL;
InjectorRef.decorators = [
{ type: Injectable }
];
/** @nocollapse */
InjectorRef.ctorParameters = () => [
{ type: Injector }
];
if (false) {
/** @type {?} */
InjectorRef.injector;
/**
* TranslationService instances.
* @type {?}
*/
InjectorRef.prototype.translations;
/** @type {?} */
InjectorRef.prototype.injector;
}
//# sourceMappingURL=injector-ref.js.map