@shaclmate/compiler 4.0.9 → 4.0.10

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 (180) hide show
  1. package/dist/ShapesGraphToAstTransformer.js +1 -1
  2. package/dist/ast/Ast.d.ts +1 -1
  3. package/dist/generators/json/AstJsonGenerator.js +1 -1
  4. package/dist/generators/ts/AbstractCollectionType.d.ts +1 -1
  5. package/dist/generators/ts/AbstractCollectionType.js +2 -2
  6. package/dist/generators/ts/AbstractContainerType.d.ts +2 -2
  7. package/dist/generators/ts/AbstractContainerType.js +1 -1
  8. package/dist/generators/ts/AbstractLazyObjectType.d.ts +3 -3
  9. package/dist/generators/ts/AbstractLazyObjectType.js +2 -2
  10. package/dist/generators/ts/AbstractNamedUnionType.d.ts +2 -2
  11. package/dist/generators/ts/AbstractNamedUnionType.js +17 -15
  12. package/dist/generators/ts/AbstractNumericType.d.ts +1 -1
  13. package/dist/generators/ts/AbstractNumericType.js +1 -1
  14. package/dist/generators/ts/AbstractType.d.ts +5 -5
  15. package/dist/generators/ts/AbstractUnionType.d.ts +1 -1
  16. package/dist/generators/ts/AbstractUnionType.js +6 -6
  17. package/dist/generators/ts/AnonymousUnionType.d.ts +1 -1
  18. package/dist/generators/ts/AnonymousUnionType.js +2 -2
  19. package/dist/generators/ts/BigDecimalType.d.ts +1 -1
  20. package/dist/generators/ts/BigDecimalType.js +2 -2
  21. package/dist/generators/ts/BigIntType.d.ts +1 -1
  22. package/dist/generators/ts/BigIntType.js +1 -1
  23. package/dist/generators/ts/BlankNodeType.d.ts +1 -1
  24. package/dist/generators/ts/BlankNodeType.js +1 -1
  25. package/dist/generators/ts/BooleanType.d.ts +1 -1
  26. package/dist/generators/ts/BooleanType.js +1 -1
  27. package/dist/generators/ts/DateTimeType.d.ts +1 -1
  28. package/dist/generators/ts/DateTimeType.js +1 -1
  29. package/dist/generators/ts/DateType.d.ts +1 -1
  30. package/dist/generators/ts/DateType.js +1 -1
  31. package/dist/generators/ts/DefaultValueType.d.ts +1 -1
  32. package/dist/generators/ts/DefaultValueType.js +3 -3
  33. package/dist/generators/ts/IdentifierType.d.ts +1 -1
  34. package/dist/generators/ts/IdentifierType.js +1 -1
  35. package/dist/generators/ts/IriType.d.ts +1 -1
  36. package/dist/generators/ts/IriType.js +1 -1
  37. package/dist/generators/ts/LazyObjectOptionType.js +1 -1
  38. package/dist/generators/ts/LazyObjectSetType.js +1 -1
  39. package/dist/generators/ts/LazyObjectType.js +2 -2
  40. package/dist/generators/ts/ListType.d.ts +2 -2
  41. package/dist/generators/ts/ListType.js +1 -1
  42. package/dist/generators/ts/LiteralType.d.ts +1 -1
  43. package/dist/generators/ts/LiteralType.js +1 -1
  44. package/dist/generators/ts/{ObjectType.d.ts → NamedObjectType.d.ts} +28 -28
  45. package/dist/generators/ts/{ObjectType.js → NamedObjectType.js} +105 -97
  46. package/dist/generators/ts/NamedObjectUnionType.d.ts +4 -4
  47. package/dist/generators/ts/NamedObjectUnionType.js +8 -12
  48. package/dist/generators/ts/OptionType.d.ts +1 -1
  49. package/dist/generators/ts/OptionType.js +2 -2
  50. package/dist/generators/ts/StringType.d.ts +1 -1
  51. package/dist/generators/ts/StringType.js +1 -1
  52. package/dist/generators/ts/TermType.d.ts +1 -1
  53. package/dist/generators/ts/TermType.js +1 -1
  54. package/dist/generators/ts/TsGenerator.js +8 -8
  55. package/dist/generators/ts/Type.d.ts +2 -2
  56. package/dist/generators/ts/TypeFactory.d.ts +2 -2
  57. package/dist/generators/ts/TypeFactory.js +36 -36
  58. package/dist/generators/ts/ZodGenerator.js +14 -12
  59. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/AbstractProperty.d.ts +6 -6
  60. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/AbstractProperty.js +3 -3
  61. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/DiscriminantProperty.d.ts +1 -1
  62. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/DiscriminantProperty.js +13 -11
  63. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/IdentifierPrefixProperty.d.ts +1 -1
  64. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/IdentifierPrefixProperty.js +4 -4
  65. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/IdentifierProperty.d.ts +1 -1
  66. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/IdentifierProperty.js +24 -24
  67. package/dist/generators/ts/_NamedObjectType/NamedObjectType_classDeclaration.d.ts +4 -0
  68. package/dist/generators/ts/{_ObjectType/ObjectType_classDeclaration.js → _NamedObjectType/NamedObjectType_classDeclaration.js} +14 -14
  69. package/dist/generators/ts/_NamedObjectType/NamedObjectType_createFunctionDeclaration.d.ts +5 -0
  70. package/dist/generators/ts/{_ObjectType/ObjectType_createFunctionDeclaration.js → _NamedObjectType/NamedObjectType_createFunctionDeclaration.js} +2 -2
  71. package/dist/generators/ts/_NamedObjectType/NamedObjectType_equalsFunctionOrMethodDeclaration.d.ts +5 -0
  72. package/dist/generators/ts/{_ObjectType/ObjectType_equalsFunctionOrMethodDeclaration.js → _NamedObjectType/NamedObjectType_equalsFunctionOrMethodDeclaration.js} +2 -2
  73. package/dist/generators/ts/_NamedObjectType/NamedObjectType_filterFunctionDeclaration.d.ts +4 -0
  74. package/dist/generators/ts/{_ObjectType/ObjectType_filterFunctionDeclaration.js → _NamedObjectType/NamedObjectType_filterFunctionDeclaration.js} +2 -2
  75. package/dist/generators/ts/_NamedObjectType/NamedObjectType_filterTypeDeclaration.d.ts +4 -0
  76. package/dist/generators/ts/{_ObjectType/ObjectType_filterTypeDeclaration.js → _NamedObjectType/NamedObjectType_filterTypeDeclaration.js} +2 -2
  77. package/dist/generators/ts/_NamedObjectType/NamedObjectType_focusSparqlConstructTriplesFunctionDeclaration.d.ts +5 -0
  78. package/dist/generators/ts/{_ObjectType/ObjectType_focusSparqlConstructTriplesFunctionDeclaration.js → _NamedObjectType/NamedObjectType_focusSparqlConstructTriplesFunctionDeclaration.js} +2 -2
  79. package/dist/generators/ts/_NamedObjectType/NamedObjectType_focusSparqlWherePatternsFunctionDeclaration.d.ts +5 -0
  80. package/dist/generators/ts/{_ObjectType/ObjectType_focusSparqlWherePatternsFunctionDeclaration.js → _NamedObjectType/NamedObjectType_focusSparqlWherePatternsFunctionDeclaration.js} +2 -2
  81. package/dist/generators/ts/_NamedObjectType/NamedObjectType_fromJsonFunctionDeclaration.d.ts +5 -0
  82. package/dist/generators/ts/{_ObjectType/ObjectType_fromJsonFunctionDeclaration.js → _NamedObjectType/NamedObjectType_fromJsonFunctionDeclaration.js} +2 -2
  83. package/dist/generators/ts/_NamedObjectType/NamedObjectType_fromRdfResourceFunctionDeclaration.d.ts +5 -0
  84. package/dist/generators/ts/{_ObjectType/ObjectType_fromRdfResourceFunctionDeclaration.js → _NamedObjectType/NamedObjectType_fromRdfResourceFunctionDeclaration.js} +2 -2
  85. package/dist/generators/ts/_NamedObjectType/NamedObjectType_fromRdfResourceValuesFunctionDeclaration.d.ts +5 -0
  86. package/dist/generators/ts/{_ObjectType/ObjectType_fromRdfResourceValuesFunctionDeclaration.js → _NamedObjectType/NamedObjectType_fromRdfResourceValuesFunctionDeclaration.js} +2 -2
  87. package/dist/generators/ts/_NamedObjectType/NamedObjectType_fromRdfTypeVariableStatement.d.ts +5 -0
  88. package/dist/generators/ts/{_ObjectType/ObjectType_fromRdfTypeVariableStatement.js → _NamedObjectType/NamedObjectType_fromRdfTypeVariableStatement.js} +2 -2
  89. package/dist/generators/ts/_NamedObjectType/NamedObjectType_graphqlTypeVariableStatement.d.ts +5 -0
  90. package/dist/generators/ts/{_ObjectType/ObjectType_graphqlTypeVariableStatement.js → _NamedObjectType/NamedObjectType_graphqlTypeVariableStatement.js} +2 -2
  91. package/dist/generators/ts/_NamedObjectType/NamedObjectType_hashFunctionOrMethodDeclarations.d.ts +4 -0
  92. package/dist/generators/ts/{_ObjectType/ObjectType_hashFunctionOrMethodDeclarations.js → _NamedObjectType/NamedObjectType_hashFunctionOrMethodDeclarations.js} +2 -2
  93. package/dist/generators/ts/_NamedObjectType/NamedObjectType_interfaceDeclaration.d.ts +4 -0
  94. package/dist/generators/ts/{_ObjectType/ObjectType_interfaceDeclaration.js → _NamedObjectType/NamedObjectType_interfaceDeclaration.js} +2 -2
  95. package/dist/generators/ts/_NamedObjectType/NamedObjectType_isTypeFunctionDeclaration.d.ts +4 -0
  96. package/dist/generators/ts/{_ObjectType/ObjectType_isTypeFunctionDeclaration.js → _NamedObjectType/NamedObjectType_isTypeFunctionDeclaration.js} +2 -2
  97. package/dist/generators/ts/_NamedObjectType/NamedObjectType_jsonParseFunctionDeclaration.d.ts +5 -0
  98. package/dist/generators/ts/_NamedObjectType/NamedObjectType_jsonParseFunctionDeclaration.js +19 -0
  99. package/dist/generators/ts/_NamedObjectType/NamedObjectType_jsonSchemaFunctionDeclaration.d.ts +5 -0
  100. package/dist/generators/ts/{_ObjectType/ObjectType_jsonZodSchemaFunctionDeclaration.js → _NamedObjectType/NamedObjectType_jsonSchemaFunctionDeclaration.js} +5 -5
  101. package/dist/generators/ts/_NamedObjectType/NamedObjectType_jsonTypeAliasDeclaration.d.ts +5 -0
  102. package/dist/generators/ts/{_ObjectType/ObjectType_jsonTypeAliasDeclaration.js → _NamedObjectType/NamedObjectType_jsonTypeAliasDeclaration.js} +2 -2
  103. package/dist/generators/ts/_NamedObjectType/NamedObjectType_jsonUiSchemaFunctionDeclaration.d.ts +5 -0
  104. package/dist/generators/ts/{_ObjectType/ObjectType_jsonUiSchemaFunctionDeclaration.js → _NamedObjectType/NamedObjectType_jsonUiSchemaFunctionDeclaration.js} +4 -4
  105. package/dist/generators/ts/_NamedObjectType/NamedObjectType_objectSetMethodNames.d.ts +9 -0
  106. package/dist/generators/ts/{_ObjectType/ObjectType_objectSetMethodNames.js → _NamedObjectType/NamedObjectType_objectSetMethodNames.js} +2 -2
  107. package/dist/generators/ts/_NamedObjectType/NamedObjectType_propertiesFromJsonFunctionDeclaration.d.ts +5 -0
  108. package/dist/generators/ts/{_ObjectType/ObjectType_propertiesFromJsonFunctionDeclaration.js → _NamedObjectType/NamedObjectType_propertiesFromJsonFunctionDeclaration.js} +2 -2
  109. package/dist/generators/ts/_NamedObjectType/NamedObjectType_propertiesFromRdfResourceFunctionDeclaration.d.ts +5 -0
  110. package/dist/generators/ts/{_ObjectType/ObjectType_propertiesFromRdfResourceFunctionDeclaration.js → _NamedObjectType/NamedObjectType_propertiesFromRdfResourceFunctionDeclaration.js} +2 -2
  111. package/dist/generators/ts/_NamedObjectType/NamedObjectType_schemaVariableStatement.d.ts +4 -0
  112. package/dist/generators/ts/{_ObjectType/ObjectType_schemaVariableStatement.js → _NamedObjectType/NamedObjectType_schemaVariableStatement.js} +2 -2
  113. package/dist/generators/ts/{_ObjectType/ObjectType_sparqlConstructQueryFunctionDeclaration.d.ts → _NamedObjectType/NamedObjectType_sparqlConstructQueryFunctionDeclaration.d.ts} +2 -2
  114. package/dist/generators/ts/{_ObjectType/ObjectType_sparqlConstructQueryFunctionDeclaration.js → _NamedObjectType/NamedObjectType_sparqlConstructQueryFunctionDeclaration.js} +2 -2
  115. package/dist/generators/ts/{_ObjectType/ObjectType_sparqlConstructQueryStringFunctionDeclaration.d.ts → _NamedObjectType/NamedObjectType_sparqlConstructQueryStringFunctionDeclaration.d.ts} +2 -2
  116. package/dist/generators/ts/{_ObjectType/ObjectType_sparqlConstructQueryStringFunctionDeclaration.js → _NamedObjectType/NamedObjectType_sparqlConstructQueryStringFunctionDeclaration.js} +2 -2
  117. package/dist/generators/ts/_NamedObjectType/NamedObjectType_toJsonFunctionOrMethodDeclaration.d.ts +5 -0
  118. package/dist/generators/ts/{_ObjectType/ObjectType_toJsonFunctionOrMethodDeclaration.js → _NamedObjectType/NamedObjectType_toJsonFunctionOrMethodDeclaration.js} +2 -2
  119. package/dist/generators/ts/_NamedObjectType/NamedObjectType_toRdfResourceFunctionOrMethodDeclaration.d.ts +5 -0
  120. package/dist/generators/ts/{_ObjectType/ObjectType_toRdfResourceFunctionOrMethodDeclaration.js → _NamedObjectType/NamedObjectType_toRdfResourceFunctionOrMethodDeclaration.js} +2 -2
  121. package/dist/generators/ts/_NamedObjectType/NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration.d.ts +5 -0
  122. package/dist/generators/ts/{_ObjectType/ObjectType_valueSparqlConstructTriplesFunctionDeclaration.js → _NamedObjectType/NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration.js} +2 -2
  123. package/dist/generators/ts/_NamedObjectType/NamedObjectType_valueSparqlWherePatternsFunctionDeclaration.d.ts +5 -0
  124. package/dist/generators/ts/{_ObjectType/ObjectType_valueSparqlWherePatternsFunctionDeclaration.js → _NamedObjectType/NamedObjectType_valueSparqlWherePatternsFunctionDeclaration.js} +2 -2
  125. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/ShaclProperty.d.ts +1 -1
  126. package/dist/generators/ts/{_ObjectType → _NamedObjectType}/ShaclProperty.js +8 -8
  127. package/dist/generators/ts/_NamedObjectType/identifierTypeDeclarations.d.ts +4 -0
  128. package/dist/generators/ts/graphqlSchemaVariableStatement.d.ts +2 -2
  129. package/dist/generators/ts/graphqlSchemaVariableStatement.js +23 -23
  130. package/dist/generators/ts/objectSetDeclarations.d.ts +2 -2
  131. package/dist/generators/ts/objectSetDeclarations.js +19 -16
  132. package/dist/generators/ts/objectSetInterfaceDeclaration.d.ts +3 -3
  133. package/dist/generators/ts/objectSetInterfaceDeclaration.js +6 -4
  134. package/dist/generators/ts/objectSetMethodSignatures.d.ts +4 -4
  135. package/dist/generators/ts/objectSetMethodSignatures.js +9 -9
  136. package/dist/generators/ts/rdfjsDatasetObjectSetClassDeclaration.d.ts +3 -3
  137. package/dist/generators/ts/rdfjsDatasetObjectSetClassDeclaration.js +47 -45
  138. package/dist/generators/ts/singleEntryRecord.d.ts +2 -0
  139. package/dist/generators/ts/singleEntryRecord.js +6 -0
  140. package/dist/generators/ts/sparqlObjectSetClassDeclaration.d.ts +3 -3
  141. package/dist/generators/ts/sparqlObjectSetClassDeclaration.js +17 -17
  142. package/dist/generators/ts/synthesizeUberObjectUnionType.d.ts +2 -2
  143. package/dist/generators/ts/synthesizeUberObjectUnionType.js +8 -8
  144. package/dist/generators/ts/unsupportedObjectSetMethodDeclarations.d.ts +5 -5
  145. package/dist/generators/ts/unsupportedObjectSetMethodDeclarations.js +2 -2
  146. package/package.json +4 -4
  147. package/dist/generators/ts/_ObjectType/ObjectType_classDeclaration.d.ts +0 -4
  148. package/dist/generators/ts/_ObjectType/ObjectType_createFunctionDeclaration.d.ts +0 -5
  149. package/dist/generators/ts/_ObjectType/ObjectType_equalsFunctionOrMethodDeclaration.d.ts +0 -5
  150. package/dist/generators/ts/_ObjectType/ObjectType_filterFunctionDeclaration.d.ts +0 -4
  151. package/dist/generators/ts/_ObjectType/ObjectType_filterTypeDeclaration.d.ts +0 -4
  152. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlConstructTriplesFunctionDeclaration.d.ts +0 -5
  153. package/dist/generators/ts/_ObjectType/ObjectType_focusSparqlWherePatternsFunctionDeclaration.d.ts +0 -5
  154. package/dist/generators/ts/_ObjectType/ObjectType_fromJsonFunctionDeclaration.d.ts +0 -5
  155. package/dist/generators/ts/_ObjectType/ObjectType_fromRdfResourceFunctionDeclaration.d.ts +0 -5
  156. package/dist/generators/ts/_ObjectType/ObjectType_fromRdfResourceValuesFunctionDeclaration.d.ts +0 -5
  157. package/dist/generators/ts/_ObjectType/ObjectType_fromRdfTypeVariableStatement.d.ts +0 -5
  158. package/dist/generators/ts/_ObjectType/ObjectType_graphqlTypeVariableStatement.d.ts +0 -5
  159. package/dist/generators/ts/_ObjectType/ObjectType_hashFunctionOrMethodDeclarations.d.ts +0 -4
  160. package/dist/generators/ts/_ObjectType/ObjectType_interfaceDeclaration.d.ts +0 -4
  161. package/dist/generators/ts/_ObjectType/ObjectType_isTypeFunctionDeclaration.d.ts +0 -4
  162. package/dist/generators/ts/_ObjectType/ObjectType_jsonSchemaFunctionDeclaration.d.ts +0 -5
  163. package/dist/generators/ts/_ObjectType/ObjectType_jsonSchemaFunctionDeclaration.js +0 -14
  164. package/dist/generators/ts/_ObjectType/ObjectType_jsonTypeAliasDeclaration.d.ts +0 -5
  165. package/dist/generators/ts/_ObjectType/ObjectType_jsonUiSchemaFunctionDeclaration.d.ts +0 -5
  166. package/dist/generators/ts/_ObjectType/ObjectType_jsonZodSchemaFunctionDeclaration.d.ts +0 -5
  167. package/dist/generators/ts/_ObjectType/ObjectType_objectSetMethodNames.d.ts +0 -9
  168. package/dist/generators/ts/_ObjectType/ObjectType_parseJsonFunctionDeclaration.d.ts +0 -5
  169. package/dist/generators/ts/_ObjectType/ObjectType_parseJsonFunctionDeclaration.js +0 -19
  170. package/dist/generators/ts/_ObjectType/ObjectType_propertiesFromJsonFunctionDeclaration.d.ts +0 -5
  171. package/dist/generators/ts/_ObjectType/ObjectType_propertiesFromRdfResourceFunctionDeclaration.d.ts +0 -5
  172. package/dist/generators/ts/_ObjectType/ObjectType_schemaVariableStatement.d.ts +0 -4
  173. package/dist/generators/ts/_ObjectType/ObjectType_toJsonFunctionOrMethodDeclaration.d.ts +0 -5
  174. package/dist/generators/ts/_ObjectType/ObjectType_toRdfResourceFunctionOrMethodDeclaration.d.ts +0 -5
  175. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlConstructTriplesFunctionDeclaration.d.ts +0 -5
  176. package/dist/generators/ts/_ObjectType/ObjectType_valueSparqlWherePatternsFunctionDeclaration.d.ts +0 -5
  177. package/dist/generators/ts/_ObjectType/identifierTypeDeclarations.d.ts +0 -4
  178. /package/dist/generators/ts/{_ObjectType → _NamedObjectType}/Property.d.ts +0 -0
  179. /package/dist/generators/ts/{_ObjectType → _NamedObjectType}/Property.js +0 -0
  180. /package/dist/generators/ts/{_ObjectType → _NamedObjectType}/identifierTypeDeclarations.js +0 -0
