@zenstackhq/language 3.5.6 → 3.6.0

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.
Files changed (45) hide show
  1. package/dist/ast-Clidp86c.cjs +1465 -0
  2. package/dist/ast-Clidp86c.cjs.map +1 -0
  3. package/dist/ast-DEfhnj8j.mjs +765 -0
  4. package/dist/ast-DEfhnj8j.mjs.map +1 -0
  5. package/dist/ast-DQDdBZQ3.d.mts +525 -0
  6. package/dist/ast-W2h6Qtfk.d.cts +525 -0
  7. package/dist/ast.cjs +130 -1432
  8. package/dist/ast.cjs.map +1 -1
  9. package/dist/ast.d.cts +2 -541
  10. package/dist/ast.d.mts +2 -0
  11. package/dist/ast.mjs +20 -0
  12. package/dist/ast.mjs.map +1 -0
  13. package/dist/factory.cjs +754 -2030
  14. package/dist/factory.cjs.map +1 -1
  15. package/dist/factory.d.cts +220 -215
  16. package/dist/factory.d.mts +289 -0
  17. package/dist/factory.mjs +778 -0
  18. package/dist/factory.mjs.map +1 -0
  19. package/dist/index.cjs +2691 -5454
  20. package/dist/index.cjs.map +1 -1
  21. package/dist/index.d.cts +104 -103
  22. package/dist/index.d.mts +170 -0
  23. package/dist/index.mjs +6925 -0
  24. package/dist/index.mjs.map +1 -0
  25. package/dist/utils-BB6L7ug2.mjs +529 -0
  26. package/dist/utils-BB6L7ug2.mjs.map +1 -0
  27. package/dist/utils-CfXGZkv7.cjs +842 -0
  28. package/dist/utils-CfXGZkv7.cjs.map +1 -0
  29. package/dist/utils.cjs +47 -1650
  30. package/dist/utils.d.cts +101 -10
  31. package/dist/{utils.d.ts → utils.d.mts} +101 -10
  32. package/dist/utils.mjs +2 -0
  33. package/package.json +16 -15
  34. package/dist/ast.d.ts +0 -541
  35. package/dist/ast.js +0 -1288
  36. package/dist/ast.js.map +0 -1
  37. package/dist/factory.d.ts +0 -284
  38. package/dist/factory.js +0 -2020
  39. package/dist/factory.js.map +0 -1
  40. package/dist/index.d.ts +0 -169
  41. package/dist/index.js +0 -9656
  42. package/dist/index.js.map +0 -1
  43. package/dist/utils.cjs.map +0 -1
  44. package/dist/utils.js +0 -1572
  45. package/dist/utils.js.map +0 -1
@@ -1,284 +1,289 @@
1
- import { BooleanLiteral, NullExpr, NumberLiteral, StringLiteral, ThisExpr, Argument, Expression, ArrayExpr, BinaryExpr, InvocationExpr, FunctionDecl, MemberAccessExpr, MemberAccessTarget, ObjectExpr, FieldInitializer, RegularID, ReferenceExpr, ReferenceTarget, ReferenceArg, UnaryExpr, AttributeArg, Attribute, InternalAttribute, AttributeParam, AttributeParamType, TypeDeclaration, DataFieldAttribute, DataModelAttribute, DataField, DataFieldType, BuiltinType, UnsupportedFieldType, LiteralExpr, DataModel, TypeDef, Enum, EnumField, RegularIDWithTypeNames, AbstractDeclaration, Model, ModelImport } from './ast.cjs';
2
- import { AstNode, Reference } from 'langium';
1
+ import { $ as ReferenceArg, A as Enum, B as InvocationExpr, D as DataModel, E as DataFieldType, F as FunctionDecl, G as ModelImport, H as MemberAccessExpr, J as ObjectExpr, K as NullExpr, M as Expression, O as DataModelAttribute, P as FieldInitializer, T as DataFieldAttribute, U as MemberAccessTarget, V as LiteralExpr, W as Model, _ as BuiltinType, at as ThisExpr, c as Argument, ct as UnaryExpr, d as AttributeArg, et as ReferenceExpr, f as AttributeParam, g as BooleanLiteral, i as Reference$1, it as StringLiteral, j as EnumField, l as ArrayExpr, lt as UnsupportedFieldType, m as BinaryExpr, nt as RegularID, ot as TypeDeclaration, p as AttributeParamType, q as NumberLiteral, rt as RegularIDWithTypeNames, s as AbstractDeclaration, st as TypeDef, t as AstNode$1, tt as ReferenceTarget, u as Attribute, w as DataField, z as InternalAttribute } from "./ast-W2h6Qtfk.cjs";
2
+ import { Reference } from "langium";
3
3
 
