@canon-protocol/types 8.0.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 (93) hide show
  1. package/dist/ctl/models/enums.d.ts +58 -0
  2. package/dist/ctl/models/enums.js +64 -0
  3. package/dist/ctl/models/types.d.ts +169 -0
  4. package/dist/ctl/models/types.js +5 -0
  5. package/dist/ctl/parsing/enums.d.ts +38 -0
  6. package/dist/ctl/parsing/enums.js +44 -0
  7. package/dist/ctl/parsing/types.d.ts +89 -0
  8. package/dist/ctl/parsing/types.js +5 -0
  9. package/dist/ctl/rendering/types.d.ts +39 -0
  10. package/dist/ctl/rendering/types.js +5 -0
  11. package/dist/ctl/resolution/enums.d.ts +34 -0
  12. package/dist/ctl/resolution/enums.js +40 -0
  13. package/dist/ctl/resolution/types.d.ts +156 -0
  14. package/dist/ctl/resolution/types.js +5 -0
  15. package/dist/ctl/validation/types.d.ts +10 -0
  16. package/dist/ctl/validation/types.js +5 -0
  17. package/dist/document/constants/types.d.ts +5 -0
  18. package/dist/document/constants/types.js +5 -0
  19. package/dist/document/filtering/index.d.ts +13 -0
  20. package/dist/document/filtering/index.js +5 -0
  21. package/dist/document/filtering/types.d.ts +14 -0
  22. package/dist/document/filtering/types.js +5 -0
  23. package/dist/document/models/enums.d.ts +21 -0
  24. package/dist/document/models/enums.js +26 -0
  25. package/dist/document/models/index.d.ts +47 -0
  26. package/dist/document/models/index.js +5 -0
  27. package/dist/document/models/types.d.ts +194 -0
  28. package/dist/document/models/types.js +5 -0
  29. package/dist/document/parsing/index.d.ts +19 -0
  30. package/dist/document/parsing/index.js +5 -0
  31. package/dist/document/parsing/types.d.ts +10 -0
  32. package/dist/document/parsing/types.js +5 -0
  33. package/dist/document/repositories/enums.d.ts +17 -0
  34. package/dist/document/repositories/enums.js +22 -0
  35. package/dist/document/repositories/types.d.ts +103 -0
  36. package/dist/document/repositories/types.js +5 -0
  37. package/dist/document/storage/index.d.ts +25 -0
  38. package/dist/document/storage/index.js +5 -0
  39. package/dist/document/storage/types.d.ts +5 -0
  40. package/dist/document/storage/types.js +5 -0
  41. package/dist/exporters/ctl/markdown/types.d.ts +10 -0
  42. package/dist/exporters/ctl/markdown/types.js +5 -0
  43. package/dist/object/canons/types.d.ts +17 -0
  44. package/dist/object/canons/types.js +5 -0
  45. package/dist/object/parsing/index.d.ts +21 -0
  46. package/dist/object/parsing/index.js +5 -0
  47. package/dist/object/parsing/types.d.ts +43 -0
  48. package/dist/object/parsing/types.js +5 -0
  49. package/dist/object/resolution/types.d.ts +116 -0
  50. package/dist/object/resolution/types.js +5 -0
  51. package/dist/object/statements/index.d.ts +2 -0
  52. package/dist/object/statements/index.js +5 -0
  53. package/dist/object/statements/types.d.ts +20 -0
  54. package/dist/object/statements/types.js +5 -0
  55. package/dist/object/uris/types.d.ts +17 -0
  56. package/dist/object/uris/types.js +5 -0
  57. package/dist/object/validation/enums.d.ts +13 -0
  58. package/dist/object/validation/enums.js +18 -0
  59. package/dist/object/validation/index.d.ts +19 -0
  60. package/dist/object/validation/index.js +5 -0
  61. package/dist/object/validation/rules/document/index.d.ts +17 -0
  62. package/dist/object/validation/rules/document/index.js +5 -0
  63. package/dist/object/validation/rules/document/types.d.ts +52 -0
  64. package/dist/object/validation/rules/document/types.js +5 -0
  65. package/dist/object/validation/rules/repository/index.d.ts +19 -0
  66. package/dist/object/validation/rules/repository/index.js +5 -0
  67. package/dist/object/validation/rules/repository/types.d.ts +148 -0
  68. package/dist/object/validation/rules/repository/types.js +5 -0
  69. package/dist/object/validation/types.d.ts +134 -0
  70. package/dist/object/validation/types.js +5 -0
  71. package/dist/registry/models/types.d.ts +253 -0
  72. package/dist/registry/models/types.js +5 -0
  73. package/dist/registry/oauth/types.d.ts +192 -0
  74. package/dist/registry/oauth/types.js +5 -0
  75. package/dist/registry/providers/enums.d.ts +8 -0
  76. package/dist/registry/providers/enums.js +13 -0
  77. package/dist/registry/providers/git/types.d.ts +43 -0
  78. package/dist/registry/providers/git/types.js +5 -0
  79. package/dist/registry/providers/github/models/types.d.ts +35 -0
  80. package/dist/registry/providers/github/models/types.js +5 -0
  81. package/dist/registry/providers/github/types.d.ts +30 -0
  82. package/dist/registry/providers/github/types.js +5 -0
  83. package/dist/registry/providers/index.d.ts +29 -0
  84. package/dist/registry/providers/index.js +5 -0
  85. package/dist/registry/providers/oci/types.d.ts +17 -0
  86. package/dist/registry/providers/oci/types.js +5 -0
  87. package/dist/registry/providers/types.d.ts +15 -0
  88. package/dist/registry/providers/types.js +5 -0
  89. package/dist/registry/services/index.d.ts +9 -0
  90. package/dist/registry/services/index.js +5 -0
  91. package/dist/registry/services/types.d.ts +153 -0
  92. package/dist/registry/services/types.js +5 -0
  93. package/package.json +99 -0