@@ -1,18 +1,18 @@
1
1
  import { Maybe } from "purify-ts";
2
2
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
3
3
  import { code, joinCode } from "../ts-poet-wrapper.js";
4
- export function ObjectType_jsonUiSchemaFunctionDeclaration() {
4
+ export function NamedObjectType_jsonUiSchemaFunctionDeclaration() {
5
5
  if (!this.features.has("json")) {
6
6
  return Maybe.empty();
7
7
  }
8
8
  const variables = { scopePrefix: code `scopePrefix` };
9
9
  const elements = this.parentObjectTypes
10
- .map((parentObjectType) => code `${parentObjectType.staticModuleName}.${syntheticNamePrefix}jsonUiSchema({ scopePrefix })`)
10
+ .map((parentObjectType) => code `${parentObjectType.staticModuleName}.${syntheticNamePrefix}Json.uiSchema({ scopePrefix })`)
11
11
  .concat(this.ownProperties.flatMap((property) => property.jsonUiSchemaElement({ variables }).toList()));
12
12
  return Maybe.of(code `\
13
- export function ${syntheticNamePrefix}jsonUiSchema(parameters?: { scopePrefix?: string }): any {
13
+ export function uiSchema(parameters?: { scopePrefix?: string }): any {
14
14
  const scopePrefix = parameters?.scopePrefix ?? "#";
15
15
  return { "elements": [ ${joinCode(elements, { on: "," })} ], label: "${this.label.orDefault(this.name)}", type: "Group" };
16
16
  }`);
17
17
  }
18
- //# sourceMappingURL=ObjectType_jsonUiSchemaFunctionDeclaration.js.map
18
+ //# sourceMappingURL=NamedObjectType_jsonUiSchemaFunctionDeclaration.js.map
@@ -0,0 +1,9 @@
1
+ export declare function NamedObjectType_objectSetMethodNames(this: {
2
+ readonly name: string;
3
+ }): {
4
+ object: string;
5
+ objectCount: string;
6
+ objectIdentifiers: string;
7
+ objects: string;
8
+ };
9
+ //# sourceMappingURL=NamedObjectType_objectSetMethodNames.d.ts.map
@@ -1,6 +1,6 @@
1
1
  import { camelCase, trainCase } from "change-case";
2
2
  import plur from "plur";
3
- export function ObjectType_objectSetMethodNames() {
3
+ export function NamedObjectType_objectSetMethodNames() {
4
4
  const prefixSingular = camelCase(this.name);
5
5
  const thisNameParts = trainCase(this.name).split("-");
6
6
  let prefixPlural = camelCase(`${thisNameParts.slice(0, thisNameParts.length - 1).join("")}${plur(thisNameParts[thisNameParts.length - 1])}`);
@@ -15,4 +15,4 @@ export function ObjectType_objectSetMethodNames() {
15
15
  objects: prefixPlural,
16
16
  };
17
17
  }
18
- //# sourceMappingURL=ObjectType_objectSetMethodNames.js.map
18
+ //# sourceMappingURL=NamedObjectType_objectSetMethodNames.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_propertiesFromJsonFunctionDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_propertiesFromJsonFunctionDeclaration.d.ts.map
@@ -4,7 +4,7 @@ import { code, joinCode } from "../ts-poet-wrapper.js";
4
4
  const variables = {
5
5
  jsonObject: code `${syntheticNamePrefix}json`,
6
6
  };
7
- export function ObjectType_propertiesFromJsonFunctionDeclaration() {
7
+ export function NamedObjectType_propertiesFromJsonFunctionDeclaration() {
8
8
  if (!this.features.has("json")) {
9
9
  return Maybe.empty();
10
10
  }
@@ -35,4 +35,4 @@ export function ${syntheticNamePrefix}propertiesFromJson(${variables.jsonObject}
35
35
  ${joinCode(statements)}
36
36
  }`);
37
37
  }
38
- //# sourceMappingURL=ObjectType_propertiesFromJsonFunctionDeclaration.js.map
38
+ //# sourceMappingURL=NamedObjectType_propertiesFromJsonFunctionDeclaration.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_propertiesFromRdfResourceFunctionDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_propertiesFromRdfResourceFunctionDeclaration.d.ts.map
@@ -14,7 +14,7 @@ const variables = {
14
14
  preferredLanguages: code `${optionsVariable}.preferredLanguages`,
15
15
  resource: code `${syntheticNamePrefix}resource`,
16
16
  };
17
- export function ObjectType_propertiesFromRdfResourceFunctionDeclaration() {
17
+ export function NamedObjectType_propertiesFromRdfResourceFunctionDeclaration() {
18
18
  if (!this.features.has("rdf")) {
19
19
  return Maybe.empty();
20
20
  }
@@ -98,4 +98,4 @@ export const ${syntheticNamePrefix}propertiesFromRdfResource: ${snippets.Propert
98
98
  ${joinCode(statements)}
99
99
  };`);
100
100
  }
101
- //# sourceMappingURL=ObjectType_propertiesFromRdfResourceFunctionDeclaration.js.map
101
+ //# sourceMappingURL=NamedObjectType_propertiesFromRdfResourceFunctionDeclaration.js.map
@@ -0,0 +1,4 @@
1
+ import type { NamedObjectType } from "../NamedObjectType.js";
2
+ import { type Code } from "../ts-poet-wrapper.js";
3
+ export declare function NamedObjectType_schemaVariableStatement(this: NamedObjectType): Code;
4
+ //# sourceMappingURL=NamedObjectType_schemaVariableStatement.d.ts.map
@@ -1,9 +1,9 @@
1
1
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
2
2
  import { code, joinCode } from "../ts-poet-wrapper.js";
3
- export function ObjectType_schemaVariableStatement() {
3
+ export function NamedObjectType_schemaVariableStatement() {
4
4
  return code `\
5
5
  export const ${syntheticNamePrefix}schema = { properties: { ${joinCode(this.parentObjectTypes
6
6
  .map((parentObjectType) => code `...${parentObjectType.staticModuleName}.${syntheticNamePrefix}schema.properties`)
7
7
  .concat(this.ownProperties.map((property) => code `${property.name}: ${property.schema}`)), { on: ", " })} } } as const;`;
8
8
  }
9
- //# sourceMappingURL=ObjectType_schemaVariableStatement.js.map
9
+ //# sourceMappingURL=NamedObjectType_schemaVariableStatement.js.map
@@ -1,10 +1,10 @@
1
1
  import { Maybe } from "purify-ts";
2
2
  import type { TsFeature } from "../../../enums/TsFeature.js";
3
3
  import { type Code } from "../ts-poet-wrapper.js";
4
- export declare function ObjectType_sparqlConstructQueryFunctionDeclaration(this: {
4
+ export declare function NamedObjectType_sparqlConstructQueryFunctionDeclaration(this: {
5
5
  readonly features: ReadonlySet<TsFeature>;
6
6
  readonly filterType: Code;
7
7
  readonly name: string;
8
8
  readonly staticModuleName: string;
9
9
  }): Maybe<Code>;
10
- //# sourceMappingURL=ObjectType_sparqlConstructQueryFunctionDeclaration.d.ts.map
10
+ //# sourceMappingURL=NamedObjectType_sparqlConstructQueryFunctionDeclaration.d.ts.map
@@ -4,7 +4,7 @@ import { imports } from "../imports.js";
4
4
  import { snippets } from "../snippets.js";
5
5
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
6
6
  import { code } from "../ts-poet-wrapper.js";
7
- export function ObjectType_sparqlConstructQueryFunctionDeclaration() {
7
+ export function NamedObjectType_sparqlConstructQueryFunctionDeclaration() {
8
8
  if (!this.features.has("sparql")) {
9
9
  return Maybe.empty();
10
10
  }
@@ -39,4 +39,4 @@ export function ${syntheticNamePrefix}sparqlConstructQuery({ filter, ignoreRdfTy
39
39
  };
40
40
  }`);
41
41
  }
42
- //# sourceMappingURL=ObjectType_sparqlConstructQueryFunctionDeclaration.js.map
42
+ //# sourceMappingURL=NamedObjectType_sparqlConstructQueryFunctionDeclaration.js.map
@@ -1,9 +1,9 @@
1
1
  import { Maybe } from "purify-ts";
2
2
  import type { TsFeature } from "../../../enums/TsFeature.js";
3
3
  import { type Code } from "../ts-poet-wrapper.js";
4
- export declare function ObjectType_sparqlConstructQueryStringFunctionDeclaration(this: {
4
+ export declare function NamedObjectType_sparqlConstructQueryStringFunctionDeclaration(this: {
5
5
  readonly features: ReadonlySet<TsFeature>;
6
6
  readonly filterType: Code;
7
7
  readonly staticModuleName: string;
8
8
  }): Maybe<Code>;
9
- //# sourceMappingURL=ObjectType_sparqlConstructQueryStringFunctionDeclaration.d.ts.map
9
+ //# sourceMappingURL=NamedObjectType_sparqlConstructQueryStringFunctionDeclaration.d.ts.map
@@ -2,7 +2,7 @@ import { Maybe } from "purify-ts";
2
2
  import { imports } from "../imports.js";
3
3
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
4
4
  import { code } from "../ts-poet-wrapper.js";
5
- export function ObjectType_sparqlConstructQueryStringFunctionDeclaration() {
5
+ export function NamedObjectType_sparqlConstructQueryStringFunctionDeclaration() {
6
6
  if (!this.features.has("sparql")) {
7
7
  return Maybe.empty();
8
8
  }
@@ -11,4 +11,4 @@ export function ${syntheticNamePrefix}sparqlConstructQueryString(parameters: Par
11
11
  return new ${imports.sparqljs}.Generator(parameters).stringify(${this.staticModuleName}.${syntheticNamePrefix}sparqlConstructQuery(parameters));
12
12
  }`);
13
13
  }
14
- //# sourceMappingURL=ObjectType_sparqlConstructQueryStringFunctionDeclaration.js.map
14
+ //# sourceMappingURL=NamedObjectType_sparqlConstructQueryStringFunctionDeclaration.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_toJsonFunctionOrMethodDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_toJsonFunctionOrMethodDeclaration.d.ts.map
@@ -1,7 +1,7 @@
1
1
  import { Maybe } from "purify-ts";
2
2
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
3
3
  import { code, joinCode } from "../ts-poet-wrapper.js";
4
- export function ObjectType_toJsonFunctionOrMethodDeclaration() {
4
+ export function NamedObjectType_toJsonFunctionOrMethodDeclaration() {
5
5
  if (!this.features.has("json")) {
6
6
  return Maybe.empty();
7
7
  }
@@ -56,4 +56,4 @@ ${preamble}${syntheticNamePrefix}toJson(${joinCode(parameters, { on: ", " })}):
56
56
  return JSON.parse(JSON.stringify({ ${joinCode(jsonObjectMembers, { on: "," })} } satisfies ${this.jsonType().name}));
57
57
  }`);
58
58
  }
59
- //# sourceMappingURL=ObjectType_toJsonFunctionOrMethodDeclaration.js.map
59
+ //# sourceMappingURL=NamedObjectType_toJsonFunctionOrMethodDeclaration.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_toRdfResourceFunctionOrMethodDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_toRdfResourceFunctionOrMethodDeclaration.d.ts.map
@@ -5,7 +5,7 @@ import { rdfjsTermExpression } from "../rdfjsTermExpression.js";
5
5
  import { snippets } from "../snippets.js";
6
6
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
7
7
  import { code, joinCode } from "../ts-poet-wrapper.js";
8
- export function ObjectType_toRdfResourceFunctionOrMethodDeclaration() {
8
+ export function NamedObjectType_toRdfResourceFunctionOrMethodDeclaration() {
9
9
  if (!this.features.has("rdf")) {
10
10
  return Maybe.empty();
11
11
  }
@@ -64,4 +64,4 @@ const variables = {
64
64
  resource: code `resource`,
65
65
  resourceSet: code `resourceSet`,
66
66
  };
67
- //# sourceMappingURL=ObjectType_toRdfResourceFunctionOrMethodDeclaration.js.map
67
+ //# sourceMappingURL=NamedObjectType_toRdfResourceFunctionOrMethodDeclaration.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration.d.ts.map
@@ -2,7 +2,7 @@ import { Maybe } from "purify-ts";
2
2
  import { snippets } from "../snippets.js";
3
3
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
4
4
  import { code } from "../ts-poet-wrapper.js";
5
- export function ObjectType_valueSparqlConstructTriplesFunctionDeclaration() {
5
+ export function NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration() {
6
6
  if (!this.features.has("sparql")) {
7
7
  return Maybe.empty();
8
8
  }
@@ -10,4 +10,4 @@ export function ObjectType_valueSparqlConstructTriplesFunctionDeclaration() {
10
10
  export const ${syntheticNamePrefix}valueSparqlConstructTriples: ${snippets.ValueSparqlConstructTriplesFunction}<${this.filterType}, ${this.schemaType}> = ({ filter, ignoreRdfType, valueVariable, variablePrefix }) =>
11
11
  ${this.staticModuleName}.${syntheticNamePrefix}focusSparqlConstructTriples({ filter, focusIdentifier: valueVariable, ignoreRdfType, variablePrefix });`);
12
12
  }
13
- //# sourceMappingURL=ObjectType_valueSparqlConstructTriplesFunctionDeclaration.js.map
13
+ //# sourceMappingURL=NamedObjectType_valueSparqlConstructTriplesFunctionDeclaration.js.map
@@ -0,0 +1,5 @@
1
+ import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "../NamedObjectType.js";
3
+ import { type Code } from "../ts-poet-wrapper.js";
4
+ export declare function NamedObjectType_valueSparqlWherePatternsFunctionDeclaration(this: NamedObjectType): Maybe<Code>;
5
+ //# sourceMappingURL=NamedObjectType_valueSparqlWherePatternsFunctionDeclaration.d.ts.map
@@ -2,7 +2,7 @@ import { Maybe } from "purify-ts";
2
2
  import { snippets } from "../snippets.js";
3
3
  import { syntheticNamePrefix } from "../syntheticNamePrefix.js";
4
4
  import { code } from "../ts-poet-wrapper.js";
5
- export function ObjectType_valueSparqlWherePatternsFunctionDeclaration() {
5
+ export function NamedObjectType_valueSparqlWherePatternsFunctionDeclaration() {
6
6
  if (!this.features.has("sparql")) {
7
7
  return Maybe.empty();
8
8
  }
@@ -12,4 +12,4 @@ export const ${syntheticNamePrefix}valueSparqlWherePatterns: ${snippets.ValueSpa
12
12
  ${this.staticModuleName}.${syntheticNamePrefix}focusSparqlWherePatterns({ filter, focusIdentifier: valueVariable, ignoreRdfType, preferredLanguages, variablePrefix })
13
13
  );`);
14
14
  }
15
- //# sourceMappingURL=ObjectType_valueSparqlWherePatternsFunctionDeclaration.js.map
15
+ //# sourceMappingURL=NamedObjectType_valueSparqlWherePatternsFunctionDeclaration.js.map
@@ -29,7 +29,7 @@ export declare class ShaclProperty<TypeT extends Type> extends AbstractProperty<
29
29
  get getAccessorDeclaration(): Maybe<Code>;
30
30
  get graphqlField(): AbstractProperty<TypeT>["graphqlField"];
31
31
  get jsonSignature(): Maybe<Code>;
32
- get jsonZodSchema(): AbstractProperty<TypeT>["jsonZodSchema"];
32
+ get jsonZchema(): AbstractProperty<TypeT>["jsonZchema"];
33
33
  protected get schemaObject(): {
34
34
  path: Code | undefined;
35
35
  kind: Code;
@@ -59,7 +59,7 @@ export class ShaclProperty extends AbstractProperty {
59
59
  }
60
60
  get declaration() {
61
61
  const lhs = [];
62
- if (this.objectType.declarationType === "class" &&
62
+ if (this.namedObjectType.declarationType === "class" &&
63
63
  this.visibility !== "public") {
64
64
  lhs.push(code `${this.visibility}`);
65
65
  }
@@ -103,8 +103,8 @@ export class ShaclProperty extends AbstractProperty {
103
103
  const typeJsonType = this.type.jsonType();
104
104
  return Maybe.of(code `readonly ${this.name}${typeJsonType.optional ? "?" : ""}: ${typeJsonType.requiredName}`);
105
105
  }
106
- get jsonZodSchema() {
107
- let schema = this.type.jsonZodSchema({
106
+ get jsonZchema() {
107
+ let schema = this.type.jsonSchema({
108
108
  context: "property",
109
109
  });
110
110
  this.comment.alt(this.description).ifJust((description) => {
@@ -120,7 +120,7 @@ export class ShaclProperty extends AbstractProperty {
120
120
  ...super.schemaObject,
121
121
  // comment: this.comment.map(JSON.stringify).extract(),
122
122
  // description: this.description.map(JSON.stringify).extract(),
123
- path: this.objectType.features.has("rdf")
123
+ path: this.namedObjectType.features.has("rdf")
124
124
  ? propertyPathToCode(this.path)
125
125
  : undefined,
126
126
  // label: this.label.map(JSON.stringify).extract(),
@@ -135,7 +135,7 @@ export class ShaclProperty extends AbstractProperty {
135
135
  constructorStatements({ variables, }) {
136
136
  const typeConversions = this.type.conversions;
137
137
  if (typeConversions.length === 1) {
138
- switch (this.objectType.declarationType) {
138
+ switch (this.namedObjectType.declarationType) {
139
139
  case "class":
140
140
  return [code `this.${this.name} = ${variables.parameter};`];
141
141
  case "interface":
@@ -144,7 +144,7 @@ export class ShaclProperty extends AbstractProperty {
144
144
  }
145
145
  let lhs;
146
146
  const statements = [];
147
- switch (this.objectType.declarationType) {
147
+ switch (this.namedObjectType.declarationType) {
148
148
  case "class":
149
149
  lhs = `this.${this.name}`;
150
150
  break;
@@ -176,7 +176,7 @@ export class ShaclProperty extends AbstractProperty {
176
176
  variables: {
177
177
  ...variables,
178
178
  ignoreRdfType: true,
179
- propertyPath: code `${this.objectType.staticModuleName}.${syntheticNamePrefix}schema.properties.${this.name}.path`,
179
+ propertyPath: code `${this.namedObjectType.staticModuleName}.${syntheticNamePrefix}schema.properties.${this.name}.path`,
180
180
  resourceValues: code `resourceValues`,
181
181
  },
182
182
  })})`,
@@ -263,5 +263,5 @@ __decorate([
263
263
  ], ShaclProperty.prototype, "jsonSignature", null);
264
264
  __decorate([
265
265
  Memoize()
266
- ], ShaclProperty.prototype, "jsonZodSchema", null);
266
+ ], ShaclProperty.prototype, "jsonZchema", null);
267
267
  //# sourceMappingURL=ShaclProperty.js.map
@@ -0,0 +1,4 @@
1
+ import type { NamedObjectType } from "../NamedObjectType.js";
2
+ import { type Code } from "../ts-poet-wrapper.js";
3
+ export declare function identifierTypeDeclarations(this: NamedObjectType): readonly Code[];
4
+ //# sourceMappingURL=identifierTypeDeclarations.d.ts.map
@@ -1,9 +1,9 @@
1
1
  import { Maybe } from "purify-ts";
2
+ import type { NamedObjectType } from "./NamedObjectType.js";
2
3
  import type { NamedObjectUnionType } from "./NamedObjectUnionType.js";
3
- import type { ObjectType } from "./ObjectType.js";
4
4
  import { type Code } from "./ts-poet-wrapper.js";
5
5
  export declare function graphqlSchemaVariableStatement(parameters: {
6
- objectTypes: readonly ObjectType[];
6
+ namedObjectTypes: readonly NamedObjectType[];
7
7
  namedObjectUnionTypes: NamedObjectUnionType[];
8
8
  }): Maybe<Code>;
9
9
  //# sourceMappingURL=graphqlSchemaVariableStatement.d.ts.map
@@ -2,25 +2,25 @@ import { Maybe } from "purify-ts";
2
2
  import { imports } from "./imports.js";
3
3
  import { syntheticNamePrefix } from "./syntheticNamePrefix.js";
4
4
  import { code } from "./ts-poet-wrapper.js";
5
- function graphqlQueryObjectType({ objectTypes, namedObjectUnionTypes, }) {
5
+ function graphqlQueryObjectType({ namedObjectTypes, namedObjectUnionTypes, }) {
6
6
  return code `new ${imports.GraphQLObjectType}<null, { objectSet: ${syntheticNamePrefix}ObjectSet }>({ name: "Query", fields: ${[
7
- ...objectTypes,
7
+ ...namedObjectTypes,
8
8
  ...namedObjectUnionTypes,
9
- ].reduce((fields, objectType) => {
10
- fields[objectType.objectSetMethodNames.object] = {
9
+ ].reduce((fields, namedObjectType) => {
10
+ fields[namedObjectType.objectSetMethodNames.object] = {
11
11
  args: {
12
12
  identifier: {
13
13
  type: code `new ${imports.GraphQLNonNull}(${imports.GraphQLID})`,
14
14
  },
15
15
  },
16
16
  resolve: code `\
17
- async (_source, args: { identifier: string }, { objectSet }): Promise<${objectType.name}> =>
18
- (await ${imports.EitherAsync}<Error, ${objectType.name}>(async ({ liftEither }) =>
19
- liftEither(await objectSet.${objectType.objectSetMethodNames.object}(await liftEither(${objectType.identifierTypeAlias}.fromString(args.identifier))))
17
+ async (_source, args: { identifier: string }, { objectSet }): Promise<${namedObjectType.name}> =>
18
+ (await ${imports.EitherAsync}<Error, ${namedObjectType.name}>(async ({ liftEither }) =>
19
+ liftEither(await objectSet.${namedObjectType.objectSetMethodNames.object}(await liftEither(${namedObjectType.identifierTypeAlias}.fromString(args.identifier))))
20
20
  )).unsafeCoerce()`,
21
- type: objectType.graphqlType.name,
21
+ type: namedObjectType.graphqlType.name,
22
22
  };
23
- fields[objectType.objectSetMethodNames.objectIdentifiers] = {
23
+ fields[namedObjectType.objectSetMethodNames.objectIdentifiers] = {
24
24
  args: {
25
25
  limit: {
26
26
  type: code `${imports.GraphQLInt}`,
@@ -31,10 +31,10 @@ async (_source, args: { identifier: string }, { objectSet }): Promise<${objectTy
31
31
  },
32
32
  resolve: code `\
33
33
  async (_source, args: { limit: number | null; offset: number | null; }, { objectSet }): Promise<readonly string[]> =>
34
- (await objectSet.${objectType.objectSetMethodNames.objectIdentifiers}({ limit: args.limit !== null ? args.limit : undefined, offset: args.offset !== null ? args.offset : undefined })).unsafeCoerce().map(${objectType.identifierTypeAlias}.toString)`,
34
+ (await objectSet.${namedObjectType.objectSetMethodNames.objectIdentifiers}({ limit: args.limit !== null ? args.limit : undefined, offset: args.offset !== null ? args.offset : undefined })).unsafeCoerce().map(${namedObjectType.identifierTypeAlias}.toString)`,
35
35
  type: code `new ${imports.GraphQLNonNull}(new ${imports.GraphQLList}(${imports.GraphQLString}))`,
36
36
  };
37
- fields[objectType.objectSetMethodNames.objects] = {
37
+ fields[namedObjectType.objectSetMethodNames.objects] = {
38
38
  args: {
39
39
  identifiers: {
40
40
  type: code `new ${imports.GraphQLList}(new ${imports.GraphQLNonNull}(${imports.GraphQLID}))`,
@@ -47,36 +47,36 @@ async (_source, args: { identifier: string }, { objectSet }): Promise<${objectTy
47
47
  },
48
48
  },
49
49
  resolve: code `\
50
- async (_source, args: { identifiers: readonly string[] | null; limit: number | null; offset: number | null; }, { objectSet }): Promise<readonly ${objectType.name}[]> =>
51
- (await ${imports.EitherAsync}<Error, readonly ${objectType.name}[]>(async ({ liftEither }) => {
52
- let filter: ${objectType.filterType} | undefined;
50
+ async (_source, args: { identifiers: readonly string[] | null; limit: number | null; offset: number | null; }, { objectSet }): Promise<readonly ${namedObjectType.name}[]> =>
51
+ (await ${imports.EitherAsync}<Error, readonly ${namedObjectType.name}[]>(async ({ liftEither }) => {
52
+ let filter: ${namedObjectType.filterType} | undefined;
53
53
  if (args.identifiers) {
54
- const identifiers: ${objectType.identifierTypeAlias}[] = [];
54
+ const identifiers: ${namedObjectType.identifierTypeAlias}[] = [];
55
55
  for (const identifierArg of args.identifiers) {
56
- identifiers.push(await liftEither(${objectType.identifierTypeAlias}.fromString(identifierArg)));
56
+ identifiers.push(await liftEither(${namedObjectType.identifierTypeAlias}.fromString(identifierArg)));
57
57
  }
58
58
  filter = { ${syntheticNamePrefix}identifier: { in: identifiers } };
59
59
  }
60
- return await liftEither(await objectSet.${objectType.objectSetMethodNames.objects}({ filter, limit: args.limit !== null ? args.limit : undefined, offset: args.offset !== null ? args.offset : undefined }));
60
+ return await liftEither(await objectSet.${namedObjectType.objectSetMethodNames.objects}({ filter, limit: args.limit !== null ? args.limit : undefined, offset: args.offset !== null ? args.offset : undefined }));
61
61
  })).unsafeCoerce()`,
62
- type: code `new ${imports.GraphQLNonNull}(new ${imports.GraphQLList}(${objectType.graphqlType.name}))`,
62
+ type: code `new ${imports.GraphQLNonNull}(new ${imports.GraphQLList}(${namedObjectType.graphqlType.name}))`,
63
63
  };
64
- fields[objectType.objectSetMethodNames.objectCount] = {
64
+ fields[namedObjectType.objectSetMethodNames.objectCount] = {
65
65
  resolve: code `\
66
- async (_source, _args, { objectSet }): Promise<number> => (await objectSet.${objectType.objectSetMethodNames.objectCount}()).unsafeCoerce()`,
66
+ async (_source, _args, { objectSet }): Promise<number> => (await objectSet.${namedObjectType.objectSetMethodNames.objectCount}()).unsafeCoerce()`,
67
67
  type: code `new ${imports.GraphQLNonNull}(${imports.GraphQLInt})`,
68
68
  };
69
69
  return fields;
70
70
  }, {})} })`;
71
71
  }
72
72
  export function graphqlSchemaVariableStatement(parameters) {
73
- const objectTypes = parameters.objectTypes.filter((objectType) => objectType.features.has("graphql") && !objectType.synthetic);
73
+ const namedObjectTypes = parameters.namedObjectTypes.filter((namedObjectType) => namedObjectType.features.has("graphql") && !namedObjectType.synthetic);
74
74
  const namedObjectUnionTypes = parameters.namedObjectUnionTypes.filter((namedObjectUnionType) => namedObjectUnionType.features.has("graphql"));
75
- if (objectTypes.length === 0) {
75
+ if (namedObjectTypes.length === 0) {
76
76
  return Maybe.empty();
77
77
  }
78
78
  return Maybe.of(code `\
79
- export const graphqlSchema = new ${imports.GraphQLSchema}({ query: ${graphqlQueryObjectType({ objectTypes, namedObjectUnionTypes })} });
79
+ export const graphqlSchema = new ${imports.GraphQLSchema}({ query: ${graphqlQueryObjectType({ namedObjectTypes: namedObjectTypes, namedObjectUnionTypes })} });
80
80
  `);
81
81
  }
82
82
  //# sourceMappingURL=graphqlSchemaVariableStatement.js.map
@@ -1,8 +1,8 @@
1
+ import type { NamedObjectType } from "./NamedObjectType.js";
1
2
  import type { NamedObjectUnionType } from "./NamedObjectUnionType.js";
2
- import type { ObjectType } from "./ObjectType.js";
3
3
  import type { Code } from "./ts-poet-wrapper.js";
4
4
  export declare function objectSetDeclarations({ namedObjectUnionTypes, ...parameters }: {
5
- objectTypes: readonly ObjectType[];
5
+ namedObjectTypes: readonly NamedObjectType[];
6
6
  namedObjectUnionTypes: readonly NamedObjectUnionType[];
7
7
  }): readonly Code[];
8
8
  //# sourceMappingURL=objectSetDeclarations.d.ts.map
@@ -2,18 +2,21 @@ import { objectSetInterfaceDeclaration } from "./objectSetInterfaceDeclaration.j
2
2
  import { rdfjsDatasetObjectSetClassDeclaration } from "./rdfjsDatasetObjectSetClassDeclaration.js";
3
3
  import { sparqlObjectSetClassDeclaration } from "./sparqlObjectSetClassDeclaration.js";
4
4
  export function objectSetDeclarations({ namedObjectUnionTypes, ...parameters }) {
5
- const objectTypes = parameters.objectTypes.filter((objectType) => !objectType.abstract && !objectType.extern && !objectType.synthetic);
6
- let objectTypesWithRdfFeatureCount = 0;
7
- let objectTypesWithSparqlFeatureCount = 0;
8
- for (const objectType of objectTypes) {
9
- if (!objectType.features.has("rdf") && !objectType.features.has("sparql")) {
5
+ const namedObjectTypes = parameters.namedObjectTypes.filter((namedObjectType) => !namedObjectType.abstract &&
6
+ !namedObjectType.extern &&
7
+ !namedObjectType.synthetic);
8
+ let namedObjectTypesWithRdfFeatureCount = 0;
9
+ let namedObjectTypesWithSparqlFeatureCount = 0;
10
+ for (const namedObjectType of namedObjectTypes) {
11
+ if (!namedObjectType.features.has("rdf") &&
12
+ !namedObjectType.features.has("sparql")) {
10
13
  continue;
11
14
  }
12
- if (objectType.features.has("rdf")) {
13
- objectTypesWithRdfFeatureCount++;
15
+ if (namedObjectType.features.has("rdf")) {
16
+ namedObjectTypesWithRdfFeatureCount++;
14
17
  }
15
- if (objectType.features.has("sparql")) {
16
- objectTypesWithSparqlFeatureCount++;
18
+ if (namedObjectType.features.has("sparql")) {
19
+ namedObjectTypesWithSparqlFeatureCount++;
17
20
  }
18
21
  }
19
22
  let namedObjectUnionTypesWithRdfFeatureCount = 0;
@@ -30,27 +33,27 @@ export function objectSetDeclarations({ namedObjectUnionTypes, ...parameters })
30
33
  namedObjectUnionTypesWithSparqlFeatureCount++;
31
34
  }
32
35
  }
33
- if (objectTypesWithRdfFeatureCount === 0 &&
34
- objectTypesWithSparqlFeatureCount === 0 &&
36
+ if (namedObjectTypesWithRdfFeatureCount === 0 &&
37
+ namedObjectTypesWithSparqlFeatureCount === 0 &&
35
38
  namedObjectUnionTypesWithRdfFeatureCount === 0 &&
36
39
  namedObjectUnionTypesWithSparqlFeatureCount === 0) {
37
40
  return [];
38
41
  }
39
42
  const declarations = [
40
43
  objectSetInterfaceDeclaration({
41
- objectTypes,
44
+ namedObjectTypes: namedObjectTypes,
42
45
  namedObjectUnionTypes,
43
46
  }),
44
47
  ];
45
- if (objectTypesWithRdfFeatureCount > 0) {
48
+ if (namedObjectTypesWithRdfFeatureCount > 0) {
46
49
  declarations.push(rdfjsDatasetObjectSetClassDeclaration({
47
- objectTypes,
50
+ namedObjectTypes: namedObjectTypes,
48
51
  namedObjectUnionTypes,
49
52
  }));
50
53
  }
51
- if (objectTypesWithSparqlFeatureCount > 0) {
54
+ if (namedObjectTypesWithSparqlFeatureCount > 0) {
52
55
  declarations.push(sparqlObjectSetClassDeclaration({
53
- objectTypes,
56
+ namedObjectTypes: namedObjectTypes,
54
57
  namedObjectUnionTypes,
55
58
  }));
56
59
  }
@@ -1,8 +1,8 @@
1
+ import type { NamedObjectType } from "./NamedObjectType.js";
1
2
  import type { NamedObjectUnionType } from "./NamedObjectUnionType.js";
2
- import type { ObjectType } from "./ObjectType.js";
3
3
  import { type Code } from "./ts-poet-wrapper.js";
4
- export declare function objectSetInterfaceDeclaration({ objectTypes, namedObjectUnionTypes, }: {
5
- objectTypes: readonly ObjectType[];
4
+ export declare function objectSetInterfaceDeclaration({ namedObjectTypes, namedObjectUnionTypes, }: {
5
+ namedObjectTypes: readonly NamedObjectType[];
6
6
  namedObjectUnionTypes: readonly NamedObjectUnionType[];
7
7
  }): Code;
8
8
  //# sourceMappingURL=objectSetInterfaceDeclaration.d.ts.map
@@ -2,12 +2,14 @@ import { imports } from "./imports.js";
2
2
  import { objectSetMethodSignatures } from "./objectSetMethodSignatures.js";
3
3
  import { syntheticNamePrefix } from "./syntheticNamePrefix.js";
4
4
  import { code, joinCode } from "./ts-poet-wrapper.js";
5
- export function objectSetInterfaceDeclaration({ objectTypes, namedObjectUnionTypes, }) {
5
+ export function objectSetInterfaceDeclaration({ namedObjectTypes, namedObjectUnionTypes, }) {
6
6
  return code `\
7
7
  export interface ${syntheticNamePrefix}ObjectSet {
8
- ${joinCode(objectTypes
9
- .flatMap((objectType) => Object.values(objectSetMethodSignatures({ objectType })))
10
- .concat(namedObjectUnionTypes.flatMap((namedObjectUnionType) => Object.values(objectSetMethodSignatures({ objectType: namedObjectUnionType }))))
8
+ ${joinCode(namedObjectTypes
9
+ .flatMap((namedObjectType) => Object.values(objectSetMethodSignatures({ namedObjectType })))
10
+ .concat(namedObjectUnionTypes.flatMap((namedObjectUnionType) => Object.values(objectSetMethodSignatures({
11
+ namedObjectType: namedObjectUnionType,
12
+ }))))
11
13
  .map((methodSignature) => code `${methodSignature.name}(${methodSignature.parameters}): ${methodSignature.returnType};`), { on: "\n\n" })}
12
14
  }
13
15
 
@@ -1,15 +1,15 @@
1
- import type { ObjectType } from "./ObjectType.js";
1
+ import type { NamedObjectType } from "./NamedObjectType.js";
2
2
  import { type Code } from "./ts-poet-wrapper.js";
3
3
  export declare function objectSetMethodSignatures(parameters: {
4
- objectType: {
4
+ namedObjectType: {
5
5
  readonly filterType: Code;
6
6
  readonly identifierTypeAlias: Code;
7
- readonly objectSetMethodNames: ObjectType.ObjectSetMethodNames;
7
+ readonly objectSetMethodNames: NamedObjectType.ObjectSetMethodNames;
8
8
  readonly name: string;
9
9
  };
10
10
  parameterNamePrefix?: string;
11
11
  queryT?: string;
12
- }): Readonly<Record<keyof ObjectType.ObjectSetMethodNames, {
12
+ }): Readonly<Record<keyof NamedObjectType.ObjectSetMethodNames, {
13
13
  readonly name: string;
14
14
  readonly parameters: Code;
15
15
  readonly returnType: Code;