1 | /**
|
---|
2 | * @license
|
---|
3 | * Copyright Google LLC All Rights Reserved.
|
---|
4 | *
|
---|
5 | * Use of this source code is governed by an MIT-style license that can be
|
---|
6 | * found in the LICENSE file at https://angular.io/license
|
---|
7 | */
|
---|
8 | import { MissingTranslationStrategy } from '../core';
|
---|
9 | import * as html from '../ml_parser/ast';
|
---|
10 | import { Console } from '../util';
|
---|
11 | import * as i18n from './i18n_ast';
|
---|
12 | import { PlaceholderMapper, Serializer } from './serializers/serializer';
|
---|
13 | /**
|
---|
14 | * A container for translated messages
|
---|
15 | */
|
---|
16 | export declare class TranslationBundle {
|
---|
17 | private _i18nNodesByMsgId;
|
---|
18 | digest: (m: i18n.Message) => string;
|
---|
19 | mapperFactory?: ((m: i18n.Message) => PlaceholderMapper) | undefined;
|
---|
20 | private _i18nToHtml;
|
---|
21 | constructor(_i18nNodesByMsgId: {
|
---|
22 | [msgId: string]: i18n.Node[];
|
---|
23 | }, locale: string | null, digest: (m: i18n.Message) => string, mapperFactory?: ((m: i18n.Message) => PlaceholderMapper) | undefined, missingTranslationStrategy?: MissingTranslationStrategy, console?: Console);
|
---|
24 | static load(content: string, url: string, serializer: Serializer, missingTranslationStrategy: MissingTranslationStrategy, console?: Console): TranslationBundle;
|
---|
25 | get(srcMsg: i18n.Message): html.Node[];
|
---|
26 | has(srcMsg: i18n.Message): boolean;
|
---|
27 | }
|
---|