@techspokes/typescript-wsdl-client 1.1.4 → 1.1.5

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 (355) hide show
  1. package/README.md +49 -1
  2. package/dist/app/generateApp.d.ts.map +1 -1
  3. package/dist/app/generateApp.js +8 -6
  4. package/dist/cli.js +49 -5
  5. package/dist/client/checkedDirectRuntime.d.ts +59 -0
  6. package/dist/client/checkedDirectRuntime.d.ts.map +1 -0
  7. package/dist/client/checkedDirectRuntime.js +23 -0
  8. package/dist/client/directClientRuntime.d.ts +49 -0
  9. package/dist/client/directClientRuntime.d.ts.map +1 -0
  10. package/dist/client/directClientRuntime.js +112 -0
  11. package/dist/client/directClientVersion.d.ts +4 -0
  12. package/dist/client/directClientVersion.d.ts.map +1 -0
  13. package/dist/client/directClientVersion.js +3 -0
  14. package/dist/client/generateDirectClient.d.ts +14 -0
  15. package/dist/client/generateDirectClient.d.ts.map +1 -0
  16. package/dist/client/generateDirectClient.js +136 -0
  17. package/dist/compiler/buildCanonicalGraph.d.ts +7 -0
  18. package/dist/compiler/buildCanonicalGraph.d.ts.map +1 -0
  19. package/dist/compiler/buildCanonicalGraph.js +381 -0
  20. package/dist/compiler/canonicalGraph.d.ts +198 -0
  21. package/dist/compiler/canonicalGraph.d.ts.map +1 -0
  22. package/dist/compiler/canonicalGraph.js +37 -0
  23. package/dist/compiler/catalogErrors.d.ts +18 -0
  24. package/dist/compiler/catalogErrors.d.ts.map +1 -0
  25. package/dist/compiler/catalogErrors.js +86 -0
  26. package/dist/compiler/catalogProvenance.d.ts +15 -0
  27. package/dist/compiler/catalogProvenance.d.ts.map +1 -0
  28. package/dist/compiler/catalogProvenance.js +229 -0
  29. package/dist/compiler/checkedAssessment.d.ts +91 -0
  30. package/dist/compiler/checkedAssessment.d.ts.map +1 -0
  31. package/dist/compiler/checkedAssessment.js +300 -0
  32. package/dist/compiler/checkedSourcePreparation.d.ts +35 -0
  33. package/dist/compiler/checkedSourcePreparation.d.ts.map +1 -0
  34. package/dist/compiler/checkedSourcePreparation.js +131 -0
  35. package/dist/compiler/complexTypeContent.d.ts +59 -0
  36. package/dist/compiler/complexTypeContent.d.ts.map +1 -0
  37. package/dist/compiler/complexTypeContent.js +558 -0
  38. package/dist/compiler/composeCanonicalGraph.d.ts +69 -0
  39. package/dist/compiler/composeCanonicalGraph.d.ts.map +1 -0
  40. package/dist/compiler/composeCanonicalGraph.js +252 -0
  41. package/dist/compiler/dataOwnership.d.ts +22 -0
  42. package/dist/compiler/dataOwnership.d.ts.map +1 -0
  43. package/dist/compiler/dataOwnership.js +157 -0
  44. package/dist/compiler/datatypeValues.d.ts +47 -0
  45. package/dist/compiler/datatypeValues.d.ts.map +1 -0
  46. package/dist/compiler/datatypeValues.js +275 -0
  47. package/dist/compiler/directCodec.d.ts +59 -0
  48. package/dist/compiler/directCodec.d.ts.map +1 -0
  49. package/dist/compiler/directCodec.js +192 -0
  50. package/dist/compiler/directExecutionPolicy.d.ts +10 -0
  51. package/dist/compiler/directExecutionPolicy.d.ts.map +1 -0
  52. package/dist/compiler/directExecutionPolicy.js +17 -0
  53. package/dist/compiler/directOperation.d.ts +72 -0
  54. package/dist/compiler/directOperation.d.ts.map +1 -0
  55. package/dist/compiler/directOperation.js +282 -0
  56. package/dist/compiler/directSoap.d.ts +42 -0
  57. package/dist/compiler/directSoap.d.ts.map +1 -0
  58. package/dist/compiler/directSoap.js +298 -0
  59. package/dist/compiler/directSoapSource.d.ts +15 -0
  60. package/dist/compiler/directSoapSource.d.ts.map +1 -0
  61. package/dist/compiler/directSoapSource.js +86 -0
  62. package/dist/compiler/directSourceCapsule.d.ts +97 -0
  63. package/dist/compiler/directSourceCapsule.d.ts.map +1 -0
  64. package/dist/compiler/directSourceCapsule.js +305 -0
  65. package/dist/compiler/directStructure.d.ts +51 -0
  66. package/dist/compiler/directStructure.d.ts.map +1 -0
  67. package/dist/compiler/directStructure.js +252 -0
  68. package/dist/compiler/directStructurePlan.d.ts +16 -0
  69. package/dist/compiler/directStructurePlan.d.ts.map +1 -0
  70. package/dist/compiler/directStructurePlan.js +58 -0
  71. package/dist/compiler/directValues.d.ts +69 -0
  72. package/dist/compiler/directValues.d.ts.map +1 -0
  73. package/dist/compiler/directValues.js +282 -0
  74. package/dist/compiler/finiteRe01Verification.d.ts +140 -0
  75. package/dist/compiler/finiteRe01Verification.d.ts.map +1 -0
  76. package/dist/compiler/finiteRe01Verification.js +830 -0
  77. package/dist/compiler/graphTraversal.d.ts +11 -0
  78. package/dist/compiler/graphTraversal.d.ts.map +1 -0
  79. package/dist/compiler/graphTraversal.js +37 -0
  80. package/dist/compiler/hypotheticalScopedIdentity.d.ts +23 -0
  81. package/dist/compiler/hypotheticalScopedIdentity.d.ts.map +1 -0
  82. package/dist/compiler/hypotheticalScopedIdentity.js +81 -0
  83. package/dist/compiler/occurrenceAnalysis.d.ts +65 -0
  84. package/dist/compiler/occurrenceAnalysis.d.ts.map +1 -0
  85. package/dist/compiler/occurrenceAnalysis.js +300 -0
  86. package/dist/compiler/originalSourceMembership.d.ts +6 -0
  87. package/dist/compiler/originalSourceMembership.d.ts.map +1 -0
  88. package/dist/compiler/originalSourceMembership.js +31 -0
  89. package/dist/compiler/particleAttribution.d.ts +17 -0
  90. package/dist/compiler/particleAttribution.d.ts.map +1 -0
  91. package/dist/compiler/particleAttribution.js +474 -0
  92. package/dist/compiler/particleDeclarationConsistency.d.ts +24 -0
  93. package/dist/compiler/particleDeclarationConsistency.d.ts.map +1 -0
  94. package/dist/compiler/particleDeclarationConsistency.js +197 -0
  95. package/dist/compiler/particleExtension.d.ts +22 -0
  96. package/dist/compiler/particleExtension.d.ts.map +1 -0
  97. package/dist/compiler/particleExtension.js +119 -0
  98. package/dist/compiler/particleLocalAssessment.d.ts +20 -0
  99. package/dist/compiler/particleLocalAssessment.d.ts.map +1 -0
  100. package/dist/compiler/particleLocalAssessment.js +92 -0
  101. package/dist/compiler/particleRestriction.d.ts +24 -0
  102. package/dist/compiler/particleRestriction.d.ts.map +1 -0
  103. package/dist/compiler/particleRestriction.js +489 -0
  104. package/dist/compiler/particleSemanticView.d.ts +50 -0
  105. package/dist/compiler/particleSemanticView.d.ts.map +1 -0
  106. package/dist/compiler/particleSemanticView.js +297 -0
  107. package/dist/compiler/particleWildcardRelation.d.ts +88 -0
  108. package/dist/compiler/particleWildcardRelation.d.ts.map +1 -0
  109. package/dist/compiler/particleWildcardRelation.js +143 -0
  110. package/dist/compiler/re01CandidateCorrespondence.d.ts +64 -0
  111. package/dist/compiler/re01CandidateCorrespondence.d.ts.map +1 -0
  112. package/dist/compiler/re01CandidateCorrespondence.js +572 -0
  113. package/dist/compiler/re01TypeProperties.d.ts +71 -0
  114. package/dist/compiler/re01TypeProperties.d.ts.map +1 -0
  115. package/dist/compiler/re01TypeProperties.js +120 -0
  116. package/dist/compiler/re01TypePropertyValidation.d.ts +23 -0
  117. package/dist/compiler/re01TypePropertyValidation.d.ts.map +1 -0
  118. package/dist/compiler/re01TypePropertyValidation.js +161 -0
  119. package/dist/compiler/resolveCanonicalGraph.d.ts +38 -0
  120. package/dist/compiler/resolveCanonicalGraph.d.ts.map +1 -0
  121. package/dist/compiler/resolveCanonicalGraph.js +170 -0
  122. package/dist/compiler/scalarSchemaAssessment.d.ts +425 -0
  123. package/dist/compiler/scalarSchemaAssessment.d.ts.map +1 -0
  124. package/dist/compiler/scalarSchemaAssessment.js +5198 -0
  125. package/dist/compiler/schemaAttributeGroupProperties.d.ts +17 -0
  126. package/dist/compiler/schemaAttributeGroupProperties.d.ts.map +1 -0
  127. package/dist/compiler/schemaAttributeGroupProperties.js +53 -0
  128. package/dist/compiler/schemaAttributeProperties.d.ts +10 -0
  129. package/dist/compiler/schemaAttributeProperties.d.ts.map +1 -0
  130. package/dist/compiler/schemaAttributeProperties.js +11 -0
  131. package/dist/compiler/schemaAttributeUses.d.ts +90 -0
  132. package/dist/compiler/schemaAttributeUses.d.ts.map +1 -0
  133. package/dist/compiler/schemaAttributeUses.js +725 -0
  134. package/dist/compiler/schemaBinaryWordReconstruction.d.ts +10 -0
  135. package/dist/compiler/schemaBinaryWordReconstruction.d.ts.map +1 -0
  136. package/dist/compiler/schemaBinaryWordReconstruction.js +33 -0
  137. package/dist/compiler/schemaBuiltinFacets.d.ts +14 -0
  138. package/dist/compiler/schemaBuiltinFacets.d.ts.map +1 -0
  139. package/dist/compiler/schemaBuiltinFacets.js +51 -0
  140. package/dist/compiler/schemaCalendarImages.d.ts +8 -0
  141. package/dist/compiler/schemaCalendarImages.d.ts.map +1 -0
  142. package/dist/compiler/schemaCalendarImages.js +204 -0
  143. package/dist/compiler/schemaCalendarLanguage.d.ts +11 -0
  144. package/dist/compiler/schemaCalendarLanguage.d.ts.map +1 -0
  145. package/dist/compiler/schemaCalendarLanguage.js +227 -0
  146. package/dist/compiler/schemaComponentEquality.d.ts +28 -0
  147. package/dist/compiler/schemaComponentEquality.d.ts.map +1 -0
  148. package/dist/compiler/schemaComponentEquality.js +446 -0
  149. package/dist/compiler/schemaConstructionAssessment.d.ts +46 -0
  150. package/dist/compiler/schemaConstructionAssessment.d.ts.map +1 -0
  151. package/dist/compiler/schemaConstructionAssessment.js +663 -0
  152. package/dist/compiler/schemaDatatypeValues.d.ts +4 -0
  153. package/dist/compiler/schemaDatatypeValues.d.ts.map +1 -0
  154. package/dist/compiler/schemaDatatypeValues.js +2 -0
  155. package/dist/compiler/schemaDecimalLanguage.d.ts +7 -0
  156. package/dist/compiler/schemaDecimalLanguage.d.ts.map +1 -0
  157. package/dist/compiler/schemaDecimalLanguage.js +102 -0
  158. package/dist/compiler/schemaDeclarationPrimitives.d.ts +34 -0
  159. package/dist/compiler/schemaDeclarationPrimitives.d.ts.map +1 -0
  160. package/dist/compiler/schemaDeclarationPrimitives.js +194 -0
  161. package/dist/compiler/schemaDocumentSyntax.d.ts +55 -0
  162. package/dist/compiler/schemaDocumentSyntax.d.ts.map +1 -0
  163. package/dist/compiler/schemaDocumentSyntax.js +294 -0
  164. package/dist/compiler/schemaDurationLanguage.d.ts +11 -0
  165. package/dist/compiler/schemaDurationLanguage.d.ts.map +1 -0
  166. package/dist/compiler/schemaDurationLanguage.js +170 -0
  167. package/dist/compiler/schemaElementProperties.d.ts +16 -0
  168. package/dist/compiler/schemaElementProperties.d.ts.map +1 -0
  169. package/dist/compiler/schemaElementProperties.js +23 -0
  170. package/dist/compiler/schemaEndpointWordCapacity.d.ts +36 -0
  171. package/dist/compiler/schemaEndpointWordCapacity.d.ts.map +1 -0
  172. package/dist/compiler/schemaEndpointWordCapacity.js +39 -0
  173. package/dist/compiler/schemaExactCalendar.d.ts +73 -0
  174. package/dist/compiler/schemaExactCalendar.d.ts.map +1 -0
  175. package/dist/compiler/schemaExactCalendar.js +264 -0
  176. package/dist/compiler/schemaFacetAnnotation.d.ts +32 -0
  177. package/dist/compiler/schemaFacetAnnotation.d.ts.map +1 -0
  178. package/dist/compiler/schemaFacetAnnotation.js +199 -0
  179. package/dist/compiler/schemaGeneratedScalarShape.d.ts +35 -0
  180. package/dist/compiler/schemaGeneratedScalarShape.d.ts.map +1 -0
  181. package/dist/compiler/schemaGeneratedScalarShape.js +176 -0
  182. package/dist/compiler/schemaIdentityConstraints.d.ts +73 -0
  183. package/dist/compiler/schemaIdentityConstraints.d.ts.map +1 -0
  184. package/dist/compiler/schemaIdentityConstraints.js +362 -0
  185. package/dist/compiler/schemaIeeeLanguage.d.ts +43 -0
  186. package/dist/compiler/schemaIeeeLanguage.d.ts.map +1 -0
  187. package/dist/compiler/schemaIeeeLanguage.js +759 -0
  188. package/dist/compiler/schemaIntegerImages.d.ts +11 -0
  189. package/dist/compiler/schemaIntegerImages.d.ts.map +1 -0
  190. package/dist/compiler/schemaIntegerImages.js +113 -0
  191. package/dist/compiler/schemaLexicalPredicates.d.ts +29 -0
  192. package/dist/compiler/schemaLexicalPredicates.d.ts.map +1 -0
  193. package/dist/compiler/schemaLexicalPredicates.js +63 -0
  194. package/dist/compiler/schemaNotationProperties.d.ts +32 -0
  195. package/dist/compiler/schemaNotationProperties.d.ts.map +1 -0
  196. package/dist/compiler/schemaNotationProperties.js +84 -0
  197. package/dist/compiler/schemaNumericImageConditions.d.ts +24 -0
  198. package/dist/compiler/schemaNumericImageConditions.d.ts.map +1 -0
  199. package/dist/compiler/schemaNumericImageConditions.js +66 -0
  200. package/dist/compiler/schemaParticleWildcardProperties.d.ts +20 -0
  201. package/dist/compiler/schemaParticleWildcardProperties.d.ts.map +1 -0
  202. package/dist/compiler/schemaParticleWildcardProperties.js +43 -0
  203. package/dist/compiler/schemaPattern.d.ts +1062 -0
  204. package/dist/compiler/schemaPattern.d.ts.map +1 -0
  205. package/dist/compiler/schemaPattern.js +581 -0
  206. package/dist/compiler/schemaRegularLanguage.d.ts +67 -0
  207. package/dist/compiler/schemaRegularLanguage.d.ts.map +1 -0
  208. package/dist/compiler/schemaRegularLanguage.js +1166 -0
  209. package/dist/compiler/schemaScalarContext.d.ts +81 -0
  210. package/dist/compiler/schemaScalarContext.d.ts.map +1 -0
  211. package/dist/compiler/schemaScalarContext.js +78 -0
  212. package/dist/compiler/schemaScalarKernel.d.ts +182 -0
  213. package/dist/compiler/schemaScalarKernel.d.ts.map +1 -0
  214. package/dist/compiler/schemaScalarKernel.js +391 -0
  215. package/dist/compiler/schemaScalarWitnesses.d.ts +6 -0
  216. package/dist/compiler/schemaScalarWitnesses.d.ts.map +1 -0
  217. package/dist/compiler/schemaScalarWitnesses.js +118 -0
  218. package/dist/compiler/schemaSimpleTypeProperties.d.ts +95 -0
  219. package/dist/compiler/schemaSimpleTypeProperties.d.ts.map +1 -0
  220. package/dist/compiler/schemaSimpleTypeProperties.js +103 -0
  221. package/dist/compiler/schemaSourceGrammar.d.ts +27 -0
  222. package/dist/compiler/schemaSourceGrammar.d.ts.map +1 -0
  223. package/dist/compiler/schemaSourceGrammar.js +290 -0
  224. package/dist/compiler/schemaSourceLexical.d.ts +4 -0
  225. package/dist/compiler/schemaSourceLexical.d.ts.map +1 -0
  226. package/dist/compiler/schemaSourceLexical.js +12 -0
  227. package/dist/compiler/schemaSourceValues.d.ts +51 -0
  228. package/dist/compiler/schemaSourceValues.d.ts.map +1 -0
  229. package/dist/compiler/schemaSourceValues.js +225 -0
  230. package/dist/compiler/schemaSourceWildcards.d.ts +28 -0
  231. package/dist/compiler/schemaSourceWildcards.d.ts.map +1 -0
  232. package/dist/compiler/schemaSourceWildcards.js +247 -0
  233. package/dist/compiler/schemaSymbolicSequences.d.ts +16 -0
  234. package/dist/compiler/schemaSymbolicSequences.d.ts.map +1 -0
  235. package/dist/compiler/schemaSymbolicSequences.js +99 -0
  236. package/dist/compiler/schemaSymbolicValueSets.d.ts +32 -0
  237. package/dist/compiler/schemaSymbolicValueSets.d.ts.map +1 -0
  238. package/dist/compiler/schemaSymbolicValueSets.js +149 -0
  239. package/dist/compiler/schemaSyntaxAssessment.d.ts +25 -0
  240. package/dist/compiler/schemaSyntaxAssessment.d.ts.map +1 -0
  241. package/dist/compiler/schemaSyntaxAssessment.js +361 -0
  242. package/dist/compiler/schemaTemporalAliases.d.ts +6 -0
  243. package/dist/compiler/schemaTemporalAliases.d.ts.map +1 -0
  244. package/dist/compiler/schemaTemporalAliases.js +195 -0
  245. package/dist/compiler/schemaTokenImages.d.ts +9 -0
  246. package/dist/compiler/schemaTokenImages.d.ts.map +1 -0
  247. package/dist/compiler/schemaTokenImages.js +142 -0
  248. package/dist/compiler/schemaTypeIdentity.d.ts +39 -0
  249. package/dist/compiler/schemaTypeIdentity.d.ts.map +1 -0
  250. package/dist/compiler/schemaTypeIdentity.js +78 -0
  251. package/dist/compiler/schemaTypeRelations.d.ts +38 -0
  252. package/dist/compiler/schemaTypeRelations.d.ts.map +1 -0
  253. package/dist/compiler/schemaTypeRelations.js +576 -0
  254. package/dist/compiler/schemaUri.d.ts +13 -0
  255. package/dist/compiler/schemaUri.d.ts.map +1 -0
  256. package/dist/compiler/schemaUri.js +103 -0
  257. package/dist/compiler/schemaValueContext.d.ts +26 -0
  258. package/dist/compiler/schemaValueContext.d.ts.map +1 -0
  259. package/dist/compiler/schemaValueContext.js +1 -0
  260. package/dist/compiler/schemaValueImages.d.ts +10 -0
  261. package/dist/compiler/schemaValueImages.d.ts.map +1 -0
  262. package/dist/compiler/schemaValueImages.js +142 -0
  263. package/dist/compiler/schemaValueSequences.d.ts +15 -0
  264. package/dist/compiler/schemaValueSequences.d.ts.map +1 -0
  265. package/dist/compiler/schemaValueSequences.js +19 -0
  266. package/dist/compiler/semanticBudget.d.ts +50 -0
  267. package/dist/compiler/semanticBudget.d.ts.map +1 -0
  268. package/dist/compiler/semanticBudget.js +178 -0
  269. package/dist/compiler/semanticCatalog.d.ts +122 -0
  270. package/dist/compiler/semanticCatalog.d.ts.map +1 -0
  271. package/dist/compiler/semanticCatalog.js +160 -0
  272. package/dist/compiler/semanticContext.d.ts +172 -0
  273. package/dist/compiler/semanticContext.d.ts.map +1 -0
  274. package/dist/compiler/semanticContext.js +1168 -0
  275. package/dist/compiler/semanticTypeDependencies.d.ts +8 -0
  276. package/dist/compiler/semanticTypeDependencies.d.ts.map +1 -0
  277. package/dist/compiler/semanticTypeDependencies.js +64 -0
  278. package/dist/compiler/semanticTypeReference.d.ts +24 -0
  279. package/dist/compiler/semanticTypeReference.d.ts.map +1 -0
  280. package/dist/compiler/semanticTypeReference.js +36 -0
  281. package/dist/compiler/shapeResolver.d.ts +1 -0
  282. package/dist/compiler/shapeResolver.d.ts.map +1 -1
  283. package/dist/compiler/shapeResolver.js +7 -9
  284. package/dist/compiler/sourceSchemaBinding.d.ts +26 -0
  285. package/dist/compiler/sourceSchemaBinding.d.ts.map +1 -0
  286. package/dist/compiler/sourceSchemaBinding.js +39 -0
  287. package/dist/compiler/structuralCompanions.d.ts +16 -0
  288. package/dist/compiler/structuralCompanions.d.ts.map +1 -0
  289. package/dist/compiler/structuralCompanions.js +232 -0
  290. package/dist/compiler/validateSemanticGraph.d.ts +5 -0
  291. package/dist/compiler/validateSemanticGraph.d.ts.map +1 -0
  292. package/dist/compiler/validateSemanticGraph.js +376 -0
  293. package/dist/compiler/wildcardAlgebra.d.ts +26 -0
  294. package/dist/compiler/wildcardAlgebra.d.ts.map +1 -0
  295. package/dist/compiler/wildcardAlgebra.js +155 -0
  296. package/dist/gateway/generateGateway.d.ts.map +1 -1
  297. package/dist/gateway/generateGateway.js +2 -2
  298. package/dist/index.d.ts +3 -0
  299. package/dist/index.d.ts.map +1 -1
  300. package/dist/index.js +2 -0
  301. package/dist/loader/orderedSyntax.d.ts +77 -0
  302. package/dist/loader/orderedSyntax.d.ts.map +1 -0
  303. package/dist/loader/orderedSyntax.js +202 -0
  304. package/dist/loader/resolutionDepth.d.ts +7 -0
  305. package/dist/loader/resolutionDepth.d.ts.map +1 -0
  306. package/dist/loader/resolutionDepth.js +65 -0
  307. package/dist/loader/schemaInput.d.ts +53 -0
  308. package/dist/loader/schemaInput.d.ts.map +1 -0
  309. package/dist/loader/schemaInput.js +212 -0
  310. package/dist/loader/schemaResources.d.ts +59 -0
  311. package/dist/loader/schemaResources.d.ts.map +1 -0
  312. package/dist/loader/schemaResources.js +292 -0
  313. package/dist/openapi/generateOpenAPI.d.ts.map +1 -1
  314. package/dist/openapi/generateOpenAPI.js +2 -2
  315. package/dist/test/generateTests.d.ts.map +1 -1
  316. package/dist/test/generateTests.js +2 -2
  317. package/dist/util/xmlWhitespace.d.ts +3 -0
  318. package/dist/util/xmlWhitespace.d.ts.map +1 -0
  319. package/dist/util/xmlWhitespace.js +4 -0
  320. package/docs/README.md +14 -1
  321. package/docs/architecture.md +9 -0
  322. package/docs/cli-reference.md +21 -1
  323. package/docs/content-model-analysis.md +92 -0
  324. package/docs/content-model-baseline.md +121 -0
  325. package/docs/content-model-catalog.md +116 -0
  326. package/docs/content-model-companions.md +90 -0
  327. package/docs/content-model-composition.md +103 -0
  328. package/docs/content-model-decisions.md +79 -0
  329. package/docs/content-model-gateway-feasibility.md +169 -0
  330. package/docs/content-model-graph.md +121 -0
  331. package/docs/content-model-loading.md +163 -0
  332. package/docs/content-model-matching.md +85 -0
  333. package/docs/content-model-readiness.md +144 -0
  334. package/docs/content-model-resolution.md +81 -0
  335. package/docs/content-model-s02-handoff.md +98 -0
  336. package/docs/content-model-s06-au-01.md +425 -0
  337. package/docs/content-model-s06-dt-01.md +386 -0
  338. package/docs/content-model-s06-pw-01.md +350 -0
  339. package/docs/content-model-s06-re-01-resolver-implementation.md +869 -0
  340. package/docs/content-model-s06-re-01-resolver.md +513 -0
  341. package/docs/content-model-s06-re-01-scalar-witnesses.md +1423 -0
  342. package/docs/content-model-s06-re-01-support-reconstruction.md +6337 -0
  343. package/docs/content-model-s06-re-01.md +7477 -0
  344. package/docs/content-model-s06-research-handoff.md +909 -0
  345. package/docs/content-model-shipped-fix.md +83 -0
  346. package/docs/content-model-soap-feasibility.md +165 -0
  347. package/docs/decisions/002-streamable-responses.md +2 -0
  348. package/docs/decisions/003-content-model-contracts.md +280 -0
  349. package/docs/direct-values.md +311 -0
  350. package/docs/reference-validation.md +243 -0
  351. package/docs/releases/v1.1.5.md +38 -0
  352. package/docs/roadmap/README.md +2 -2
  353. package/docs/supported-patterns.md +13 -5
  354. package/package.json +26 -13
  355. package/src/generation/preambles/direct-client/typescript.preamble +3 -0
