source: trip-planner-front/node_modules/@angular/compiler/src/compiler_facade_interface.d.ts

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

initial commit

  • Property mode set to 100644
File size: 8.9 KB
Line 
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/**
9 * A set of interfaces which are shared between `@angular/core` and `@angular/compiler` to allow
10 * for late binding of `@angular/compiler` for JIT purposes.
11 *
12 * This file has two copies. Please ensure that they are in sync:
13 * - packages/compiler/src/compiler_facade_interface.ts (main)
14 * - packages/core/src/compiler/compiler_facade_interface.ts (replica)
15 *
16 * Please ensure that the two files are in sync using this command:
17 * ```
18 * cp packages/compiler/src/compiler_facade_interface.ts \
19 * packages/core/src/compiler/compiler_facade_interface.ts
20 * ```
21 */
22export interface ExportedCompilerFacade {
23 ɵcompilerFacade: CompilerFacade;
24}
25export interface CompilerFacade {
26 compilePipe(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3PipeMetadataFacade): any;
27 compilePipeDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, declaration: R3DeclarePipeFacade): any;
28 compileInjectable(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3InjectableMetadataFacade): any;
29 compileInjectableDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3DeclareInjectableFacade): any;
30 compileInjector(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3InjectorMetadataFacade): any;
31 compileInjectorDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, declaration: R3DeclareInjectorFacade): any;
32 compileNgModule(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3NgModuleMetadataFacade): any;
33 compileNgModuleDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, declaration: R3DeclareNgModuleFacade): any;
34 compileDirective(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3DirectiveMetadataFacade): any;
35 compileDirectiveDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, declaration: R3DeclareDirectiveFacade): any;
36 compileComponent(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3ComponentMetadataFacade): any;
37 compileComponentDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, declaration: R3DeclareComponentFacade): any;
38 compileFactory(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3FactoryDefMetadataFacade): any;
39 compileFactoryDeclaration(angularCoreEnv: CoreEnvironment, sourceMapUrl: string, meta: R3DeclareFactoryFacade): any;
40 createParseSourceSpan(kind: string, typeName: string, sourceUrl: string): ParseSourceSpan;
41 FactoryTarget: typeof FactoryTarget;
42 ResourceLoader: Function & {
43 prototype: ResourceLoader;
44 };
45}
46export interface CoreEnvironment {
47 [name: string]: Function;
48}
49export declare type ResourceLoader = {
50 get(url: string): Promise<string> | string;
51};
52export declare type StringMap = {
53 [key: string]: string;
54};
55export declare type StringMapWithRename = {
56 [key: string]: string | [string, string];
57};
58export declare type Provider = unknown;
59export declare type Type = Function;
60export declare type OpaqueValue = unknown;
61export declare enum FactoryTarget {
62 Directive = 0,
63 Component = 1,
64 Injectable = 2,
65 Pipe = 3,
66 NgModule = 4
67}
68export interface R3DependencyMetadataFacade {
69 token: OpaqueValue;
70 attribute: string | null;
71 host: boolean;
72 optional: boolean;
73 self: boolean;
74 skipSelf: boolean;
75}
76export interface R3DeclareDependencyMetadataFacade {
77 token: OpaqueValue;
78 attribute?: boolean;
79 host?: boolean;
80 optional?: boolean;
81 self?: boolean;
82 skipSelf?: boolean;
83}
84export interface R3PipeMetadataFacade {
85 name: string;
86 type: Type;
87 pipeName: string;
88 pure: boolean;
89}
90export interface R3InjectableMetadataFacade {
91 name: string;
92 type: Type;
93 typeArgumentCount: number;
94 providedIn?: Type | 'root' | 'platform' | 'any' | null;
95 useClass?: OpaqueValue;
96 useFactory?: OpaqueValue;
97 useExisting?: OpaqueValue;
98 useValue?: OpaqueValue;
99 deps?: R3DependencyMetadataFacade[];
100}
101export interface R3NgModuleMetadataFacade {
102 type: Type;
103 bootstrap: Function[];
104 declarations: Function[];
105 imports: Function[];
106 exports: Function[];
107 schemas: {
108 name: string;
109 }[] | null;
110 id: string | null;
111}
112export interface R3InjectorMetadataFacade {
113 name: string;
114 type: Type;
115 providers: Provider[];
116 imports: OpaqueValue[];
117}
118export interface R3DirectiveMetadataFacade {
119 name: string;
120 type: Type;
121 typeSourceSpan: ParseSourceSpan;
122 selector: string | null;
123 queries: R3QueryMetadataFacade[];
124 host: {
125 [key: string]: string;
126 };
127 propMetadata: {
128 [key: string]: OpaqueValue[];
129 };
130 lifecycle: {
131 usesOnChanges: boolean;
132 };
133 inputs: string[];
134 outputs: string[];
135 usesInheritance: boolean;
136 exportAs: string[] | null;
137 providers: Provider[] | null;
138 viewQueries: R3QueryMetadataFacade[];
139}
140export interface R3ComponentMetadataFacade extends R3DirectiveMetadataFacade {
141 template: string;
142 preserveWhitespaces: boolean;
143 animations: OpaqueValue[] | undefined;
144 pipes: Map<string, any>;
145 directives: R3UsedDirectiveMetadata[];
146 styles: string[];
147 encapsulation: ViewEncapsulation;
148 viewProviders: Provider[] | null;
149 interpolation?: [string, string];
150 changeDetection?: ChangeDetectionStrategy;
151}
152export interface R3DeclareDirectiveFacade {
153 selector?: string;
154 type: Type;
155 inputs?: {
156 [classPropertyName: string]: string | [string, string];
157 };
158 outputs?: {
159 [classPropertyName: string]: string;
160 };
161 host?: {
162 attributes?: {
163 [key: string]: OpaqueValue;
164 };
165 listeners?: {
166 [key: string]: string;
167 };
168 properties?: {
169 [key: string]: string;
170 };
171 classAttribute?: string;
172 styleAttribute?: string;
173 };
174 queries?: R3DeclareQueryMetadataFacade[];
175 viewQueries?: R3DeclareQueryMetadataFacade[];
176 providers?: OpaqueValue;
177 exportAs?: string[];
178 usesInheritance?: boolean;
179 usesOnChanges?: boolean;
180}
181export interface R3DeclareComponentFacade extends R3DeclareDirectiveFacade {
182 template: string;
183 isInline?: boolean;
184 styles?: string[];
185 components?: R3DeclareUsedDirectiveFacade[];
186 directives?: R3DeclareUsedDirectiveFacade[];
187 pipes?: {
188 [pipeName: string]: OpaqueValue | (() => OpaqueValue);
189 };
190 viewProviders?: OpaqueValue;
191 animations?: OpaqueValue;
192 changeDetection?: ChangeDetectionStrategy;
193 encapsulation?: ViewEncapsulation;
194 interpolation?: [string, string];
195 preserveWhitespaces?: boolean;
196}
197export interface R3DeclareUsedDirectiveFacade {
198 selector: string;
199 type: OpaqueValue | (() => OpaqueValue);
200 inputs?: string[];
201 outputs?: string[];
202 exportAs?: string[];
203}
204export interface R3UsedDirectiveMetadata {
205 selector: string;
206 inputs: string[];
207 outputs: string[];
208 exportAs: string[] | null;
209 type: any;
210}
211export interface R3FactoryDefMetadataFacade {
212 name: string;
213 type: Type;
214 typeArgumentCount: number;
215 deps: R3DependencyMetadataFacade[] | null;
216 target: FactoryTarget;
217}
218export interface R3DeclareFactoryFacade {
219 type: Type;
220 deps: R3DeclareDependencyMetadataFacade[] | 'invalid' | null;
221 target: FactoryTarget;
222}
223export interface R3DeclareInjectableFacade {
224 type: Type;
225 providedIn?: Type | 'root' | 'platform' | 'any' | null;
226 useClass?: OpaqueValue;
227 useFactory?: OpaqueValue;
228 useExisting?: OpaqueValue;
229 useValue?: OpaqueValue;
230 deps?: R3DeclareDependencyMetadataFacade[];
231}
232export declare enum ViewEncapsulation {
233 Emulated = 0,
234 None = 2,
235 ShadowDom = 3
236}
237export declare type ChangeDetectionStrategy = number;
238export interface R3QueryMetadataFacade {
239 propertyName: string;
240 first: boolean;
241 predicate: OpaqueValue | string[];
242 descendants: boolean;
243 emitDistinctChangesOnly: boolean;
244 read: OpaqueValue | null;
245 static: boolean;
246}
247export interface R3DeclareQueryMetadataFacade {
248 propertyName: string;
249 first?: boolean;
250 predicate: OpaqueValue | string[];
251 descendants?: boolean;
252 read?: OpaqueValue;
253 static?: boolean;
254 emitDistinctChangesOnly?: boolean;
255}
256export interface R3DeclareInjectorFacade {
257 type: Type;
258 imports?: OpaqueValue[];
259 providers?: OpaqueValue[];
260}
261export interface R3DeclareNgModuleFacade {
262 type: Type;
263 bootstrap?: OpaqueValue[] | (() => OpaqueValue[]);
264 declarations?: OpaqueValue[] | (() => OpaqueValue[]);
265 imports?: OpaqueValue[] | (() => OpaqueValue[]);
266 exports?: OpaqueValue[] | (() => OpaqueValue[]);
267 schemas?: OpaqueValue[];
268 id?: OpaqueValue;
269}
270export interface R3DeclarePipeFacade {
271 type: Type;
272 name: string;
273 pure?: boolean;
274}
275export interface ParseSourceSpan {
276 start: any;
277 end: any;
278 details: any;
279 fullStart: any;
280}
Note: See TracBrowser for help on using the repository browser.