(locales: ILocale[], localeId: string)
| 95 | } |
| 96 | |
| 97 | public initialize(locales: ILocale[], localeId: string) { |
| 98 | this.addLocales(locales); |
| 99 | if (this._locales.get(localeId)) { |
| 100 | this._current = this._locales.get(localeId); |
| 101 | } else { |
| 102 | logger.error(`Cannot initialize the locale with ${localeId}`); |
| 103 | } |
| 104 | } |
| 105 | |
| 106 | public getCurrentLocale(): ILocale | undefined { |
| 107 | return this._current && Object.assign({}, this._current); |
nothing calls this directly
no test coverage detected