@shaclmate/compiler 4.0.50 → 4.0.51

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 (599) hide show
  1. package/dist/Compiler.d.ts +14 -0
  2. package/dist/Compiler.js +18 -0
  3. package/dist/Eithers.d.ts +14 -0
  4. package/dist/Eithers.js +67 -0
  5. package/dist/ShapesGraphToAstTransformer.d.ts +18 -0
  6. package/dist/ShapesGraphToAstTransformer.js +50 -0
  7. package/dist/_ShapesGraphToAstTransformer/ShapeStack.d.ts +15 -0
  8. package/dist/_ShapesGraphToAstTransformer/ShapeStack.js +51 -0
  9. package/dist/_ShapesGraphToAstTransformer/defaultNodeShapeNodeKinds.d.ts +3 -0
  10. package/dist/_ShapesGraphToAstTransformer/defaultNodeShapeNodeKinds.js +5 -0
  11. package/dist/_ShapesGraphToAstTransformer/shapeAstTypeName.d.ts +4 -0
  12. package/dist/_ShapesGraphToAstTransformer/shapeAstTypeName.js +24 -0
  13. package/dist/_ShapesGraphToAstTransformer/shapeNodeKinds.d.ts +9 -0
  14. package/dist/_ShapesGraphToAstTransformer/shapeNodeKinds.js +150 -0
  15. package/dist/_ShapesGraphToAstTransformer/shapeOntology.d.ts +5 -0
  16. package/dist/_ShapesGraphToAstTransformer/shapeOntology.js +26 -0
  17. package/dist/_ShapesGraphToAstTransformer/transformPropertyShapeToAstStructTypeField.d.ts +17 -0
  18. package/dist/_ShapesGraphToAstTransformer/transformPropertyShapeToAstStructTypeField.js +285 -0
  19. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstCompoundType.d.ts +10 -0
  20. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstCompoundType.js +92 -0
  21. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstListType.d.ts +11 -0
  22. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstListType.js +149 -0
  23. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstStructType.d.ts +7 -0
  24. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstStructType.js +171 -0
  25. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstTermType.d.ts +12 -0
  26. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstTermType.js +110 -0
  27. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstType.d.ts +11 -0
  28. package/dist/_ShapesGraphToAstTransformer/transformShapeToAstType.js +46 -0
  29. package/dist/ast/AbstractCollectionType.d.ts +30 -0
  30. package/dist/ast/AbstractCollectionType.js +33 -0
  31. package/dist/ast/AbstractCompoundType.d.ts +45 -0
  32. package/dist/ast/AbstractCompoundType.js +81 -0
  33. package/dist/ast/AbstractContainerType.d.ts +44 -0
  34. package/dist/ast/AbstractContainerType.js +63 -0
  35. package/dist/ast/AbstractLazyType.d.ts +117 -0
  36. package/dist/ast/AbstractLazyType.js +40 -0
  37. package/dist/ast/AbstractTermType.d.ts +33 -0
  38. package/dist/ast/AbstractTermType.js +47 -0
  39. package/dist/ast/AbstractType.d.ts +55 -0
  40. package/dist/ast/AbstractType.js +55 -0
  41. package/dist/ast/Ast.d.ts +6 -0
  42. package/dist/ast/Ast.js +2 -0
  43. package/dist/ast/BlankNodeType.d.ts +11 -0
  44. package/dist/ast/BlankNodeType.js +17 -0
  45. package/dist/ast/DefaultValueType.d.ts +35 -0
  46. package/dist/ast/DefaultValueType.js +50 -0
  47. package/dist/ast/IdentifierType.d.ts +12 -0
  48. package/dist/ast/IdentifierType.js +20 -0
  49. package/dist/ast/IntersectionType.d.ts +14 -0
  50. package/dist/ast/IntersectionType.js +17 -0
  51. package/dist/ast/IriType.d.ts +10 -0
  52. package/dist/ast/IriType.js +10 -0
  53. package/dist/ast/LazyOptionType.d.ts +6 -0
  54. package/dist/ast/LazyOptionType.js +5 -0
  55. package/dist/ast/LazySetType.d.ts +6 -0
  56. package/dist/ast/LazySetType.js +5 -0
  57. package/dist/ast/LazyType.d.ts +5 -0
  58. package/dist/ast/LazyType.js +5 -0
  59. package/dist/ast/ListType.d.ts +44 -0
  60. package/dist/ast/ListType.js +56 -0
  61. package/dist/ast/LiteralType.d.ts +40 -0
  62. package/dist/ast/LiteralType.js +59 -0
  63. package/dist/ast/OptionType.d.ts +13 -0
  64. package/dist/ast/OptionType.js +21 -0
  65. package/dist/ast/SetType.d.ts +31 -0
  66. package/dist/ast/SetType.js +42 -0
  67. package/dist/ast/StructCompoundType.d.ts +12 -0
  68. package/dist/ast/StructCompoundType.js +87 -0
  69. package/dist/ast/StructIntersectionType.d.ts +4 -0
  70. package/dist/ast/StructIntersectionType.js +2 -0
  71. package/dist/ast/StructType.d.ts +178 -0
  72. package/dist/ast/StructType.js +314 -0
  73. package/dist/ast/StructUnionType.d.ts +4 -0
  74. package/dist/ast/StructUnionType.js +2 -0
  75. package/dist/ast/TermType.d.ts +14 -0
  76. package/dist/ast/TermType.js +16 -0
  77. package/dist/ast/Type.d.ts +20 -0
  78. package/dist/ast/Type.js +42 -0
  79. package/dist/ast/UnionType.d.ts +30 -0
  80. package/dist/ast/UnionType.js +27 -0
  81. package/dist/ast/equals.d.ts +12 -0
  82. package/dist/ast/equals.js +65 -0
  83. package/dist/ast/index.d.ts +21 -0
  84. package/dist/ast/index.js +21 -0
  85. package/dist/generators/AstJsonGenerator.d.ts +6 -0
  86. package/dist/generators/AstJsonGenerator.js +15 -0
  87. package/dist/generators/Cx2Generator.d.ts +10 -0
  88. package/dist/generators/Cx2Generator.js +140 -0
  89. package/dist/generators/Generator.d.ts +5 -0
  90. package/dist/generators/Generator.js +2 -0
  91. package/dist/generators/LabeledPropertyGraph.d.ts +42 -0
  92. package/dist/generators/LabeledPropertyGraph.js +2 -0
  93. package/dist/generators/index.d.ts +6 -0
  94. package/dist/generators/index.js +6 -0
  95. package/dist/generators/transformAstToLabeledPropertyGraph.d.ts +4 -0
  96. package/dist/generators/transformAstToLabeledPropertyGraph.js +78 -0
  97. package/dist/generators/ts/AbstractCollectionType.d.ts +37 -0
  98. package/dist/generators/ts/AbstractCollectionType.js +88 -0
  99. package/dist/generators/ts/AbstractContainerType.d.ts +53 -0
  100. package/dist/generators/ts/AbstractContainerType.js +97 -0
  101. package/dist/generators/ts/AbstractDateType.d.ts +23 -0
  102. package/dist/generators/ts/AbstractDateType.js +37 -0
  103. package/dist/generators/ts/AbstractIdentifierType.d.ts +21 -0
  104. package/dist/generators/ts/AbstractIdentifierType.js +25 -0
  105. package/dist/generators/ts/AbstractLazyType.d.ts +67 -0
  106. package/dist/generators/ts/AbstractLazyType.js +154 -0
  107. package/dist/generators/ts/AbstractLiteralType.d.ts +26 -0
  108. package/dist/generators/ts/AbstractLiteralType.js +15 -0
  109. package/dist/generators/ts/AbstractNumericType.d.ts +21 -0
  110. package/dist/generators/ts/AbstractNumericType.js +65 -0
  111. package/dist/generators/ts/AbstractObjectSetType.d.ts +36 -0
  112. package/dist/generators/ts/AbstractObjectSetType.js +44 -0
  113. package/dist/generators/ts/AbstractPrimitiveType.d.ts +32 -0
  114. package/dist/generators/ts/AbstractPrimitiveType.js +51 -0
  115. package/dist/generators/ts/AbstractTermType.d.ts +50 -0
  116. package/dist/generators/ts/AbstractTermType.js +102 -0
  117. package/dist/generators/ts/AbstractType.d.ts +345 -0
  118. package/dist/generators/ts/AbstractType.js +135 -0
  119. package/dist/generators/ts/BigDecimalType.d.ts +28 -0
  120. package/dist/generators/ts/BigDecimalType.js +58 -0
  121. package/dist/generators/ts/BigIntType.d.ts +17 -0
  122. package/dist/generators/ts/BigIntType.js +56 -0
  123. package/dist/generators/ts/BlankNodeType.d.ts +22 -0
  124. package/dist/generators/ts/BlankNodeType.js +67 -0
  125. package/dist/generators/ts/BooleanType.d.ts +21 -0
  126. package/dist/generators/ts/BooleanType.js +53 -0
  127. package/dist/generators/ts/DateTimeType.d.ts +13 -0
  128. package/dist/generators/ts/DateTimeType.js +31 -0
  129. package/dist/generators/ts/DateType.d.ts +14 -0
  130. package/dist/generators/ts/DateType.js +32 -0
  131. package/dist/generators/ts/DefaultValueType.d.ts +83 -0
  132. package/dist/generators/ts/DefaultValueType.js +143 -0
  133. package/dist/generators/ts/FloatType.d.ts +13 -0
  134. package/dist/generators/ts/FloatType.js +30 -0
  135. package/dist/generators/ts/GraphqlSchema.d.ts +22 -0
  136. package/dist/generators/ts/GraphqlSchema.js +87 -0
  137. package/dist/generators/ts/IdentifierType.d.ts +23 -0
  138. package/dist/generators/ts/IdentifierType.js +83 -0
  139. package/dist/generators/ts/Imports.d.ts +40 -0
  140. package/dist/generators/ts/Imports.js +41 -0
  141. package/dist/generators/ts/IntType.d.ts +13 -0
  142. package/dist/generators/ts/IntType.js +30 -0
  143. package/dist/generators/ts/IriType.d.ts +23 -0
  144. package/dist/generators/ts/IriType.js +112 -0
  145. package/dist/generators/ts/LazyOptionType.d.ts +36 -0
  146. package/dist/generators/ts/LazyOptionType.js +75 -0
  147. package/dist/generators/ts/LazySetType.d.ts +20 -0
  148. package/dist/generators/ts/LazySetType.js +76 -0
  149. package/dist/generators/ts/LazyType.d.ts +19 -0
  150. package/dist/generators/ts/LazyType.js +65 -0
  151. package/dist/generators/ts/ListType.d.ts +49 -0
  152. package/dist/generators/ts/ListType.js +161 -0
  153. package/dist/generators/ts/LiteralType.d.ts +27 -0
  154. package/dist/generators/ts/LiteralType.js +71 -0
  155. package/dist/generators/ts/ObjectSetType.d.ts +6 -0
  156. package/dist/generators/ts/ObjectSetType.js +36 -0
  157. package/dist/generators/ts/ObjectType.d.ts +105 -0
  158. package/dist/generators/ts/ObjectType.js +503 -0
  159. package/dist/generators/ts/ObjectUnionType.d.ts +20 -0
  160. package/dist/generators/ts/ObjectUnionType.js +223 -0
  161. package/dist/generators/ts/OptionType.d.ts +39 -0
  162. package/dist/generators/ts/OptionType.js +157 -0
  163. package/dist/generators/ts/RdfjsDatasetObjectSetType.d.ts +6 -0
  164. package/dist/generators/ts/RdfjsDatasetObjectSetType.js +323 -0
  165. package/dist/generators/ts/Reusables.d.ts +13 -0
  166. package/dist/generators/ts/Reusables.js +15 -0
  167. package/dist/generators/ts/SetType.d.ts +32 -0
  168. package/dist/generators/ts/SetType.js +132 -0
  169. package/dist/generators/ts/Snippet.d.ts +3 -0
  170. package/dist/generators/ts/Snippet.js +2 -0
  171. package/dist/generators/ts/SnippetFactory.d.ts +16 -0
  172. package/dist/generators/ts/SnippetFactory.js +2 -0
  173. package/dist/generators/ts/Snippets.d.ts +180 -0
  174. package/dist/generators/ts/Snippets.js +1184 -0
  175. package/dist/generators/ts/SparqlObjectSetType.d.ts +6 -0
  176. package/dist/generators/ts/SparqlObjectSetType.js +241 -0
  177. package/dist/generators/ts/StringType.d.ts +22 -0
  178. package/dist/generators/ts/StringType.js +68 -0
  179. package/dist/generators/ts/TermType.d.ts +31 -0
  180. package/dist/generators/ts/TermType.js +143 -0
  181. package/dist/generators/ts/TsFeature.d.ts +3 -0
  182. package/dist/generators/ts/TsFeature.js +28 -0
  183. package/dist/generators/ts/TsGenerator.d.ts +30 -0
  184. package/dist/generators/ts/TsGenerator.js +292 -0
  185. package/dist/generators/ts/Type.d.ts +25 -0
  186. package/dist/generators/ts/Type.js +2 -0
  187. package/dist/generators/ts/TypeFactory.d.ts +43 -0
  188. package/dist/generators/ts/TypeFactory.js +540 -0
  189. package/dist/generators/ts/Typeof.d.ts +2 -0
  190. package/dist/generators/ts/Typeof.js +2 -0
  191. package/dist/generators/ts/UnionType.d.ts +126 -0
  192. package/dist/generators/ts/UnionType.js +850 -0
  193. package/dist/generators/ts/ZodGenerator.d.ts +11 -0
  194. package/dist/generators/ts/ZodGenerator.js +60 -0
  195. package/dist/generators/ts/_ObjectType/AbstractProperty.d.ts +217 -0
  196. package/dist/generators/ts/_ObjectType/AbstractProperty.js +37 -0
  197. package/dist/generators/ts/_ObjectType/DiscriminantProperty.d.ts +45 -0
  198. package/dist/generators/ts/_ObjectType/DiscriminantProperty.js +104 -0
  199. package/dist/generators/ts/_ObjectType/IdentifierProperty.d.ts +43 -0
  200. package/dist/generators/ts/_ObjectType/IdentifierProperty.js +205 -0
  201. package/dist/generators/ts/_ObjectType/ObjectType_createFunctionExpression.d.ts +4 -0
  202. package/dist/generators/ts/_ObjectType/ObjectType_createFunctionExpression.js +28 -0
  203. package/dist/generators/ts/_ObjectType/ObjectType_equalsFunctionExpression.d.ts +4 -0
  204. package/dist/generators/ts/_ObjectType/ObjectType_equalsFunctionExpression.js +19 -0
  205. package/dist/generators/ts/_ObjectType/ObjectType_filterFunctionExpression.d.ts +4 -0
  206. package/dist/generators/ts/_ObjectType/ObjectType_filterFunctionExpression.js +12 -0
  207. package/dist/generators/ts/_ObjectType/ObjectType_filterTypeExpression.d.ts +4 -0
  208. package/dist/generators/ts/_ObjectType/ObjectType_filterTypeExpression.js +20 -0
  209. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlConstructTriplesFunctionExpression.d.ts +4 -0
  210. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlConstructTriplesFunctionExpression.js +46 -0
  211. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlWherePatternsFunctionExpression.d.ts +4 -0
  212. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlWherePatternsFunctionExpression.js +79 -0
  213. package/dist/generators/ts/_ObjectType/ObjectType_fromJsonFunctionExpression.d.ts +4 -0
  214. package/dist/generators/ts/_ObjectType/ObjectType_fromJsonFunctionExpression.js +12 -0
  215. package/dist/generators/ts/_ObjectType/ObjectType_fromRdfResourceFunctionExpression.d.ts +4 -0
  216. package/dist/generators/ts/_ObjectType/ObjectType_fromRdfResourceFunctionExpression.js +38 -0
  217. package/dist/generators/ts/_ObjectType/ObjectType_graphqlTypeExpression.d.ts +4 -0
  218. package/dist/generators/ts/_ObjectType/ObjectType_graphqlTypeExpression.js +26 -0
  219. package/dist/generators/ts/_ObjectType/ObjectType_hashFunctionExpression.d.ts +4 -0
  220. package/dist/generators/ts/_ObjectType/ObjectType_hashFunctionExpression.js +30 -0
  221. package/dist/generators/ts/_ObjectType/ObjectType_identifierTypeDeclarations.d.ts +4 -0
  222. package/dist/generators/ts/_ObjectType/ObjectType_identifierTypeDeclarations.js +13 -0
  223. package/dist/generators/ts/_ObjectType/ObjectType_isTypeFunctionDeclaration.d.ts +5 -0
  224. package/dist/generators/ts/_ObjectType/ObjectType_isTypeFunctionDeclaration.js +20 -0
  225. package/dist/generators/ts/_ObjectType/ObjectType_jsonParseFunctionDeclaration.d.ts +4 -0
  226. package/dist/generators/ts/_ObjectType/ObjectType_jsonParseFunctionDeclaration.js +10 -0
  227. package/dist/generators/ts/_ObjectType/ObjectType_jsonSchemaExpression.d.ts +4 -0
  228. package/dist/generators/ts/_ObjectType/ObjectType_jsonSchemaExpression.js +22 -0
  229. package/dist/generators/ts/_ObjectType/ObjectType_jsonTypeExpression.d.ts +4 -0
  230. package/dist/generators/ts/_ObjectType/ObjectType_jsonTypeExpression.js +5 -0
  231. package/dist/generators/ts/_ObjectType/ObjectType_jsonUiSchemaFunctionExpression.d.ts +4 -0
  232. package/dist/generators/ts/_ObjectType/ObjectType_jsonUiSchemaFunctionExpression.js +17 -0
  233. package/dist/generators/ts/_ObjectType/ObjectType_objectSetMethodNames.d.ts +11 -0
  234. package/dist/generators/ts/_ObjectType/ObjectType_objectSetMethodNames.js +23 -0
  235. package/dist/generators/ts/_ObjectType/ObjectType_schemaExpression.d.ts +4 -0
  236. package/dist/generators/ts/_ObjectType/ObjectType_schemaExpression.js +21 -0
  237. package/dist/generators/ts/_ObjectType/ObjectType_schemaTypeExpression.d.ts +4 -0
  238. package/dist/generators/ts/_ObjectType/ObjectType_schemaTypeExpression.js +18 -0
  239. package/dist/generators/ts/_ObjectType/ObjectType_sparqlConstructQueryFunctionDeclaration.d.ts +10 -0
  240. package/dist/generators/ts/_ObjectType/ObjectType_sparqlConstructQueryFunctionDeclaration.js +35 -0
  241. package/dist/generators/ts/_ObjectType/ObjectType_sparqlConstructQueryStringFunctionDeclaration.d.ts +10 -0
  242. package/dist/generators/ts/_ObjectType/ObjectType_sparqlConstructQueryStringFunctionDeclaration.js +8 -0
  243. package/dist/generators/ts/_ObjectType/ObjectType_toJsonFunctionExpression.d.ts +4 -0
  244. package/dist/generators/ts/_ObjectType/ObjectType_toJsonFunctionExpression.js +14 -0
  245. package/dist/generators/ts/_ObjectType/ObjectType_toRdfResourceFunctionExpression.d.ts +4 -0
  246. package/dist/generators/ts/_ObjectType/ObjectType_toRdfResourceFunctionExpression.js +33 -0
  247. package/dist/generators/ts/_ObjectType/ObjectType_toStringFunctionExpression.d.ts +4 -0
  248. package/dist/generators/ts/_ObjectType/ObjectType_toStringFunctionExpression.js +7 -0
  249. package/dist/generators/ts/_ObjectType/ObjectType_toStringRecordFunctionExpression.d.ts +4 -0
  250. package/dist/generators/ts/_ObjectType/ObjectType_toStringRecordFunctionExpression.js +5 -0
  251. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlConstructTriplesFunctionExpression.d.ts +4 -0
  252. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlConstructTriplesFunctionExpression.js +8 -0
  253. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlWherePatternsFunctionExpression.d.ts +4 -0
  254. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlWherePatternsFunctionExpression.js +10 -0
  255. package/dist/generators/ts/_ObjectType/Property.d.ts +6 -0
  256. package/dist/generators/ts/_ObjectType/Property.js +2 -0
  257. package/dist/generators/ts/_ObjectType/ShaclProperty.d.ts +53 -0
  258. package/dist/generators/ts/_ObjectType/ShaclProperty.js +284 -0
  259. package/dist/generators/ts/_snippets/snippets_BlankNodeFilter.d.ts +3 -0
  260. package/dist/generators/ts/_snippets/snippets_BlankNodeFilter.js +5 -0
  261. package/dist/generators/ts/_snippets/snippets_BlankNodeSchema.d.ts +3 -0
  262. package/dist/generators/ts/_snippets/snippets_BlankNodeSchema.js +6 -0
  263. package/dist/generators/ts/_snippets/snippets_BooleanFilter.d.ts +3 -0
  264. package/dist/generators/ts/_snippets/snippets_BooleanFilter.js +6 -0
  265. package/dist/generators/ts/_snippets/snippets_BooleanSchema.d.ts +3 -0
  266. package/dist/generators/ts/_snippets/snippets_BooleanSchema.js +8 -0
  267. package/dist/generators/ts/_snippets/snippets_CollectionFilter.d.ts +3 -0
  268. package/dist/generators/ts/_snippets/snippets_CollectionFilter.js +7 -0
  269. package/dist/generators/ts/_snippets/snippets_CollectionSchema.d.ts +3 -0
  270. package/dist/generators/ts/_snippets/snippets_CollectionSchema.js +8 -0
  271. package/dist/generators/ts/_snippets/snippets_ConversionFunction.d.ts +3 -0
  272. package/dist/generators/ts/_snippets/snippets_ConversionFunction.js +4 -0
  273. package/dist/generators/ts/_snippets/snippets_DateFilter.d.ts +3 -0
  274. package/dist/generators/ts/_snippets/snippets_DateFilter.js +10 -0
  275. package/dist/generators/ts/_snippets/snippets_DateSchema.d.ts +3 -0
  276. package/dist/generators/ts/_snippets/snippets_DateSchema.js +8 -0
  277. package/dist/generators/ts/_snippets/snippets_DefaultValueSchema.d.ts +3 -0
  278. package/dist/generators/ts/_snippets/snippets_DefaultValueSchema.js +8 -0
  279. package/dist/generators/ts/_snippets/snippets_EqualsFunction.d.ts +3 -0
  280. package/dist/generators/ts/_snippets/snippets_EqualsFunction.js +4 -0
  281. package/dist/generators/ts/_snippets/snippets_EqualsResult.d.ts +3 -0
  282. package/dist/generators/ts/_snippets/snippets_EqualsResult.js +63 -0
  283. package/dist/generators/ts/_snippets/snippets_FocusSparqlConstructTriplesFunction.d.ts +3 -0
  284. package/dist/generators/ts/_snippets/snippets_FocusSparqlConstructTriplesFunction.js +10 -0
  285. package/dist/generators/ts/_snippets/snippets_FocusSparqlWherePatternsFunction.d.ts +3 -0
  286. package/dist/generators/ts/_snippets/snippets_FocusSparqlWherePatternsFunction.js +11 -0
  287. package/dist/generators/ts/_snippets/snippets_FromRdfResourceFunction.d.ts +3 -0
  288. package/dist/generators/ts/_snippets/snippets_FromRdfResourceFunction.js +13 -0
  289. package/dist/generators/ts/_snippets/snippets_FromRdfResourceValuesFunction.d.ts +3 -0
  290. package/dist/generators/ts/_snippets/snippets_FromRdfResourceValuesFunction.js +16 -0
  291. package/dist/generators/ts/_snippets/snippets_HashFunction.d.ts +3 -0
  292. package/dist/generators/ts/_snippets/snippets_HashFunction.js +4 -0
  293. package/dist/generators/ts/_snippets/snippets_Hasher.d.ts +3 -0
  294. package/dist/generators/ts/_snippets/snippets_Hasher.js +3 -0
  295. package/dist/generators/ts/_snippets/snippets_IdentifierFilter.d.ts +3 -0
  296. package/dist/generators/ts/_snippets/snippets_IdentifierFilter.js +7 -0
  297. package/dist/generators/ts/_snippets/snippets_IdentifierSchema.d.ts +3 -0
  298. package/dist/generators/ts/_snippets/snippets_IdentifierSchema.js +7 -0
  299. package/dist/generators/ts/_snippets/snippets_IdentifierSet.d.ts +3 -0
  300. package/dist/generators/ts/_snippets/snippets_IdentifierSet.js +27 -0
  301. package/dist/generators/ts/_snippets/snippets_IriFilter.d.ts +3 -0
  302. package/dist/generators/ts/_snippets/snippets_IriFilter.js +6 -0
  303. package/dist/generators/ts/_snippets/snippets_IriSchema.d.ts +3 -0
  304. package/dist/generators/ts/_snippets/snippets_IriSchema.js +8 -0
  305. package/dist/generators/ts/_snippets/snippets_Lazy.d.ts +3 -0
  306. package/dist/generators/ts/_snippets/snippets_Lazy.js +22 -0
  307. package/dist/generators/ts/_snippets/snippets_LazyOption.d.ts +3 -0
  308. package/dist/generators/ts/_snippets/snippets_LazyOption.js +25 -0
  309. package/dist/generators/ts/_snippets/snippets_LazySet.d.ts +3 -0
  310. package/dist/generators/ts/_snippets/snippets_LazySet.js +40 -0
  311. package/dist/generators/ts/_snippets/snippets_LiteralFilter.d.ts +3 -0
  312. package/dist/generators/ts/_snippets/snippets_LiteralFilter.js +4 -0
  313. package/dist/generators/ts/_snippets/snippets_LiteralSchema.d.ts +3 -0
  314. package/dist/generators/ts/_snippets/snippets_LiteralSchema.js +9 -0
  315. package/dist/generators/ts/_snippets/snippets_MaybeFilter.d.ts +3 -0
  316. package/dist/generators/ts/_snippets/snippets_MaybeFilter.js +4 -0
  317. package/dist/generators/ts/_snippets/snippets_MaybeSchema.d.ts +3 -0
  318. package/dist/generators/ts/_snippets/snippets_MaybeSchema.js +7 -0
  319. package/dist/generators/ts/_snippets/snippets_NumericFilter.d.ts +3 -0
  320. package/dist/generators/ts/_snippets/snippets_NumericFilter.js +10 -0
  321. package/dist/generators/ts/_snippets/snippets_NumericSchema.d.ts +3 -0
  322. package/dist/generators/ts/_snippets/snippets_NumericSchema.js +8 -0
  323. package/dist/generators/ts/_snippets/snippets_PropertyPath.d.ts +6 -0
  324. package/dist/generators/ts/_snippets/snippets_PropertyPath.js +46 -0
  325. package/dist/generators/ts/_snippets/snippets_RdfVocabularies.d.ts +3 -0
  326. package/dist/generators/ts/_snippets/snippets_RdfVocabularies.js +40 -0
  327. package/dist/generators/ts/_snippets/snippets_ShaclPropertySchema.d.ts +3 -0
  328. package/dist/generators/ts/_snippets/snippets_ShaclPropertySchema.js +8 -0
  329. package/dist/generators/ts/_snippets/snippets_SparqlFilterPattern.d.ts +3 -0
  330. package/dist/generators/ts/_snippets/snippets_SparqlFilterPattern.js +3 -0
  331. package/dist/generators/ts/_snippets/snippets_SparqlPattern.d.ts +3 -0
  332. package/dist/generators/ts/_snippets/snippets_SparqlPattern.js +3 -0
  333. package/dist/generators/ts/_snippets/snippets_SparqlPattern_isSolutionGenerating.d.ts +3 -0
  334. package/dist/generators/ts/_snippets/snippets_SparqlPattern_isSolutionGenerating.js +30 -0
  335. package/dist/generators/ts/_snippets/snippets_StringFilter.d.ts +3 -0
  336. package/dist/generators/ts/_snippets/snippets_StringFilter.js +8 -0
  337. package/dist/generators/ts/_snippets/snippets_StringSchema.d.ts +3 -0
  338. package/dist/generators/ts/_snippets/snippets_StringSchema.js +9 -0
  339. package/dist/generators/ts/_snippets/snippets_TermFilter.d.ts +3 -0
  340. package/dist/generators/ts/_snippets/snippets_TermFilter.js +9 -0
  341. package/dist/generators/ts/_snippets/snippets_TermSchema.d.ts +3 -0
  342. package/dist/generators/ts/_snippets/snippets_TermSchema.js +9 -0
  343. package/dist/generators/ts/_snippets/snippets_ToRdfResourceFunction.d.ts +3 -0
  344. package/dist/generators/ts/_snippets/snippets_ToRdfResourceFunction.js +11 -0
  345. package/dist/generators/ts/_snippets/snippets_ToRdfResourceValuesFunction.d.ts +3 -0
  346. package/dist/generators/ts/_snippets/snippets_ToRdfResourceValuesFunction.js +16 -0
  347. package/dist/generators/ts/_snippets/snippets_UnwrapR.d.ts +3 -0
  348. package/dist/generators/ts/_snippets/snippets_UnwrapR.js +4 -0
  349. package/dist/generators/ts/_snippets/snippets_ValidationFunction.d.ts +3 -0
  350. package/dist/generators/ts/_snippets/snippets_ValidationFunction.js +4 -0
  351. package/dist/generators/ts/_snippets/snippets_ValueSparqlConstructTriplesFunction.d.ts +3 -0
  352. package/dist/generators/ts/_snippets/snippets_ValueSparqlConstructTriplesFunction.js +11 -0
  353. package/dist/generators/ts/_snippets/snippets_ValueSparqlWherePatternsFunction.d.ts +3 -0
  354. package/dist/generators/ts/_snippets/snippets_ValueSparqlWherePatternsFunction.js +13 -0
  355. package/dist/generators/ts/_snippets/snippets__FromRdfResourceFunction.d.ts +3 -0
  356. package/dist/generators/ts/_snippets/snippets__FromRdfResourceFunction.js +13 -0
  357. package/dist/generators/ts/_snippets/snippets__ToRdfResourceFunction.d.ts +3 -0
  358. package/dist/generators/ts/_snippets/snippets__ToRdfResourceFunction.js +12 -0
  359. package/dist/generators/ts/_snippets/snippets_arrayEquals.d.ts +3 -0
  360. package/dist/generators/ts/_snippets/snippets_arrayEquals.js +68 -0
  361. package/dist/generators/ts/_snippets/snippets_arrayIntersection.d.ts +3 -0
  362. package/dist/generators/ts/_snippets/snippets_arrayIntersection.js +29 -0
  363. package/dist/generators/ts/_snippets/snippets_bigDecimalFromRdfResourceValues.d.ts +3 -0
  364. package/dist/generators/ts/_snippets/snippets_bigDecimalFromRdfResourceValues.js +6 -0
  365. package/dist/generators/ts/_snippets/snippets_bigDecimalLiteral.d.ts +3 -0
  366. package/dist/generators/ts/_snippets/snippets_bigDecimalLiteral.js +9 -0
  367. package/dist/generators/ts/_snippets/snippets_bigDecimalSparqlWherePatterns.d.ts +3 -0
  368. package/dist/generators/ts/_snippets/snippets_bigDecimalSparqlWherePatterns.js +83 -0
  369. package/dist/generators/ts/_snippets/snippets_bigIntFromRdfResourceValues.d.ts +3 -0
  370. package/dist/generators/ts/_snippets/snippets_bigIntFromRdfResourceValues.js +6 -0
  371. package/dist/generators/ts/_snippets/snippets_blankNodeFromRdfResourceValues.d.ts +3 -0
  372. package/dist/generators/ts/_snippets/snippets_blankNodeFromRdfResourceValues.js +6 -0
  373. package/dist/generators/ts/_snippets/snippets_blankNodeSparqlWherePatterns.d.ts +3 -0
  374. package/dist/generators/ts/_snippets/snippets_blankNodeSparqlWherePatterns.js +5 -0
  375. package/dist/generators/ts/_snippets/snippets_booleanEquals.d.ts +3 -0
  376. package/dist/generators/ts/_snippets/snippets_booleanEquals.js +16 -0
  377. package/dist/generators/ts/_snippets/snippets_booleanFromRdfResourceValues.d.ts +3 -0
  378. package/dist/generators/ts/_snippets/snippets_booleanFromRdfResourceValues.js +6 -0
  379. package/dist/generators/ts/_snippets/snippets_booleanSparqlWherePatterns.d.ts +3 -0
  380. package/dist/generators/ts/_snippets/snippets_booleanSparqlWherePatterns.js +15 -0
  381. package/dist/generators/ts/_snippets/snippets_compactRecord.d.ts +3 -0
  382. package/dist/generators/ts/_snippets/snippets_compactRecord.js +15 -0
  383. package/dist/generators/ts/_snippets/snippets_convertToArraySet.d.ts +3 -0
  384. package/dist/generators/ts/_snippets/snippets_convertToArraySet.js +8 -0
  385. package/dist/generators/ts/_snippets/snippets_convertToBlankNode.d.ts +3 -0
  386. package/dist/generators/ts/_snippets/snippets_convertToBlankNode.js +11 -0
  387. package/dist/generators/ts/_snippets/snippets_convertToBlankNodeIdentifierProperty.d.ts +3 -0
  388. package/dist/generators/ts/_snippets/snippets_convertToBlankNodeIdentifierProperty.js +17 -0
  389. package/dist/generators/ts/_snippets/snippets_convertToIdentifier.d.ts +3 -0
  390. package/dist/generators/ts/_snippets/snippets_convertToIdentifier.js +13 -0
  391. package/dist/generators/ts/_snippets/snippets_convertToIdentifierProperty.d.ts +3 -0
  392. package/dist/generators/ts/_snippets/snippets_convertToIdentifierProperty.js +21 -0
  393. package/dist/generators/ts/_snippets/snippets_convertToIri.d.ts +3 -0
  394. package/dist/generators/ts/_snippets/snippets_convertToIri.js +11 -0
  395. package/dist/generators/ts/_snippets/snippets_convertToIriIdentifierProperty.d.ts +3 -0
  396. package/dist/generators/ts/_snippets/snippets_convertToIriIdentifierProperty.js +17 -0
  397. package/dist/generators/ts/_snippets/snippets_convertToLazy.d.ts +3 -0
  398. package/dist/generators/ts/_snippets/snippets_convertToLazy.js +15 -0
  399. package/dist/generators/ts/_snippets/snippets_convertToLazyOption.d.ts +3 -0
  400. package/dist/generators/ts/_snippets/snippets_convertToLazyOption.js +33 -0
  401. package/dist/generators/ts/_snippets/snippets_convertToLazySet.d.ts +3 -0
  402. package/dist/generators/ts/_snippets/snippets_convertToLazySet.js +27 -0
  403. package/dist/generators/ts/_snippets/snippets_convertToList.d.ts +3 -0
  404. package/dist/generators/ts/_snippets/snippets_convertToList.js +7 -0
  405. package/dist/generators/ts/_snippets/snippets_convertToLiteral.d.ts +3 -0
  406. package/dist/generators/ts/_snippets/snippets_convertToLiteral.js +13 -0
  407. package/dist/generators/ts/_snippets/snippets_convertToMaybe.d.ts +3 -0
  408. package/dist/generators/ts/_snippets/snippets_convertToMaybe.js +19 -0
  409. package/dist/generators/ts/_snippets/snippets_convertToScalarSet.d.ts +3 -0
  410. package/dist/generators/ts/_snippets/snippets_convertToScalarSet.js +15 -0
  411. package/dist/generators/ts/_snippets/snippets_convertWithDefaultValue.d.ts +3 -0
  412. package/dist/generators/ts/_snippets/snippets_convertWithDefaultValue.js +11 -0
  413. package/dist/generators/ts/_snippets/snippets_dateEquals.d.ts +3 -0
  414. package/dist/generators/ts/_snippets/snippets_dateEquals.js +13 -0
  415. package/dist/generators/ts/_snippets/snippets_dateFromRdfResourceValues.d.ts +3 -0
  416. package/dist/generators/ts/_snippets/snippets_dateFromRdfResourceValues.js +6 -0
  417. package/dist/generators/ts/_snippets/snippets_dateSparqlWherePatterns.d.ts +3 -0
  418. package/dist/generators/ts/_snippets/snippets_dateSparqlWherePatterns.js +71 -0
  419. package/dist/generators/ts/_snippets/snippets_dateTimeFromRdfResourceValues.d.ts +3 -0
  420. package/dist/generators/ts/_snippets/snippets_dateTimeFromRdfResourceValues.js +6 -0
  421. package/dist/generators/ts/_snippets/snippets_decodeBigDecimalLiteral.d.ts +3 -0
  422. package/dist/generators/ts/_snippets/snippets_decodeBigDecimalLiteral.js +9 -0
  423. package/dist/generators/ts/_snippets/snippets_deduplicateSparqlPatterns.d.ts +3 -0
  424. package/dist/generators/ts/_snippets/snippets_deduplicateSparqlPatterns.js +19 -0
  425. package/dist/generators/ts/_snippets/snippets_defaultValueFromRdfResourceValues.d.ts +3 -0
  426. package/dist/generators/ts/_snippets/snippets_defaultValueFromRdfResourceValues.js +10 -0
  427. package/dist/generators/ts/_snippets/snippets_defaultValueSparqlWherePatterns.d.ts +3 -0
  428. package/dist/generators/ts/_snippets/snippets_defaultValueSparqlWherePatterns.js +9 -0
  429. package/dist/generators/ts/_snippets/snippets_ensureRdfResourceType.d.ts +3 -0
  430. package/dist/generators/ts/_snippets/snippets_ensureRdfResourceType.js +16 -0
  431. package/dist/generators/ts/_snippets/snippets_filterArray.d.ts +3 -0
  432. package/dist/generators/ts/_snippets/snippets_filterArray.js +22 -0
  433. package/dist/generators/ts/_snippets/snippets_filterBigDecimal.d.ts +3 -0
  434. package/dist/generators/ts/_snippets/snippets_filterBigDecimal.js +26 -0
  435. package/dist/generators/ts/_snippets/snippets_filterBlankNode.d.ts +3 -0
  436. package/dist/generators/ts/_snippets/snippets_filterBlankNode.js +6 -0
  437. package/dist/generators/ts/_snippets/snippets_filterBoolean.d.ts +3 -0
  438. package/dist/generators/ts/_snippets/snippets_filterBoolean.js +10 -0
  439. package/dist/generators/ts/_snippets/snippets_filterDate.d.ts +3 -0
  440. package/dist/generators/ts/_snippets/snippets_filterDate.js +26 -0
  441. package/dist/generators/ts/_snippets/snippets_filterIdentifier.d.ts +3 -0
  442. package/dist/generators/ts/_snippets/snippets_filterIdentifier.js +14 -0
  443. package/dist/generators/ts/_snippets/snippets_filterIri.d.ts +3 -0
  444. package/dist/generators/ts/_snippets/snippets_filterIri.js +10 -0
  445. package/dist/generators/ts/_snippets/snippets_filterLiteral.d.ts +3 -0
  446. package/dist/generators/ts/_snippets/snippets_filterLiteral.js +6 -0
  447. package/dist/generators/ts/_snippets/snippets_filterMaybe.d.ts +3 -0
  448. package/dist/generators/ts/_snippets/snippets_filterMaybe.js +22 -0
  449. package/dist/generators/ts/_snippets/snippets_filterNumeric.d.ts +3 -0
  450. package/dist/generators/ts/_snippets/snippets_filterNumeric.js +26 -0
  451. package/dist/generators/ts/_snippets/snippets_filterString.d.ts +3 -0
  452. package/dist/generators/ts/_snippets/snippets_filterString.js +18 -0
  453. package/dist/generators/ts/_snippets/snippets_filterTerm.d.ts +3 -0
  454. package/dist/generators/ts/_snippets/snippets_filterTerm.js +22 -0
  455. package/dist/generators/ts/_snippets/snippets_floatFromRdfResourceValues.d.ts +3 -0
  456. package/dist/generators/ts/_snippets/snippets_floatFromRdfResourceValues.js +6 -0
  457. package/dist/generators/ts/_snippets/snippets_hashArray.d.ts +3 -0
  458. package/dist/generators/ts/_snippets/snippets_hashArray.js +11 -0
  459. package/dist/generators/ts/_snippets/snippets_hashBigDecimal.d.ts +3 -0
  460. package/dist/generators/ts/_snippets/snippets_hashBigDecimal.js +7 -0
  461. package/dist/generators/ts/_snippets/snippets_hashBoolean.d.ts +3 -0
  462. package/dist/generators/ts/_snippets/snippets_hashBoolean.js +7 -0
  463. package/dist/generators/ts/_snippets/snippets_hashDate.d.ts +3 -0
  464. package/dist/generators/ts/_snippets/snippets_hashDate.js +7 -0
  465. package/dist/generators/ts/_snippets/snippets_hashDateTime.d.ts +3 -0
  466. package/dist/generators/ts/_snippets/snippets_hashDateTime.js +7 -0
  467. package/dist/generators/ts/_snippets/snippets_hashMaybe.d.ts +3 -0
  468. package/dist/generators/ts/_snippets/snippets_hashMaybe.js +11 -0
  469. package/dist/generators/ts/_snippets/snippets_hashNumeric.d.ts +3 -0
  470. package/dist/generators/ts/_snippets/snippets_hashNumeric.js +7 -0
  471. package/dist/generators/ts/_snippets/snippets_hashString.d.ts +3 -0
  472. package/dist/generators/ts/_snippets/snippets_hashString.js +7 -0
  473. package/dist/generators/ts/_snippets/snippets_hashTerm.d.ts +3 -0
  474. package/dist/generators/ts/_snippets/snippets_hashTerm.js +12 -0
  475. package/dist/generators/ts/_snippets/snippets_identifierFromRdfResourceValues.d.ts +3 -0
  476. package/dist/generators/ts/_snippets/snippets_identifierFromRdfResourceValues.js +6 -0
  477. package/dist/generators/ts/_snippets/snippets_identifierSparqlWherePatterns.d.ts +3 -0
  478. package/dist/generators/ts/_snippets/snippets_identifierSparqlWherePatterns.js +30 -0
  479. package/dist/generators/ts/_snippets/snippets_identityConversionFunction.d.ts +3 -0
  480. package/dist/generators/ts/_snippets/snippets_identityConversionFunction.js +6 -0
  481. package/dist/generators/ts/_snippets/snippets_identityValidationFunction.d.ts +3 -0
  482. package/dist/generators/ts/_snippets/snippets_identityValidationFunction.js +6 -0
  483. package/dist/generators/ts/_snippets/snippets_intFromRdfResourceValues.d.ts +3 -0
  484. package/dist/generators/ts/_snippets/snippets_intFromRdfResourceValues.js +6 -0
  485. package/dist/generators/ts/_snippets/snippets_iriFromRdfResourceValues.d.ts +3 -0
  486. package/dist/generators/ts/_snippets/snippets_iriFromRdfResourceValues.js +6 -0
  487. package/dist/generators/ts/_snippets/snippets_iriSparqlWherePatterns.d.ts +3 -0
  488. package/dist/generators/ts/_snippets/snippets_iriSparqlWherePatterns.js +13 -0
  489. package/dist/generators/ts/_snippets/snippets_liftSparqlPatterns.d.ts +3 -0
  490. package/dist/generators/ts/_snippets/snippets_liftSparqlPatterns.js +15 -0
  491. package/dist/generators/ts/_snippets/snippets_listFromRdfResourceValues.d.ts +3 -0
  492. package/dist/generators/ts/_snippets/snippets_listFromRdfResourceValues.js +15 -0
  493. package/dist/generators/ts/_snippets/snippets_listSparqlConstructTriples.d.ts +3 -0
  494. package/dist/generators/ts/_snippets/snippets_listSparqlConstructTriples.js +37 -0
  495. package/dist/generators/ts/_snippets/snippets_listSparqlWherePatterns.d.ts +3 -0
  496. package/dist/generators/ts/_snippets/snippets_listSparqlWherePatterns.js +116 -0
  497. package/dist/generators/ts/_snippets/snippets_literalFactory.d.ts +3 -0
  498. package/dist/generators/ts/_snippets/snippets_literalFactory.js +3 -0
  499. package/dist/generators/ts/_snippets/snippets_literalFromRdfResourceValues.d.ts +3 -0
  500. package/dist/generators/ts/_snippets/snippets_literalFromRdfResourceValues.js +6 -0
  501. package/dist/generators/ts/_snippets/snippets_literalSchemaSparqlPatterns.d.ts +3 -0
  502. package/dist/generators/ts/_snippets/snippets_literalSchemaSparqlPatterns.js +39 -0
  503. package/dist/generators/ts/_snippets/snippets_literalSparqlWherePatterns.d.ts +3 -0
  504. package/dist/generators/ts/_snippets/snippets_literalSparqlWherePatterns.js +5 -0
  505. package/dist/generators/ts/_snippets/snippets_maybeEquals.d.ts +3 -0
  506. package/dist/generators/ts/_snippets/snippets_maybeEquals.js +31 -0
  507. package/dist/generators/ts/_snippets/snippets_maybeFromRdfResourceValues.d.ts +3 -0
  508. package/dist/generators/ts/_snippets/snippets_maybeFromRdfResourceValues.js +11 -0
  509. package/dist/generators/ts/_snippets/snippets_maybeSparqlConstructTriples.d.ts +3 -0
  510. package/dist/generators/ts/_snippets/snippets_maybeSparqlConstructTriples.js +6 -0
  511. package/dist/generators/ts/_snippets/snippets_maybeSparqlWherePatterns.d.ts +3 -0
  512. package/dist/generators/ts/_snippets/snippets_maybeSparqlWherePatterns.js +21 -0
  513. package/dist/generators/ts/_snippets/snippets_monkeyPatchObject.d.ts +3 -0
  514. package/dist/generators/ts/_snippets/snippets_monkeyPatchObject.js +16 -0
  515. package/dist/generators/ts/_snippets/snippets_mutableListFromRdfResourceValues.d.ts +3 -0
  516. package/dist/generators/ts/_snippets/snippets_mutableListFromRdfResourceValues.js +8 -0
  517. package/dist/generators/ts/_snippets/snippets_mutableSetFromRdfResourceValues.d.ts +3 -0
  518. package/dist/generators/ts/_snippets/snippets_mutableSetFromRdfResourceValues.js +8 -0
  519. package/dist/generators/ts/_snippets/snippets_normalizeSparqlWherePatterns.d.ts +3 -0
  520. package/dist/generators/ts/_snippets/snippets_normalizeSparqlWherePatterns.js +92 -0
  521. package/dist/generators/ts/_snippets/snippets_numericSparqlWherePatterns.d.ts +3 -0
  522. package/dist/generators/ts/_snippets/snippets_numericSparqlWherePatterns.js +62 -0
  523. package/dist/generators/ts/_snippets/snippets_parseBlankNode.d.ts +3 -0
  524. package/dist/generators/ts/_snippets/snippets_parseBlankNode.js +9 -0
  525. package/dist/generators/ts/_snippets/snippets_parseIdentifier.d.ts +3 -0
  526. package/dist/generators/ts/_snippets/snippets_parseIdentifier.js +4 -0
  527. package/dist/generators/ts/_snippets/snippets_parseIri.d.ts +3 -0
  528. package/dist/generators/ts/_snippets/snippets_parseIri.js +9 -0
  529. package/dist/generators/ts/_snippets/snippets_propertyEquals.d.ts +3 -0
  530. package/dist/generators/ts/_snippets/snippets_propertyEquals.js +11 -0
  531. package/dist/generators/ts/_snippets/snippets_rdfResourceIdentifierValues.d.ts +3 -0
  532. package/dist/generators/ts/_snippets/snippets_rdfResourceIdentifierValues.js +12 -0
  533. package/dist/generators/ts/_snippets/snippets_sequenceRecord.d.ts +3 -0
  534. package/dist/generators/ts/_snippets/snippets_sequenceRecord.js +18 -0
  535. package/dist/generators/ts/_snippets/snippets_setFromRdfResourceValues.d.ts +3 -0
  536. package/dist/generators/ts/_snippets/snippets_setFromRdfResourceValues.js +9 -0
  537. package/dist/generators/ts/_snippets/snippets_setSparqlConstructTriples.d.ts +3 -0
  538. package/dist/generators/ts/_snippets/snippets_setSparqlConstructTriples.js +6 -0
  539. package/dist/generators/ts/_snippets/snippets_setSparqlWherePatterns.d.ts +3 -0
  540. package/dist/generators/ts/_snippets/snippets_setSparqlWherePatterns.js +17 -0
  541. package/dist/generators/ts/_snippets/snippets_shaclPropertyFromRdf.d.ts +3 -0
  542. package/dist/generators/ts/_snippets/snippets_shaclPropertyFromRdf.js +17 -0
  543. package/dist/generators/ts/_snippets/snippets_shaclPropertySparqlConstructTriples.d.ts +3 -0
  544. package/dist/generators/ts/_snippets/snippets_shaclPropertySparqlConstructTriples.js +90 -0
  545. package/dist/generators/ts/_snippets/snippets_shaclPropertySparqlWherePatterns.d.ts +3 -0
  546. package/dist/generators/ts/_snippets/snippets_shaclPropertySparqlWherePatterns.js +86 -0
  547. package/dist/generators/ts/_snippets/snippets_sortSparqlPatterns.d.ts +3 -0
  548. package/dist/generators/ts/_snippets/snippets_sortSparqlPatterns.js +24 -0
  549. package/dist/generators/ts/_snippets/snippets_sparqlInstancesOfPattern.d.ts +3 -0
  550. package/dist/generators/ts/_snippets/snippets_sparqlInstancesOfPattern.js +29 -0
  551. package/dist/generators/ts/_snippets/snippets_sparqlPropertyPath.d.ts +3 -0
  552. package/dist/generators/ts/_snippets/snippets_sparqlPropertyPath.js +59 -0
  553. package/dist/generators/ts/_snippets/snippets_sparqlValueInPattern.d.ts +3 -0
  554. package/dist/generators/ts/_snippets/snippets_sparqlValueInPattern.js +23 -0
  555. package/dist/generators/ts/_snippets/snippets_strictEquals.d.ts +3 -0
  556. package/dist/generators/ts/_snippets/snippets_strictEquals.js +12 -0
  557. package/dist/generators/ts/_snippets/snippets_stringFromRdfResourceValues.d.ts +3 -0
  558. package/dist/generators/ts/_snippets/snippets_stringFromRdfResourceValues.js +6 -0
  559. package/dist/generators/ts/_snippets/snippets_stringSparqlWherePatterns.d.ts +3 -0
  560. package/dist/generators/ts/_snippets/snippets_stringSparqlWherePatterns.js +39 -0
  561. package/dist/generators/ts/_snippets/snippets_termFilterSparqlPatterns.d.ts +3 -0
  562. package/dist/generators/ts/_snippets/snippets_termFilterSparqlPatterns.js +93 -0
  563. package/dist/generators/ts/_snippets/snippets_termFromRdfResourceValues.d.ts +3 -0
  564. package/dist/generators/ts/_snippets/snippets_termFromRdfResourceValues.js +17 -0
  565. package/dist/generators/ts/_snippets/snippets_termLikeFromRdfResourceValues.d.ts +3 -0
  566. package/dist/generators/ts/_snippets/snippets_termLikeFromRdfResourceValues.js +60 -0
  567. package/dist/generators/ts/_snippets/snippets_termSchemaSparqlPatterns.d.ts +3 -0
  568. package/dist/generators/ts/_snippets/snippets_termSchemaSparqlPatterns.js +24 -0
  569. package/dist/generators/ts/_snippets/snippets_termSparqlWherePatterns.d.ts +3 -0
  570. package/dist/generators/ts/_snippets/snippets_termSparqlWherePatterns.js +5 -0
  571. package/dist/generators/ts/_snippets/snippets_toIsoDateString.d.ts +3 -0
  572. package/dist/generators/ts/_snippets/snippets_toIsoDateString.js +6 -0
  573. package/dist/generators/ts/_snippets/snippets_validateArray.d.ts +3 -0
  574. package/dist/generators/ts/_snippets/snippets_validateArray.js +13 -0
  575. package/dist/generators/ts/_snippets/snippets_validateMaybe.d.ts +3 -0
  576. package/dist/generators/ts/_snippets/snippets_validateMaybe.js +7 -0
  577. package/dist/generators/ts/_snippets/snippets_wrap_FromRdfResourceFunction.d.ts +3 -0
  578. package/dist/generators/ts/_snippets/snippets_wrap_FromRdfResourceFunction.js +9 -0
  579. package/dist/generators/ts/_snippets/snippets_wrap_ToRdfResourceFunction.d.ts +3 -0
  580. package/dist/generators/ts/_snippets/snippets_wrap_ToRdfResourceFunction.js +14 -0
  581. package/dist/generators/ts/codeEquals.d.ts +3 -0
  582. package/dist/generators/ts/codeEquals.js +7 -0
  583. package/dist/generators/ts/rdfjsTermExpression.d.ts +11 -0
  584. package/dist/generators/ts/rdfjsTermExpression.js +72 -0
  585. package/dist/generators/ts/singleEntryRecord.d.ts +2 -0
  586. package/dist/generators/ts/singleEntryRecord.js +6 -0
  587. package/dist/generators/ts/ts-poet-wrapper.d.ts +5 -0
  588. package/dist/generators/ts/ts-poet-wrapper.js +13 -0
  589. package/dist/generators/ts/tsComment.d.ts +5 -0
  590. package/dist/generators/ts/tsComment.js +11 -0
  591. package/dist/index.d.ts +6 -0
  592. package/dist/index.js +6 -0
  593. package/dist/input/ShapesGraph.d.ts +44 -0
  594. package/dist/input/ShapesGraph.js +66 -0
  595. package/dist/input/index.d.ts +3 -0
  596. package/dist/input/index.js +3 -0
  597. package/dist/input/input.shaclmate.d.ts +4567 -0
  598. package/dist/input/input.shaclmate.js +3595 -0
  599. package/package.json +600 -600