4
- type ContainerProps<T extends AstNode | undefined> = {
5
- $container: T;
6
- $containerProperty?: string;
7
- $containerIndex?: number;
4
+ //#region src/factory/ast-factory.d.ts
5
+ type ContainerProps<T extends AstNode$1 | undefined> = {
6
+ $container: T;
7
+ $containerProperty?: string;
8
+ $containerIndex?: number;
8
9
  };
9
- type NodeFactoriesFor<N> = {
10
- [K in keyof N as {} extends Pick<N, K> ? never : K]: N[K] extends (infer U)[] ? (AstFactory<U extends AstNode ? U : AstNode> | U)[] : AstFactory<N[K] extends AstNode ? N[K] : AstNode> | N[K];
11
- } & {
12
- [K in keyof N as {} extends Pick<N, K> ? K : never]?: N[K] extends (infer U)[] ? (AstFactory<U extends AstNode ? U : AstNode> | U)[] : AstFactory<N[K] extends AstNode ? N[K] : AstNode> | N[K];
13
- };
14
- declare abstract class AstFactory<T extends AstNode = AstNode> {
15
- node: T;
16
- constructor({ type, node }: {
17
- type: T['$type'];
18
- node?: Partial<T>;
19
- });
20
- setContainer(container: T['$container']): this;
21
- get(params?: ContainerProps<T['$container']>): T;
22
- update(nodeArg: Partial<T | NodeFactoriesFor<T>>): T;
10
+ type NodeFactoriesFor<N> = { [K in keyof N as {} extends Pick<N, K> ? never : K]: N[K] extends (infer U)[] ? (AstFactory<U extends AstNode$1 ? U : AstNode$1> | U)[] : AstFactory<N[K] extends AstNode$1 ? N[K] : AstNode$1> | N[K] } & { [K in keyof N as {} extends Pick<N, K> ? K : never]?: N[K] extends (infer U)[] ? (AstFactory<U extends AstNode$1 ? U : AstNode$1> | U)[] : AstFactory<N[K] extends AstNode$1 ? N[K] : AstNode$1> | N[K] };
11
+ declare abstract class AstFactory<T extends AstNode$1 = AstNode$1> {
12
+ node: T;
13
+ constructor({
14
+ type,
15
+ node
16
+ }: {
17
+ type: T['$type'];
18
+ node?: Partial<T>;
19
+ });
20
+ setContainer(container: T['$container']): this;
21
+ get(params?: ContainerProps<T['$container']>): T;
22
+ update(nodeArg: Partial<T | NodeFactoriesFor<T>>): T;
23
23
  }
24
-
24
+ //#endregion
25
+ //#region src/factory/primitives.d.ts
25
26
  declare class ThisExprFactory extends AstFactory<ThisExpr> {
26
- constructor();
27
+ constructor();
27
28
  }
28
29
  declare class NullExprFactory extends AstFactory<NullExpr> {
29
- constructor();
30
+ constructor();
30
31
  }
31
32
  declare class NumberLiteralFactory extends AstFactory<NumberLiteral> {
32
- value?: number | string;
33
- constructor();
34
- setValue(value: number | string): this;
33
+ value?: number | string;
34
+ constructor();
35
+ setValue(value: number | string): this;
35
36
  }
36
37
  declare class StringLiteralFactory extends AstFactory<StringLiteral> {
37
- value?: string;
38
- constructor();
39
- setValue(value: string): this;
38
+ value?: string;
39
+ constructor();
40
+ setValue(value: string): this;
40
41
  }
41
42
  declare class BooleanLiteralFactory extends AstFactory<BooleanLiteral> {
42
- value?: boolean;
43
- constructor();
44
- setValue(value: boolean): this;
43
+ value?: boolean;
44
+ constructor();
45
+ setValue(value: boolean): this;
45
46
  }
46
-
47
- type ExpressionFactoryMap = ReturnType<typeof ExpressionBuilder>;
47
+ //#endregion
48
+ //#region src/factory/expression.d.ts
48
49
  declare const ExpressionBuilder: () => {
49
- readonly ArrayExpr: ArrayExprFactory;
50
- readonly BinaryExpr: BinaryExprFactory;
51
- readonly BooleanLiteral: BooleanLiteralFactory;
52
- readonly InvocationExpr: InvocationExprFactory;
53
- readonly MemberAccessExpr: MemberAccessExprFactory;
54
- readonly NullExpr: NullExprFactory;
55
- readonly NumberLiteral: NumberLiteralFactory;
56
- readonly ObjectExpr: ObjectExprFactory;
57
- readonly ReferenceExpr: ReferenceExprFactory;
58
- readonly StringLiteral: StringLiteralFactory;
59
- readonly ThisExpr: ThisExprFactory;
60
- readonly UnaryExpr: UnaryExprFactory;
50
+ readonly ArrayExpr: ArrayExprFactory;
51
+ readonly BinaryExpr: BinaryExprFactory;
52
+ readonly BooleanLiteral: BooleanLiteralFactory;
53
+ readonly InvocationExpr: InvocationExprFactory;
54
+ readonly MemberAccessExpr: MemberAccessExprFactory;
55
+ readonly NullExpr: NullExprFactory;
56
+ readonly NumberLiteral: NumberLiteralFactory;
57
+ readonly ObjectExpr: ObjectExprFactory;
58
+ readonly ReferenceExpr: ReferenceExprFactory;
59
+ readonly StringLiteral: StringLiteralFactory;
60
+ readonly ThisExpr: ThisExprFactory;
61
+ readonly UnaryExpr: UnaryExprFactory;
61
62
  };
63
+ type ExpressionFactoryMap = ReturnType<typeof ExpressionBuilder>;
62
64
  type ExpressionBuilder<T extends Expression = Expression> = Pick<ExpressionFactoryMap, Extract<T['$type'], keyof ExpressionFactoryMap>>;
63
65
  declare class UnaryExprFactory extends AstFactory<UnaryExpr> {
64
- operand?: AstFactory<Expression>;
65
- constructor();
66
- setOperand(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
66
+ operand?: AstFactory<Expression>;
67
+ constructor();
68
+ setOperand(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
67
69
  }
68
70
  declare class ReferenceExprFactory extends AstFactory<ReferenceExpr> {
69
- target?: Reference<ReferenceTarget>;
70
- args: ReferenceArgFactory[];
71
- constructor();
72
- setTarget(target: ReferenceTarget): this;
73
- addArg(builder: (a: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
71
+ target?: Reference<ReferenceTarget>;
72
+ args: ReferenceArgFactory[];
73
+ constructor();
74
+ setTarget(target: ReferenceTarget): this;
75
+ addArg(builder: (a: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
74
76
  }
75
77
  declare class ReferenceArgFactory extends AstFactory<ReferenceArg> {
76
- name?: string;
77
- value?: AstFactory<Expression>;
78
- constructor();
79
- setName(name: string): this;
80
- setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
78
+ name?: string;
79
+ value?: AstFactory<Expression>;
80
+ constructor();
81
+ setName(name: string): this;
82
+ setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
81
83
  }
82
84
  declare class MemberAccessExprFactory extends AstFactory<MemberAccessExpr> {
83
- member?: Reference<MemberAccessTarget>;
84
- operand?: AstFactory<Expression>;
85
- constructor();
86
- setMember(target: Reference<MemberAccessTarget>): this;
87
- setOperand(builder: (b: ExpressionBuilder) => AstFactory<Expression>): this;
85
+ member?: Reference<MemberAccessTarget>;
86
+ operand?: AstFactory<Expression>;
87
+ constructor();
88
+ setMember(target: Reference<MemberAccessTarget>): this;
89
+ setOperand(builder: (b: ExpressionBuilder) => AstFactory<Expression>): this;
88
90
  }
89
91
  declare class ObjectExprFactory extends AstFactory<ObjectExpr> {
90
- fields: FieldInitializerFactory[];
91
- constructor();
92
- addField(builder: (b: FieldInitializerFactory) => FieldInitializerFactory): this;
92
+ fields: FieldInitializerFactory[];
93
+ constructor();
94
+ addField(builder: (b: FieldInitializerFactory) => FieldInitializerFactory): this;
93
95
  }
94
96
  declare class FieldInitializerFactory extends AstFactory<FieldInitializer> {
95
- name?: RegularID;
96
- value?: AstFactory<Expression>;
97
- constructor();
98
- setName(name: RegularID): this;
99
- setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
97
+ name?: RegularID;
98
+ value?: AstFactory<Expression>;
99
+ constructor();
100
+ setName(name: RegularID): this;
101
+ setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
100
102
  }
101
103
  declare class InvocationExprFactory extends AstFactory<InvocationExpr> {
102
- args: ArgumentFactory[];
103
- function?: Reference<FunctionDecl>;
104
- constructor();
105
- addArg(builder: (arg: ArgumentFactory) => ArgumentFactory): this;
106
- setFunction(value: FunctionDecl): this;
104
+ args: ArgumentFactory[];
105
+ function?: Reference<FunctionDecl>;
106
+ constructor();
107
+ addArg(builder: (arg: ArgumentFactory) => ArgumentFactory): this;
108
+ setFunction(value: FunctionDecl): this;
107
109
  }
108
110
  declare class ArgumentFactory extends AstFactory<Argument> {
109
- value?: AstFactory<Expression>;
110
- constructor();
111
- setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
111
+ value?: AstFactory<Expression>;
112
+ constructor();
113
+ setValue(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
112
114
  }
113
115
  declare class ArrayExprFactory extends AstFactory<ArrayExpr> {
114
- items: AstFactory<Expression>[];
115
- constructor();
116
- addItem(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
116
+ items: AstFactory<Expression>[];
117
+ constructor();
118
+ addItem(builder: (a: ExpressionBuilder) => AstFactory<Expression>): this;
117
119
  }
118
120
  declare class BinaryExprFactory extends AstFactory<BinaryExpr> {
119
- operator?: BinaryExpr['operator'];
120
- right?: AstFactory<Expression>;
121
- left?: AstFactory<Expression>;
122
- constructor();
123
- setOperator(operator: BinaryExpr['operator']): this;
124
- setRight(builder: (arg: ExpressionBuilder) => AstFactory<Expression>): this;
125
- setLeft(builder: (arg: ExpressionBuilder) => AstFactory<Expression>): this;
121
+ operator?: BinaryExpr['operator'];
122
+ right?: AstFactory<Expression>;
123
+ left?: AstFactory<Expression>;
124
+ constructor();
125
+ setOperator(operator: BinaryExpr['operator']): this;
126
+ setRight(builder: (arg: ExpressionBuilder) => AstFactory<Expression>): this;
127
+ setLeft(builder: (arg: ExpressionBuilder) => AstFactory<Expression>): this;
126
128
  }
127
-
129
+ //#endregion
130
+ //#region src/factory/attribute.d.ts
128
131
  declare class DataFieldAttributeFactory extends AstFactory<DataFieldAttribute> {
129
- args: AttributeArgFactory[];
130
- decl?: Reference<Attribute>;
131
- constructor();
132
- setDecl(decl: Attribute): this;
133
- addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
132
+ args: AttributeArgFactory[];
133
+ decl?: Reference$1<Attribute>;
134
+ constructor();
135
+ setDecl(decl: Attribute): this;
136
+ addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
134
137
  }
135
138
  declare class DataModelAttributeFactory extends AstFactory<DataModelAttribute> {
136
- args: AttributeArgFactory[];
137
- decl?: Reference<Attribute>;
138
- constructor();
139
- setDecl(decl: Attribute): this;
140
- addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
139
+ args: AttributeArgFactory[];
140
+ decl?: Reference$1<Attribute>;
141
+ constructor();
142
+ setDecl(decl: Attribute): this;
143
+ addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
141
144
  }
142
145
  declare class AttributeArgFactory extends AstFactory<AttributeArg> {
143
- name?: RegularID;
144
- value?: AstFactory<Expression>;
145
- constructor();
146
- setName(name: RegularID): this;
147
- setValue(builder: (b: ExpressionBuilder) => AstFactory<Expression>): this;
146
+ name?: RegularID;
147
+ value?: AstFactory<Expression>;
148
+ constructor();
149
+ setName(name: RegularID): this;
150
+ setValue(builder: (b: ExpressionBuilder) => AstFactory<Expression>): this;
148
151
  }
149
152
  declare class InternalAttributeFactory extends AstFactory<InternalAttribute> {
150
- decl?: Reference<Attribute>;
151
- args: AttributeArgFactory[];
152
- constructor();
153
- setDecl(decl: Attribute): this;
154
- addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
153
+ decl?: Reference$1<Attribute>;
154
+ args: AttributeArgFactory[];
155
+ constructor();
156
+ setDecl(decl: Attribute): this;
157
+ addArg(builder: (b: ExpressionBuilder) => AstFactory<Expression>, name?: string): this;
155
158
  }
156
159
  declare class AttributeParamFactory extends AstFactory<AttributeParam> {
157
- attributes: InternalAttributeFactory[];
158
- comments: string[];
159
- default?: boolean;
160
- name?: RegularID;
161
- type?: AttributeParamTypeFactory;
162
- constructor();
163
- addAttribute(builder: (b: InternalAttributeFactory) => InternalAttributeFactory): this;
164
- setComments(comments: string[]): this;
165
- setDefault(defaultValue: boolean): this;
166
- setName(name: string): this;
167
- setType(builder: (b: AttributeParamTypeFactory) => AttributeParamTypeFactory): this;
160
+ attributes: InternalAttributeFactory[];
161
+ comments: string[];
162
+ default?: boolean;
163
+ name?: RegularID;
164
+ type?: AttributeParamTypeFactory;
165
+ constructor();
166
+ addAttribute(builder: (b: InternalAttributeFactory) => InternalAttributeFactory): this;
167
+ setComments(comments: string[]): this;
168
+ setDefault(defaultValue: boolean): this;
169
+ setName(name: string): this;
170
+ setType(builder: (b: AttributeParamTypeFactory) => AttributeParamTypeFactory): this;
168
171
  }
169
172
  declare class AttributeParamTypeFactory extends AstFactory<AttributeParamType> {
170
- array?: boolean;
171
- optional?: boolean;
172
- reference?: Reference<TypeDeclaration>;
173
- type?: AttributeParamType['type'];
174
- constructor();
175
- setArray(array: boolean): this;
176
- setOptional(optional: boolean): this;
177
- setReference(reference: TypeDeclaration): this;
178
- setType(type: AttributeParamType['type']): this;
173
+ array?: boolean;
174
+ optional?: boolean;
175
+ reference?: Reference$1<TypeDeclaration>;
176
+ type?: AttributeParamType['type'];
177
+ constructor();
178
+ setArray(array: boolean): this;
179
+ setOptional(optional: boolean): this;
180
+ setReference(reference: TypeDeclaration): this;
181
+ setType(type: AttributeParamType['type']): this;
179
182
  }
180
183
  declare class AttributeFactory extends AstFactory<Attribute> {
181
- name?: string;
182
- comments: string[];
183
- attributes: InternalAttributeFactory[];
184
- params: AttributeParamFactory[];
185
- constructor();
186
- setName(name: string): this;
187
- setComments(comments: string[]): this;
188
- addAttribute(builder: (b: InternalAttributeFactory) => InternalAttributeFactory): this;
189
- addParam(builder: (b: AttributeParamFactory) => AttributeParamFactory): this;
184
+ name?: string;
185
+ comments: string[];
186
+ attributes: InternalAttributeFactory[];
187
+ params: AttributeParamFactory[];
188
+ constructor();
189
+ setName(name: string): this;
190
+ setComments(comments: string[]): this;
191
+ addAttribute(builder: (b: InternalAttributeFactory) => InternalAttributeFactory): this;
192
+ addParam(builder: (b: AttributeParamFactory) => AttributeParamFactory): this;
190
193
  }
191
-
192
- type DeclarationBuilderMap = ReturnType<typeof DeclarationBuilder>;
194
+ //#endregion
195
+ //#region src/factory/declaration.d.ts
193
196
  declare const DeclarationBuilder: () => {
194
- readonly Attribute: AttributeFactory;
195
- readonly DataModel: DataModelFactory;
196
- readonly DataSource: any;
197
- readonly Enum: EnumFactory;
198
- readonly FunctionDecl: any;
199
- readonly GeneratorDecl: any;
200
- readonly Plugin: any;
201
- readonly Procedure: any;
202
- readonly TypeDef: any;
197
+ readonly Attribute: AttributeFactory;
198
+ readonly DataModel: DataModelFactory;
199
+ readonly DataSource: any;
200
+ readonly Enum: EnumFactory;
201
+ readonly FunctionDecl: any;
202
+ readonly GeneratorDecl: any;
203
+ readonly Plugin: any;
204
+ readonly Procedure: any;
205
+ readonly TypeDef: any;
203
206
  };
207
+ type DeclarationBuilderMap = ReturnType<typeof DeclarationBuilder>;
204
208
  type DeclarationBuilder<T extends AbstractDeclaration = AbstractDeclaration> = Pick<DeclarationBuilderMap, Extract<T['$type'], keyof DeclarationBuilderMap>>;
205
209
  declare class DataModelFactory extends AstFactory<DataModel> {
206
- attributes: DataModelAttributeFactory[];
207
- baseModel?: Reference<DataModel>;
208
- comments: string[];
209
- fields: DataFieldFactory[];
210
- isView?: boolean;
211
- mixins: Reference<TypeDef>[];
212
- name?: RegularID;
213
- constructor();
214
- addAttribute(builder: (attr: DataModelAttributeFactory) => DataModelAttributeFactory): this;
215
- setBaseModel(model: Reference<DataModel>): this;
216
- setComments(comments: string[]): this;
217
- addComment(comment: string): this;
218
- addField(builder: (field: DataFieldFactory) => DataFieldFactory): this;
219
- setIsView(isView: boolean): this;
220
- addMixin(mixin: Reference<TypeDef>): this;
221
- setName(name: string): this;
210
+ attributes: DataModelAttributeFactory[];
211
+ baseModel?: Reference$1<DataModel>;
212
+ comments: string[];
213
+ fields: DataFieldFactory[];
214
+ isView?: boolean;
215
+ mixins: Reference$1<TypeDef>[];
216
+ name?: RegularID;
217
+ constructor();
218
+ addAttribute(builder: (attr: DataModelAttributeFactory) => DataModelAttributeFactory): this;
219
+ setBaseModel(model: Reference$1<DataModel>): this;
220
+ setComments(comments: string[]): this;
221
+ addComment(comment: string): this;
222
+ addField(builder: (field: DataFieldFactory) => DataFieldFactory): this;
223
+ setIsView(isView: boolean): this;
224
+ addMixin(mixin: Reference$1<TypeDef>): this;
225
+ setName(name: string): this;
222
226
  }
223
227
  declare class DataFieldFactory extends AstFactory<DataField> {
224
- attributes: DataFieldAttributeFactory[];
225
- comments: string[];
226
- name?: string;
227
- type?: DataFieldTypeFactory;
228
- constructor();
229
- addAttribute(builder: ((attr: DataFieldAttributeFactory) => DataFieldAttributeFactory) | DataFieldAttributeFactory): this;
230
- setComments(comments: string[]): this;
231
- setName(name: string): this;
232
- setType(builder: (type: DataFieldTypeFactory) => DataFieldTypeFactory): this;
228
+ attributes: DataFieldAttributeFactory[];
229
+ comments: string[];
230
+ name?: string;
231
+ type?: DataFieldTypeFactory;
232
+ constructor();
233
+ addAttribute(builder: ((attr: DataFieldAttributeFactory) => DataFieldAttributeFactory) | DataFieldAttributeFactory): this;
234
+ setComments(comments: string[]): this;
235
+ setName(name: string): this;
236
+ setType(builder: (type: DataFieldTypeFactory) => DataFieldTypeFactory): this;
233
237
  }
234
238
  declare class DataFieldTypeFactory extends AstFactory<DataFieldType> {
235
- array?: boolean;
236
- optional?: boolean;
237
- reference?: Reference<TypeDeclaration>;
238
- type?: BuiltinType;
239
- unsupported?: UnsupportedFieldTypeFactory;
240
- constructor();
241
- setArray(array: boolean): this;
242
- setOptional(optional: boolean): this;
243
- setReference(reference: TypeDeclaration): this;
244
- setType(type: BuiltinType): this;
245
- setUnsupported(builder: (a: UnsupportedFieldTypeFactory) => UnsupportedFieldTypeFactory): this;
239
+ array?: boolean;
240
+ optional?: boolean;
241
+ reference?: Reference$1<TypeDeclaration>;
242
+ type?: BuiltinType;
243
+ unsupported?: UnsupportedFieldTypeFactory;
244
+ constructor();
245
+ setArray(array: boolean): this;
246
+ setOptional(optional: boolean): this;
247
+ setReference(reference: TypeDeclaration): this;
248
+ setType(type: BuiltinType): this;
249
+ setUnsupported(builder: (a: UnsupportedFieldTypeFactory) => UnsupportedFieldTypeFactory): this;
246
250
  }
247
251
  declare class UnsupportedFieldTypeFactory extends AstFactory<UnsupportedFieldType> {
248
- value?: AstFactory<LiteralExpr>;
249
- constructor();
250
- setValue(builder: (value: ExpressionBuilder<LiteralExpr>) => AstFactory<LiteralExpr>): this;
252
+ value?: AstFactory<LiteralExpr>;
253
+ constructor();
254
+ setValue(builder: (value: ExpressionBuilder<LiteralExpr>) => AstFactory<LiteralExpr>): this;
251
255
  }
252
256
  declare class ModelFactory extends AstFactory<Model> {
253
- declarations: AstFactory<AbstractDeclaration>[];
254
- imports: ModelImportFactory[];
255
- constructor();
256
- addImport(builder: (b: ModelImportFactory) => ModelImportFactory): this;
257
- addDeclaration(builder: (b: DeclarationBuilder) => AstFactory<AbstractDeclaration>): this;
257
+ declarations: AstFactory<AbstractDeclaration>[];
258
+ imports: ModelImportFactory[];
259
+ constructor();
260
+ addImport(builder: (b: ModelImportFactory) => ModelImportFactory): this;
261
+ addDeclaration(builder: (b: DeclarationBuilder) => AstFactory<AbstractDeclaration>): this;
258
262
  }
259
263
  declare class ModelImportFactory extends AstFactory<ModelImport> {
260
- path?: string | undefined;
261
- constructor();
262
- setPath(path: string): this;
264
+ path?: string | undefined;
265
+ constructor();
266
+ setPath(path: string): this;
263
267
  }
264
268
  declare class EnumFactory extends AstFactory<Enum> {
265
- name?: string;
266
- comments: string[];
267
- fields: EnumFieldFactory[];
268
- attributes: DataModelAttributeFactory[];
269
- constructor();
270
- addField(builder: (b: EnumFieldFactory) => EnumFieldFactory): this;
271
- addAttribute(builder: (b: DataModelAttributeFactory) => DataModelAttributeFactory): this;
272
- setName(name: string): this;
269
+ name?: string;
270
+ comments: string[];
271
+ fields: EnumFieldFactory[];
272
+ attributes: DataModelAttributeFactory[];
273
+ constructor();
274
+ addField(builder: (b: EnumFieldFactory) => EnumFieldFactory): this;
275
+ addAttribute(builder: (b: DataModelAttributeFactory) => DataModelAttributeFactory): this;
276
+ setName(name: string): this;
273
277
  }
274
278
  declare class EnumFieldFactory extends AstFactory<EnumField> {
275
- name?: RegularIDWithTypeNames;
276
- comments: string[];
277
- attributes: DataFieldAttributeFactory[];
278
- constructor();
279
- setName(name: RegularIDWithTypeNames): this;
280
- addAttribute(builder: (b: DataFieldAttributeFactory) => DataFieldAttributeFactory): this;
281
- addComment(comment: string): this;
279
+ name?: RegularIDWithTypeNames;
280
+ comments: string[];
281
+ attributes: DataFieldAttributeFactory[];
282
+ constructor();
283
+ setName(name: RegularIDWithTypeNames): this;
284
+ addAttribute(builder: (b: DataFieldAttributeFactory) => DataFieldAttributeFactory): this;
285
+ addComment(comment: string): this;
282
286
  }
283
-
284
- export { ArgumentFactory, ArrayExprFactory, AstFactory, AttributeArgFactory, AttributeFactory, AttributeParamFactory, AttributeParamTypeFactory, BinaryExprFactory, BooleanLiteralFactory, type ContainerProps, DataFieldAttributeFactory, DataFieldFactory, DataFieldTypeFactory, DataModelAttributeFactory, DataModelFactory, DeclarationBuilder, EnumFactory, EnumFieldFactory, ExpressionBuilder, FieldInitializerFactory, InternalAttributeFactory, InvocationExprFactory, MemberAccessExprFactory, ModelFactory, ModelImportFactory, NullExprFactory, NumberLiteralFactory, ObjectExprFactory, ReferenceArgFactory, ReferenceExprFactory, StringLiteralFactory, ThisExprFactory, UnaryExprFactory, UnsupportedFieldTypeFactory };
287
+ //#endregion
288
+ export { ArgumentFactory, ArrayExprFactory, AstFactory, AttributeArgFactory, AttributeFactory, AttributeParamFactory, AttributeParamTypeFactory, BinaryExprFactory, BooleanLiteralFactory, ContainerProps, DataFieldAttributeFactory, DataFieldFactory, DataFieldTypeFactory, DataModelAttributeFactory, DataModelFactory, DeclarationBuilder, EnumFactory, EnumFieldFactory, ExpressionBuilder, FieldInitializerFactory, InternalAttributeFactory, InvocationExprFactory, MemberAccessExprFactory, ModelFactory, ModelImportFactory, NullExprFactory, NumberLiteralFactory, ObjectExprFactory, ReferenceArgFactory, ReferenceExprFactory, StringLiteralFactory, ThisExprFactory, UnaryExprFactory, UnsupportedFieldTypeFactory };
289
+ //# sourceMappingURL=factory.d.cts.map