source: trip-planner-front/node_modules/@angular/compiler-cli/linker/src/file_linker/emit_scopes/iife_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/iife_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 * as o from '@angular/compiler/src/output/output_ast';
10import { AstFactory } from '../../../../src/ngtsc/translator';
11import { Translator } from '../translator';
12import { EmitScope } from './emit_scope';
13/**
14 * This class is a specialization of the `EmitScope` class that is designed for the situation where
15 * there is no clear shared scope for constant statements. In this case they are bundled with the
16 * translated definition inside an IIFE.
17 */
18export declare class IifeEmitScope<TStatement, TExpression> extends EmitScope<TStatement, TExpression> {
19 private readonly factory;
20 constructor(ngImport: TExpression, translator: Translator<TStatement, TExpression>, factory: AstFactory<TStatement, TExpression>);
21 /**
22 * Translate the given Output AST definition expression into a generic `TExpression`.
23 *
24 * Wraps the output from `EmitScope.translateDefinition()` and `EmitScope.getConstantStatements()`
25 * in an IIFE.
26 */
27 translateDefinition(definition: o.Expression): TExpression;
28 /**
29 * It is not valid to call this method, since there will be no shared constant statements - they
30 * are already emitted in the IIFE alongside the translated definition.
31 */
32 getConstantStatements(): TStatement[];
33}
Note: See TracBrowser for help on using the repository browser.