@@ -0,0 +1,156 @@
1
+ import { CtlDocument } from '../../ctl/models/types';
2
+ import { ResolvedResourceType } from '../../ctl/resolution/enums';
3
+ import { SubjectCanon } from '../../object/canons/types';
4
+ /**
5
+ * Resolves the complete entity graph for a CTL document. Recursively resolves all referenced entities and their dependencies, organizing them into tiers by importance. Uses ResourceResolver from Canon.Object for proper transitive alias resolution.
6
+ */
7
+ export interface CtlGraphResolver {
8
+ /**
9
+ * Resolves the complete entity graph for a CTL document.
10
+ */
11
+ resolveAsync(document: CtlDocument, maxDepth?: number): Promise<ResolvedResourceGraph>;
12
+ }
13
+ /**
14
+ * A property of a resolved Class entity.
15
+ */
16
+ export interface ResolvedProperty {
17
+ /**
18
+ * The property name.
19
+ */
20
+ name: string;
21
+ /**
22
+ * The property's range types (supports RDF union types like range: [string, anyURI]).
23
+ */
24
+ rangeTypes: Array<string>;
25
+ /**
26
+ * The property's domain types (supports multiple domains like domain: [ClassA, ClassB]).
27
+ */
28
+ domains: Array<string>;
29
+ /**
30
+ * Convenience property for single range type (first in list, or "unknown" if empty).
31
+ */
32
+ readonly rangeType: string;
33
+ /**
34
+ * Whether this is an object property (reference to another entity).
35
+ */
36
+ isObjectProperty: boolean;
37
+ /**
38
+ * Whether this property is a collection.
39
+ */
40
+ isCollection: boolean;
41
+ /**
42
+ * The rdfs:comment or description of this property.
43
+ */
44
+ comment?: string | null | undefined;
45
+ }
46
+ /**
47
+ * A resolved Canon resource with metadata for documentation rendering.
48
+ */
49
+ export interface ResolvedResource {
50
+ /**
51
+ * The resource name (e.g., "Farm", "tableName").
52
+ */
53
+ name: string;
54
+ /**
55
+ * The full Canon URI (e.g., "canon://spec.farm/models.farming@1.1.0/Farm").
56
+ */
57
+ canonUri: string;
58
+ /**
59
+ * The parsed SubjectCanon resource (contains all statements/properties).
60
+ */
61
+ resource: SubjectCanon;
62
+ /**
63
+ * The semantic type of this resource.
64
+ */
65
+ resourceType: ResolvedResourceType;
66
+ /**
67
+ * Parent class name (for Class entities with subClassOf).
68
+ */
69
+ parentClass?: string | null | undefined;
70
+ /**
71
+ * Multiple parent classes (for Class entities with multiple inheritance).
72
+ */
73
+ parentClasses: Array<string>;
74
+ /**
75
+ * The rdfs:comment or description of this entity.
76
+ */
77
+ comment?: string | null | undefined;
78
+ /**
79
+ * Properties defined on this entity (for Class entities).
80
+ */
81
+ properties: Array<ResolvedProperty>;
82
+ /**
83
+ * The namespace this entity belongs to.
84
+ */
85
+ namespace_: string;
86
+ /**
87
+ * The depth at which this entity was resolved (0 = direct reference).
88
+ */
89
+ resolutionDepth: number;
90
+ /**
91
+ * For Instance resources, the type/class this is an instance of.
92
+ */
93
+ instanceOf_?: string | null | undefined;
94
+ }
95
+ /**
96
+ * Represents a fully resolved entity graph from a CTL document. Entities are organized into tiers by importance/proximity to the source document.
97
+ */
98
+ export interface ResolvedResourceGraph {
99
+ /**
100
+ * The source file path (if available).
101
+ */
102
+ sourceFile?: string | null | undefined;
103
+ /**
104
+ * The original markdown content of the CTL document.
105
+ */
106
+ originalContent: string;
107
+ /**
108
+ * The title extracted from the first H1 heading, if present.
109
+ */
110
+ title?: string | null | undefined;
111
+ /**
112
+ * Direct references - entities explicitly referenced in the template via can:// links. These are the most important and appear first in output.
113
+ */
114
+ directReferences: Array<ResolvedResource>;
115
+ /**
116
+ * Inherited references - parent classes (subClassOf), property ranges, etc. These are referenced by direct entities but not explicitly in the template.
117
+ */
118
+ inheritedReferences: Array<ResolvedResource>;
119
+ /**
120
+ * Foundation types - core ontology types (rdf:Class, rdfs:Resource, owl:Thing, etc.). These form the base of the type hierarchy.
121
+ */
122
+ foundationTypes: Array<ResolvedResource>;
123
+ /**
124
+ * Total number of resolved resources across all tiers.
125
+ */
126
+ readonly totalResourceCount: number;
127
+ /**
128
+ * All resolved resources across all tiers (for iteration).
129
+ */
130
+ readonly allResources: Array<ResolvedResource>;
131
+ /**
132
+ * Maximum depth reached during resolution.
133
+ */
134
+ maxDepthReached: number;
135
+ /**
136
+ * Whether resolution was truncated due to depth limit.
137
+ */
138
+ wasTruncated: boolean;
139
+ /**
140
+ * Resources that failed to resolve (for diagnostic purposes).
141
+ */
142
+ unresolvedResources: Array<UnresolvedResource>;
143
+ }
144
+ /**
145
+ * An entity that failed to resolve.
146
+ */
147
+ export interface UnresolvedResource {
148
+ /**
149
+ * The entity name or URI that failed to resolve.
150
+ */
151
+ reference: string;
152
+ /**
153
+ * The reason for failure.
154
+ */
155
+ reason: string;
156
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: 2 files in namespace
3
+ // SourceHash: sha256-e8d0e7bd29c93f972dd742211e808362e50f44937f3ac3f58183c4e80ff1d915
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,10 @@
1
+ import { CtlDocument, CtlValidationResult } from '../../ctl/models/types';
2
+ /**
3
+ * Validates CTL documents by resolving all Canon URI references. CTL only supports entity-level references (Entity and DeepLink URIs). Package and publisher-level URIs are not supported.
4
+ */
5
+ export interface CtlValidator {
6
+ /**
7
+ * Validates a CTL document by resolving all Canon URI references.
8
+ */
9
+ validateAsync(document: CtlDocument): Promise<CtlValidationResult>;
10
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.CTL\Validation\CtlValidator.cs
3
+ // SourceHash: sha256-42749bb4e59250ddc768f7b819f4879f31ac6630b37fe9c037603a5239a73baa
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Centralized constants for core Canon Protocol package names and identifiers. All package name references should use these constants for maintainability.
3
+ */
4
+ export interface CorePackageConstants {
5
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Constants\CorePackageConstants.cs
3
+ // SourceHash: sha256-9611765721146ac8fd17225b61b74595345a8cfbfe8dcff3fdd4889cb48362b2
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Interface for filtering files based on .gitignore rules
3
+ */
4
+ export interface IGitIgnoreFilter {
5
+ /**
6
+ * Checks if a file path should be ignored based on gitignore rules
7
+ */
8
+ shouldIgnore(absolutePath: string): boolean;
9
+ /**
10
+ * Checks if a directory path should be ignored based on gitignore rules. Used to skip entire directory trees before traversing them.
11
+ */
12
+ shouldIgnoreDirectory(absoluteDirectoryPath: string): boolean;
13
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Filtering\IGitIgnoreFilter.cs
3
+ // SourceHash: sha256-aa344789a9cec0636546e34be71710e93530a8a0d8d8b111c87f019d730296c4
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,14 @@
1
+ import { IGitIgnoreFilter } from '../../document/filtering/index';
2
+ /**
3
+ * Filters files based on .gitignore rules using the MAB.DotIgnore library
4
+ */
5
+ export interface GitIgnoreFilter extends IGitIgnoreFilter {
6
+ /**
7
+ * Checks if a file should be ignored based on the loaded .gitignore rules
8
+ */
9
+ shouldIgnore(absolutePath: string): boolean;
10
+ /**
11
+ * Checks if a directory should be ignored based on the loaded .gitignore rules. Used to skip entire directory trees before traversing them.
12
+ */
13
+ shouldIgnoreDirectory(absoluteDirectoryPath: string): boolean;
14
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Filtering\GitIgnoreFilter.cs
3
+ // SourceHash: sha256-f32af7a28fd3c633051f3583193d8582c3236e03d68ec478ccc18d11f7bc2427
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Represents the version operator used in import specifications
3
+ */
4
+ export declare enum VersionOperator {
5
+ /**
6
+ * Any version (*) - Accepts any version
7
+ */
8
+ Any = 0,
9
+ /**
10
+ * Compatible version (~) - Accepts patch and minor updates
11
+ */
12
+ Compatible = 1,
13
+ /**
14
+ * Major version (^) - Accepts minor and patch updates
15
+ */
16
+ Major = 2,
17
+ /**
18
+ * Exact version (=) - Requires exact version match
19
+ */
20
+ Exact = 3
21
+ }
@@ -0,0 +1,26 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Models\VersionOperator.cs
3
+ // SourceHash: sha256-8d43eda1be57ff8cf7ff83b6184ff78ad02e30009a8c9ebbeb16ed011589cb11
4
+ // DO NOT EDIT - changes will be overwritten
5
+ /**
6
+ * Represents the version operator used in import specifications
7
+ */
8
+ export var VersionOperator;
9
+ (function (VersionOperator) {
10
+ /**
11
+ * Any version (*) - Accepts any version
12
+ */
13
+ VersionOperator[VersionOperator["Any"] = 0] = "Any";
14
+ /**
15
+ * Compatible version (~) - Accepts patch and minor updates
16
+ */
17
+ VersionOperator[VersionOperator["Compatible"] = 1] = "Compatible";
18
+ /**
19
+ * Major version (^) - Accepts minor and patch updates
20
+ */
21
+ VersionOperator[VersionOperator["Major"] = 2] = "Major";
22
+ /**
23
+ * Exact version (=) - Requires exact version match
24
+ */
25
+ VersionOperator[VersionOperator["Exact"] = 3] = "Exact";
26
+ })(VersionOperator || (VersionOperator = {}));
@@ -0,0 +1,47 @@
1
+ import { CanonDocument, DocumentReference, Import } from '../../document/models/types';
2
+ export { CanonDocument, DocumentReference, Import };
3
+ /**
4
+ * Repository interface for managing Canon documents
5
+ */
6
+ export interface ICanonDocumentRepository {
7
+ /**
8
+ * Loads all Canon documents from the repository
9
+ */
10
+ getAllDocumentsAsync(): Promise<Array<CanonDocument>>;
11
+ /**
12
+ * Loads a specific Canon document by path or identifier
13
+ */
14
+ getDocumentAsync(identifier: string): Promise<CanonDocument | null>;
15
+ /**
16
+ * Loads all Canon documents from a specific namespace
17
+ */
18
+ getDocumentsByNamespaceAsync(publisher: string, package_: string): Promise<Array<CanonDocument>>;
19
+ /**
20
+ * Finds the highest compatible version of a document that matches the import specification
21
+ */
22
+ getHighestCompatibleVersionAsync(publisher: string, import_: Import): Promise<CanonDocument | null>;
23
+ /**
24
+ * Saves a Canon document to the repository
25
+ */
26
+ saveDocumentAsync(document: CanonDocument, identifier: string): Promise<void>;
27
+ /**
28
+ * Deletes a Canon document from the repository
29
+ */
30
+ deleteDocumentAsync(identifier: string): Promise<void>;
31
+ /**
32
+ * Removes all documents from a specific namespace
33
+ */
34
+ clearNamespaceAsync(publisher: string, package_: string): Promise<void>;
35
+ /**
36
+ * Gets references to all documents in the repository, including documents that failed to parse. Used for workspace-wide validation to ensure all documents are checked, even those with syntax errors.
37
+ */
38
+ getAllDocumentReferencesAsync(): Promise<Array<DocumentReference>>;
39
+ /**
40
+ * Gets the raw content of a document by identifier. This is used for validation and diagnostics where the actual YAML content is needed.
41
+ */
42
+ getDocumentContentAsync(identifier: string): Promise<string | null>;
43
+ /**
44
+ * Gets the URI for a specific document by identifier. Used for navigation (go-to-definition) where the target URI is needed.
45
+ */
46
+ getDocumentUriAsync(identifier: string): Promise<string | null>;
47
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Models\ICanonDocumentRepository.cs
3
+ // SourceHash: sha256-6fdc69d495e3e615a710d0b4133ce3348719d44fbbc053f94e286858bcd11046
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,194 @@
1
+ import { VersionOperator } from '../../document/models/enums';
2
+ /**
3
+ * Represents a Canon document in universal bundle format
4
+ */
5
+ export interface CanonDocument {
6
+ metadata: CanonMetadata;
7
+ body: Record<string, any | null>;
8
+ toString(): string;
9
+ }
10
+ /**
11
+ * Metadata for a Canon document (Package declaration)
12
+ */
13
+ export interface CanonMetadata {
14
+ /**
15
+ * The type of the metadata entry. Always "Package".
16
+ */
17
+ type_?: string | null | undefined;
18
+ /**
19
+ * The namespace of the Canon document (publisher/package/version)
20
+ */
21
+ namespace_?: Namespace | null | undefined;
22
+ /**
23
+ * Imports with optional namespace aliases. Key is the publisher (e.g., "canon-protocol.org"), value is list of Import objects. Imports are stored grouped by publisher for efficient lookup.
24
+ */
25
+ imports?: Record<string, Array<Import>> | undefined;
26
+ /**
27
+ * Gets all imports as a flat list.
28
+ */
29
+ readonly allImports: Array<Import>;
30
+ }
31
+ /**
32
+ * Reference to a Canon document in a repository, including metadata for validation scenarios. Used by workspace validators to enumerate all documents, including those with parse errors.
33
+ */
34
+ export interface DocumentReference {
35
+ /**
36
+ * Unique identifier for the document (namespace string or repository-specific ID)
37
+ */
38
+ identifier: string;
39
+ /**
40
+ * URI for publishing diagnostics (e.g., file:// for local files, http:// for remote, canon:// for API-based)
41
+ */
42
+ uri: string;
43
+ /**
44
+ * Indicates whether this document failed to parse (e.g., duplicate keys, syntax errors)
45
+ */
46
+ hasParseError: boolean;
47
+ }
48
+ /**
49
+ * Represents an import with optional namespace alias
50
+ */
51
+ export interface Import {
52
+ /**
53
+ * The full package specification (e.g., "classes ~ 1.0.0") This is computed from the other properties
54
+ */
55
+ package_: string;
56
+ /**
57
+ * The publisher domain (e.g., "canon-protocol.org")
58
+ */
59
+ publisher?: string | null | undefined;
60
+ /**
61
+ * The package name without version (e.g., "classes")
62
+ */
63
+ packageName: string;
64
+ /**
65
+ * The version operator (*, ~, ^, =)
66
+ */
67
+ versionOperator: VersionOperator;
68
+ /**
69
+ * The semantic version
70
+ */
71
+ version: Version;
72
+ /**
73
+ * Optional namespace alias for the import (e.g., "cls")
74
+ */
75
+ alias?: string | null | undefined;
76
+ /**
77
+ * Gets the minimum version allowed by this import specification
78
+ */
79
+ readonly minVersion: Version;
80
+ /**
81
+ * Gets the maximum version allowed by this import specification
82
+ */
83
+ readonly maxVersion: Version;
84
+ /**
85
+ * Converts this Import to an embedded object dictionary for serialization
86
+ */
87
+ toEmbeddedObject(): Record<string, any>;
88
+ /**
89
+ * Returns the string representation of the import
90
+ */
91
+ toString(): string;
92
+ }
93
+ /**
94
+ * Represents a Canon namespace with Publisher, Package, and optional Version components
95
+ */
96
+ export interface Namespace {
97
+ /**
98
+ * The publisher component (e.g., "geography.org", "test")
99
+ */
100
+ publisher: string;
101
+ /**
102
+ * The package component (e.g., "rivers", "entities")
103
+ */
104
+ package_: string;
105
+ /**
106
+ * The version component (optional, e.g., "1.0.0")
107
+ */
108
+ version?: Version | null | undefined;
109
+ /**
110
+ * Returns the string representation of the namespace
111
+ */
112
+ toString(): string;
113
+ /**
114
+ * Determines whether the specified object is equal to the current namespace
115
+ */
116
+ equals(obj: any | null): boolean;
117
+ /**
118
+ * Returns the hash code for this namespace
119
+ */
120
+ getHashCode(): number;
121
+ }
122
+ /**
123
+ * Represents a parse-time error with position information
124
+ */
125
+ export interface ParseError {
126
+ /**
127
+ * Line number where error occurred (1-based)
128
+ */
129
+ line: number;
130
+ /**
131
+ * Column number where error occurred (1-based)
132
+ */
133
+ column: number;
134
+ /**
135
+ * Human-readable error message
136
+ */
137
+ message: string;
138
+ /**
139
+ * Type of error (e.g., "DuplicateKey", "SyntaxError", "InvalidYaml")
140
+ */
141
+ errorType: string;
142
+ /**
143
+ * For duplicate key errors, the name of the duplicate key
144
+ */
145
+ keyName?: string | null | undefined;
146
+ toString(): string;
147
+ }
148
+ /**
149
+ * Result of parsing a Canon YAML document, including any parse-level errors
150
+ */
151
+ export interface ParseResult {
152
+ /**
153
+ * The parsed Canon document (null if parsing failed)
154
+ */
155
+ document?: CanonDocument | null | undefined;
156
+ /**
157
+ * List of parse errors encountered
158
+ */
159
+ errors: Array<ParseError>;
160
+ /**
161
+ * True if parsing succeeded with no errors
162
+ */
163
+ readonly isValid: boolean;
164
+ }
165
+ /**
166
+ * Represents a semantic version with Major, Minor, and Patch components
167
+ */
168
+ export interface Version {
169
+ /**
170
+ * Major version number
171
+ */
172
+ major: number;
173
+ /**
174
+ * Minor version number
175
+ */
176
+ minor: number;
177
+ /**
178
+ * Patch version number
179
+ */
180
+ patch: number;
181
+ /**
182
+ * Returns the string representation of the version
183
+ */
184
+ toString(): string;
185
+ /** C# method 'Equals' has 2 overloads. Using overload with most parameters. */
186
+ equals(obj: any | null): boolean;
187
+ getHashCode(): number;
188
+ compareTo(other: Version): number;
189
+ }
190
+ /**
191
+ * Helper methods for VersionOperator
192
+ */
193
+ export interface VersionOperatorExtensions {
194
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: 8 files in namespace
3
+ // SourceHash: sha256-5160cd915fa26623fabad4f5ecee9c0bbbd58b76203fd8df2c26007e3c33e814
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,19 @@
1
+ import { CanonDocument, ParseResult } from '../../document/models/types';
2
+ export { CanonDocument, ParseResult };
3
+ /**
4
+ * Interface for parsing and saving Canon YAML documents
5
+ */
6
+ export interface ICanonParser {
7
+ /**
8
+ * Parses a Canon YAML document from text
9
+ */
10
+ parse(yamlText: string): CanonDocument;
11
+ /**
12
+ * Parses a Canon YAML document from text, returning errors instead of throwing
13
+ */
14
+ parseWithErrors(yamlText: string): ParseResult;
15
+ /**
16
+ * Saves a CanonDocument to YAML format
17
+ */
18
+ save(document: CanonDocument): string;
19
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Parsing\ICanonParser.cs
3
+ // SourceHash: sha256-2231324bdf79500108ca3f8b2e3d0215283858cfdac31e098153386b7f551ece
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,10 @@
1
+ import { CanonDocument, ParseResult } from '../../document/models/types';
2
+ import { ICanonParser } from '../../document/parsing/index';
3
+ /**
4
+ * Parser for Canon YAML documents
5
+ */
6
+ export interface CanonParser extends ICanonParser {
7
+ parse(yamlText: string): CanonDocument;
8
+ parseWithErrors(yamlText: string): ParseResult;
9
+ save(document: CanonDocument): string;
10
+ }
@@ -0,0 +1,5 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Parsing\CanonParser.cs
3
+ // SourceHash: sha256-33ccc509e140f483bf083292e7c64d72f175e16d83f0f1d2611ef0c7e870ee53
4
+ // DO NOT EDIT - changes will be overwritten
5
+ export {};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Indicates where a document is located
3
+ */
4
+ export declare enum DocumentLocation {
5
+ /**
6
+ * Document not found
7
+ */
8
+ NotFound = 0,
9
+ /**
10
+ * Document is in workspace (user file, should be committed)
11
+ */
12
+ Workspace = 1,
13
+ /**
14
+ * Document is in cache (downloaded package, gitignored)
15
+ */
16
+ Cache = 2
17
+ }
@@ -0,0 +1,22 @@
1
+ // This file was auto-generated by Canon SDK Transpiler v1.0.0
2
+ // Source: canon-sdk-csharp\Canon.Document\Repositories\CompositeCanonDocumentRepository.cs
3
+ // SourceHash: sha256-52ad39ced6b6f4649b4683acc1593211fa4617663b235ae3a6d3da716c5cbd09
4
+ // DO NOT EDIT - changes will be overwritten
5
+ /**
6
+ * Indicates where a document is located
7
+ */
8
+ export var DocumentLocation;
9
+ (function (DocumentLocation) {
10
+ /**
11
+ * Document not found
12
+ */
13
+ DocumentLocation[DocumentLocation["NotFound"] = 0] = "NotFound";
14
+ /**
15
+ * Document is in workspace (user file, should be committed)
16
+ */
17
+ DocumentLocation[DocumentLocation["Workspace"] = 1] = "Workspace";
18
+ /**
19
+ * Document is in cache (downloaded package, gitignored)
20
+ */
21
+ DocumentLocation[DocumentLocation["Cache"] = 2] = "Cache";
22
+ })(DocumentLocation || (DocumentLocation = {}));