MCPcopy Index your code
hub / github.com/NativeScript/NativeScript / buildTemplate

Method buildTemplate

packages/core/ui/builder/index.ts:563–585  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

561 }
562
563 public buildTemplate(): Template {
564 if (__UI_USE_XML_PARSER__) {
565 const context = this._context;
566 const errorFormat = this._templateProperty.errorFormat;
567 const sourceTracker = this._templateProperty.sourceTracker;
568 const template: Template = <Template>profile('Template()', () => {
569 let start: xml2ui.XmlArgsReplay;
570 let ui: xml2ui.ComponentParser;
571
572 (start = new xml2ui.XmlArgsReplay(this._recordedXmlStream, errorFormat))
573 // No platform filter, it has been filtered already
574 .pipe(new XmlStateParser((ui = new ComponentParser(context, errorFormat, sourceTracker))));
575
576 start.replay();
577
578 return ui.rootComponentModule.component;
579 });
580
581 return template;
582 } else {
583 return null;
584 }
585 }
586 }
587
588 export class MultiTemplateParser implements XmlStateConsumer {

Callers 2

parseEndElementMethod · 0.95
parseMethod · 0.80

Calls 3

profileFunction · 0.90
replayMethod · 0.80
pipeMethod · 0.65

Tested by

no test coverage detected