@angular/compiler 14.0.0-next.8 → 14.0.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/src/compiler.mjs +3 -2
- package/esm2020/src/compiler_facade_interface.mjs +7 -1
- package/esm2020/src/core.mjs +6 -6
- package/esm2020/src/expression_parser/parser.mjs +12 -12
- package/esm2020/src/i18n/i18n_parser.mjs +3 -3
- package/esm2020/src/jit_compiler_facade.mjs +74 -42
- package/esm2020/src/ml_parser/html_whitespaces.mjs +2 -2
- package/esm2020/src/ml_parser/lexer.mjs +36 -36
- package/esm2020/src/ml_parser/parser.mjs +41 -41
- package/esm2020/src/render3/partial/api.mjs +1 -1
- package/esm2020/src/render3/partial/class_metadata.mjs +1 -1
- package/esm2020/src/render3/partial/component.mjs +28 -37
- package/esm2020/src/render3/partial/directive.mjs +6 -3
- package/esm2020/src/render3/partial/factory.mjs +1 -1
- package/esm2020/src/render3/partial/injectable.mjs +1 -1
- package/esm2020/src/render3/partial/injector.mjs +1 -1
- package/esm2020/src/render3/partial/ng_module.mjs +3 -3
- package/esm2020/src/render3/partial/pipe.mjs +6 -3
- package/esm2020/src/render3/r3_ast.mjs +3 -3
- package/esm2020/src/render3/r3_factory.mjs +6 -6
- package/esm2020/src/render3/r3_identifiers.mjs +2 -1
- package/esm2020/src/render3/r3_pipe_compiler.mjs +5 -1
- package/esm2020/src/render3/util.mjs +4 -4
- package/esm2020/src/render3/view/api.mjs +7 -2
- package/esm2020/src/render3/view/compiler.mjs +45 -35
- package/esm2020/src/render3/view/i18n/get_msg_utils.mjs +58 -5
- package/esm2020/src/render3/view/i18n/meta.mjs +4 -4
- package/esm2020/src/render3/view/i18n/util.mjs +2 -2
- package/esm2020/src/render3/view/style_parser.mjs +19 -19
- package/esm2020/src/render3/view/styling_builder.mjs +6 -6
- package/esm2020/src/render3/view/template.mjs +25 -25
- package/esm2020/src/render3/view/util.mjs +14 -5
- package/esm2020/src/selector.mjs +8 -8
- package/esm2020/src/template_parser/binding_parser.mjs +8 -8
- package/esm2020/src/util.mjs +8 -8
- package/esm2020/src/version.mjs +1 -1
- package/fesm2015/compiler.mjs +416 -301
- package/fesm2015/compiler.mjs.map +1 -1
- package/fesm2015/testing.mjs +1 -1
- package/fesm2020/compiler.mjs +424 -314
- package/fesm2020/compiler.mjs.map +1 -1
- package/fesm2020/testing.mjs +1 -1
- package/index.d.ts +4964 -5
- package/package.json +3 -3
- package/testing/index.d.ts +22 -5
- package/compiler.d.ts +0 -8
- package/public_api.d.ts +0 -13
- package/src/assertions.d.ts +0 -8
- package/src/chars.d.ts +0 -75
- package/src/compiler.d.ts +0 -77
- package/src/compiler_facade_interface.d.ts +0 -284
- package/src/compiler_util/expression_converter.d.ts +0 -71
- package/src/config.d.ts +0 -25
- package/src/constant_pool.d.ts +0 -37
- package/src/core.d.ts +0 -216
- package/src/expression_parser/ast.d.ts +0 -440
- package/src/expression_parser/lexer.d.ts +0 -47
- package/src/expression_parser/parser.d.ts +0 -315
- package/src/i18n/big_integer.d.ts +0 -108
- package/src/i18n/digest.d.ts +0 -44
- package/src/i18n/extractor_merger.d.ts +0 -27
- package/src/i18n/i18n_ast.d.ts +0 -148
- package/src/i18n/i18n_html_parser.d.ts +0 -19
- package/src/i18n/i18n_parser.d.ts +0 -18
- package/src/i18n/index.d.ts +0 -15
- package/src/i18n/message_bundle.d.ts +0 -28
- package/src/i18n/parse_util.d.ts +0 -14
- package/src/i18n/serializers/placeholder.d.ts +0 -25
- package/src/i18n/serializers/serializer.d.ts +0 -46
- package/src/i18n/serializers/xliff.d.ts +0 -19
- package/src/i18n/serializers/xliff2.d.ts +0 -19
- package/src/i18n/serializers/xmb.d.ts +0 -22
- package/src/i18n/serializers/xml_helper.d.ts +0 -52
- package/src/i18n/serializers/xtb.d.ts +0 -20
- package/src/i18n/translation_bundle.d.ts +0 -27
- package/src/injectable_compiler_2.d.ts +0 -24
- package/src/jit_compiler_facade.d.ts +0 -46
- package/src/ml_parser/ast.d.ts +0 -89
- package/src/ml_parser/entities.d.ts +0 -9
- package/src/ml_parser/html_parser.d.ts +0 -13
- package/src/ml_parser/html_tags.d.ts +0 -33
- package/src/ml_parser/html_whitespaces.d.ts +0 -45
- package/src/ml_parser/icu_ast_expander.d.ts +0 -42
- package/src/ml_parser/interpolation_config.d.ts +0 -14
- package/src/ml_parser/lexer.d.ts +0 -114
- package/src/ml_parser/parser.d.ts +0 -26
- package/src/ml_parser/tags.d.ts +0 -29
- package/src/ml_parser/tokens.d.ts +0 -141
- package/src/ml_parser/xml_parser.d.ts +0 -13
- package/src/ml_parser/xml_tags.d.ts +0 -24
- package/src/output/abstract_emitter.d.ts +0 -66
- package/src/output/abstract_js_emitter.d.ts +0 -19
- package/src/output/map_util.d.ts +0 -18
- package/src/output/output_ast.d.ts +0 -575
- package/src/output/output_jit.d.ts +0 -73
- package/src/output/output_jit_trusted_types.d.ts +0 -43
- package/src/output/source_map.d.ts +0 -29
- package/src/parse_util.d.ts +0 -75
- package/src/render3/partial/api.d.ts +0 -441
- package/src/render3/partial/class_metadata.d.ts +0 -10
- package/src/render3/partial/component.d.ts +0 -39
- package/src/render3/partial/directive.d.ts +0 -13
- package/src/render3/partial/factory.d.ts +0 -3
- package/src/render3/partial/injectable.d.ts +0 -19
- package/src/render3/partial/injector.d.ts +0 -3
- package/src/render3/partial/ng_module.d.ts +0 -3
- package/src/render3/partial/pipe.d.ts +0 -12
- package/src/render3/partial/util.d.ts +0 -33
- package/src/render3/r3_ast.d.ts +0 -211
- package/src/render3/r3_class_metadata_compiler.d.ts +0 -35
- package/src/render3/r3_factory.d.ts +0 -94
- package/src/render3/r3_identifiers.d.ts +0 -182
- package/src/render3/r3_injector_compiler.d.ts +0 -18
- package/src/render3/r3_jit.d.ts +0 -22
- package/src/render3/r3_module_compiler.d.ts +0 -103
- package/src/render3/r3_pipe_compiler.d.ts +0 -50
- package/src/render3/r3_template_transform.d.ts +0 -24
- package/src/render3/util.d.ts +0 -94
- package/src/render3/view/api.d.ts +0 -328
- package/src/render3/view/compiler.d.ts +0 -86
- package/src/render3/view/i18n/context.d.ts +0 -68
- package/src/render3/view/i18n/get_msg_utils.d.ts +0 -13
- package/src/render3/view/i18n/icu_serializer.d.ts +0 -9
- package/src/render3/view/i18n/localize_utils.d.ts +0 -24
- package/src/render3/view/i18n/meta.d.ts +0 -78
- package/src/render3/view/i18n/util.d.ts +0 -78
- package/src/render3/view/style_parser.d.ts +0 -18
- package/src/render3/view/styling_builder.d.ts +0 -211
- package/src/render3/view/t2_api.d.ts +0 -152
- package/src/render3/view/t2_binder.d.ts +0 -57
- package/src/render3/view/template.d.ts +0 -450
- package/src/render3/view/util.d.ts +0 -94
- package/src/resource_loader.d.ts +0 -17
- package/src/schema/dom_element_schema_registry.d.ts +0 -45
- package/src/schema/dom_security_schema.d.ts +0 -11
- package/src/schema/element_schema_registry.d.ts +0 -29
- package/src/schema/trusted_types_sinks.d.ts +0 -15
- package/src/selector.d.ts +0 -105
- package/src/shadow_css.d.ts +0 -76
- package/src/style_url_resolver.d.ts +0 -8
- package/src/template_parser/binding_parser.d.ts +0 -91
- package/src/template_parser/template_preparser.d.ts +0 -24
- package/src/util.d.ts +0 -42
- package/src/version.d.ts +0 -14
- package/testing/package.json +0 -9
- package/testing/public_api.d.ts +0 -13
- package/testing/src/testing.d.ts +0 -23
- package/testing/testing.d.ts +0 -4
package/src/core.d.ts
DELETED
|
@@ -1,216 +0,0 @@
|
|
|
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
|
-
export declare const emitDistinctChangesOnlyDefaultValue = true;
|
|
9
|
-
export declare enum ViewEncapsulation {
|
|
10
|
-
Emulated = 0,
|
|
11
|
-
None = 2,
|
|
12
|
-
ShadowDom = 3
|
|
13
|
-
}
|
|
14
|
-
export declare enum ChangeDetectionStrategy {
|
|
15
|
-
OnPush = 0,
|
|
16
|
-
Default = 1
|
|
17
|
-
}
|
|
18
|
-
export interface Input {
|
|
19
|
-
bindingPropertyName?: string;
|
|
20
|
-
}
|
|
21
|
-
export interface Output {
|
|
22
|
-
bindingPropertyName?: string;
|
|
23
|
-
}
|
|
24
|
-
export interface HostBinding {
|
|
25
|
-
hostPropertyName?: string;
|
|
26
|
-
}
|
|
27
|
-
export interface HostListener {
|
|
28
|
-
eventName?: string;
|
|
29
|
-
args?: string[];
|
|
30
|
-
}
|
|
31
|
-
export interface SchemaMetadata {
|
|
32
|
-
name: string;
|
|
33
|
-
}
|
|
34
|
-
export declare const CUSTOM_ELEMENTS_SCHEMA: SchemaMetadata;
|
|
35
|
-
export declare const NO_ERRORS_SCHEMA: SchemaMetadata;
|
|
36
|
-
export interface Type extends Function {
|
|
37
|
-
new (...args: any[]): any;
|
|
38
|
-
}
|
|
39
|
-
export declare const Type: FunctionConstructor;
|
|
40
|
-
export declare enum SecurityContext {
|
|
41
|
-
NONE = 0,
|
|
42
|
-
HTML = 1,
|
|
43
|
-
STYLE = 2,
|
|
44
|
-
SCRIPT = 3,
|
|
45
|
-
URL = 4,
|
|
46
|
-
RESOURCE_URL = 5
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* Injection flags for DI.
|
|
50
|
-
*/
|
|
51
|
-
export declare const enum InjectFlags {
|
|
52
|
-
Default = 0,
|
|
53
|
-
/**
|
|
54
|
-
* Specifies that an injector should retrieve a dependency from any injector until reaching the
|
|
55
|
-
* host element of the current component. (Only used with Element Injector)
|
|
56
|
-
*/
|
|
57
|
-
Host = 1,
|
|
58
|
-
/** Don't descend into ancestors of the node requesting injection. */
|
|
59
|
-
Self = 2,
|
|
60
|
-
/** Skip the node that is requesting injection. */
|
|
61
|
-
SkipSelf = 4,
|
|
62
|
-
/** Inject `defaultValue` instead if token not found. */
|
|
63
|
-
Optional = 8
|
|
64
|
-
}
|
|
65
|
-
export declare enum MissingTranslationStrategy {
|
|
66
|
-
Error = 0,
|
|
67
|
-
Warning = 1,
|
|
68
|
-
Ignore = 2
|
|
69
|
-
}
|
|
70
|
-
/**
|
|
71
|
-
* Flags used to generate R3-style CSS Selectors. They are pasted from
|
|
72
|
-
* core/src/render3/projection.ts because they cannot be referenced directly.
|
|
73
|
-
*/
|
|
74
|
-
export declare const enum SelectorFlags {
|
|
75
|
-
/** Indicates this is the beginning of a new negative selector */
|
|
76
|
-
NOT = 1,
|
|
77
|
-
/** Mode for matching attributes */
|
|
78
|
-
ATTRIBUTE = 2,
|
|
79
|
-
/** Mode for matching tag names */
|
|
80
|
-
ELEMENT = 4,
|
|
81
|
-
/** Mode for matching class names */
|
|
82
|
-
CLASS = 8
|
|
83
|
-
}
|
|
84
|
-
export declare type R3CssSelector = (string | SelectorFlags)[];
|
|
85
|
-
export declare type R3CssSelectorList = R3CssSelector[];
|
|
86
|
-
export declare function parseSelectorToR3Selector(selector: string | null): R3CssSelectorList;
|
|
87
|
-
/**
|
|
88
|
-
* Flags passed into template functions to determine which blocks (i.e. creation, update)
|
|
89
|
-
* should be executed.
|
|
90
|
-
*
|
|
91
|
-
* Typically, a template runs both the creation block and the update block on initialization and
|
|
92
|
-
* subsequent runs only execute the update block. However, dynamically created views require that
|
|
93
|
-
* the creation block be executed separately from the update block (for backwards compat).
|
|
94
|
-
*/
|
|
95
|
-
export declare const enum RenderFlags {
|
|
96
|
-
Create = 1,
|
|
97
|
-
Update = 2
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* A set of marker values to be used in the attributes arrays. These markers indicate that some
|
|
101
|
-
* items are not regular attributes and the processing should be adapted accordingly.
|
|
102
|
-
*/
|
|
103
|
-
export declare const enum AttributeMarker {
|
|
104
|
-
/**
|
|
105
|
-
* Marker indicates that the following 3 values in the attributes array are:
|
|
106
|
-
* namespaceUri, attributeName, attributeValue
|
|
107
|
-
* in that order.
|
|
108
|
-
*/
|
|
109
|
-
NamespaceURI = 0,
|
|
110
|
-
/**
|
|
111
|
-
* Signals class declaration.
|
|
112
|
-
*
|
|
113
|
-
* Each value following `Classes` designates a class name to include on the element.
|
|
114
|
-
* ## Example:
|
|
115
|
-
*
|
|
116
|
-
* Given:
|
|
117
|
-
* ```
|
|
118
|
-
* <div class="foo bar baz">...<d/vi>
|
|
119
|
-
* ```
|
|
120
|
-
*
|
|
121
|
-
* the generated code is:
|
|
122
|
-
* ```
|
|
123
|
-
* var _c1 = [AttributeMarker.Classes, 'foo', 'bar', 'baz'];
|
|
124
|
-
* ```
|
|
125
|
-
*/
|
|
126
|
-
Classes = 1,
|
|
127
|
-
/**
|
|
128
|
-
* Signals style declaration.
|
|
129
|
-
*
|
|
130
|
-
* Each pair of values following `Styles` designates a style name and value to include on the
|
|
131
|
-
* element.
|
|
132
|
-
* ## Example:
|
|
133
|
-
*
|
|
134
|
-
* Given:
|
|
135
|
-
* ```
|
|
136
|
-
* <div style="width:100px; height:200px; color:red">...</div>
|
|
137
|
-
* ```
|
|
138
|
-
*
|
|
139
|
-
* the generated code is:
|
|
140
|
-
* ```
|
|
141
|
-
* var _c1 = [AttributeMarker.Styles, 'width', '100px', 'height'. '200px', 'color', 'red'];
|
|
142
|
-
* ```
|
|
143
|
-
*/
|
|
144
|
-
Styles = 2,
|
|
145
|
-
/**
|
|
146
|
-
* Signals that the following attribute names were extracted from input or output bindings.
|
|
147
|
-
*
|
|
148
|
-
* For example, given the following HTML:
|
|
149
|
-
*
|
|
150
|
-
* ```
|
|
151
|
-
* <div moo="car" [foo]="exp" (bar)="doSth()">
|
|
152
|
-
* ```
|
|
153
|
-
*
|
|
154
|
-
* the generated code is:
|
|
155
|
-
*
|
|
156
|
-
* ```
|
|
157
|
-
* var _c1 = ['moo', 'car', AttributeMarker.Bindings, 'foo', 'bar'];
|
|
158
|
-
* ```
|
|
159
|
-
*/
|
|
160
|
-
Bindings = 3,
|
|
161
|
-
/**
|
|
162
|
-
* Signals that the following attribute names were hoisted from an inline-template declaration.
|
|
163
|
-
*
|
|
164
|
-
* For example, given the following HTML:
|
|
165
|
-
*
|
|
166
|
-
* ```
|
|
167
|
-
* <div *ngFor="let value of values; trackBy:trackBy" dirA [dirB]="value">
|
|
168
|
-
* ```
|
|
169
|
-
*
|
|
170
|
-
* the generated code for the `template()` instruction would include:
|
|
171
|
-
*
|
|
172
|
-
* ```
|
|
173
|
-
* ['dirA', '', AttributeMarker.Bindings, 'dirB', AttributeMarker.Template, 'ngFor', 'ngForOf',
|
|
174
|
-
* 'ngForTrackBy', 'let-value']
|
|
175
|
-
* ```
|
|
176
|
-
*
|
|
177
|
-
* while the generated code for the `element()` instruction inside the template function would
|
|
178
|
-
* include:
|
|
179
|
-
*
|
|
180
|
-
* ```
|
|
181
|
-
* ['dirA', '', AttributeMarker.Bindings, 'dirB']
|
|
182
|
-
* ```
|
|
183
|
-
*/
|
|
184
|
-
Template = 4,
|
|
185
|
-
/**
|
|
186
|
-
* Signals that the following attribute is `ngProjectAs` and its value is a parsed `CssSelector`.
|
|
187
|
-
*
|
|
188
|
-
* For example, given the following HTML:
|
|
189
|
-
*
|
|
190
|
-
* ```
|
|
191
|
-
* <h1 attr="value" ngProjectAs="[title]">
|
|
192
|
-
* ```
|
|
193
|
-
*
|
|
194
|
-
* the generated code for the `element()` instruction would include:
|
|
195
|
-
*
|
|
196
|
-
* ```
|
|
197
|
-
* ['attr', 'value', AttributeMarker.ProjectAs, ['', 'title', '']]
|
|
198
|
-
* ```
|
|
199
|
-
*/
|
|
200
|
-
ProjectAs = 5,
|
|
201
|
-
/**
|
|
202
|
-
* Signals that the following attribute will be translated by runtime i18n
|
|
203
|
-
*
|
|
204
|
-
* For example, given the following HTML:
|
|
205
|
-
*
|
|
206
|
-
* ```
|
|
207
|
-
* <div moo="car" foo="value" i18n-foo [bar]="binding" i18n-bar>
|
|
208
|
-
* ```
|
|
209
|
-
*
|
|
210
|
-
* the generated code is:
|
|
211
|
-
*
|
|
212
|
-
* ```
|
|
213
|
-
* var _c1 = ['moo', 'car', AttributeMarker.I18n, 'foo', 'bar'];
|
|
214
|
-
*/
|
|
215
|
-
I18n = 6
|
|
216
|
-
}
|
|
@@ -1,440 +0,0 @@
|
|
|
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
|
-
import { SecurityContext } from '../core';
|
|
9
|
-
import { ParseSourceSpan } from '../parse_util';
|
|
10
|
-
export declare class ParserError {
|
|
11
|
-
input: string;
|
|
12
|
-
errLocation: string;
|
|
13
|
-
ctxLocation?: any;
|
|
14
|
-
message: string;
|
|
15
|
-
constructor(message: string, input: string, errLocation: string, ctxLocation?: any);
|
|
16
|
-
}
|
|
17
|
-
export declare class ParseSpan {
|
|
18
|
-
start: number;
|
|
19
|
-
end: number;
|
|
20
|
-
constructor(start: number, end: number);
|
|
21
|
-
toAbsolute(absoluteOffset: number): AbsoluteSourceSpan;
|
|
22
|
-
}
|
|
23
|
-
export declare abstract class AST {
|
|
24
|
-
span: ParseSpan;
|
|
25
|
-
/**
|
|
26
|
-
* Absolute location of the expression AST in a source code file.
|
|
27
|
-
*/
|
|
28
|
-
sourceSpan: AbsoluteSourceSpan;
|
|
29
|
-
constructor(span: ParseSpan,
|
|
30
|
-
/**
|
|
31
|
-
* Absolute location of the expression AST in a source code file.
|
|
32
|
-
*/
|
|
33
|
-
sourceSpan: AbsoluteSourceSpan);
|
|
34
|
-
abstract visit(visitor: AstVisitor, context?: any): any;
|
|
35
|
-
toString(): string;
|
|
36
|
-
}
|
|
37
|
-
export declare abstract class ASTWithName extends AST {
|
|
38
|
-
nameSpan: AbsoluteSourceSpan;
|
|
39
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, nameSpan: AbsoluteSourceSpan);
|
|
40
|
-
}
|
|
41
|
-
export declare class EmptyExpr extends AST {
|
|
42
|
-
visit(visitor: AstVisitor, context?: any): void;
|
|
43
|
-
}
|
|
44
|
-
export declare class ImplicitReceiver extends AST {
|
|
45
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
46
|
-
}
|
|
47
|
-
/**
|
|
48
|
-
* Receiver when something is accessed through `this` (e.g. `this.foo`). Note that this class
|
|
49
|
-
* inherits from `ImplicitReceiver`, because accessing something through `this` is treated the
|
|
50
|
-
* same as accessing it implicitly inside of an Angular template (e.g. `[attr.title]="this.title"`
|
|
51
|
-
* is the same as `[attr.title]="title"`.). Inheriting allows for the `this` accesses to be treated
|
|
52
|
-
* the same as implicit ones, except for a couple of exceptions like `$event` and `$any`.
|
|
53
|
-
* TODO: we should find a way for this class not to extend from `ImplicitReceiver` in the future.
|
|
54
|
-
*/
|
|
55
|
-
export declare class ThisReceiver extends ImplicitReceiver {
|
|
56
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Multiple expressions separated by a semicolon.
|
|
60
|
-
*/
|
|
61
|
-
export declare class Chain extends AST {
|
|
62
|
-
expressions: any[];
|
|
63
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expressions: any[]);
|
|
64
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
65
|
-
}
|
|
66
|
-
export declare class Conditional extends AST {
|
|
67
|
-
condition: AST;
|
|
68
|
-
trueExp: AST;
|
|
69
|
-
falseExp: AST;
|
|
70
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, condition: AST, trueExp: AST, falseExp: AST);
|
|
71
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
72
|
-
}
|
|
73
|
-
export declare class PropertyRead extends ASTWithName {
|
|
74
|
-
receiver: AST;
|
|
75
|
-
name: string;
|
|
76
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, nameSpan: AbsoluteSourceSpan, receiver: AST, name: string);
|
|
77
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
78
|
-
}
|
|
79
|
-
export declare class PropertyWrite extends ASTWithName {
|
|
80
|
-
receiver: AST;
|
|
81
|
-
name: string;
|
|
82
|
-
value: AST;
|
|
83
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, nameSpan: AbsoluteSourceSpan, receiver: AST, name: string, value: AST);
|
|
84
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
85
|
-
}
|
|
86
|
-
export declare class SafePropertyRead extends ASTWithName {
|
|
87
|
-
receiver: AST;
|
|
88
|
-
name: string;
|
|
89
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, nameSpan: AbsoluteSourceSpan, receiver: AST, name: string);
|
|
90
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
91
|
-
}
|
|
92
|
-
export declare class KeyedRead extends AST {
|
|
93
|
-
receiver: AST;
|
|
94
|
-
key: AST;
|
|
95
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, receiver: AST, key: AST);
|
|
96
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
97
|
-
}
|
|
98
|
-
export declare class SafeKeyedRead extends AST {
|
|
99
|
-
receiver: AST;
|
|
100
|
-
key: AST;
|
|
101
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, receiver: AST, key: AST);
|
|
102
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
103
|
-
}
|
|
104
|
-
export declare class KeyedWrite extends AST {
|
|
105
|
-
receiver: AST;
|
|
106
|
-
key: AST;
|
|
107
|
-
value: AST;
|
|
108
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, receiver: AST, key: AST, value: AST);
|
|
109
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
110
|
-
}
|
|
111
|
-
export declare class BindingPipe extends ASTWithName {
|
|
112
|
-
exp: AST;
|
|
113
|
-
name: string;
|
|
114
|
-
args: any[];
|
|
115
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, exp: AST, name: string, args: any[], nameSpan: AbsoluteSourceSpan);
|
|
116
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
117
|
-
}
|
|
118
|
-
export declare class LiteralPrimitive extends AST {
|
|
119
|
-
value: any;
|
|
120
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, value: any);
|
|
121
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
122
|
-
}
|
|
123
|
-
export declare class LiteralArray extends AST {
|
|
124
|
-
expressions: any[];
|
|
125
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expressions: any[]);
|
|
126
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
127
|
-
}
|
|
128
|
-
export declare type LiteralMapKey = {
|
|
129
|
-
key: string;
|
|
130
|
-
quoted: boolean;
|
|
131
|
-
};
|
|
132
|
-
export declare class LiteralMap extends AST {
|
|
133
|
-
keys: LiteralMapKey[];
|
|
134
|
-
values: any[];
|
|
135
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, keys: LiteralMapKey[], values: any[]);
|
|
136
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
137
|
-
}
|
|
138
|
-
export declare class Interpolation extends AST {
|
|
139
|
-
strings: any[];
|
|
140
|
-
expressions: any[];
|
|
141
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, strings: any[], expressions: any[]);
|
|
142
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
143
|
-
}
|
|
144
|
-
export declare class Binary extends AST {
|
|
145
|
-
operation: string;
|
|
146
|
-
left: AST;
|
|
147
|
-
right: AST;
|
|
148
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, operation: string, left: AST, right: AST);
|
|
149
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
150
|
-
}
|
|
151
|
-
/**
|
|
152
|
-
* For backwards compatibility reasons, `Unary` inherits from `Binary` and mimics the binary AST
|
|
153
|
-
* node that was originally used. This inheritance relation can be deleted in some future major,
|
|
154
|
-
* after consumers have been given a chance to fully support Unary.
|
|
155
|
-
*/
|
|
156
|
-
export declare class Unary extends Binary {
|
|
157
|
-
operator: string;
|
|
158
|
-
expr: AST;
|
|
159
|
-
left: never;
|
|
160
|
-
right: never;
|
|
161
|
-
operation: never;
|
|
162
|
-
/**
|
|
163
|
-
* Creates a unary minus expression "-x", represented as `Binary` using "0 - x".
|
|
164
|
-
*/
|
|
165
|
-
static createMinus(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expr: AST): Unary;
|
|
166
|
-
/**
|
|
167
|
-
* Creates a unary plus expression "+x", represented as `Binary` using "x - 0".
|
|
168
|
-
*/
|
|
169
|
-
static createPlus(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expr: AST): Unary;
|
|
170
|
-
/**
|
|
171
|
-
* During the deprecation period this constructor is private, to avoid consumers from creating
|
|
172
|
-
* a `Unary` with the fallback properties for `Binary`.
|
|
173
|
-
*/
|
|
174
|
-
private constructor();
|
|
175
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
176
|
-
}
|
|
177
|
-
export declare class PrefixNot extends AST {
|
|
178
|
-
expression: AST;
|
|
179
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expression: AST);
|
|
180
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
181
|
-
}
|
|
182
|
-
export declare class NonNullAssert extends AST {
|
|
183
|
-
expression: AST;
|
|
184
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, expression: AST);
|
|
185
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
186
|
-
}
|
|
187
|
-
export declare class Call extends AST {
|
|
188
|
-
receiver: AST;
|
|
189
|
-
args: AST[];
|
|
190
|
-
argumentSpan: AbsoluteSourceSpan;
|
|
191
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, receiver: AST, args: AST[], argumentSpan: AbsoluteSourceSpan);
|
|
192
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
193
|
-
}
|
|
194
|
-
export declare class SafeCall extends AST {
|
|
195
|
-
receiver: AST;
|
|
196
|
-
args: AST[];
|
|
197
|
-
argumentSpan: AbsoluteSourceSpan;
|
|
198
|
-
constructor(span: ParseSpan, sourceSpan: AbsoluteSourceSpan, receiver: AST, args: AST[], argumentSpan: AbsoluteSourceSpan);
|
|
199
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
200
|
-
}
|
|
201
|
-
/**
|
|
202
|
-
* Records the absolute position of a text span in a source file, where `start` and `end` are the
|
|
203
|
-
* starting and ending byte offsets, respectively, of the text span in a source file.
|
|
204
|
-
*/
|
|
205
|
-
export declare class AbsoluteSourceSpan {
|
|
206
|
-
readonly start: number;
|
|
207
|
-
readonly end: number;
|
|
208
|
-
constructor(start: number, end: number);
|
|
209
|
-
}
|
|
210
|
-
export declare class ASTWithSource extends AST {
|
|
211
|
-
ast: AST;
|
|
212
|
-
source: string | null;
|
|
213
|
-
location: string;
|
|
214
|
-
errors: ParserError[];
|
|
215
|
-
constructor(ast: AST, source: string | null, location: string, absoluteOffset: number, errors: ParserError[]);
|
|
216
|
-
visit(visitor: AstVisitor, context?: any): any;
|
|
217
|
-
toString(): string;
|
|
218
|
-
}
|
|
219
|
-
/**
|
|
220
|
-
* TemplateBinding refers to a particular key-value pair in a microsyntax
|
|
221
|
-
* expression. A few examples are:
|
|
222
|
-
*
|
|
223
|
-
* |---------------------|--------------|---------|--------------|
|
|
224
|
-
* | expression | key | value | binding type |
|
|
225
|
-
* |---------------------|--------------|---------|--------------|
|
|
226
|
-
* | 1. let item | item | null | variable |
|
|
227
|
-
* | 2. of items | ngForOf | items | expression |
|
|
228
|
-
* | 3. let x = y | x | y | variable |
|
|
229
|
-
* | 4. index as i | i | index | variable |
|
|
230
|
-
* | 5. trackBy: func | ngForTrackBy | func | expression |
|
|
231
|
-
* | 6. *ngIf="cond" | ngIf | cond | expression |
|
|
232
|
-
* |---------------------|--------------|---------|--------------|
|
|
233
|
-
*
|
|
234
|
-
* (6) is a notable exception because it is a binding from the template key in
|
|
235
|
-
* the LHS of a HTML attribute to the expression in the RHS. All other bindings
|
|
236
|
-
* in the example above are derived solely from the RHS.
|
|
237
|
-
*/
|
|
238
|
-
export declare type TemplateBinding = VariableBinding | ExpressionBinding;
|
|
239
|
-
export declare class VariableBinding {
|
|
240
|
-
readonly sourceSpan: AbsoluteSourceSpan;
|
|
241
|
-
readonly key: TemplateBindingIdentifier;
|
|
242
|
-
readonly value: TemplateBindingIdentifier | null;
|
|
243
|
-
/**
|
|
244
|
-
* @param sourceSpan entire span of the binding.
|
|
245
|
-
* @param key name of the LHS along with its span.
|
|
246
|
-
* @param value optional value for the RHS along with its span.
|
|
247
|
-
*/
|
|
248
|
-
constructor(sourceSpan: AbsoluteSourceSpan, key: TemplateBindingIdentifier, value: TemplateBindingIdentifier | null);
|
|
249
|
-
}
|
|
250
|
-
export declare class ExpressionBinding {
|
|
251
|
-
readonly sourceSpan: AbsoluteSourceSpan;
|
|
252
|
-
readonly key: TemplateBindingIdentifier;
|
|
253
|
-
readonly value: ASTWithSource | null;
|
|
254
|
-
/**
|
|
255
|
-
* @param sourceSpan entire span of the binding.
|
|
256
|
-
* @param key binding name, like ngForOf, ngForTrackBy, ngIf, along with its
|
|
257
|
-
* span. Note that the length of the span may not be the same as
|
|
258
|
-
* `key.source.length`. For example,
|
|
259
|
-
* 1. key.source = ngFor, key.span is for "ngFor"
|
|
260
|
-
* 2. key.source = ngForOf, key.span is for "of"
|
|
261
|
-
* 3. key.source = ngForTrackBy, key.span is for "trackBy"
|
|
262
|
-
* @param value optional expression for the RHS.
|
|
263
|
-
*/
|
|
264
|
-
constructor(sourceSpan: AbsoluteSourceSpan, key: TemplateBindingIdentifier, value: ASTWithSource | null);
|
|
265
|
-
}
|
|
266
|
-
export interface TemplateBindingIdentifier {
|
|
267
|
-
source: string;
|
|
268
|
-
span: AbsoluteSourceSpan;
|
|
269
|
-
}
|
|
270
|
-
export interface AstVisitor {
|
|
271
|
-
/**
|
|
272
|
-
* The `visitUnary` method is declared as optional for backwards compatibility. In an upcoming
|
|
273
|
-
* major release, this method will be made required.
|
|
274
|
-
*/
|
|
275
|
-
visitUnary?(ast: Unary, context: any): any;
|
|
276
|
-
visitBinary(ast: Binary, context: any): any;
|
|
277
|
-
visitChain(ast: Chain, context: any): any;
|
|
278
|
-
visitConditional(ast: Conditional, context: any): any;
|
|
279
|
-
/**
|
|
280
|
-
* The `visitThisReceiver` method is declared as optional for backwards compatibility.
|
|
281
|
-
* In an upcoming major release, this method will be made required.
|
|
282
|
-
*/
|
|
283
|
-
visitThisReceiver?(ast: ThisReceiver, context: any): any;
|
|
284
|
-
visitImplicitReceiver(ast: ImplicitReceiver, context: any): any;
|
|
285
|
-
visitInterpolation(ast: Interpolation, context: any): any;
|
|
286
|
-
visitKeyedRead(ast: KeyedRead, context: any): any;
|
|
287
|
-
visitKeyedWrite(ast: KeyedWrite, context: any): any;
|
|
288
|
-
visitLiteralArray(ast: LiteralArray, context: any): any;
|
|
289
|
-
visitLiteralMap(ast: LiteralMap, context: any): any;
|
|
290
|
-
visitLiteralPrimitive(ast: LiteralPrimitive, context: any): any;
|
|
291
|
-
visitPipe(ast: BindingPipe, context: any): any;
|
|
292
|
-
visitPrefixNot(ast: PrefixNot, context: any): any;
|
|
293
|
-
visitNonNullAssert(ast: NonNullAssert, context: any): any;
|
|
294
|
-
visitPropertyRead(ast: PropertyRead, context: any): any;
|
|
295
|
-
visitPropertyWrite(ast: PropertyWrite, context: any): any;
|
|
296
|
-
visitSafePropertyRead(ast: SafePropertyRead, context: any): any;
|
|
297
|
-
visitSafeKeyedRead(ast: SafeKeyedRead, context: any): any;
|
|
298
|
-
visitCall(ast: Call, context: any): any;
|
|
299
|
-
visitSafeCall(ast: SafeCall, context: any): any;
|
|
300
|
-
visitASTWithSource?(ast: ASTWithSource, context: any): any;
|
|
301
|
-
/**
|
|
302
|
-
* This function is optionally defined to allow classes that implement this
|
|
303
|
-
* interface to selectively decide if the specified `ast` should be visited.
|
|
304
|
-
* @param ast node to visit
|
|
305
|
-
* @param context context that gets passed to the node and all its children
|
|
306
|
-
*/
|
|
307
|
-
visit?(ast: AST, context?: any): any;
|
|
308
|
-
}
|
|
309
|
-
export declare class RecursiveAstVisitor implements AstVisitor {
|
|
310
|
-
visit(ast: AST, context?: any): any;
|
|
311
|
-
visitUnary(ast: Unary, context: any): any;
|
|
312
|
-
visitBinary(ast: Binary, context: any): any;
|
|
313
|
-
visitChain(ast: Chain, context: any): any;
|
|
314
|
-
visitConditional(ast: Conditional, context: any): any;
|
|
315
|
-
visitPipe(ast: BindingPipe, context: any): any;
|
|
316
|
-
visitImplicitReceiver(ast: ThisReceiver, context: any): any;
|
|
317
|
-
visitThisReceiver(ast: ThisReceiver, context: any): any;
|
|
318
|
-
visitInterpolation(ast: Interpolation, context: any): any;
|
|
319
|
-
visitKeyedRead(ast: KeyedRead, context: any): any;
|
|
320
|
-
visitKeyedWrite(ast: KeyedWrite, context: any): any;
|
|
321
|
-
visitLiteralArray(ast: LiteralArray, context: any): any;
|
|
322
|
-
visitLiteralMap(ast: LiteralMap, context: any): any;
|
|
323
|
-
visitLiteralPrimitive(ast: LiteralPrimitive, context: any): any;
|
|
324
|
-
visitPrefixNot(ast: PrefixNot, context: any): any;
|
|
325
|
-
visitNonNullAssert(ast: NonNullAssert, context: any): any;
|
|
326
|
-
visitPropertyRead(ast: PropertyRead, context: any): any;
|
|
327
|
-
visitPropertyWrite(ast: PropertyWrite, context: any): any;
|
|
328
|
-
visitSafePropertyRead(ast: SafePropertyRead, context: any): any;
|
|
329
|
-
visitSafeKeyedRead(ast: SafeKeyedRead, context: any): any;
|
|
330
|
-
visitCall(ast: Call, context: any): any;
|
|
331
|
-
visitSafeCall(ast: SafeCall, context: any): any;
|
|
332
|
-
visitAll(asts: AST[], context: any): any;
|
|
333
|
-
}
|
|
334
|
-
export declare class AstTransformer implements AstVisitor {
|
|
335
|
-
visitImplicitReceiver(ast: ImplicitReceiver, context: any): AST;
|
|
336
|
-
visitThisReceiver(ast: ThisReceiver, context: any): AST;
|
|
337
|
-
visitInterpolation(ast: Interpolation, context: any): AST;
|
|
338
|
-
visitLiteralPrimitive(ast: LiteralPrimitive, context: any): AST;
|
|
339
|
-
visitPropertyRead(ast: PropertyRead, context: any): AST;
|
|
340
|
-
visitPropertyWrite(ast: PropertyWrite, context: any): AST;
|
|
341
|
-
visitSafePropertyRead(ast: SafePropertyRead, context: any): AST;
|
|
342
|
-
visitLiteralArray(ast: LiteralArray, context: any): AST;
|
|
343
|
-
visitLiteralMap(ast: LiteralMap, context: any): AST;
|
|
344
|
-
visitUnary(ast: Unary, context: any): AST;
|
|
345
|
-
visitBinary(ast: Binary, context: any): AST;
|
|
346
|
-
visitPrefixNot(ast: PrefixNot, context: any): AST;
|
|
347
|
-
visitNonNullAssert(ast: NonNullAssert, context: any): AST;
|
|
348
|
-
visitConditional(ast: Conditional, context: any): AST;
|
|
349
|
-
visitPipe(ast: BindingPipe, context: any): AST;
|
|
350
|
-
visitKeyedRead(ast: KeyedRead, context: any): AST;
|
|
351
|
-
visitKeyedWrite(ast: KeyedWrite, context: any): AST;
|
|
352
|
-
visitCall(ast: Call, context: any): AST;
|
|
353
|
-
visitSafeCall(ast: SafeCall, context: any): AST;
|
|
354
|
-
visitAll(asts: any[]): any[];
|
|
355
|
-
visitChain(ast: Chain, context: any): AST;
|
|
356
|
-
visitSafeKeyedRead(ast: SafeKeyedRead, context: any): AST;
|
|
357
|
-
}
|
|
358
|
-
export declare class AstMemoryEfficientTransformer implements AstVisitor {
|
|
359
|
-
visitImplicitReceiver(ast: ImplicitReceiver, context: any): AST;
|
|
360
|
-
visitThisReceiver(ast: ThisReceiver, context: any): AST;
|
|
361
|
-
visitInterpolation(ast: Interpolation, context: any): Interpolation;
|
|
362
|
-
visitLiteralPrimitive(ast: LiteralPrimitive, context: any): AST;
|
|
363
|
-
visitPropertyRead(ast: PropertyRead, context: any): AST;
|
|
364
|
-
visitPropertyWrite(ast: PropertyWrite, context: any): AST;
|
|
365
|
-
visitSafePropertyRead(ast: SafePropertyRead, context: any): AST;
|
|
366
|
-
visitLiteralArray(ast: LiteralArray, context: any): AST;
|
|
367
|
-
visitLiteralMap(ast: LiteralMap, context: any): AST;
|
|
368
|
-
visitUnary(ast: Unary, context: any): AST;
|
|
369
|
-
visitBinary(ast: Binary, context: any): AST;
|
|
370
|
-
visitPrefixNot(ast: PrefixNot, context: any): AST;
|
|
371
|
-
visitNonNullAssert(ast: NonNullAssert, context: any): AST;
|
|
372
|
-
visitConditional(ast: Conditional, context: any): AST;
|
|
373
|
-
visitPipe(ast: BindingPipe, context: any): AST;
|
|
374
|
-
visitKeyedRead(ast: KeyedRead, context: any): AST;
|
|
375
|
-
visitKeyedWrite(ast: KeyedWrite, context: any): AST;
|
|
376
|
-
visitAll(asts: any[]): any[];
|
|
377
|
-
visitChain(ast: Chain, context: any): AST;
|
|
378
|
-
visitCall(ast: Call, context: any): AST;
|
|
379
|
-
visitSafeCall(ast: SafeCall, context: any): AST;
|
|
380
|
-
visitSafeKeyedRead(ast: SafeKeyedRead, context: any): AST;
|
|
381
|
-
}
|
|
382
|
-
export declare class ParsedProperty {
|
|
383
|
-
name: string;
|
|
384
|
-
expression: ASTWithSource;
|
|
385
|
-
type: ParsedPropertyType;
|
|
386
|
-
sourceSpan: ParseSourceSpan;
|
|
387
|
-
readonly keySpan: ParseSourceSpan;
|
|
388
|
-
valueSpan: ParseSourceSpan | undefined;
|
|
389
|
-
readonly isLiteral: boolean;
|
|
390
|
-
readonly isAnimation: boolean;
|
|
391
|
-
constructor(name: string, expression: ASTWithSource, type: ParsedPropertyType, sourceSpan: ParseSourceSpan, keySpan: ParseSourceSpan, valueSpan: ParseSourceSpan | undefined);
|
|
392
|
-
}
|
|
393
|
-
export declare enum ParsedPropertyType {
|
|
394
|
-
DEFAULT = 0,
|
|
395
|
-
LITERAL_ATTR = 1,
|
|
396
|
-
ANIMATION = 2
|
|
397
|
-
}
|
|
398
|
-
export declare const enum ParsedEventType {
|
|
399
|
-
Regular = 0,
|
|
400
|
-
Animation = 1
|
|
401
|
-
}
|
|
402
|
-
export declare class ParsedEvent {
|
|
403
|
-
name: string;
|
|
404
|
-
targetOrPhase: string;
|
|
405
|
-
type: ParsedEventType;
|
|
406
|
-
handler: ASTWithSource;
|
|
407
|
-
sourceSpan: ParseSourceSpan;
|
|
408
|
-
handlerSpan: ParseSourceSpan;
|
|
409
|
-
readonly keySpan: ParseSourceSpan;
|
|
410
|
-
constructor(name: string, targetOrPhase: string, type: ParsedEventType, handler: ASTWithSource, sourceSpan: ParseSourceSpan, handlerSpan: ParseSourceSpan, keySpan: ParseSourceSpan);
|
|
411
|
-
}
|
|
412
|
-
/**
|
|
413
|
-
* ParsedVariable represents a variable declaration in a microsyntax expression.
|
|
414
|
-
*/
|
|
415
|
-
export declare class ParsedVariable {
|
|
416
|
-
readonly name: string;
|
|
417
|
-
readonly value: string;
|
|
418
|
-
readonly sourceSpan: ParseSourceSpan;
|
|
419
|
-
readonly keySpan: ParseSourceSpan;
|
|
420
|
-
readonly valueSpan?: ParseSourceSpan | undefined;
|
|
421
|
-
constructor(name: string, value: string, sourceSpan: ParseSourceSpan, keySpan: ParseSourceSpan, valueSpan?: ParseSourceSpan | undefined);
|
|
422
|
-
}
|
|
423
|
-
export declare const enum BindingType {
|
|
424
|
-
Property = 0,
|
|
425
|
-
Attribute = 1,
|
|
426
|
-
Class = 2,
|
|
427
|
-
Style = 3,
|
|
428
|
-
Animation = 4
|
|
429
|
-
}
|
|
430
|
-
export declare class BoundElementProperty {
|
|
431
|
-
name: string;
|
|
432
|
-
type: BindingType;
|
|
433
|
-
securityContext: SecurityContext;
|
|
434
|
-
value: ASTWithSource;
|
|
435
|
-
unit: string | null;
|
|
436
|
-
sourceSpan: ParseSourceSpan;
|
|
437
|
-
readonly keySpan: ParseSourceSpan | undefined;
|
|
438
|
-
valueSpan: ParseSourceSpan | undefined;
|
|
439
|
-
constructor(name: string, type: BindingType, securityContext: SecurityContext, value: ASTWithSource, unit: string | null, sourceSpan: ParseSourceSpan, keySpan: ParseSourceSpan | undefined, valueSpan: ParseSourceSpan | undefined);
|
|
440
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
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
|
-
export declare enum TokenType {
|
|
9
|
-
Character = 0,
|
|
10
|
-
Identifier = 1,
|
|
11
|
-
PrivateIdentifier = 2,
|
|
12
|
-
Keyword = 3,
|
|
13
|
-
String = 4,
|
|
14
|
-
Operator = 5,
|
|
15
|
-
Number = 6,
|
|
16
|
-
Error = 7
|
|
17
|
-
}
|
|
18
|
-
export declare class Lexer {
|
|
19
|
-
tokenize(text: string): Token[];
|
|
20
|
-
}
|
|
21
|
-
export declare class Token {
|
|
22
|
-
index: number;
|
|
23
|
-
end: number;
|
|
24
|
-
type: TokenType;
|
|
25
|
-
numValue: number;
|
|
26
|
-
strValue: string;
|
|
27
|
-
constructor(index: number, end: number, type: TokenType, numValue: number, strValue: string);
|
|
28
|
-
isCharacter(code: number): boolean;
|
|
29
|
-
isNumber(): boolean;
|
|
30
|
-
isString(): boolean;
|
|
31
|
-
isOperator(operator: string): boolean;
|
|
32
|
-
isIdentifier(): boolean;
|
|
33
|
-
isPrivateIdentifier(): boolean;
|
|
34
|
-
isKeyword(): boolean;
|
|
35
|
-
isKeywordLet(): boolean;
|
|
36
|
-
isKeywordAs(): boolean;
|
|
37
|
-
isKeywordNull(): boolean;
|
|
38
|
-
isKeywordUndefined(): boolean;
|
|
39
|
-
isKeywordTrue(): boolean;
|
|
40
|
-
isKeywordFalse(): boolean;
|
|
41
|
-
isKeywordThis(): boolean;
|
|
42
|
-
isError(): boolean;
|
|
43
|
-
toNumber(): number;
|
|
44
|
-
toString(): string | null;
|
|
45
|
-
}
|
|
46
|
-
export declare const EOF: Token;
|
|
47
|
-
export declare function isIdentifier(input: string): boolean;
|