@atomic-ehr/codegen 0.0.1-canary.20250811235950.67a72a5 → 0.0.1-canary.20250819094151.a48e310
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/dist/api/builder.d.ts.map +1 -1
- package/dist/api/generators/base/BaseGenerator.d.ts +186 -0
- package/dist/api/generators/base/BaseGenerator.d.ts.map +1 -0
- package/dist/api/generators/base/FileManager.d.ts +90 -0
- package/dist/api/generators/base/FileManager.d.ts.map +1 -0
- package/dist/api/generators/base/HandlebarsTemplateEngine.d.ts +60 -0
- package/dist/api/generators/base/HandlebarsTemplateEngine.d.ts.map +1 -0
- package/dist/api/generators/base/PythonTypeMapper.d.ts +17 -0
- package/dist/api/generators/base/PythonTypeMapper.d.ts.map +1 -0
- package/dist/api/generators/base/TemplateEngine.d.ts +127 -0
- package/dist/api/generators/base/TemplateEngine.d.ts.map +1 -0
- package/dist/api/generators/base/TypeMapper.d.ts +130 -0
- package/dist/api/generators/base/TypeMapper.d.ts.map +1 -0
- package/dist/api/generators/base/TypeScriptTypeMapper.d.ts +52 -0
- package/dist/api/generators/base/TypeScriptTypeMapper.d.ts.map +1 -0
- package/dist/api/generators/base/builders/DirectoryBuilder.d.ts +100 -0
- package/dist/api/generators/base/builders/DirectoryBuilder.d.ts.map +1 -0
- package/dist/api/generators/base/builders/FileBuilder.d.ts +161 -0
- package/dist/api/generators/base/builders/FileBuilder.d.ts.map +1 -0
- package/dist/api/generators/base/builders/IndexBuilder.d.ts +127 -0
- package/dist/api/generators/base/builders/IndexBuilder.d.ts.map +1 -0
- package/dist/api/generators/base/enhanced-errors.d.ts +85 -0
- package/dist/api/generators/base/enhanced-errors.d.ts.map +1 -0
- package/dist/api/generators/base/error-handler.d.ts +90 -0
- package/dist/api/generators/base/error-handler.d.ts.map +1 -0
- package/dist/api/generators/base/errors.d.ts +252 -0
- package/dist/api/generators/base/errors.d.ts.map +1 -0
- package/dist/api/generators/base/index.d.ts +104 -0
- package/dist/api/generators/base/index.d.ts.map +1 -0
- package/dist/api/generators/base/types.d.ts +434 -0
- package/dist/api/generators/base/types.d.ts.map +1 -0
- package/dist/api/generators/typescript.d.ts +81 -135
- package/dist/api/generators/typescript.d.ts.map +1 -1
- package/dist/api/index.d.ts +3 -2
- package/dist/api/index.d.ts.map +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/index-vysn9shw.js +14370 -0
- package/dist/index.js +3 -3
- package/package.json +13 -4
- package/dist/index-m60p8fkc.js +0 -6709
|
@@ -0,0 +1,434 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Core types and interfaces for the base generator system
|
|
3
|
+
*
|
|
4
|
+
* This module provides the foundational type definitions that all generators
|
|
5
|
+
* build upon, ensuring consistency and type safety across the system.
|
|
6
|
+
*/
|
|
7
|
+
import type { TypeSchema, TypeSchemaIdentifier } from "../../../typeschema";
|
|
8
|
+
import type { CodegenLogger } from "../../../utils/codegen-logger";
|
|
9
|
+
/**
|
|
10
|
+
* Base configuration options that all generators must support
|
|
11
|
+
* These options provide the minimum required configuration for any generator
|
|
12
|
+
*/
|
|
13
|
+
export interface BaseGeneratorOptions {
|
|
14
|
+
/** Output directory where generated files will be written */
|
|
15
|
+
outputDir: string;
|
|
16
|
+
/** Logger instance for tracking generation progress and errors */
|
|
17
|
+
logger?: CodegenLogger;
|
|
18
|
+
/** Whether to overwrite existing files (default: true) */
|
|
19
|
+
overwrite?: boolean;
|
|
20
|
+
/** Whether to validate schemas and generated content (default: true) */
|
|
21
|
+
validate?: boolean;
|
|
22
|
+
/** Enable detailed logging for debugging (default: false) */
|
|
23
|
+
verbose?: boolean;
|
|
24
|
+
/** Enable beginner-friendly error messages and guidance (default: false) */
|
|
25
|
+
beginnerMode?: boolean;
|
|
26
|
+
/** Format for error output: console, json, or structured (default: 'console') */
|
|
27
|
+
errorFormat?: "console" | "json" | "structured";
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Language-specific type representation
|
|
31
|
+
* This interface standardizes how FHIR types are mapped to target languages
|
|
32
|
+
*/
|
|
33
|
+
export interface LanguageType {
|
|
34
|
+
/** The type string in the target language (e.g., "string", "number", "Patient") */
|
|
35
|
+
name: string;
|
|
36
|
+
/** Whether this is a primitive type that doesn't need imports */
|
|
37
|
+
isPrimitive: boolean;
|
|
38
|
+
/** Import path if this type needs to be imported from another module */
|
|
39
|
+
importPath?: string;
|
|
40
|
+
/** Generic parameters if this is a generic type (e.g., ["T", "K"] for Map<T,K>) */
|
|
41
|
+
generics?: string[];
|
|
42
|
+
/** Whether this type is nullable/optional in the target language */
|
|
43
|
+
nullable?: boolean;
|
|
44
|
+
/** Additional metadata specific to the target language */
|
|
45
|
+
metadata?: Record<string, unknown>;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Generated file metadata and content
|
|
49
|
+
* Represents a single generated file with all its associated information
|
|
50
|
+
*/
|
|
51
|
+
export interface GeneratedFile {
|
|
52
|
+
/** Full file system path where the file was/will be written */
|
|
53
|
+
path: string;
|
|
54
|
+
/** Filename only (without directory path) */
|
|
55
|
+
filename: string;
|
|
56
|
+
/** The generated content of the file */
|
|
57
|
+
content: string;
|
|
58
|
+
/** List of symbols exported from this file */
|
|
59
|
+
exports: string[];
|
|
60
|
+
/** File size in bytes */
|
|
61
|
+
size: number;
|
|
62
|
+
/** When this file was generated */
|
|
63
|
+
timestamp: Date;
|
|
64
|
+
/** Additional metadata about the generation process */
|
|
65
|
+
metadata?: {
|
|
66
|
+
/** Time taken to generate this file in milliseconds */
|
|
67
|
+
generationTime?: number;
|
|
68
|
+
/** Number of schemas processed for this file */
|
|
69
|
+
schemaCount?: number;
|
|
70
|
+
/** Template used to generate this file */
|
|
71
|
+
templateName?: string;
|
|
72
|
+
/** Any warnings generated during processing */
|
|
73
|
+
warnings?: string[];
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Template context provided to template engines
|
|
78
|
+
* Contains all the data needed to render templates for code generation
|
|
79
|
+
*/
|
|
80
|
+
export interface TemplateContext {
|
|
81
|
+
/** The schema being processed */
|
|
82
|
+
schema: TypeSchema;
|
|
83
|
+
/** Type mapper for the target language */
|
|
84
|
+
typeMapper: TypeMapper;
|
|
85
|
+
/** Current file being generated */
|
|
86
|
+
filename: string;
|
|
87
|
+
/** Target language name (e.g., "TypeScript", "Python") */
|
|
88
|
+
language: string;
|
|
89
|
+
/** Generation timestamp in ISO format */
|
|
90
|
+
timestamp: string;
|
|
91
|
+
/** Import map for the current file */
|
|
92
|
+
imports?: Map<string, string>;
|
|
93
|
+
/** Export set for the current file */
|
|
94
|
+
exports?: Set<string>;
|
|
95
|
+
/** Additional context data that templates can use */
|
|
96
|
+
[key: string]: unknown;
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* File builder context passed to lifecycle hooks
|
|
100
|
+
* Provides access to file generation state during the build process
|
|
101
|
+
*/
|
|
102
|
+
export interface FileContext {
|
|
103
|
+
/** Name of the file being generated */
|
|
104
|
+
filename: string;
|
|
105
|
+
/** Current file content */
|
|
106
|
+
content: string;
|
|
107
|
+
/** Map of imports (symbol name -> import path) */
|
|
108
|
+
imports: Map<string, string>;
|
|
109
|
+
/** Set of exported symbols */
|
|
110
|
+
exports: Set<string>;
|
|
111
|
+
/** Additional metadata about the file */
|
|
112
|
+
metadata: Record<string, unknown>;
|
|
113
|
+
/** The schema that generated this file (if applicable) */
|
|
114
|
+
schema?: TypeSchema;
|
|
115
|
+
/** Template name used to generate this file (if applicable) */
|
|
116
|
+
templateName?: string;
|
|
117
|
+
}
|
|
118
|
+
/**
|
|
119
|
+
* Statistics about file operations
|
|
120
|
+
* Used for performance monitoring and optimization
|
|
121
|
+
*/
|
|
122
|
+
export interface FileStats {
|
|
123
|
+
/** File size in bytes */
|
|
124
|
+
size: number;
|
|
125
|
+
/** Time taken to generate content in milliseconds */
|
|
126
|
+
generationTime: number;
|
|
127
|
+
/** Time taken to write to disk in milliseconds */
|
|
128
|
+
writeTime: number;
|
|
129
|
+
/** Memory used during generation in bytes */
|
|
130
|
+
memoryUsed?: number;
|
|
131
|
+
/** Number of template renders performed */
|
|
132
|
+
templateRenders?: number;
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Progress callback signature for monitoring generation
|
|
136
|
+
* Allows consumers to track progress of long-running operations
|
|
137
|
+
*/
|
|
138
|
+
export type ProgressCallback = (
|
|
139
|
+
/** Current phase of generation */
|
|
140
|
+
phase: "validation" | "generation" | "writing" | "complete",
|
|
141
|
+
/** Current item number being processed */
|
|
142
|
+
current: number,
|
|
143
|
+
/** Total number of items to process */
|
|
144
|
+
total: number,
|
|
145
|
+
/** Optional message describing current operation */
|
|
146
|
+
message?: string,
|
|
147
|
+
/** Schema being processed (if applicable) */
|
|
148
|
+
schema?: TypeSchema) => void;
|
|
149
|
+
/**
|
|
150
|
+
* Lifecycle hook signatures for file operations
|
|
151
|
+
* These hooks allow customization of the file generation process
|
|
152
|
+
*/
|
|
153
|
+
/** Hook called before saving a file - can modify content or abort save */
|
|
154
|
+
export type BeforeSaveHook = (context: FileContext) => void | Promise<void>;
|
|
155
|
+
/** Hook called after successfully saving a file */
|
|
156
|
+
export type AfterSaveHook = (filePath: string, stats: FileStats) => void | Promise<void>;
|
|
157
|
+
/** Hook called when an error occurs during file operations */
|
|
158
|
+
export type ErrorHook = (error: Error, context: FileContext) => void | Promise<void>;
|
|
159
|
+
/**
|
|
160
|
+
* File builder configuration options
|
|
161
|
+
* Controls how files are generated and processed
|
|
162
|
+
*/
|
|
163
|
+
export interface FileBuilderOptions {
|
|
164
|
+
/** Template name to use for content generation */
|
|
165
|
+
template?: string;
|
|
166
|
+
/** Strategy for resolving import paths */
|
|
167
|
+
importStrategy?: "auto" | "manual" | "none";
|
|
168
|
+
/** Level of content validation to perform */
|
|
169
|
+
validation?: "strict" | "loose" | "none";
|
|
170
|
+
/** Enable pretty printing of generated content */
|
|
171
|
+
prettify?: boolean;
|
|
172
|
+
/** Custom formatting options */
|
|
173
|
+
formatting?: {
|
|
174
|
+
/** Number of spaces for indentation (default: 2) */
|
|
175
|
+
indentSize?: number;
|
|
176
|
+
/** Use tabs instead of spaces (default: false) */
|
|
177
|
+
useTabs?: boolean;
|
|
178
|
+
/** Maximum line length before wrapping (default: 100) */
|
|
179
|
+
maxLineLength?: number;
|
|
180
|
+
};
|
|
181
|
+
/** File encoding (default: 'utf-8') */
|
|
182
|
+
encoding?: BufferEncoding;
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Abstract base class for type mapping between FHIR and target languages
|
|
186
|
+
* Each language-specific generator must implement this interface
|
|
187
|
+
*/
|
|
188
|
+
export declare abstract class TypeMapper {
|
|
189
|
+
/**
|
|
190
|
+
* Map a FHIR primitive type to the target language
|
|
191
|
+
* @param fhirType - FHIR primitive type name (e.g., "string", "integer")
|
|
192
|
+
* @returns Language-specific type representation
|
|
193
|
+
*/
|
|
194
|
+
abstract mapPrimitive(fhirType: string): LanguageType;
|
|
195
|
+
/**
|
|
196
|
+
* Map a FHIR reference to the target language
|
|
197
|
+
* @param targets - Array of possible reference targets
|
|
198
|
+
* @returns Language-specific reference type
|
|
199
|
+
*/
|
|
200
|
+
abstract mapReference(targets: TypeSchemaIdentifier[]): LanguageType;
|
|
201
|
+
/**
|
|
202
|
+
* Map an array type in the target language
|
|
203
|
+
* @param elementType - The element type name
|
|
204
|
+
* @returns Language-specific array type
|
|
205
|
+
*/
|
|
206
|
+
abstract mapArray(elementType: string): LanguageType;
|
|
207
|
+
/**
|
|
208
|
+
* Map optional/nullable types
|
|
209
|
+
* @param type - The base type
|
|
210
|
+
* @param required - Whether the field is required
|
|
211
|
+
* @returns Language-specific optional type
|
|
212
|
+
*/
|
|
213
|
+
abstract mapOptional(type: string, required: boolean): LanguageType;
|
|
214
|
+
/**
|
|
215
|
+
* Map enumerated values to the target language
|
|
216
|
+
* @param values - Array of possible values
|
|
217
|
+
* @param name - Optional name for the enum type
|
|
218
|
+
* @returns Language-specific enum type
|
|
219
|
+
*/
|
|
220
|
+
abstract mapEnum(values: string[], name?: string): LanguageType;
|
|
221
|
+
/**
|
|
222
|
+
* Format a FHIR type name according to target language conventions
|
|
223
|
+
* @param name - FHIR type name
|
|
224
|
+
* @returns Formatted type name
|
|
225
|
+
*/
|
|
226
|
+
abstract formatTypeName(name: string): string;
|
|
227
|
+
/**
|
|
228
|
+
* Format a field name according to target language conventions
|
|
229
|
+
* @param name - FHIR field name
|
|
230
|
+
* @returns Formatted field name
|
|
231
|
+
*/
|
|
232
|
+
abstract formatFieldName(name: string): string;
|
|
233
|
+
/**
|
|
234
|
+
* Format a filename according to target language conventions
|
|
235
|
+
* @param name - Base filename
|
|
236
|
+
* @returns Formatted filename (without extension)
|
|
237
|
+
*/
|
|
238
|
+
abstract formatFileName(name: string): string;
|
|
239
|
+
/**
|
|
240
|
+
* Map a complete TypeSchema identifier to target language type
|
|
241
|
+
* @param identifier - FHIR type identifier
|
|
242
|
+
* @returns Language-specific type representation
|
|
243
|
+
*/
|
|
244
|
+
abstract mapType(identifier: TypeSchemaIdentifier): LanguageType;
|
|
245
|
+
/**
|
|
246
|
+
* Get import statement format for the target language
|
|
247
|
+
* @param symbols - Symbols to import
|
|
248
|
+
* @param from - Module to import from
|
|
249
|
+
* @returns Formatted import statement
|
|
250
|
+
*/
|
|
251
|
+
formatImport?(symbols: string[], from: string): string;
|
|
252
|
+
/**
|
|
253
|
+
* Get export statement format for the target language
|
|
254
|
+
* @param symbols - Symbols to export
|
|
255
|
+
* @returns Formatted export statement
|
|
256
|
+
*/
|
|
257
|
+
formatExport?(symbols: string[]): string;
|
|
258
|
+
}
|
|
259
|
+
/**
|
|
260
|
+
* Directory builder configuration
|
|
261
|
+
* Used for batch directory operations
|
|
262
|
+
*/
|
|
263
|
+
export interface DirectoryBuilderConfig {
|
|
264
|
+
/** Directory path relative to output directory */
|
|
265
|
+
path: string;
|
|
266
|
+
/** File manager instance for file operations */
|
|
267
|
+
fileManager: any;
|
|
268
|
+
/** Logger for directory operations */
|
|
269
|
+
logger: CodegenLogger;
|
|
270
|
+
/** Whether to clean directory before creating files */
|
|
271
|
+
clean?: boolean;
|
|
272
|
+
}
|
|
273
|
+
/**
|
|
274
|
+
* Index builder configuration
|
|
275
|
+
* Used for generating index/barrel files
|
|
276
|
+
*/
|
|
277
|
+
export interface IndexBuilderConfig {
|
|
278
|
+
/** Directory to create index for */
|
|
279
|
+
directory: string;
|
|
280
|
+
/** File manager instance */
|
|
281
|
+
fileManager: any;
|
|
282
|
+
/** Template engine for rendering index files */
|
|
283
|
+
templateEngine: any;
|
|
284
|
+
/** Logger instance */
|
|
285
|
+
logger: CodegenLogger;
|
|
286
|
+
/** Header to include in index file */
|
|
287
|
+
header?: string;
|
|
288
|
+
/** Footer to include in index file */
|
|
289
|
+
footer?: string;
|
|
290
|
+
}
|
|
291
|
+
/**
|
|
292
|
+
* Batch operation result
|
|
293
|
+
* Used for tracking results of operations on multiple items
|
|
294
|
+
*/
|
|
295
|
+
export interface BatchResult<T> {
|
|
296
|
+
/** Successful results */
|
|
297
|
+
successes: T[];
|
|
298
|
+
/** Failed operations with their errors */
|
|
299
|
+
failures: Array<{
|
|
300
|
+
/** The item that failed */
|
|
301
|
+
item: unknown;
|
|
302
|
+
/** The error that occurred */
|
|
303
|
+
error: Error;
|
|
304
|
+
/** Index of the failed item */
|
|
305
|
+
index: number;
|
|
306
|
+
}>;
|
|
307
|
+
/** Total number of items processed */
|
|
308
|
+
total: number;
|
|
309
|
+
/** Time taken for the entire batch operation */
|
|
310
|
+
duration: number;
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* Template engine interface
|
|
314
|
+
* Abstraction for different template engines (Handlebars, etc.)
|
|
315
|
+
*/
|
|
316
|
+
export interface TemplateEngine {
|
|
317
|
+
/**
|
|
318
|
+
* Render a template with the given context
|
|
319
|
+
* @param templateName - Name of the template to render
|
|
320
|
+
* @param context - Data to pass to the template
|
|
321
|
+
* @returns Rendered content
|
|
322
|
+
*/
|
|
323
|
+
render(templateName: string, context: Record<string, unknown>): string;
|
|
324
|
+
/**
|
|
325
|
+
* Register a template
|
|
326
|
+
* @param name - Template name
|
|
327
|
+
* @param template - Template content or compiled template
|
|
328
|
+
*/
|
|
329
|
+
registerTemplate(name: string, template: string | Function): void;
|
|
330
|
+
/**
|
|
331
|
+
* Register a helper function
|
|
332
|
+
* @param name - Helper name
|
|
333
|
+
* @param helper - Helper function
|
|
334
|
+
*/
|
|
335
|
+
registerHelper(name: string, helper: Function): void;
|
|
336
|
+
/**
|
|
337
|
+
* Check if a template exists
|
|
338
|
+
* @param name - Template name
|
|
339
|
+
* @returns True if template exists
|
|
340
|
+
*/
|
|
341
|
+
hasTemplate(name: string): boolean;
|
|
342
|
+
/**
|
|
343
|
+
* Get list of available templates
|
|
344
|
+
* @returns Array of template names
|
|
345
|
+
*/
|
|
346
|
+
getAvailableTemplates(): string[];
|
|
347
|
+
}
|
|
348
|
+
/**
|
|
349
|
+
* File manager interface
|
|
350
|
+
* Abstraction for file system operations
|
|
351
|
+
*/
|
|
352
|
+
export interface FileManager {
|
|
353
|
+
/**
|
|
354
|
+
* Write a file with automatic directory creation
|
|
355
|
+
* @param relativePath - Path relative to output directory
|
|
356
|
+
* @param content - File content
|
|
357
|
+
* @param options - Write options
|
|
358
|
+
* @returns Write result with path and stats
|
|
359
|
+
*/
|
|
360
|
+
writeFile(relativePath: string, content: string, options?: {
|
|
361
|
+
encoding?: BufferEncoding;
|
|
362
|
+
overwrite?: boolean;
|
|
363
|
+
}): Promise<{
|
|
364
|
+
path: string;
|
|
365
|
+
size: number;
|
|
366
|
+
writeTime: number;
|
|
367
|
+
}>;
|
|
368
|
+
/**
|
|
369
|
+
* Write multiple files in batch
|
|
370
|
+
* @param files - Map of path to content
|
|
371
|
+
* @returns Array of write results
|
|
372
|
+
*/
|
|
373
|
+
writeBatch(files: Map<string, string>): Promise<Array<{
|
|
374
|
+
path: string;
|
|
375
|
+
size: number;
|
|
376
|
+
writeTime: number;
|
|
377
|
+
}>>;
|
|
378
|
+
/**
|
|
379
|
+
* Ensure directory exists
|
|
380
|
+
* @param dirPath - Directory path
|
|
381
|
+
*/
|
|
382
|
+
ensureDirectory(dirPath: string): Promise<void>;
|
|
383
|
+
/**
|
|
384
|
+
* Clean directory contents
|
|
385
|
+
* @param relativePath - Path relative to output directory
|
|
386
|
+
*/
|
|
387
|
+
cleanDirectory(relativePath?: string): Promise<void>;
|
|
388
|
+
/**
|
|
389
|
+
* Get relative import path between files
|
|
390
|
+
* @param fromFile - Source file
|
|
391
|
+
* @param toFile - Target file
|
|
392
|
+
* @returns Relative import path
|
|
393
|
+
*/
|
|
394
|
+
getRelativeImportPath(fromFile: string, toFile: string): string;
|
|
395
|
+
}
|
|
396
|
+
/**
|
|
397
|
+
* Generator configuration validation result
|
|
398
|
+
* Used to validate generator options before initialization
|
|
399
|
+
*/
|
|
400
|
+
export interface ConfigValidationResult {
|
|
401
|
+
/** Whether the configuration is valid */
|
|
402
|
+
isValid: boolean;
|
|
403
|
+
/** Validation errors if any */
|
|
404
|
+
errors: string[];
|
|
405
|
+
/** Non-fatal warnings */
|
|
406
|
+
warnings: string[];
|
|
407
|
+
/** Suggested fixes for invalid configuration */
|
|
408
|
+
suggestions: string[];
|
|
409
|
+
}
|
|
410
|
+
/**
|
|
411
|
+
* Generator capabilities interface
|
|
412
|
+
* Describes what a generator can do - used for introspection
|
|
413
|
+
*/
|
|
414
|
+
export interface GeneratorCapabilities {
|
|
415
|
+
/** Programming language this generator targets */
|
|
416
|
+
language: string;
|
|
417
|
+
/** File extensions this generator produces */
|
|
418
|
+
fileExtensions: string[];
|
|
419
|
+
/** Whether this generator supports templates */
|
|
420
|
+
supportsTemplates: boolean;
|
|
421
|
+
/** Whether this generator supports custom type mapping */
|
|
422
|
+
supportsCustomTypeMapping: boolean;
|
|
423
|
+
/** Whether this generator supports incremental generation */
|
|
424
|
+
supportsIncrementalGeneration: boolean;
|
|
425
|
+
/** Whether this generator supports validation */
|
|
426
|
+
supportsValidation: boolean;
|
|
427
|
+
/** Supported schema kinds */
|
|
428
|
+
supportedSchemaKinds: Array<"resource" | "complex-type" | "profile" | "primitive-type" | "logical">;
|
|
429
|
+
/** Version of the generator */
|
|
430
|
+
version: string;
|
|
431
|
+
/** Additional metadata about capabilities */
|
|
432
|
+
metadata?: Record<string, unknown>;
|
|
433
|
+
}
|
|
434
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/api/generators/base/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAC5E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAEnE;;;GAGG;AACH,MAAM,WAAW,oBAAoB;IACpC,6DAA6D;IAC7D,SAAS,EAAE,MAAM,CAAC;IAElB,kEAAkE;IAClE,MAAM,CAAC,EAAE,aAAa,CAAC;IAEvB,0DAA0D;IAC1D,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB,wEAAwE;IACxE,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,6DAA6D;IAC7D,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB,4EAA4E;IAC5E,YAAY,CAAC,EAAE,OAAO,CAAC;IAEvB,iFAAiF;IACjF,WAAW,CAAC,EAAE,SAAS,GAAG,MAAM,GAAG,YAAY,CAAC;CAChD;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC5B,mFAAmF;IACnF,IAAI,EAAE,MAAM,CAAC;IAEb,iEAAiE;IACjE,WAAW,EAAE,OAAO,CAAC;IAErB,wEAAwE;IACxE,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB,mFAAmF;IACnF,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IAEpB,oEAAoE;IACpE,QAAQ,CAAC,EAAE,OAAO,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