MCPcopy Index your code
hub / github.com/angular/angular / parse

Method parse

packages/compiler/src/i18n/serializers/xliff.ts:225–239  ·  view source on GitHub ↗
(xliff: string, url: string)

Source from the content-addressed store, hash-verified

223 private _locale: string | null = null;
224
225 parse(xliff: string, url: string) {
226 this._unitMlString = null;
227 this._msgIdToHtml = {};
228
229 const xml = new XmlParser().parse(xliff, url);
230
231 this._errors = xml.errors;
232 ml.visitAll(this, xml.rootNodes, null);
233
234 return {
235 msgIdToHtml: this._msgIdToHtml,
236 errors: this._errors,
237 locale: this._locale,
238 };
239 }
240
241 visitElement(element: ml.Element, context: any): any {
242 switch (element.name) {

Callers 1

loadMethod · 0.95

Calls 2

parseMethod · 0.65
visitAllMethod · 0.45

Tested by

no test coverage detected