@@ -0,0 +1,195 @@
1
+ /** Complete fixed-value calendar aliases under the accepted DT A coordinates. */
2
+ import { showInstant } from './schemaExactCalendar.js';
3
+ export function* calendarAliasExpressions(calendar, owner, c) {
4
+ const budget = { charge: work => c.step(owner, work), text: text => { c.text(text, owner); },
5
+ arithmetic: digits => c.step(owner, (digits + 2) ** 2) };
6
+ const value = calendar.seconds;
7
+ budget.arithmetic(value.digits + value.scale + 4);
8
+ const power = 10n ** BigInt(value.scale);
9
+ const shifted = (seconds) => {
10
+ budget.arithmetic(value.digits + value.scale + 8);
11
+ c.step(owner, 4);
12
+ return { ...value, coefficient: value.coefficient + BigInt(seconds) * power };
13
+ };
14
+ const quote = (text) => {
15
+ c.text(text, owner);
16
+ c.step(owner, text.length * 2 + 1);
17
+ return text.replace(/[\\.\-^?*+{}()\[\]|]/g, '\\$&');
18
+ };
19
+ const two = (value) => { c.step(owner, 4); return value.toString().padStart(2, '0'); };
20
+ const offsets = function* () {
21
+ yield 0;
22
+ if (calendar.zoned)
23
+ for (let minute = 1; minute <= 840; minute++) {
24
+ c.step(owner, 2);
25
+ yield minute;
26
+ yield -minute;
27
+ }
28
+ };
29
+ const expression = (instant, zone, second60 = false, hour24 = false) => {
30
+ c.text(instant, owner);
31
+ c.step(owner, instant.length * 3 + 12);
32
+ const match = /^(-?[0-9]+)-([0-9]{2})-([0-9]{2})T([0-9]{2}):([0-9]{2}):([0-9]{2})(?:\.([0-9]+))?Z$/.exec(instant);
33
+ const [, year, month, day, h, m, s, fraction = ''] = match;
34
+ const hour = hour24 ? '24' : h, second = second60 ? '60' : s;
35
+ const suffix = fraction ? '[.]' + fraction + '0*' : '([.]0+)?';
36
+ const clock = hour + ':' + m + ':' + second;
37
+ const zeroClock = h === '00' && m === '00' && s === '00' && !fraction;
38
+ let text;
39
+ switch (calendar.family) {
40
+ case 'dateTime':
41
+ text = quote(year + '-' + month + '-' + day + 'T' + clock) + suffix;
42
+ break;
43
+ case 'time':
44
+ text = quote(clock) + suffix;
45
+ break;
46
+ case 'date':
47
+ if (!zeroClock)
48
+ return undefined;
49
+ text = quote(year + '-' + month + '-' + day);
50
+ break;
51
+ case 'gYear':
52
+ if (!zeroClock || month !== '01' || day !== '01')
53
+ return undefined;
54
+ text = quote(year);
55
+ break;
56
+ case 'gYearMonth':
57
+ if (!zeroClock || day !== '01')
58
+ return undefined;
59
+ text = quote(year + '-' + month);
60
+ break;
61
+ case 'gMonthDay':
62
+ if (!zeroClock || year !== '2000')
63
+ return undefined;
64
+ text = quote('--' + month + '-' + day);
65
+ break;
66
+ case 'gDay':
67
+ if (!zeroClock || year !== '2000' || month !== '01')
68
+ return undefined;
69
+ text = quote('---' + day);
70
+ break;
71
+ case 'gMonth':
72
+ if (!zeroClock || year !== '2000' || day !== '01')
73
+ return undefined;
74
+ text = quote('--' + month);
75
+ break;
76
+ }
77
+ c.step(owner, text.length + zone.length * 2 + 1);
78
+ return text + quote(zone);
79
+ };
80
+ for (const offset of offsets()) {
81
+ c.step(owner, 4);
82
+ const local = shifted(offset * 60), instant = showInstant(local, budget);
83
+ const zone = calendar.zoned ? (offset < 0 ? '-' : '+') + two(Math.floor(Math.abs(offset) / 60)) + ':' + two(Math.abs(offset) % 60) : '';
84
+ c.step(owner, 4);
85
+ const zones = calendar.zoned && offset === 0 ? ['Z', '+00:00', '-00:00'] : [zone];
86
+ for (const zone of zones) {
87
+ const normal = expression(instant, zone);
88
+ if (normal !== undefined)
89
+ yield normal;
90
+ if (calendar.family !== 'dateTime' && calendar.family !== 'time')
91
+ continue;
92
+ // Second 60 is an overflow into the next minute, including fractions.
93
+ if (/T[0-9]{2}:[0-9]{2}:00(?:\.[0-9]+)?Z$/.test(instant)) {
94
+ budget.arithmetic(local.digits + local.scale + 8);
95
+ c.step(owner, 4);
96
+ const priorMinute = showInstant({ ...local, coefficient: local.coefficient - 60n * power }, budget);
97
+ const overflow = expression(priorMinute, zone, true);
98
+ if (overflow !== undefined)
99
+ yield overflow;
100
+ }
101
+ if (/T00:00:00Z$/.test(instant)) {
102
+ budget.arithmetic(local.digits + local.scale + 8);
103
+ c.step(owner, 4);
104
+ const priorDay = showInstant({ ...local, coefficient: local.coefficient - 86400n * power }, budget);
105
+ const midnight = expression(priorDay, zone, false, true);
106
+ if (midnight !== undefined)
107
+ yield midnight;
108
+ }
109
+ }
110
+ }
111
+ }
112
+ /** Finite field decompositions, each with its complete infinite zero aliases. */
113
+ export function* durationAliasExpressions(duration, owner, c, canMatch) {
114
+ const digits = duration.digits + duration.seconds.scale + 8;
115
+ const arithmetic = () => c.step(owner, (digits + 2) ** 2);
116
+ arithmetic();
117
+ const months = duration.months < 0n ? -duration.months : duration.months;
118
+ const seconds = duration.seconds.coefficient < 0n ? -duration.seconds.coefficient : duration.seconds.coefficient;
119
+ const power = 10n ** BigInt(duration.seconds.scale), unit = 60n * power;
120
+ const sign = duration.months < 0n || duration.seconds.coefficient < 0n ? '\\-' : '';
121
+ const integer = (number) => { arithmetic(); c.step(owner, digits + 4); return number === 0n ? '0+' : '0*' + number; };
122
+ const field = (number, suffix) => {
123
+ const value = integer(number);
124
+ c.step(owner, value.length + 8);
125
+ return number === 0n ? '(' + value + suffix + ')?' : value + suffix;
126
+ };
127
+ const second = (coefficient) => {
128
+ arithmetic();
129
+ c.step(owner, digits * 4 + 8);
130
+ const whole = coefficient / power, remainder = coefficient % power;
131
+ const fraction = remainder === 0n ? '([.]0+)?' : '[.]' + remainder.toString().padStart(duration.seconds.scale, '0').replace(/0+$/, '') + '0*';
132
+ return integer(whole) + fraction + 'S';
133
+ };
134
+ const zeroTime = () => {
135
+ c.step(owner, 4);
136
+ const choices = [];
137
+ for (let mask = 1; mask < 8; mask++) {
138
+ c.step(owner, 64);
139
+ choices.push('T' + (mask & 1 ? '0+H' : '') + (mask & 2 ? '0+M' : '') + (mask & 4 ? '0+([.]0+)?S' : ''));
140
+ }
141
+ c.step(owner, 256);
142
+ return '(' + choices.join('|') + ')?';
143
+ };
144
+ const branch = (y, m, d, h, minute, remainder) => {
145
+ const prefix = sign + 'P' + field(y, 'Y') + field(m, 'M') + field(d, 'D');
146
+ c.step(owner, prefix.length + digits * 8 + 64);
147
+ return h === 0n && minute === 0n && remainder === 0n ? prefix + zeroTime()
148
+ : prefix + 'T' + field(h, 'H') + field(minute, 'M') + (remainder === 0n ? '(' + second(0n) + ')?' : second(remainder));
149
+ };
150
+ if (months === 0n && seconds === 0n) {
151
+ for (let mask = 1; mask < 64; mask++) {
152
+ c.step(owner, 96);
153
+ const date = (mask & 1 ? '0+Y' : '') + (mask & 2 ? '0+M' : '') + (mask & 4 ? '0+D' : '');
154
+ const time = (mask & 8 ? '0+H' : '') + (mask & 16 ? '0+M' : '') + (mask & 32 ? '0+([.]0+)?S' : '');
155
+ yield '\\-?P' + date + (time ? 'T' + time : '');
156
+ }
157
+ return;
158
+ }
159
+ // A conventional decomposition supplies a cheap complete-language branch
160
+ // before exhaustive finite alternatives; no failure of it proves absence.
161
+ arithmetic();
162
+ const y = months / 12n, m = months % 12n, d = seconds / (86400n * power);
163
+ const rest = seconds - d * 86400n * power, h = rest / (3600n * power), restHour = rest - h * 3600n * power;
164
+ const minute = restHour / unit;
165
+ yield branch(y, m, d, h, minute, restHour - minute * unit);
166
+ for (let year = 0n; year * 12n <= months; year++) {
167
+ arithmetic();
168
+ const month = months - year * 12n;
169
+ const datePrefix = sign + 'P' + field(year, 'Y') + field(month, 'M');
170
+ c.step(owner, datePrefix.length + 128);
171
+ if (!canMatch(datePrefix + '([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+([.][0-9]+)?S)?)?'))
172
+ continue;
173
+ for (let day = 0n; day * 86400n * power <= seconds; day++) {
174
+ arithmetic();
175
+ const remaining = seconds - day * 86400n * power, prefix = datePrefix + field(day, 'D');
176
+ c.step(owner, prefix.length + 96);
177
+ if (!canMatch(prefix + '(T([0-9]+H)?([0-9]+M)?([0-9]+([.][0-9]+)?S)?)?'))
178
+ continue;
179
+ for (let hour = 0n; hour * 3600n * power <= remaining; hour++) {
180
+ arithmetic();
181
+ const afterHour = remaining - hour * 3600n * power;
182
+ c.step(owner, prefix.length + digits * 4 + 96);
183
+ if (!canMatch(prefix + 'T' + field(hour, 'H') + '([0-9]+M)?([0-9]+([.][0-9]+)?S)?')) {
184
+ if (hour !== 0n || afterHour !== 0n)
185
+ continue;
186
+ }
187
+ for (let min = 0n; min * unit <= afterHour; min++) {
188
+ arithmetic();
189
+ const remainingSeconds = afterHour - min * unit;
190
+ yield branch(year, month, day, hour, min, remainingSeconds);
191
+ }
192
+ }
193
+ }
194
+ }
195
+ }
@@ -0,0 +1,9 @@
1
+ /** Finite token-boundary transducers with complete source-owned value labels. */
2
+ import type { SchemaPatternContext } from './schemaValueContext.js';
3
+ import type { RegularLanguage } from './schemaRegularLanguage.js';
4
+ import { schemaRegularLanguages } from './schemaRegularLanguage.js';
5
+ import type { SymbolicSequence } from './schemaSymbolicSequences.js';
6
+ export declare function schemaTokenImages<Owner, Label>(c: SchemaPatternContext<Owner>, regular: ReturnType<typeof schemaRegularLanguages<Owner>>, token: (owner: Owner) => RegularLanguage, labels: (paths: RegularLanguage, position: number, rejected: readonly number[], owner: Owner) => readonly Label[], whitespace: (codepoint: number, owner: Owner) => Label): {
7
+ image: (source: RegularLanguage, rejectedCount: number, maximumPosition: number, mode: "list" | "string", owner: Owner) => SymbolicSequence<Label>;
8
+ };
9
+ //# sourceMappingURL=schemaTokenImages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schemaTokenImages.d.ts","sourceRoot":"","sources":["../../src/compiler/schemaTokenImages.ts"],"names":[],"mappings":"AAAA,iFAAiF;AACjF,OAAO,KAAK,EAAC,oBAAoB,EAAC,MAAM,yBAAyB,CAAC;AAClE,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAC,sBAAsB,EAAC,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,8BAA8B,CAAC;AAEnE,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,oBAAoB,CAAC,KAAK,CAAC,EAAE,OAAO,EAAE,UAAU,CAAC,OAAO,sBAAsB,CAAC,KAAK,CAAC,CAAC,EACvI,KAAK,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,eAAe,EACxC,MAAM,EAAE,CAAC,KAAK,EAAE,eAAe,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,SAAS,MAAM,EAAE,EAAE,KAAK,EAAE,KAAK,KAAK,SAAS,KAAK,EAAE,EACjH,UAAU,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,KAAK,KAAK;oBAC/B,eAAe,iBAAiB,MAAM,mBAAmB,MAAM,QAAQ,MAAM,GAAG,QAAQ,SAAS,KAAK,KAAG,gBAAgB,CAAC,KAAK,CAAC;EAmExJ"}
@@ -0,0 +1,142 @@
1
+ import { schemaRegularLanguages } from './schemaRegularLanguage.js';
2
+ export function schemaTokenImages(c, regular, token, labels, whitespace) {
3
+ const image = (source, rejectedCount, maximumPosition, mode, owner) => {
4
+ const program = regular.automaton(source, owner), tokenDomain = token(owner);
5
+ const maskCost = Math.min(Number.MAX_SAFE_INTEGER, (rejectedCount + 4) ** 2);
6
+ const masks = (operations = 1) => c.step(owner, Math.min(Number.MAX_SAFE_INTEGER, maskCost * operations));
7
+ c.step(owner, rejectedCount + 16);
8
+ masks(2);
9
+ const all = (1n << BigInt(rejectedCount)) - 1n;
10
+ const inputs = [], states = [], known = new Map();
11
+ const intern = (state) => {
12
+ c.step(owner, 64);
13
+ masks(2);
14
+ const key = state.at + ':' + state.failed + ':' + state.position + ':' + state.after, before = known.get(key);
15
+ if (before !== undefined)
16
+ return before;
17
+ c.step(owner, 6);
18
+ const index = states.length;
19
+ known.set(key, index);
20
+ inputs.push(state);
21
+ states.push({ accepting: program.states[state.at].accepting && state.failed === all, edges: [] });
22
+ return index;
23
+ };
24
+ const start = intern({ at: program.start, failed: 0n, position: 0, after: false });
25
+ const gaps = [9, 10, 13, 32];
26
+ c.step(owner, program.states.length * 3 + 6);
27
+ const pathCache = new Map(), labelCache = new WeakMap();
28
+ const incoming = program.states.map(() => []), productive = new Set(), pending = [];
29
+ for (let at = 0; at < program.states.length; at++) {
30
+ if (program.states[at].accepting) {
31
+ c.step(owner, 2);
32
+ productive.add(at);
33
+ pending.push(at);
34
+ }
35
+ for (const edge of program.states[at].transitions) {
36
+ c.step(owner);
37
+ incoming[edge.to].push(at);
38
+ }
39
+ }
40
+ while (pending.length)
41
+ for (const at of incoming[pending.pop()]) {
42
+ c.step(owner);
43
+ if (!productive.has(at)) {
44
+ c.step(owner, 2);
45
+ productive.add(at);
46
+ pending.push(at);
47
+ }
48
+ }
49
+ for (let cursor = 0; cursor < inputs.length; cursor++) {
50
+ const from = inputs[cursor];
51
+ c.step(owner);
52
+ if (mode === 'string')
53
+ for (const edge of program.states[from.at].transitions)
54
+ for (const cp of gaps) {
55
+ c.step(owner);
56
+ if (cp < edge.lo || cp > edge.hi)
57
+ continue;
58
+ const to = intern({ ...from, at: edge.to, after: false });
59
+ c.step(owner, 3);
60
+ states[cursor].edges.push({ to, label: whitespace(cp, owner) });
61
+ }
62
+ if (from.after)
63
+ continue;
64
+ for (let end = 0; end < program.states.length; end++) {
65
+ c.step(owner);
66
+ const endpoint = program.states[end];
67
+ if (!productive.has(end))
68
+ continue;
69
+ if (!endpoint.accepting && !endpoint.transitions.some(edge => gaps.some(cp => edge.lo <= cp && edge.hi >= cp)))
70
+ continue;
71
+ c.step(owner, 32);
72
+ const key = from.at + ':' + end;
73
+ let paths = pathCache.get(key);
74
+ if (!paths) {
75
+ paths = regular.intersect([regular.paths(program, [from.at], new Set([end]), owner), tokenDomain], owner);
76
+ c.step(owner, 2);
77
+ pathCache.set(key, paths);
78
+ }
79
+ if (regular.witness(paths, owner) === undefined)
80
+ continue;
81
+ c.step(owner, rejectedCount * 3 + 6);
82
+ const missing = [];
83
+ for (let bit = 0; bit < rejectedCount; bit++) {
84
+ masks(2);
85
+ if (!(from.failed & (1n << BigInt(bit))))
86
+ missing.push(bit);
87
+ }
88
+ masks();
89
+ const limit = 1n << BigInt(missing.length);
90
+ for (let mask = 0n; mask < limit;) {
91
+ c.step(owner, missing.length * 3 + 6);
92
+ const rejected = [];
93
+ let failed = from.failed;
94
+ for (let bit = 0; bit < missing.length; bit++) {
95
+ masks(2);
96
+ if (mask & (1n << BigInt(bit))) {
97
+ rejected.push(missing[bit]);
98
+ masks(2);
99
+ failed |= 1n << BigInt(missing[bit]);
100
+ }
101
+ }
102
+ masks();
103
+ mask++;
104
+ c.step(owner, rejected.length * 16 + 6);
105
+ const labelKey = from.position + ':' + JSON.stringify(rejected);
106
+ let table = labelCache.get(paths);
107
+ if (!table) {
108
+ c.step(owner, 2);
109
+ table = new Map();
110
+ labelCache.set(paths, table);
111
+ }
112
+ let selected = table.get(labelKey);
113
+ if (!selected) {
114
+ selected = labels(paths, from.position, rejected, owner);
115
+ c.step(owner, 2);
116
+ table.set(labelKey, selected);
117
+ }
118
+ if (!selected.length)
119
+ continue;
120
+ const position = Math.min(maximumPosition, from.position + 1), destinations = [];
121
+ if (mode === 'string')
122
+ destinations.push(intern({ at: end, failed, position, after: true }));
123
+ else {
124
+ if (endpoint.accepting)
125
+ destinations.push(intern({ at: end, failed, position, after: true }));
126
+ for (const edge of endpoint.transitions) {
127
+ c.step(owner);
128
+ if (edge.lo <= 32 && edge.hi >= 32)
129
+ destinations.push(intern({ at: edge.to, failed, position, after: false }));
130
+ }
131
+ }
132
+ c.step(owner, destinations.length * selected.length * 3 + 2);
133
+ for (const to of destinations)
134
+ for (const label of selected)
135
+ states[cursor].edges.push({ to, label });
136
+ }
137
+ }
138
+ }
139
+ return { start, states };
140
+ };
141
+ return { image };
142
+ }
@@ -0,0 +1,39 @@
1
+ /** Internal semantic type identities. Call within the shared request guard. */
2
+ import type { AttributeNode, ComplexTypeNode, ElementNode, NodeId, SimpleTypeNode } from './canonicalGraph.js';
3
+ import type { ExpandedName } from '../loader/orderedSyntax.js';
4
+ import type { SemanticContext } from './semanticContext.js';
5
+ import type { OriginalGeneratedScalarReference, SemanticTypeIdentity, SemanticTypeReference } from './semanticTypeReference.js';
6
+ export type SemanticTypeResolution = Readonly<{
7
+ kind: 'component';
8
+ node: SimpleTypeNode | ComplexTypeNode;
9
+ identity: Readonly<{
10
+ kind: 'component';
11
+ id: NodeId;
12
+ }>;
13
+ }> | Readonly<{
14
+ kind: 'builtin';
15
+ name: ExpandedName;
16
+ identity: Readonly<{
17
+ kind: 'builtin';
18
+ name: ExpandedName;
19
+ }>;
20
+ }> | Readonly<{
21
+ kind: 'original-generated';
22
+ slot: OriginalGeneratedScalarReference;
23
+ identity: OriginalGeneratedScalarReference;
24
+ }> | Readonly<{
25
+ kind: 'missing';
26
+ reference: SemanticTypeReference;
27
+ }> | Readonly<{
28
+ kind: 'outside-context';
29
+ reference: SemanticTypeReference;
30
+ }> | Readonly<{
31
+ kind: 'wrong-role';
32
+ reference: SemanticTypeReference;
33
+ component: NodeId;
34
+ }>;
35
+ export declare function resolveSemanticType(context: SemanticContext, reference: SemanticTypeReference): SemanticTypeResolution;
36
+ export declare function declaredType(context: SemanticContext, node: ElementNode | AttributeNode): SemanticTypeReference;
37
+ /** Collision-free key only; supplied identity data is not lookup authority. */
38
+ export declare function semanticTypeKey(context: SemanticContext, identity: SemanticTypeIdentity): string;
39
+ //# sourceMappingURL=schemaTypeIdentity.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schemaTypeIdentity.d.ts","sourceRoot":"","sources":["../../src/compiler/schemaTypeIdentity.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAC/E,OAAO,KAAK,EAAC,aAAa,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,EAAE,cAAc,EAAC,MAAM,qBAAqB,CAAC;AAE7G,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,4BAA4B,CAAC;AAG7D,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,sBAAsB,CAAC;AAC1D,OAAO,KAAK,EAAC,gCAAgC,EAAE,oBAAoB,EAAE,qBAAqB,EAAC,MAAM,4BAA4B,CAAC;AAE9H,MAAM,MAAM,sBAAsB,GAC9B,QAAQ,CAAC;IAAC,IAAI,EAAE,WAAW,CAAC;IAAC,IAAI,EAAE,cAAc,GAAG,eAAe,CAAC;IAAC,QAAQ,EAAE,QAAQ,CAAC;QAAC,IAAI,EAAE,WAAW,CAAC;QAAC,EAAE,EAAE,MAAM,CAAA;KAAC,CAAC,CAAA;CAAC,CAAC,GAC1H,QAAQ,CAAC;IAAC,IAAI,EAAE,SAAS,CAAC;IAAC,IAAI,EAAE,YAAY,CAAC;IAAC,QAAQ,EAAE,QAAQ,CAAC;QAAC,IAAI,EAAE,SAAS,CAAC;QAAC,IAAI,EAAE,YAAY,CAAA;KAAC,CAAC,CAAA;CAAC,CAAC,GAC1G,QAAQ,CAAC;IAAC,IAAI,EAAE,oBAAoB,CAAC;IAAC,IAAI,EAAE,gCAAgC,CAAC;IAAC,QAAQ,EAAE,gCAAgC,CAAA;CAAC,CAAC,GAC1H,QAAQ,CAAC;IAAC,IAAI,EAAE,SAAS,CAAC;IAAC,SAAS,EAAE,qBAAqB,CAAA;CAAC,CAAC,GAC7D,QAAQ,CAAC;IAAC,IAAI,EAAE,iBAAiB,CAAC;IAAC,SAAS,EAAE,qBAAqB,CAAA;CAAC,CAAC,GACrE,QAAQ,CAAC;IAAC,IAAI,EAAE,YAAY,CAAC;IAAC,SAAS,EAAE,qBAAqB,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAC,CAAC,CAAC;AAExF,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,eAAe,EAAE,SAAS,EAAE,qBAAqB,GAAG,sBAAsB,CAoBtH;AAED,wBAAgB,YAAY,CAAC,OAAO,EAAE,eAAe,EAAE,IAAI,EAAE,WAAW,GAAG,aAAa,GAAG,qBAAqB,CAS/G;AAeD,+EAA+E;AAC/E,wBAAgB,eAAe,CAAC,OAAO,EAAC,eAAe,EAAC,QAAQ,EAAC,oBAAoB,GAAE,MAAM,CAU5F"}
@@ -0,0 +1,78 @@
1
+ import { isBuiltinType } from './canonicalGraph.js';
2
+ import { XSD_NAMESPACE } from '../loader/orderedSyntax.js';
3
+ import { assertSemanticContext, SemanticContextAccessError } from './semanticContext.js';
4
+ export function resolveSemanticType(context, reference) {
5
+ assertSemanticContext(context);
6
+ const budget = context.budget;
7
+ const kind = ownField(context, reference, 'kind');
8
+ budget.chargeWork(8);
9
+ if (kind === 'original-generated') {
10
+ const found = context.lookupScalarSlot(reference);
11
+ return found.kind === 'found' ? Object.freeze({ kind: 'original-generated', slot: found.slot, identity: found.slot })
12
+ : Object.freeze({ kind: found.kind, reference: budget.freeze(budget.snapshot(reference)) });
13
+ }
14
+ let found;
15
+ try {
16
+ found = context.resolve(reference);
17
+ }
18
+ catch (error) {
19
+ if (error instanceof SemanticContextAccessError && error.code === 'reference') {
20
+ budget.chargeWork(4);
21
+ throw new TypeError('Malformed semantic type reference');
22
+ }
23
+ throw error;
24
+ }
25
+ if (found.kind === 'builtin') {
26
+ if (found.name.namespace !== XSD_NAMESPACE || !isBuiltinType(found.name.local))
27
+ throw new TypeError('Unknown builtin type');
28
+ return Object.freeze({ kind: 'builtin', name: found.name, identity: Object.freeze({ kind: 'builtin', name: found.name }) });
29
+ }
30
+ if (found.kind !== 'found')
31
+ return Object.freeze({ kind: found.kind, reference: budget.freeze(budget.snapshot(reference)) });
32
+ if (context.originalSourceComponentAbsent(found.node.id) || found.node.kind !== 'simpleType' && found.node.kind !== 'complexType')
33
+ return Object.freeze({ kind: 'wrong-role', reference: budget.freeze(budget.snapshot(reference)), component: found.node.id });
34
+ return Object.freeze({ kind: 'component', node: found.node, identity: Object.freeze({ kind: 'component', id: found.node.id }) });
35
+ }
36
+ export function declaredType(context, node) {
37
+ assertSemanticContext(context);
38
+ context.budget.chargeWork(48);
39
+ const field = node && typeof node === 'object' ? Object.getOwnPropertyDescriptor(node, 'id') : undefined;
40
+ if (!field || !('value' in field) || typeof field.value !== 'string')
41
+ throw new TypeError('Unauthenticated declaration');
42
+ const found = context.lookup(field.value);
43
+ if (found.kind !== 'found' || found.node !== node || node.kind !== 'element' && node.kind !== 'attribute')
44
+ throw new TypeError('Unauthenticated declaration');
45
+ return node.kind === 'element' ? context.rawElementProperties(node.id)?.type ?? node.type
46
+ : context.rawAttributeProperties(node.id)?.type ?? node.type;
47
+ }
48
+ /** Own primitive data only: a key cannot establish membership or validity. */
49
+ function ownField(context, value, name) {
50
+ context.budget.chargeWork(56 + name.length);
51
+ if (!value || typeof value !== 'object')
52
+ throw new TypeError('Expected own semantic identity data');
53
+ const field = Object.getOwnPropertyDescriptor(value, name);
54
+ if (!field || !('value' in field))
55
+ throw new TypeError('Semantic identity fields must be own data');
56
+ return field.value;
57
+ }
58
+ function stringField(context, value, name) {
59
+ const field = ownField(context, value, name);
60
+ if (typeof field !== 'string')
61
+ throw new TypeError('Semantic identity field must be a string');
62
+ return field;
63
+ }
64
+ /** Collision-free key only; supplied identity data is not lookup authority. */
65
+ export function semanticTypeKey(context, identity) {
66
+ assertSemanticContext(context);
67
+ const budget = context.budget, kind = stringField(context, identity, 'kind');
68
+ if (kind === 'component' || kind === 'original-generated') {
69
+ const id = stringField(context, identity, kind === 'component' ? 'id' : 'owner');
70
+ budget.chargeWork(id.length * 2 + 20);
71
+ return (kind === 'component' ? 'component:' : 'generated:') + id.length + ':' + id;
72
+ }
73
+ if (kind !== 'builtin')
74
+ throw new TypeError('Malformed semantic type identity');
75
+ const name = ownField(context, identity, 'name'), namespace = stringField(context, name, 'namespace'), local = stringField(context, name, 'local');
76
+ budget.chargeWork((namespace.length + local.length) * 2 + 20);
77
+ return 'builtin:' + namespace.length + ':' + namespace + ':' + local.length + ':' + local;
78
+ }
@@ -0,0 +1,38 @@
1
+ import type { SemanticTypeReference as Reference, SemanticTypeDependency } from './semanticTypeReference.js';
2
+ /** XSD 1.0 dated local relations. Success never certifies component/schema validity. */
3
+ import type { GraphNode, NodeId } from './canonicalGraph.js';
4
+ import type { SemanticContext } from './semanticContext.js';
5
+ import type { ResourceLimitFailure } from './semanticBudget.js';
6
+ export type DerivationMethod = 'extension' | 'restriction' | 'list' | 'union';
7
+ export type RelationReceipt<T = boolean> = Readonly<{
8
+ kind: 'checked';
9
+ value: T;
10
+ contextId: string;
11
+ authority: 'XSD10-local-relations-v1';
12
+ obligations: readonly ('component-validity' | 'complete-substitution-universe')[];
13
+ dependencies: readonly string[];
14
+ typeDependencies: readonly SemanticTypeDependency[];
15
+ }>;
16
+ export type RelationFailure = Readonly<{
17
+ kind: 'unresolved' | 'invalid-input';
18
+ rule: string;
19
+ component?: string;
20
+ message: string;
21
+ }>;
22
+ export type RelationResult<T = boolean> = RelationReceipt<T> | RelationFailure | ResourceLimitFailure;
23
+ export type SubstitutionOptions = Readonly<{
24
+ mode: 'affiliation' | 'substitutability';
25
+ blocking?: readonly ('extension' | 'restriction' | 'substitution')[];
26
+ }>;
27
+ export declare class RelationProblem extends Error {
28
+ readonly result: RelationFailure;
29
+ constructor(result: RelationFailure);
30
+ }
31
+ /** The graph mapping owns legal syntax; this parser diagnoses token-list errors locally. */
32
+ export declare function declarationMethods(context: SemanticContext, node: GraphNode, property: 'final' | 'block'): readonly (DerivationMethod | 'substitution')[];
33
+ export declare const checkTypeDerivation: (context: SemanticContext, derived: Reference, base: Reference, excluded: readonly DerivationMethod[]) => RelationResult;
34
+ export declare const checkImmediateTypeFinal: (context: SemanticContext, derived: Reference) => RelationResult;
35
+ export declare const immediateTypeBase: (context: SemanticContext, reference: Reference) => RelationResult<Reference | undefined>;
36
+ export declare const checkSubstitution: (context: SemanticContext, member: NodeId, head: NodeId, options: SubstitutionOptions) => RelationResult;
37
+ export declare const effectiveSubstitutionMembers: (context: SemanticContext, head: NodeId) => RelationResult<readonly NodeId[]>;
38
+ //# sourceMappingURL=schemaTypeRelations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schemaTypeRelations.d.ts","sourceRoot":"","sources":["../../src/compiler/schemaTypeRelations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,qBAAqB,IAAI,SAAS,EAAE,sBAAsB,EAAmC,MAAM,4BAA4B,CAAC;AAC7I,wFAAwF;AACxF,OAAO,KAAK,EAAc,SAAS,EAAE,MAAM,EAAC,MAAM,qBAAqB,CAAC;AAMxE,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,sBAAsB,CAAC;AAE1D,OAAO,KAAK,EAAC,oBAAoB,EAAC,MAAM,qBAAqB,CAAC;AAE9D,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,aAAa,GAAG,MAAM,GAAG,OAAO,CAAC;AAC9E,MAAM,MAAM,eAAe,CAAC,CAAC,GAAG,OAAO,IAAI,QAAQ,CAAC;IAAC,IAAI,EAAE,SAAS,CAAC;IAAC,KAAK,EAAE,CAAC,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAChG,SAAS,EAAE,0BAA0B,CAAC;IAAC,WAAW,EAAE,SAAS,CAAC,oBAAoB,GAAG,gCAAgC,CAAC,EAAE,CAAC;IAAC,YAAY,EAAE,SAAS,MAAM,EAAE,CAAC;IAAC,gBAAgB,EAAE,SAAS,sBAAsB,EAAE,CAAA;CAAC,CAAC,CAAC;AACnN,MAAM,MAAM,eAAe,GAAG,QAAQ,CAAC;IAAC,IAAI,EAAE,YAAY,GAAG,eAAe,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAC,CAAC,CAAC;AAClI,MAAM,MAAM,cAAc,CAAC,CAAC,GAAG,OAAO,IAAI,eAAe,CAAC,CAAC,CAAC,GAAG,eAAe,GAAG,oBAAoB,CAAC;AACtG,MAAM,MAAM,mBAAmB,GAAG,QAAQ,CAAC;IAAC,IAAI,EAAE,aAAa,GAAG,kBAAkB,CAAC;IAAC,QAAQ,CAAC,EAAE,SAAS,CAAC,WAAW,GAAG,aAAa,GAAG,cAAc,CAAC,EAAE,CAAA;CAAC,CAAC,CAAC;AAS7J,qBAAa,eAAgB,SAAQ,KAAK;IAC5B,QAAQ,CAAC,MAAM,EAAE,eAAe;gBAAvB,MAAM,EAAE,eAAe;CAC7C;AACD,4FAA4F;AAC5F,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,eAAe,EAAE,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,GAAG,OAAO,GAAG,SAAS,CAAC,gBAAgB,GAAG,cAAc,CAAC,EAAE,CAwBzJ;AA2WD,eAAO,MAAM,mBAAmB,GAAI,SAAS,eAAe,EAAE,SAAS,SAAS,EAAE,MAAM,SAAS,EAAE,UAAU,SAAS,gBAAgB,EAAE,KAAG,cACrE,CAAC;AACvE,eAAO,MAAM,uBAAuB,GAAI,SAAS,eAAe,EAAE,SAAS,SAAS,KAAG,cAAsE,CAAC;AAC9J,eAAO,MAAM,iBAAiB,GAAI,SAAS,eAAe,EAAE,WAAW,SAAS,KAAG,cAAc,CAAC,SAAS,GAAG,SAAS,CAA0D,CAAC;AAClL,eAAO,MAAM,iBAAiB,GAAI,SAAS,eAAe,EAAE,QAAQ,MAAM,EAAE,MAAM,MAAM,EAAE,SAAS,mBAAmB,KAAG,cACvD,CAAC;AACnE,eAAO,MAAM,4BAA4B,GAAI,SAAS,eAAe,EAAE,MAAM,MAAM,KAAG,cAAc,CAAC,SAAS,MAAM,EAAE,CAA+K,CAAC"}