source: trip-planner-front/node_modules/@angular/compiler-cli/linker/src/file_linker/emit_scopes/emit_scope.d.ts@ 6a3a178

Last change on this file since 6a3a178 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.5 KB
Line 
1/// <amd-module name="@angular/compiler-cli/linker/src/file_linker/emit_scopes/emit_scope" />
2/**
3 * @license
4 * Copyright Google LLC All Rights Reserved.
5 *
6 * Use of this source code is governed by an MIT-style license that can be
7 * found in the LICENSE file at https://angular.io/license
8 */
9import { ConstantPool } from '@angular/compiler';
10import * as o from '@angular/compiler/src/output/output_ast';
11import { Translator } from '../translator';
12/**
13 * This class represents (from the point of view of the `FileLinker`) the scope in which
14 * statements and expressions related to a linked partial declaration will be emitted.
15 *
16 * It holds a copy of a `ConstantPool` that is used to capture any constant statements that need to
17 * be emitted in this context.
18 *
19 * This implementation will emit the definition and the constant statements separately.
20 */
21export declare class EmitScope<TStatement, TExpression> {
22 protected readonly ngImport: TExpression;
23 protected readonly translator: Translator<TStatement, TExpression>;
24 readonly constantPool: ConstantPool;
25 constructor(ngImport: TExpression, translator: Translator<TStatement, TExpression>);
26 /**
27 * Translate the given Output AST definition expression into a generic `TExpression`.
28 *
29 * Use a `LinkerImportGenerator` to handle any imports in the definition.
30 */
31 translateDefinition(definition: o.Expression): TExpression;
32 /**
33 * Return any constant statements that are shared between all uses of this `EmitScope`.
34 */
35 getConstantStatements(): TStatement[];
36}
Note: See TracBrowser for help on using the repository browser.