@@ -0,0 +1,76 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { Maybe } from "purify-ts";
8
+ import { invariant } from "ts-invariant";
9
+ import { Memoize } from "typescript-memoize";
10
+ import { AbstractLazyType } from "./AbstractLazyType.js";
11
+ import { code } from "./ts-poet-wrapper.js";
12
+ export class LazySetType extends AbstractLazyType {
13
+ graphqlArgs = Maybe.of({
14
+ limit: {
15
+ type: code `${this.reusables.imports.GraphQLInt}`,
16
+ },
17
+ offset: {
18
+ type: code `${this.reusables.imports.GraphQLInt}`,
19
+ },
20
+ });
21
+ kind = "LazySet";
22
+ get conversionFunction() {
23
+ invariant(this.jsTypes.length === 1);
24
+ invariant(this.resolveType.jsTypes.length === 1);
25
+ return Maybe.of({
26
+ code: code `${this.reusables.snippets.convertToLazySet}<${this.partialType.itemType.expression}, ${this.resolveType.itemType.expression}>(${this.resolveToPartialFunction({ partialType: this.partialType.itemType, resolveType: this.resolveType.itemType })})`,
27
+ sourceTypes: [
28
+ {
29
+ expression: this.expression,
30
+ jsType: this.jsTypes[0],
31
+ },
32
+ {
33
+ expression: this.resolveType.expression,
34
+ jsType: this.resolveType.jsTypes[0],
35
+ },
36
+ {
37
+ expression: code `undefined`,
38
+ jsType: { typeof: "undefined" },
39
+ },
40
+ ],
41
+ });
42
+ }
43
+ get runtimeClass() {
44
+ return {
45
+ name: code `${this.reusables.snippets.LazySet}<${this.partialType.itemType.expression}, ${this.resolveType.itemType.expression}>`,
46
+ partialPropertyName: "partials",
47
+ rawName: code `${this.reusables.snippets.LazySet}`,
48
+ };
49
+ }
50
+ fromJsonExpression(parameters) {
51
+ return code `${this.partialType.fromJsonExpression(parameters)}.map(partials => new ${this.runtimeClass.name}({ ${this.runtimeClass.partialPropertyName}: partials, resolver: () => Promise.resolve(${this.reusables.imports.Left}(new Error("unable to resolve partials deserialized from JSON"))) }))`;
52
+ }
53
+ get fromRdfResourceValuesFunction() {
54
+ return code `\
55
+ (
56
+ (
57
+ (values, { objectSet, schema, ...otherOptions }) =>
58
+ ${this.partialType.fromRdfResourceValuesFunction}(values, { ...otherOptions, objectSet, schema: schema.partialType })
59
+ .map(values => values.map(${this.runtimeClass.partialPropertyName} => new ${this.runtimeClass.name}({ ${this.runtimeClass.partialPropertyName}, resolver: (partials, options) => objectSet.${this.resolveType.itemType.objectSetMethodNames.objects}({ identifiers: partials.map(partial => partial.${this.configuration.syntheticNamePrefix}identifier()), ...options }) })))
60
+ ) satisfies ${this.reusables.snippets.FromRdfResourceValuesFunction}<${this.expression}, ${this.schemaType}>
61
+ )`;
62
+ }
63
+ graphqlResolveExpression({ variables, }) {
64
+ return code `(${variables.value}.resolve({ limit: ${variables.args}.limit, offset: ${variables.args}.offset })).then(either => either.unsafeCoerce())`;
65
+ }
66
+ }
67
+ __decorate([
68
+ Memoize()
69
+ ], LazySetType.prototype, "conversionFunction", null);
70
+ __decorate([
71
+ Memoize()
72
+ ], LazySetType.prototype, "runtimeClass", null);
73
+ __decorate([
74
+ Memoize()
75
+ ], LazySetType.prototype, "fromRdfResourceValuesFunction", null);
76
+ //# sourceMappingURL=LazySetType.js.map
@@ -0,0 +1,19 @@
1
+ import { Maybe } from "purify-ts";
2
+ import { AbstractLazyType } from "./AbstractLazyType.js";
3
+ import { type Code } from "./ts-poet-wrapper.js";
4
+ export declare class LazyType extends AbstractLazyType<AbstractLazyType.ItemTypeConstraint, AbstractLazyType.ItemTypeConstraint> {
5
+ readonly graphqlArgs: Super["graphqlArgs"];
6
+ readonly kind = "Lazy";
7
+ get conversionFunction(): Maybe<AbstractLazyType.ConversionFunction>;
8
+ protected get runtimeClass(): {
9
+ name: Code;
10
+ partialPropertyName: string;
11
+ rawName: Code;
12
+ };
13
+ fromJsonExpression(parameters: Parameters<Super["fromJsonExpression"]>[0]): Code;
14
+ get fromRdfResourceValuesFunction(): Code;
15
+ graphqlResolveExpression({ variables, }: Parameters<Super["graphqlResolveExpression"]>[0]): Code;
16
+ }
17
+ type Super = AbstractLazyType<AbstractLazyType.ItemTypeConstraint, AbstractLazyType.ItemTypeConstraint>;
18
+ export {};
19
+ //# sourceMappingURL=LazyType.d.ts.map
@@ -0,0 +1,65 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { Maybe } from "purify-ts";
8
+ import { invariant } from "ts-invariant";
9
+ import { Memoize } from "typescript-memoize";
10
+ import { AbstractLazyType } from "./AbstractLazyType.js";
11
+ import { code } from "./ts-poet-wrapper.js";
12
+ export class LazyType extends AbstractLazyType {
13
+ graphqlArgs = Maybe.empty();
14
+ kind = "Lazy";
15
+ get conversionFunction() {
16
+ invariant(this.jsTypes.length === 1);
17
+ invariant(this.resolveType.jsTypes.length === 1);
18
+ return Maybe.of({
19
+ code: code `${this.reusables.snippets.convertToLazy}<${this.partialType.expression}, ${this.resolveType.expression}>(${this.resolveToPartialFunction({ partialType: this.partialType, resolveType: this.resolveType })})`,
20
+ sourceTypes: [
21
+ {
22
+ expression: this.expression,
23
+ jsType: this.jsTypes[0],
24
+ },
25
+ {
26
+ expression: this.resolveType.expression,
27
+ jsType: this.resolveType.jsTypes[0],
28
+ },
29
+ ],
30
+ });
31
+ }
32
+ get runtimeClass() {
33
+ return {
34
+ name: code `${this.reusables.snippets.Lazy}<${this.partialType.expression}, ${this.resolveType.expression}>`,
35
+ partialPropertyName: "partial",
36
+ rawName: code `${this.reusables.snippets.Lazy}`,
37
+ };
38
+ }
39
+ fromJsonExpression(parameters) {
40
+ return code `${this.partialType.fromJsonExpression(parameters)}.map(partial => new ${this.runtimeClass.name}({ ${this.runtimeClass.partialPropertyName}: partial, resolver: (partial) => Promise.resolve(${this.reusables.imports.Left}(new Error(\`unable to resolve \${partial} deserialized from JSON\`))) }))`;
41
+ }
42
+ get fromRdfResourceValuesFunction() {
43
+ return code `\
44
+ (
45
+ (
46
+ (values, { objectSet, schema, ...otherOptions }) =>
47
+ ${this.partialType.fromRdfResourceValuesFunction}(values, { ...otherOptions, objectSet, schema: schema.partialType })
48
+ .map(values => values.map(${this.runtimeClass.partialPropertyName} => new ${this.runtimeClass.name}({ ${this.runtimeClass.partialPropertyName}, resolver: (partial, options) => objectSet.${this.resolveType.objectSetMethodNames.object}(partial.${this.configuration.syntheticNamePrefix}identifier(), options) })))
49
+ ) satisfies ${this.reusables.snippets.FromRdfResourceValuesFunction}<${this.expression}, ${this.schemaType}>
50
+ )`;
51
+ }
52
+ graphqlResolveExpression({ variables, }) {
53
+ return code `${variables.value}.resolve().then(either => either.unsafeCoerce())`;
54
+ }
55
+ }
56
+ __decorate([
57
+ Memoize()
58
+ ], LazyType.prototype, "conversionFunction", null);
59
+ __decorate([
60
+ Memoize()
61
+ ], LazyType.prototype, "runtimeClass", null);
62
+ __decorate([
63
+ Memoize()
64
+ ], LazyType.prototype, "fromRdfResourceValuesFunction", null);
65
+ //# sourceMappingURL=LazyType.js.map
@@ -0,0 +1,49 @@
1
+ import type { NamedNode } from "@rdfjs/types";
2
+ import { Maybe } from "purify-ts";
3
+ import { AbstractCollectionType } from "./AbstractCollectionType.js";
4
+ import type { BigDecimalType } from "./BigDecimalType.js";
5
+ import type { BigIntType } from "./BigIntType.js";
6
+ import type { BlankNodeType } from "./BlankNodeType.js";
7
+ import type { BooleanType } from "./BooleanType.js";
8
+ import type { DateTimeType } from "./DateTimeType.js";
9
+ import type { DateType } from "./DateType.js";
10
+ import type { FloatType } from "./FloatType.js";
11
+ import type { IdentifierType } from "./IdentifierType.js";
12
+ import type { IntType } from "./IntType.js";
13
+ import type { IriType } from "./IriType.js";
14
+ import type { LiteralType } from "./LiteralType.js";
15
+ import type { ObjectType } from "./ObjectType.js";
16
+ import type { ObjectUnionType } from "./ObjectUnionType.js";
17
+ import type { StringType } from "./StringType.js";
18
+ import type { TermType } from "./TermType.js";
19
+ import type { Type } from "./Type.js";
20
+ import { type Code } from "./ts-poet-wrapper.js";
21
+ import type { UnionType } from "./UnionType.js";
22
+ export declare class ListType<ItemTypeT extends ListType.ItemType> extends AbstractCollectionType<ItemTypeT> {
23
+ private readonly identifierNodeKind;
24
+ private readonly toRdfTypes;
25
+ readonly jsTypes: readonly [{
26
+ readonly instanceof: "Array";
27
+ readonly typeof: "object";
28
+ }];
29
+ readonly kind = "List";
30
+ constructor({ identifierNodeKind, toRdfTypes, ...superParameters }: {
31
+ identifierNodeKind: ListType<ItemTypeT>["identifierNodeKind"];
32
+ toRdfTypes: readonly NamedNode[];
33
+ } & ConstructorParameters<typeof AbstractCollectionType<ItemTypeT>>[0]);
34
+ get conversionFunction(): Maybe<AbstractCollectionType.ConversionFunction>;
35
+ get fromRdfResourceValuesFunction(): Code;
36
+ get toRdfResourceValueTypes(): AbstractCollectionType<ItemTypeT>["toRdfResourceValueTypes"];
37
+ get valueSparqlConstructTriplesFunction(): Code;
38
+ get valueSparqlWherePatternsFunction(): Code;
39
+ fromJsonExpression({ variables, }: Parameters<AbstractCollectionType<ItemTypeT>["fromJsonExpression"]>[0]): Code;
40
+ jsonSchema(parameters: Parameters<AbstractCollectionType<ItemTypeT>["jsonSchema"]>[0]): Code;
41
+ jsonType(): AbstractCollectionType.JsonType;
42
+ toRdfResourceValuesExpression({ variables, }: Parameters<AbstractCollectionType<ItemTypeT>["toRdfResourceValuesExpression"]>[0]): Code;
43
+ toStringExpression({ variables, }: Parameters<AbstractCollectionType<ItemTypeT>["toStringExpression"]>[0]): Code;
44
+ }
45
+ export declare namespace ListType {
46
+ type ItemType = BigDecimalType | BigIntType | BlankNodeType | BooleanType | DateTimeType | DateType | FloatType | IdentifierType | IntType | IriType | ListType<ListType.ItemType> | LiteralType | ObjectUnionType | ObjectType | StringType | TermType | UnionType<Type>;
47
+ function isItemType(type: Type): type is ItemType;
48
+ }
49
+ //# sourceMappingURL=ListType.d.ts.map
@@ -0,0 +1,161 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { rdf } from "@tpluscode/rdf-ns-builders";
8
+ import { Maybe } from "purify-ts";
9
+ import { Memoize } from "typescript-memoize";
10
+ import { AbstractCollectionType } from "./AbstractCollectionType.js";
11
+ import { code, joinCode, literalOf } from "./ts-poet-wrapper.js";
12
+ export class ListType extends AbstractCollectionType {
13
+ identifierNodeKind;
14
+ toRdfTypes;
15
+ jsTypes = [
16
+ { instanceof: "Array", typeof: "object" },
17
+ ];
18
+ kind = "List";
19
+ constructor({ identifierNodeKind, toRdfTypes, ...superParameters }) {
20
+ super(superParameters);
21
+ this.identifierNodeKind = identifierNodeKind;
22
+ this.toRdfTypes = toRdfTypes;
23
+ }
24
+ get conversionFunction() {
25
+ const itemConversionFunction = this.itemType.conversionFunction.orDefault(this.itemConversionFunctionDefault);
26
+ return Maybe.of({
27
+ code: code `${this.reusables.snippets.convertToList}(${itemConversionFunction.code}, ${literalOf(!this._mutable)})`,
28
+ sourceTypes: [
29
+ {
30
+ expression: code `readonly (${joinCode(itemConversionFunction.sourceTypes.map((itemSourceType) => code `${itemSourceType.expression}`), { on: " | " })})[]`,
31
+ jsType: { instanceof: "Array", typeof: "object" },
32
+ },
33
+ ],
34
+ });
35
+ }
36
+ get fromRdfResourceValuesFunction() {
37
+ return code `${this._mutable ? this.reusables.snippets.mutableListFromRdfResourceValues : this.reusables.snippets.listFromRdfResourceValues}<${this.itemType.expression}, ${this.itemType.schemaType}>(${this.itemType.fromRdfResourceValuesFunction})`;
38
+ }
39
+ get toRdfResourceValueTypes() {
40
+ return new Set(["BlankNode", "NamedNode"]); // List or rdf:nil
41
+ }
42
+ get valueSparqlConstructTriplesFunction() {
43
+ return code `${this.reusables.snippets.listSparqlConstructTriples}<${this.itemType.filterType}, ${this.itemType.schemaType}>(${this.itemType.valueSparqlConstructTriplesFunction})`;
44
+ }
45
+ get valueSparqlWherePatternsFunction() {
46
+ return code `${this.reusables.snippets.listSparqlWherePatterns}<${this.itemType.filterType}, ${this.itemType.schemaType}>(${this.itemType.valueSparqlWherePatternsFunction})`;
47
+ }
48
+ fromJsonExpression({ variables, }) {
49
+ return code `${this.reusables.imports.Either}.sequence<Error, ${this.itemType.expression}>(${variables.value}.map(item => (${this.itemType.fromJsonExpression({
50
+ variables: { value: code `item` },
51
+ })})))`;
52
+ }
53
+ jsonSchema(parameters) {
54
+ let schema = code `${this.itemType.jsonSchema(parameters)}.array()`;
55
+ if (!this._mutable) {
56
+ schema = code `${schema}.readonly()`;
57
+ }
58
+ return schema;
59
+ }
60
+ jsonType() {
61
+ return new AbstractCollectionType.JsonType(code `${!this.mutable ? "readonly " : ""}(${this.itemType.jsonType().expression})[]`);
62
+ }
63
+ toRdfResourceValuesExpression({ variables, }) {
64
+ let mintListIdentifierFunction;
65
+ let mintSubListIdentifierFunction;
66
+ let resourceTypeExpression;
67
+ switch (this.identifierNodeKind) {
68
+ case "BlankNode": {
69
+ mintListIdentifierFunction =
70
+ mintSubListIdentifierFunction = code `(() => ${this.reusables.imports.dataFactory}.blankNode())`;
71
+ resourceTypeExpression = code `${this.reusables.imports.Resource}<${this.reusables.imports.BlankNode}>`;
72
+ break;
73
+ }
74
+ case "IRI": {
75
+ resourceTypeExpression = code `${this.reusables.imports.Resource}<${this.reusables.imports.NamedNode}>`;
76
+ throw new RangeError("list IRI minting is unsupported");
77
+ }
78
+ }
79
+ return code `[${variables.value}.length > 0 ? ${variables.value}.reduce(({ currentSubListResource, listResource }, item, itemIndex, list) => {
80
+ if (itemIndex === 0) {
81
+ currentSubListResource = listResource;
82
+ } else {
83
+ const newSubListResource = ${variables.resourceSet}.resource(${mintSubListIdentifierFunction}());
84
+ currentSubListResource!.add(${this.rdfjsTermExpression(rdf.rest)}, newSubListResource.identifier, ${variables.graph});
85
+ currentSubListResource = newSubListResource;
86
+ }
87
+
88
+ ${joinCode(this.toRdfTypes.map((rdfType) => code `currentSubListResource.add(${this.rdfjsTermExpression(rdf.type)}, ${this.reusables.imports.dataFactory}.namedNode("${rdfType.value}"), ${variables.graph})`))}
89
+
90
+ currentSubListResource.add(${this.rdfjsTermExpression(rdf.first)}, ${this.itemType.toRdfResourceValuesExpression({ variables: { graph: variables.graph, propertyPath: this.rdfjsTermExpression(rdf.first), resource: code `currentSubListResource`, resourceSet: variables.resourceSet, value: code `item` } })}, ${variables.graph});
91
+
92
+ if (itemIndex + 1 === list.length) {
93
+ currentSubListResource.add(${this.rdfjsTermExpression(rdf.rest)}, ${this.rdfjsTermExpression(rdf.nil)}, ${variables.graph});
94
+ }
95
+
96
+ return { currentSubListResource, listResource };
97
+ },
98
+ {
99
+ currentSubListResource: null,
100
+ listResource: ${variables.resourceSet}.resource(${mintListIdentifierFunction}()),
101
+ } as {
102
+ currentSubListResource: ${resourceTypeExpression} | null;
103
+ listResource: ${resourceTypeExpression};
104
+ },
105
+ ).listResource.identifier : ${this.rdfjsTermExpression(rdf.nil)}]`;
106
+ }
107
+ toStringExpression({ variables, }) {
108
+ return code `\`[\${${variables.value}.map(item => (${this.itemType.toStringExpression({ variables: { value: code `item` } })}))}]\``;
109
+ }
110
+ }
111
+ __decorate([
112
+ Memoize()
113
+ ], ListType.prototype, "conversionFunction", null);
114
+ __decorate([
115
+ Memoize()
116
+ ], ListType.prototype, "fromRdfResourceValuesFunction", null);
117
+ __decorate([
118
+ Memoize()
119
+ ], ListType.prototype, "toRdfResourceValueTypes", null);
120
+ __decorate([
121
+ Memoize()
122
+ ], ListType.prototype, "valueSparqlConstructTriplesFunction", null);
123
+ __decorate([
124
+ Memoize()
125
+ ], ListType.prototype, "valueSparqlWherePatternsFunction", null);
126
+ __decorate([
127
+ Memoize()
128
+ ], ListType.prototype, "jsonType", null);
129
+ (function (ListType) {
130
+ function isItemType(type) {
131
+ switch (type.kind) {
132
+ case "BigDecimal":
133
+ case "BigInt":
134
+ case "BlankNode":
135
+ case "Boolean":
136
+ case "DateTime":
137
+ case "Date":
138
+ case "Float":
139
+ case "Identifier":
140
+ case "Iri":
141
+ case "Int":
142
+ case "List":
143
+ case "Literal":
144
+ case "ObjectUnion":
145
+ case "Object":
146
+ case "String":
147
+ case "Term":
148
+ case "Union":
149
+ return true;
150
+ case "DefaultValue":
151
+ case "LazyOption":
152
+ case "LazySet":
153
+ case "Lazy":
154
+ case "Option":
155
+ case "Set":
156
+ return false;
157
+ }
158
+ }
159
+ ListType.isItemType = isItemType;
160
+ })(ListType || (ListType = {}));
161
+ //# sourceMappingURL=ListType.js.map
@@ -0,0 +1,27 @@
1
+ import type { Literal } from "@rdfjs/types";
2
+ import { Maybe } from "purify-ts";
3
+ import { AbstractLiteralType } from "./AbstractLiteralType.js";
4
+ import { type Code } from "./ts-poet-wrapper.js";
5
+ export declare class LiteralType extends AbstractLiteralType {
6
+ protected readonly inlineExpression: Code;
7
+ readonly conversionFunction: Maybe<AbstractLiteralType.ConversionFunction>;
8
+ readonly filterFunction: Code;
9
+ readonly filterType: Code;
10
+ readonly fromRdfResourceValuesFunction: Code;
11
+ readonly jsTypes: readonly [{
12
+ readonly instanceof: "Object";
13
+ readonly typeof: "object";
14
+ }];
15
+ readonly kind = "Literal";
16
+ readonly schemaType: Code;
17
+ readonly valueSparqlWherePatternsFunction: Code;
18
+ get graphqlType(): AbstractLiteralType.GraphqlType;
19
+ protected get schemaInitializers(): readonly Code[];
20
+ fromJsonExpression({ variables, }: Parameters<AbstractLiteralType["fromJsonExpression"]>[0]): Code;
21
+ graphqlResolveExpression(_parameters: Parameters<AbstractLiteralType["graphqlResolveExpression"]>[0]): Code;
22
+ jsonSchema({ includeDiscriminantProperty, }: Parameters<AbstractLiteralType["jsonSchema"]>[0]): Code;
23
+ jsonType(parameters?: Parameters<AbstractLiteralType["jsonType"]>[0]): AbstractLiteralType.JsonType;
24
+ literalValueExpression(literal: Literal): Code;
25
+ toJsonExpression({ includeDiscriminantProperty, variables, }: Parameters<AbstractLiteralType["toJsonExpression"]>[0]): Code;
26
+ }
27
+ //# sourceMappingURL=LiteralType.d.ts.map
@@ -0,0 +1,71 @@
1
+ import { xsd } from "@tpluscode/rdf-ns-builders";
2
+ import { Maybe } from "purify-ts";
3
+ import { AbstractLiteralType } from "./AbstractLiteralType.js";
4
+ import { arrayOf, code } from "./ts-poet-wrapper.js";
5
+ export class LiteralType extends AbstractLiteralType {
6
+ inlineExpression = code `${this.reusables.imports.Literal}`;
7
+ conversionFunction = Maybe.of({
8
+ code: code `${this.reusables.snippets.convertToLiteral}`,
9
+ sourceTypes: [
10
+ ...["bigint", "boolean", "number", "string"].map((typeof_) => ({
11
+ expression: code `${typeof_}`,
12
+ jsType: { typeof: typeof_ },
13
+ })),
14
+ {
15
+ expression: code `Date`,
16
+ jsType: { instanceof: "Date", typeof: "object" },
17
+ },
18
+ {
19
+ expression: code `${this.reusables.imports.Literal}`,
20
+ jsType: { instanceof: "Object", typeof: "object" },
21
+ },
22
+ ],
23
+ });
24
+ filterFunction = code `${this.reusables.snippets.filterLiteral}`;
25
+ filterType = code `${this.reusables.snippets.LiteralFilter}`;
26
+ fromRdfResourceValuesFunction = code `${this.reusables.snippets.literalFromRdfResourceValues}`;
27
+ jsTypes = [
28
+ { instanceof: "Object", typeof: "object" },
29
+ ];
30
+ kind = "Literal";
31
+ schemaType = code `${this.reusables.snippets.LiteralSchema}`;
32
+ valueSparqlWherePatternsFunction = code `${this.reusables.snippets.literalSparqlWherePatterns}`;
33
+ get graphqlType() {
34
+ throw new Error("not implemented");
35
+ }
36
+ get schemaInitializers() {
37
+ let initializers = super.schemaInitializers;
38
+ if (this.in_.length > 0) {
39
+ initializers = initializers.concat(code `in: ${arrayOf(...this.in_.map((in_) => this.rdfjsTermExpression(in_)))}`);
40
+ }
41
+ if (this.languageIn.length > 0) {
42
+ initializers = initializers.concat(code `languageIn: ${arrayOf(...this.languageIn)}`);
43
+ }
44
+ return initializers;
45
+ }
46
+ fromJsonExpression({ variables, }) {
47
+ return code `${this.reusables.imports.Either}.of<Error, ${this.expression}>(${this.reusables.imports.dataFactory}.literal(${variables.value}["@value"], ${variables.value}["@language"] !== undefined ? ${variables.value}["@language"] : (${variables.value}["@type"] !== undefined ? ${this.reusables.imports.dataFactory}.namedNode(${variables.value}["@type"]!) : undefined)))`;
48
+ }
49
+ graphqlResolveExpression(_parameters) {
50
+ throw new Error("not implemented");
51
+ }
52
+ jsonSchema({ includeDiscriminantProperty, }) {
53
+ const discriminantProperty = includeDiscriminantProperty
54
+ ? code `, termType: ${this.reusables.imports.z}.literal("Literal")`
55
+ : "";
56
+ return code `${this.reusables.imports.z}.object({ "@language": ${this.reusables.imports.z}.string().optional()${discriminantProperty}, "@type": ${this.reusables.imports.z}.string().optional(), "@value": ${this.reusables.imports.z}.string() })`;
57
+ }
58
+ jsonType(parameters) {
59
+ const discriminantProperty = parameters?.includeDiscriminantProperty
60
+ ? `, readonly termType: "Literal"`
61
+ : "";
62
+ return new AbstractLiteralType.JsonType(code `{ readonly "@language"?: string${discriminantProperty}, readonly "@type"?: string, readonly "@value": string }`);
63
+ }
64
+ literalValueExpression(literal) {
65
+ return this.rdfjsTermExpression(literal);
66
+ }
67
+ toJsonExpression({ includeDiscriminantProperty, variables, }) {
68
+ return code `{ "@language": ${variables.value}.language.length > 0 ? ${variables.value}.language : undefined${includeDiscriminantProperty ? `, "termType": "Literal" as const` : ""}, "@type": ${variables.value}.datatype.value !== "${xsd.string.value}" ? ${variables.value}.datatype.value : undefined, "@value": ${variables.value}.value }`;
69
+ }
70
+ }
71
+ //# sourceMappingURL=LiteralType.js.map
@@ -0,0 +1,6 @@
1
+ import { AbstractObjectSetType } from "./AbstractObjectSetType.js";
2
+ import { type Code } from "./ts-poet-wrapper.js";
3
+ export declare class ObjectSetType extends AbstractObjectSetType {
4
+ get declaration(): Code;
5
+ }
6
+ //# sourceMappingURL=ObjectSetType.d.ts.map
@@ -0,0 +1,36 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { Memoize } from "typescript-memoize";
8
+ import { AbstractObjectSetType } from "./AbstractObjectSetType.js";
9
+ import { code, joinCode } from "./ts-poet-wrapper.js";
10
+ export class ObjectSetType extends AbstractObjectSetType {
11
+ get declaration() {
12
+ const syntheticNamePrefix = this.configuration.syntheticNamePrefix;
13
+ return code `\
14
+ export interface ${syntheticNamePrefix}ObjectSet {
15
+ ${joinCode(this.namedObjectTypes
16
+ .flatMap((namedObjectType) => Object.values(this.methodSignatures(namedObjectType)))
17
+ .concat(this.namedObjectUnionTypes.flatMap((namedObjectUnionType) => Object.values(this.methodSignatures(namedObjectUnionType))))
18
+ .map((methodSignature) => code `${methodSignature.name}(${methodSignature.parameters}): ${methodSignature.returnType};`), { on: "\n\n" })}
19
+ }
20
+
21
+ export namespace ${syntheticNamePrefix}ObjectSet {
22
+ export interface Query<ObjectFilterT, ObjectIdentifierT extends ${this.reusables.imports.BlankNode} | ${this.reusables.imports.NamedNode}> {
23
+ readonly filter?: ObjectFilterT;
24
+ readonly graph?: Exclude<${this.reusables.imports.Quad_Graph}, ${this.reusables.imports.Variable}>;
25
+ readonly identifiers?: readonly ObjectIdentifierT[];
26
+ readonly limit?: number;
27
+ readonly offset?: number;
28
+ readonly preferredLanguages?: readonly string[];
29
+ }
30
+ }`;
31
+ }
32
+ }
33
+ __decorate([
34
+ Memoize()
35
+ ], ObjectSetType.prototype, "declaration", null);
36
+ //# sourceMappingURL=ObjectSetType.js.map
@@ -0,0 +1,105 @@
1
+ import type { NamedNode } from "@rdfjs/types";
2
+ import { Maybe } from "purify-ts";
3
+ import { DiscriminantProperty as _DiscriminantProperty } from "./_ObjectType/DiscriminantProperty.js";
4
+ import { IdentifierProperty as _IdentifierProperty } from "./_ObjectType/IdentifierProperty.js";
5
+ import type { Property as _Property } from "./_ObjectType/Property.js";
6
+ import { ShaclProperty as _ShaclProperty } from "./_ObjectType/ShaclProperty.js";
7
+ import { AbstractType } from "./AbstractType.js";
8
+ import type { BlankNodeType } from "./BlankNodeType.js";
9
+ import type { IdentifierType } from "./IdentifierType.js";
10
+ import type { IriType } from "./IriType.js";
11
+ import type { Type } from "./Type.js";
12
+ import { type Code } from "./ts-poet-wrapper.js";
13
+ export declare class ObjectType extends AbstractType {
14
+ protected readonly toRdfTypes: readonly NamedNode[];
15
+ readonly discriminantProperty: Maybe<ObjectType.DiscriminantProperty>;
16
+ readonly extern: boolean;
17
+ readonly fromRdfType: Maybe<NamedNode>;
18
+ readonly graphqlArgs: AbstractType["graphqlArgs"];
19
+ readonly identifierType: BlankNodeType | IdentifierType | IriType;
20
+ readonly jsTypes: readonly [{
21
+ readonly instanceof: "Object";
22
+ readonly typeof: "object";
23
+ }];
24
+ readonly kind = "Object";
25
+ readonly recursive: boolean;
26
+ readonly synthetic: boolean;
27
+ readonly validationFunction: Maybe<Code>;
28
+ constructor({ discriminantProperty, extern, fromRdfType, identifierType, lazyProperties, recursive, synthetic, toRdfTypes, ...superParameters }: {
29
+ discriminantProperty: Maybe<ObjectType.DiscriminantProperty>;
30
+ comment: Maybe<string>;
31
+ extern: boolean;
32
+ fromRdfType: Maybe<NamedNode>;
33
+ identifierType: BlankNodeType | IdentifierType | IriType;
34
+ label: Maybe<string>;
35
+ lazyProperties: (objectType: ObjectType) => readonly ObjectType.Property[];
36
+ recursive: boolean;
37
+ synthetic: boolean;
38
+ toRdfTypes: readonly NamedNode[];
39
+ } & ConstructorParameters<typeof AbstractType>[0]);
40
+ get conversionFunction(): Maybe<AbstractType.ConversionFunction>;
41
+ get declaration(): Maybe<Code>;
42
+ get equalsFunction(): Code;
43
+ get expression(): Code;
44
+ get filterFunction(): Code;
45
+ get filterType(): Code;
46
+ get fromRdfResourceValuesFunction(): Code;
47
+ get fromRdfTypeVariable(): Maybe<Code>;
48
+ get graphqlType(): AbstractType.GraphqlType;
49
+ get hashFunction(): Code;
50
+ get identifierTypeAlias(): Code;
51
+ get mutable(): boolean;
52
+ get objectSetMethodNames(): ObjectType.ObjectSetMethodNames;
53
+ get properties(): readonly ObjectType.Property[];
54
+ get referencesNamedType(): boolean;
55
+ get schema(): Code;
56
+ get schemaType(): Code;
57
+ get toRdfResourceValueTypes(): AbstractType["toRdfResourceValueTypes"];
58
+ get toRdfjsResourceType(): Code;
59
+ get valueSparqlConstructTriplesFunction(): Code;
60
+ get valueSparqlWherePatternsFunction(): Code;
61
+ protected get constructorParameters(): {
62
+ hasQuestionToken: boolean;
63
+ signature: Code;
64
+ type: {
65
+ expression: Code;
66
+ };
67
+ variable: string;
68
+ };
69
+ protected get createFunction(): Code;
70
+ protected get thisVariable(): Code;
71
+ protected get toJsonFunction(): Code;
72
+ protected get toRdfTypesVariable(): Maybe<Code>;
73
+ protected get toStringFunction(): Code;
74
+ private get inlineExpression();
75
+ fromJsonExpression({ variables, }: Parameters<AbstractType["fromJsonExpression"]>[0]): Code;
76
+ graphqlResolveExpression({ variables, }: {
77
+ variables: {
78
+ value: Code;
79
+ };
80
+ }): Code;
81
+ jsonSchema({ context, }: Parameters<AbstractType["jsonSchema"]>[0]): Code;
82
+ jsonType(): AbstractType.JsonType;
83
+ jsonUiSchemaElement({ variables, }: Parameters<AbstractType["jsonUiSchemaElement"]>[0]): Maybe<Code>;
84
+ toJsonExpression({ variables, }: Parameters<AbstractType["toJsonExpression"]>[0]): Code;
85
+ toRdfResourceValuesExpression({ variables, }: Parameters<AbstractType["toRdfResourceValuesExpression"]>[0]): Code;
86
+ toStringExpression({ variables, }: Parameters<AbstractType["toStringExpression"]>[0]): Code;
87
+ protected toStringRecordExpression({ variables, }: Parameters<AbstractType["toStringExpression"]>[0]): Code;
88
+ private readonly lazyProperties;
89
+ }
90
+ export declare namespace ObjectType {
91
+ const IdentifierProperty: typeof _IdentifierProperty;
92
+ type IdentifierProperty = _IdentifierProperty;
93
+ type ObjectSetMethodNames = {
94
+ readonly object: string;
95
+ readonly objectCount: string;
96
+ readonly objectIdentifiers: string;
97
+ readonly objects: string;
98
+ };
99
+ type Property = _Property;
100
+ const ShaclProperty: typeof _ShaclProperty;
101
+ type ShaclProperty<TypeT extends Type> = _ShaclProperty<TypeT>;
102
+ const DiscriminantProperty: typeof _DiscriminantProperty;
103
+ type DiscriminantProperty = _DiscriminantProperty;
104
+ }
105
+ //# sourceMappingURL=ObjectType.d.ts.map