@ifc-lite/export 5.0.0 → 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (298) hide show
  1. package/README.md +42 -20
  2. package/dist/anonymize-placement.d.ts.map +1 -1
  3. package/dist/anonymize-placement.js +2 -2
  4. package/dist/anonymize-placement.js.map +1 -1
  5. package/dist/anonymize-types.d.ts +2 -0
  6. package/dist/anonymize-types.d.ts.map +1 -1
  7. package/dist/declared-property-type.d.ts +2 -110
  8. package/dist/declared-property-type.d.ts.map +1 -1
  9. package/dist/declared-property-type.js +15 -0
  10. package/dist/declared-property-type.js.map +1 -1
  11. package/dist/energy-artifact.d.ts +6 -0
  12. package/dist/energy-artifact.d.ts.map +1 -0
  13. package/dist/energy-artifact.js +33 -0
  14. package/dist/energy-artifact.js.map +1 -0
  15. package/dist/entity-iteration.d.ts +1 -1
  16. package/dist/entity-iteration.d.ts.map +1 -1
  17. package/dist/entity-iteration.js.map +1 -1
  18. package/dist/generated/ifc2x3-typed-properties.d.ts +11 -0
  19. package/dist/generated/ifc2x3-typed-properties.d.ts.map +1 -0
  20. package/dist/generated/ifc2x3-typed-properties.js +49 -0
  21. package/dist/generated/ifc2x3-typed-properties.js.map +1 -0
  22. package/dist/generated/ifc4-required-slots.d.ts +4 -1
  23. package/dist/generated/ifc4-required-slots.d.ts.map +1 -1
  24. package/dist/generated/ifc4-required-slots.js +704 -0
  25. package/dist/generated/ifc4-required-slots.js.map +1 -1
  26. package/dist/geometry-diagnostics.d.ts +14 -0
  27. package/dist/geometry-diagnostics.d.ts.map +1 -0
  28. package/dist/geometry-diagnostics.js +29 -0
  29. package/dist/geometry-diagnostics.js.map +1 -0
  30. package/dist/index.d.ts +5 -0
  31. package/dist/index.d.ts.map +1 -1
  32. package/dist/index.js +7 -0
  33. package/dist/index.js.map +1 -1
  34. package/dist/merged-exporter.d.ts +1 -4
  35. package/dist/merged-exporter.d.ts.map +1 -1
  36. package/dist/merged-exporter.js +99 -81
  37. package/dist/merged-exporter.js.map +1 -1
  38. package/dist/merged-guid.d.ts +5 -7
  39. package/dist/merged-guid.d.ts.map +1 -1
  40. package/dist/merged-guid.js +37 -42
  41. package/dist/merged-guid.js.map +1 -1
  42. package/dist/merged-header.d.ts +7 -0
  43. package/dist/merged-header.d.ts.map +1 -1
  44. package/dist/merged-header.js +14 -0
  45. package/dist/merged-header.js.map +1 -1
  46. package/dist/merged-inherited-units.d.ts +8 -0
  47. package/dist/merged-inherited-units.d.ts.map +1 -0
  48. package/dist/merged-inherited-units.js +117 -0
  49. package/dist/merged-inherited-units.js.map +1 -0
  50. package/dist/merged-inverse-claims.d.ts +5 -6
  51. package/dist/merged-inverse-claims.d.ts.map +1 -1
  52. package/dist/merged-inverse-claims.js +32 -12
  53. package/dist/merged-inverse-claims.js.map +1 -1
  54. package/dist/merged-planner-guids.d.ts +1 -0
  55. package/dist/merged-planner-guids.d.ts.map +1 -1
  56. package/dist/merged-planner-guids.js +5 -6
  57. package/dist/merged-planner-guids.js.map +1 -1
  58. package/dist/merged-profile-units.d.ts +9 -0
  59. package/dist/merged-profile-units.d.ts.map +1 -0
  60. package/dist/merged-profile-units.js +44 -0
  61. package/dist/merged-profile-units.js.map +1 -0
  62. package/dist/merged-remap.d.ts +1 -1
  63. package/dist/merged-remap.d.ts.map +1 -1
  64. package/dist/merged-remap.js +5 -1
  65. package/dist/merged-remap.js.map +1 -1
  66. package/dist/related-entities.d.ts.map +1 -1
  67. package/dist/related-entities.js +11 -9
  68. package/dist/related-entities.js.map +1 -1
  69. package/dist/rust-artifact.d.ts +4 -0
  70. package/dist/rust-artifact.d.ts.map +1 -0
  71. package/dist/rust-artifact.js +15 -0
  72. package/dist/rust-artifact.js.map +1 -0
  73. package/dist/schema-calendar-date-values.d.ts +16 -0
  74. package/dist/schema-calendar-date-values.d.ts.map +1 -0
  75. package/dist/schema-calendar-date-values.js +107 -0
  76. package/dist/schema-calendar-date-values.js.map +1 -0
  77. package/dist/schema-calendar-dates.d.ts +26 -0
  78. package/dist/schema-calendar-dates.d.ts.map +1 -0
  79. package/dist/schema-calendar-dates.js +226 -0
  80. package/dist/schema-calendar-dates.js.map +1 -0
  81. package/dist/schema-conversion-loss-description.d.ts +3 -0
  82. package/dist/schema-conversion-loss-description.d.ts.map +1 -0
  83. package/dist/schema-conversion-loss-description.js +26 -0
  84. package/dist/schema-conversion-loss-description.js.map +1 -0
  85. package/dist/schema-conversion-loss-report.d.ts +7 -12
  86. package/dist/schema-conversion-loss-report.d.ts.map +1 -1
  87. package/dist/schema-conversion-loss-report.js +98 -76
  88. package/dist/schema-conversion-loss-report.js.map +1 -1
  89. package/dist/schema-conversion-loss-varying.d.ts +11 -0
  90. package/dist/schema-conversion-loss-varying.d.ts.map +1 -0
  91. package/dist/schema-conversion-loss-varying.js +44 -0
  92. package/dist/schema-conversion-loss-varying.js.map +1 -0
  93. package/dist/schema-converter-attr-maps.d.ts +18 -5
  94. package/dist/schema-converter-attr-maps.d.ts.map +1 -1
  95. package/dist/schema-converter-attr-maps.js +59 -13
  96. package/dist/schema-converter-attr-maps.js.map +1 -1
  97. package/dist/schema-converter-attr-remap.d.ts +2 -2
  98. package/dist/schema-converter-attr-remap.d.ts.map +1 -1
  99. package/dist/schema-converter-attr-remap.js +4 -4
  100. package/dist/schema-converter-attr-remap.js.map +1 -1
  101. package/dist/schema-converter-document-links.d.ts +1 -1
  102. package/dist/schema-converter-document-links.d.ts.map +1 -1
  103. package/dist/schema-converter-document-links.js +2 -2
  104. package/dist/schema-converter-document-links.js.map +1 -1
  105. package/dist/schema-converter-durations.d.ts +6 -0
  106. package/dist/schema-converter-durations.d.ts.map +1 -0
  107. package/dist/schema-converter-durations.js +42 -0
  108. package/dist/schema-converter-durations.js.map +1 -0
  109. package/dist/schema-converter-enums.d.ts +11 -1
  110. package/dist/schema-converter-enums.d.ts.map +1 -1
  111. package/dist/schema-converter-enums.js +36 -10
  112. package/dist/schema-converter-enums.js.map +1 -1
  113. package/dist/schema-converter-ifc2x3-slots.d.ts +1 -1
  114. package/dist/schema-converter-ifc2x3-slots.d.ts.map +1 -1
  115. package/dist/schema-converter-ifc2x3-slots.js +6 -5
  116. package/dist/schema-converter-ifc2x3-slots.js.map +1 -1
  117. package/dist/schema-converter-ifc4-slots.d.ts +10 -5
  118. package/dist/schema-converter-ifc4-slots.d.ts.map +1 -1
  119. package/dist/schema-converter-ifc4-slots.js +17 -20
  120. package/dist/schema-converter-ifc4-slots.js.map +1 -1
  121. package/dist/schema-converter-ifc4x3-upgrade.d.ts +6 -0
  122. package/dist/schema-converter-ifc4x3-upgrade.d.ts.map +1 -0
  123. package/dist/schema-converter-ifc4x3-upgrade.js +48 -0
  124. package/dist/schema-converter-ifc4x3-upgrade.js.map +1 -0
  125. package/dist/schema-converter-material-referent.d.ts +58 -0
  126. package/dist/schema-converter-material-referent.d.ts.map +1 -0
  127. package/dist/schema-converter-material-referent.js +202 -0
  128. package/dist/schema-converter-material-referent.js.map +1 -0
  129. package/dist/schema-converter-owner-history.d.ts +1 -1
  130. package/dist/schema-converter-owner-history.d.ts.map +1 -1
  131. package/dist/schema-converter-owner-history.js +4 -3
  132. package/dist/schema-converter-owner-history.js.map +1 -1
  133. package/dist/schema-converter-product-proxy.d.ts +0 -23
  134. package/dist/schema-converter-product-proxy.d.ts.map +1 -1
  135. package/dist/schema-converter-product-proxy.js +2 -1
  136. package/dist/schema-converter-product-proxy.js.map +1 -1
  137. package/dist/schema-converter-space-boundary.d.ts +47 -0
  138. package/dist/schema-converter-space-boundary.d.ts.map +1 -0
  139. package/dist/schema-converter-space-boundary.js +108 -0
  140. package/dist/schema-converter-space-boundary.js.map +1 -0
  141. package/dist/schema-converter-step-finish.d.ts +4 -0
  142. package/dist/schema-converter-step-finish.d.ts.map +1 -0
  143. package/dist/schema-converter-step-finish.js +28 -0
  144. package/dist/schema-converter-step-finish.js.map +1 -0
  145. package/dist/schema-converter-structural-axes.d.ts +1 -1
  146. package/dist/schema-converter-structural-axes.d.ts.map +1 -1
  147. package/dist/schema-converter-structural-axes.js +2 -2
  148. package/dist/schema-converter-structural-axes.js.map +1 -1
  149. package/dist/schema-converter-structural-carriers.d.ts +2 -0
  150. package/dist/schema-converter-structural-carriers.d.ts.map +1 -1
  151. package/dist/schema-converter-structural-carriers.js +6 -0
  152. package/dist/schema-converter-structural-carriers.js.map +1 -1
  153. package/dist/schema-converter-structural-diagnostics.d.ts +13 -0
  154. package/dist/schema-converter-structural-diagnostics.d.ts.map +1 -1
  155. package/dist/schema-converter-structural-diagnostics.js +37 -4
  156. package/dist/schema-converter-structural-diagnostics.js.map +1 -1
  157. package/dist/schema-converter-structural-source.d.ts +10 -0
  158. package/dist/schema-converter-structural-source.d.ts.map +1 -1
  159. package/dist/schema-converter-structural-source.js +16 -6
  160. package/dist/schema-converter-structural-source.js.map +1 -1
  161. package/dist/schema-converter-structural-varying.d.ts +15 -2
  162. package/dist/schema-converter-structural-varying.d.ts.map +1 -1
  163. package/dist/schema-converter-structural-varying.js +51 -21
  164. package/dist/schema-converter-structural-varying.js.map +1 -1
  165. package/dist/schema-converter-structural.d.ts +3 -0
  166. package/dist/schema-converter-structural.d.ts.map +1 -1
  167. package/dist/schema-converter-structural.js +13 -5
  168. package/dist/schema-converter-structural.js.map +1 -1
  169. package/dist/schema-converter-typed-properties.d.ts +30 -0
  170. package/dist/schema-converter-typed-properties.d.ts.map +1 -0
  171. package/dist/schema-converter-typed-properties.js +172 -0
  172. package/dist/schema-converter-typed-properties.js.map +1 -0
  173. package/dist/schema-converter-unrooted-upgrade.d.ts +31 -0
  174. package/dist/schema-converter-unrooted-upgrade.d.ts.map +1 -0
  175. package/dist/schema-converter-unrooted-upgrade.js +278 -0
  176. package/dist/schema-converter-unrooted-upgrade.js.map +1 -0
  177. package/dist/schema-converter-userdefined-label.d.ts +1 -1
  178. package/dist/schema-converter-userdefined-label.d.ts.map +1 -1
  179. package/dist/schema-converter-userdefined-label.js +7 -6
  180. package/dist/schema-converter-userdefined-label.js.map +1 -1
  181. package/dist/schema-converter-value-forms.d.ts +32 -1
  182. package/dist/schema-converter-value-forms.d.ts.map +1 -1
  183. package/dist/schema-converter-value-forms.js +73 -23
  184. package/dist/schema-converter-value-forms.js.map +1 -1
  185. package/dist/schema-converter.d.ts +8 -12
  186. package/dist/schema-converter.d.ts.map +1 -1
  187. package/dist/schema-converter.js +61 -58
  188. package/dist/schema-converter.js.map +1 -1
  189. package/dist/schema-ifc2x3-placements.d.ts.map +1 -1
  190. package/dist/schema-ifc2x3-placements.js +20 -31
  191. package/dist/schema-ifc2x3-placements.js.map +1 -1
  192. package/dist/schema-ifc2x3-records.d.ts.map +1 -1
  193. package/dist/schema-ifc2x3-records.js +3 -2
  194. package/dist/schema-ifc2x3-records.js.map +1 -1
  195. package/dist/schema-ifc2x3-style-assignments.d.ts +4 -0
  196. package/dist/schema-ifc2x3-style-assignments.d.ts.map +1 -0
  197. package/dist/schema-ifc2x3-style-assignments.js +33 -0
  198. package/dist/schema-ifc2x3-style-assignments.js.map +1 -0
  199. package/dist/schema-project-time-unit.d.ts +8 -0
  200. package/dist/schema-project-time-unit.d.ts.map +1 -0
  201. package/dist/schema-project-time-unit.js +123 -0
  202. package/dist/schema-project-time-unit.js.map +1 -0
  203. package/dist/schema-structural-varying-constant.d.ts +16 -0
  204. package/dist/schema-structural-varying-constant.d.ts.map +1 -0
  205. package/dist/schema-structural-varying-constant.js +36 -0
  206. package/dist/schema-structural-varying-constant.js.map +1 -0
  207. package/dist/schema-structural-varying-effective.d.ts +2 -0
  208. package/dist/schema-structural-varying-effective.d.ts.map +1 -0
  209. package/dist/schema-structural-varying-effective.js +85 -0
  210. package/dist/schema-structural-varying-effective.js.map +1 -0
  211. package/dist/schema-untranslatable.d.ts +22 -13
  212. package/dist/schema-untranslatable.d.ts.map +1 -1
  213. package/dist/schema-untranslatable.js +87 -6
  214. package/dist/schema-untranslatable.js.map +1 -1
  215. package/dist/schema-value-form-policy.d.ts +1 -1
  216. package/dist/schema-value-form-policy.d.ts.map +1 -1
  217. package/dist/schema-value-form-policy.js +37 -4
  218. package/dist/schema-value-form-policy.js.map +1 -1
  219. package/dist/schema-work-control-durations.d.ts +13 -0
  220. package/dist/schema-work-control-durations.d.ts.map +1 -0
  221. package/dist/schema-work-control-durations.js +74 -0
  222. package/dist/schema-work-control-durations.js.map +1 -0
  223. package/dist/step-argument-parser.d.ts +3 -3
  224. package/dist/step-argument-parser.d.ts.map +1 -1
  225. package/dist/step-argument-parser.js +6 -6
  226. package/dist/step-argument-parser.js.map +1 -1
  227. package/dist/step-comment-skip.d.ts.map +1 -1
  228. package/dist/step-comment-skip.js +3 -1
  229. package/dist/step-comment-skip.js.map +1 -1
  230. package/dist/step-export-types.d.ts +6 -6
  231. package/dist/step-export-types.d.ts.map +1 -1
  232. package/dist/step-export-types.js.map +1 -1
  233. package/dist/step-exporter.d.ts.map +1 -1
  234. package/dist/step-exporter.js +12 -6
  235. package/dist/step-exporter.js.map +1 -1
  236. package/dist/step-georeferencing.d.ts.map +1 -1
  237. package/dist/step-georeferencing.js +4 -17
  238. package/dist/step-georeferencing.js.map +1 -1
  239. package/dist/step-map-unit-normalization.d.ts.map +1 -1
  240. package/dist/step-map-unit-normalization.js +5 -4
  241. package/dist/step-map-unit-normalization.js.map +1 -1
  242. package/dist/step-omission-predicates.d.ts.map +1 -1
  243. package/dist/step-omission-predicates.js +3 -1
  244. package/dist/step-omission-predicates.js.map +1 -1
  245. package/dist/step-outer-args.d.ts +1 -1
  246. package/dist/step-outer-args.d.ts.map +1 -1
  247. package/dist/step-outer-args.js +10 -3
  248. package/dist/step-outer-args.js.map +1 -1
  249. package/dist/step-overlay-entities.d.ts.map +1 -1
  250. package/dist/step-overlay-entities.js +9 -0
  251. package/dist/step-overlay-entities.js.map +1 -1
  252. package/dist/step-pass-builder.d.ts.map +1 -1
  253. package/dist/step-pass-builder.js +63 -1
  254. package/dist/step-pass-builder.js.map +1 -1
  255. package/dist/step-property-set-readers.d.ts +4 -4
  256. package/dist/step-property-set-readers.d.ts.map +1 -1
  257. package/dist/step-property-set-readers.js +13 -13
  258. package/dist/step-property-set-readers.js.map +1 -1
  259. package/dist/step-ref-scan.d.ts +5 -0
  260. package/dist/step-ref-scan.d.ts.map +1 -1
  261. package/dist/step-ref-scan.js +1 -1
  262. package/dist/step-ref-scan.js.map +1 -1
  263. package/dist/step-retype-type-link.d.ts +7 -0
  264. package/dist/step-retype-type-link.d.ts.map +1 -0
  265. package/dist/step-retype-type-link.js +95 -0
  266. package/dist/step-retype-type-link.js.map +1 -0
  267. package/dist/step-slot-grammar.d.ts +3 -2
  268. package/dist/step-slot-grammar.d.ts.map +1 -1
  269. package/dist/step-slot-grammar.js +5 -5
  270. package/dist/step-slot-grammar.js.map +1 -1
  271. package/dist/step-source-iteration.d.ts.map +1 -1
  272. package/dist/step-source-iteration.js +12 -6
  273. package/dist/step-source-iteration.js.map +1 -1
  274. package/dist/step-subset-relations.d.ts +131 -0
  275. package/dist/step-subset-relations.d.ts.map +1 -0
  276. package/dist/step-subset-relations.js +342 -0
  277. package/dist/step-subset-relations.js.map +1 -0
  278. package/dist/step-subset-spatial-ancestors.d.ts +26 -0
  279. package/dist/step-subset-spatial-ancestors.d.ts.map +1 -0
  280. package/dist/step-subset-spatial-ancestors.js +103 -0
  281. package/dist/step-subset-spatial-ancestors.js.map +1 -0
  282. package/dist/step-subset-storey.d.ts +21 -0
  283. package/dist/step-subset-storey.d.ts.map +1 -0
  284. package/dist/step-subset-storey.js +319 -0
  285. package/dist/step-subset-storey.js.map +1 -0
  286. package/dist/step-subset.d.ts +68 -0
  287. package/dist/step-subset.d.ts.map +1 -0
  288. package/dist/step-subset.js +388 -0
  289. package/dist/step-subset.js.map +1 -0
  290. package/dist/unit-normalize.d.ts +15 -14
  291. package/dist/unit-normalize.d.ts.map +1 -1
  292. package/dist/unit-normalize.js +118 -91
  293. package/dist/unit-normalize.js.map +1 -1
  294. package/dist/xlsx-limits.d.ts +12 -0
  295. package/dist/xlsx-limits.d.ts.map +1 -0
  296. package/dist/xlsx-limits.js +48 -0
  297. package/dist/xlsx-limits.js.map +1 -0
  298. package/package.json +7 -7
@@ -1,12 +1,43 @@
1
+ import { CalendarDates } from './schema-calendar-dates.js';
2
+ import { WorkControlDurations } from './schema-work-control-durations.js';
3
+ interface Rule {
4
+ readonly index: number;
5
+ readonly where: string;
6
+ readonly required: boolean;
7
+ /** The target aggregate may be empty. */
8
+ readonly empty: boolean;
9
+ /** Slots emptied together when a positional member is rejected. */
10
+ readonly whole: readonly number[];
11
+ /** Form -> null (drop), `T:NAME` (wrap), `U` (unwrap), `U1` (one member) or an integer form (`I`, `AI`). */
12
+ readonly forms: ReadonlyMap<string, string | null>;
13
+ /** Typed forms with a payload row (`T:NAME(F)`), the only ones whose payload is read. */
14
+ readonly payload: ReadonlySet<string>;
15
+ readonly hasCalendar: boolean;
16
+ }
17
+ /** A target type's attribute count and its rules. */
18
+ interface Rules {
19
+ readonly arity: number;
20
+ readonly rules: readonly Rule[];
21
+ }
22
+ export declare function rulesFor(from: string, to: string, type: string): Rules;
1
23
  /** Value-form reconciliation for one export: rewrites, and names what it dropped. */
2
24
  export declare class ValueForms {
25
+ private readonly deferred;
3
26
  /** Per `TYPE.Attribute`: values dropped, and those that left a required slot `$`. */
4
27
  private readonly dropped;
5
28
  private readonly emptied;
29
+ private readonly narrowedDates;
30
+ /** Times written with a minute or second the IFC2X3 source left unset (#11199). */
31
+ private readonly filledDates;
32
+ readonly dates: CalendarDates;
33
+ readonly durations: WorkControlDurations;
34
+ constructor(deferred?: boolean);
6
35
  /** `line`, already converted from `from` to `to`, with every slot in a form the target accepts. */
7
- apply(line: string, from: string, to: string): string;
36
+ apply(line: string, from: string, to: string, maxReferenceId?: number): string;
37
+ omitStoreyAttributes(type: string, values: readonly string[], source: readonly string[], target: readonly string[]): void;
8
38
  private count;
9
39
  /** One warning per kind, naming every slot a value was dropped from (#10847). */
10
40
  warnings(): string[];
11
41
  }
42
+ export {};
12
43
  //# sourceMappingURL=schema-converter-value-forms.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"schema-converter-value-forms.d.ts","sourceRoot":"","sources":["../src/schema-converter-value-forms.ts"],"names":[],"mappings":"AAgJA,qFAAqF;AACrF,qBAAa,UAAU;IACrB,qFAAqF;IACrF,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA6B;IACrD,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA6B;IAErD,mGAAmG;IACnG,KAAK,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,MAAM;IAsCrD,OAAO,CAAC,KAAK;IAIb,iFAAiF;IACjF,QAAQ,IAAI,MAAM,EAAE;CAUrB"}
1
+ {"version":3,"file":"schema-converter-value-forms.d.ts","sourceRoot":"","sources":["../src/schema-converter-value-forms.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAQ3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,oCAAoC,CAAC;AAI1E,UAAU,IAAI;IACZ,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,yCAAyC;IACzC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,mEAAmE;IACnE,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;IAClC,4GAA4G;IAC5G,QAAQ,CAAC,KAAK,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC;IACnD,yFAAyF;IACzF,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACtC,QAAQ,CAAC,WAAW,EAAE,OAAO,CAAC;CAC/B;AAGD,qDAAqD;AACrD,UAAU,KAAK;IAAG,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,SAAS,IAAI,EAAE,CAAA;CAAE;AAK3E,wBAAgB,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,KAAK,CAuBtE;AAqFD,qFAAqF;AACrF,qBAAa,UAAU;IAST,OAAO,CAAC,QAAQ,CAAC,QAAQ;IARrC,qFAAqF;IACrF,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA6B;IACrD,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA6B;IACrD,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA6B;IAC3D,mFAAmF;IACnF,OAAO,CAAC,QAAQ,CAAC,WAAW,CAA6B;IACzD,QAAQ,CAAC,KAAK,EAAE,aAAa,CAAC;IAC9B,QAAQ,CAAC,SAAS,uBAA8B;gBACnB,QAAQ,UAAQ;IAE7C,mGAAmG;IACnG,KAAK,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,cAAc,CAAC,EAAE,MAAM,GAAG,MAAM;IAqD9E,oBAAoB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,MAAM,EAAE,EAAE,MAAM,EAAE,SAAS,MAAM,EAAE,EAAE,MAAM,EAAE,SAAS,MAAM,EAAE,GAAG,IAAI;IAMzH,OAAO,CAAC,KAAK;IAIb,iFAAiF;IACjF,QAAQ,IAAI,MAAM,EAAE;CAcrB"}
@@ -13,17 +13,21 @@
13
13
  * `generated/value_forms.rs` (`scripts/generate-value-forms.mjs --check`).
14
14
  */
15
15
  import { getCanonicalEntityName, getSchemaRegistryForVersion } from '@ifc-lite/parser';
16
+ import { CalendarDates } from './schema-calendar-dates.js';
16
17
  import { valueForm, valueFormSlotsOf } from './schema-value-form-policy.js';
17
18
  import { getAttrMaps } from './schema-converter-attr-maps.js';
18
- import { withoutComments } from './step-comment-skip.js';
19
+ import { holdsValue, withoutComments } from './step-comment-skip.js';
19
20
  import { listItems } from './schema-converter-structural-axes.js';
20
21
  import { readStepSlots } from './step-argument-parser.js';
22
+ import { durationFromSeconds, durationToSeconds } from './schema-converter-durations.js';
23
+ import { slotRef } from './schema-converter-structural-source.js';
24
+ import { WorkControlDurations } from './schema-work-control-durations.js';
21
25
  import { stepRecordHead } from './step-record-frame.js';
22
- import { parseStepNumber, skipStepTrivia } from './step-slot-grammar.js';
26
+ import { isStepValue, parseStepNumber, skipStepTrivia } from './step-slot-grammar.js';
23
27
  const SCHEMAS = new Set(['IFC2X3', 'IFC4', 'IFC4X3']);
24
28
  const RULES = new Map();
25
29
  const NONE = { arity: 0, rules: [] };
26
- function rulesFor(from, to, type) {
30
+ export function rulesFor(from, to, type) {
27
31
  const key = `${from}>${to}`;
28
32
  let byType = RULES.get(key);
29
33
  if (!byType)
@@ -43,6 +47,7 @@ function rulesFor(from, to, type) {
43
47
  empty: slot.empty,
44
48
  whole: slot.whole,
45
49
  forms: new Map(slot.rejected.map((f) => [f.split('>')[0], f.split('>')[1] ?? null])),
50
+ hasCalendar: slot.rejected.some((f) => f.includes('>C')),
46
51
  payload: new Set(slot.rejected.filter((f) => f.split('>')[0].endsWith(')')).map((f) => f.slice(0, f.indexOf('(')))),
47
52
  })) };
48
53
  byType.set(type, rules);
@@ -55,17 +60,21 @@ function wholeDecimal(token) {
55
60
  return !!m && /^0*$/.test(`${m[1]}${m[2] ?? ''}`.slice(Math.max(m[1].length + Number(m[3] ?? 0), 0)));
56
61
  }
57
62
  /** How many values a slot holds: its members, or one unless it is `$`. */
58
- function valueCount(slot) {
59
- return listItems(slot)?.length ?? (valueForm(withoutComments(slot)) === null ? 0 : 1);
63
+ function valueCount(slot, maxReferenceId) {
64
+ return listItems(slot, maxReferenceId)?.length ?? (valueForm(withoutComments(slot)) === null ? 0 : 1);
60
65
  }
61
66
  /** A typed value's argument, `NAME(arg)` -> `arg`. */
62
67
  function unwrapped(body) {
63
68
  const close = body.lastIndexOf(')');
64
69
  return close < 0 ? null : body.slice(body.indexOf('(') + 1, close).trim();
65
70
  }
71
+ /** Retype exactly one STEP string without decoding its escapes. */
72
+ function asText(value) {
73
+ return value?.startsWith("'") && isStepValue(value) ? 'IFCTEXT(' + value + ')' : null;
74
+ }
66
75
  /** The one member of an aggregate; null for any other count. */
67
- function onlyMember(list) {
68
- const members = list === null ? null : listItems(list);
76
+ function onlyMember(list, maxReferenceId) {
77
+ const members = list === null ? null : listItems(list, maxReferenceId);
69
78
  return members?.length === 1 ? members[0].trim() : null;
70
79
  }
71
80
  /** A whole STEP real as an integer token; null for a fraction or one past the safe range. */
@@ -83,18 +92,18 @@ function narrowed(value, body, form, rule) {
83
92
  return int === null ? { value: null, lost: 1 } : { value: `${body.slice(0, body.indexOf('(')).trimEnd()}(${int})`, lost: 0 };
84
93
  }
85
94
  /** `value` in the target's form (null to drop it), and how many values that lost. */
86
- function fix(value, prefix, rule) {
95
+ function fix(value, prefix, rule, markDuration, maxReferenceId) {
87
96
  const start = skipStepTrivia(value, 0);
88
97
  if (start < 0)
89
98
  return { value, lost: 0 };
90
99
  if (value[start] === '(') {
91
- const members = listItems(value);
100
+ const members = listItems(value, maxReferenceId);
92
101
  if (!members)
93
102
  return { value, lost: 0 };
94
103
  const kept = [];
95
104
  let lost = 0;
96
105
  for (const member of members) {
97
- const fixed = fix(member, `${prefix}A`, rule);
106
+ const fixed = fix(member, `${prefix}A`, rule, markDuration, maxReferenceId);
98
107
  lost += fixed.lost;
99
108
  if (fixed.value !== null)
100
109
  kept.push(fixed.value);
@@ -112,28 +121,48 @@ function fix(value, prefix, rule) {
112
121
  // The shared STEP number grammar gates the integer form; `wholeDecimal` reads the digits.
113
122
  const fixed = to === null ? null
114
123
  : to.startsWith('T:') ? `${to.slice(2)}(${body})`
115
- : to === 'U' ? unwrapped(body)
116
- : to === 'U1' ? onlyMember(unwrapped(body))
117
- : asInteger(body); // an integer form, `I` or `AI`
124
+ : to === 'TEXT' ? asText(unwrapped(body))
125
+ : to === 'D+' ? durationFromSeconds(body)
126
+ : to === 'D-' ? durationToSeconds(body)
127
+ : to === 'U' ? unwrapped(body)
128
+ : to === 'U1' ? onlyMember(unwrapped(body), maxReferenceId)
129
+ : asInteger(body); // an integer form, `I` or `AI`
118
130
  // A set of references that could not be unwrapped loses each of them, and at least one value,
119
131
  // so an emptied slot is always named.
132
+ if (fixed !== null && (to === 'D+' || to === 'D-'))
133
+ markDuration();
120
134
  const inner = to === 'U1' ? unwrapped(body) : null;
121
- const lost = fixed === null ? Math.max(1, inner === null ? 1 : valueCount(inner)) : 0;
135
+ const lost = fixed === null ? Math.max(1, inner === null ? 1 : valueCount(inner, maxReferenceId)) : 0;
122
136
  return { value: fixed, lost };
123
137
  }
124
138
  /** Value-form reconciliation for one export: rewrites, and names what it dropped. */
125
139
  export class ValueForms {
140
+ deferred;
126
141
  /** Per `TYPE.Attribute`: values dropped, and those that left a required slot `$`. */
127
142
  dropped = new Map();
128
143
  emptied = new Map();
144
+ narrowedDates = new Map();
145
+ /** Times written with a minute or second the IFC2X3 source left unset (#11199). */
146
+ filledDates = new Map();
147
+ dates;
148
+ durations = new WorkControlDurations();
149
+ constructor(deferred = false) {
150
+ this.deferred = deferred;
151
+ this.dates = new CalendarDates(deferred);
152
+ }
129
153
  /** `line`, already converted from `from` to `to`, with every slot in a form the target accepts. */
130
- apply(line, from, to) {
154
+ apply(line, from, to, maxReferenceId) {
131
155
  if (!SCHEMAS.has(from) || !SCHEMAS.has(to) || from === to)
132
156
  return line;
133
157
  // The head names the type; most records stop before their slots are split.
134
158
  const head = stepRecordHead(line);
135
- const { arity, rules } = head ? rulesFor(from, to, line.slice(head.typeStart, head.typeEnd).toUpperCase()) : NONE;
136
- const record = rules.length ? readStepSlots(line) : null;
159
+ if (!head)
160
+ return line;
161
+ const type = line.slice(head.typeStart, head.typeEnd).toUpperCase();
162
+ if (from === 'IFC2X3' && (to === 'IFC4' || to === 'IFC4X3'))
163
+ this.dates.noteUpgraded(type, to); // #11199
164
+ const { arity, rules } = rulesFor(from, to, type);
165
+ const record = rules.length ? readStepSlots(line, maxReferenceId) : null;
137
166
  // A record whose arity is not the target's is left alone: slot i need not be attribute i.
138
167
  if (!record || record.slots.length !== arity)
139
168
  return line;
@@ -142,12 +171,20 @@ export class ValueForms {
142
171
  for (const rule of rules) {
143
172
  if (rule.index >= slots.length)
144
173
  continue;
145
- const fixed = fix(slots[rule.index], '', rule);
174
+ const form = rule.hasCalendar ? valueForm(withoutComments(slots[rule.index])) : null;
175
+ const calendar = form === null ? null : rule.forms.get(form);
176
+ if (calendar?.startsWith('C') && this.dates.defer(line, rule.index, calendar, (loss) => this.count(loss === 'narrowed' ? this.narrowedDates : loss === 'filled' ? this.filledDates : rule.required ? this.emptied : this.dropped, rule.where, 1)))
177
+ continue;
178
+ const fixed = fix(slots[rule.index], '', rule, () => {
179
+ const id = this.deferred ? slotRef(line.slice(0, head.eq)) : null;
180
+ if (id !== null)
181
+ this.durations.capture(id, rule.index, from === 'IFC2X3');
182
+ }, maxReferenceId);
146
183
  if (fixed.lost && rule.whole.length) {
147
184
  // Positional members: every slot of the group goes whole, each named for what it held.
148
185
  for (const i of rule.whole) {
149
186
  // The generator gives every slot of a group a row like this one.
150
- const own = rules.find((r) => r.index === i), held = own ? valueCount(slots[i]) : 0;
187
+ const own = rules.find((r) => r.index === i), held = own ? valueCount(slots[i], maxReferenceId) : 0;
151
188
  if (!own || !held)
152
189
  continue;
153
190
  const emptied = own.empty && own.required ? '()' : '$';
@@ -168,20 +205,33 @@ export class ValueForms {
168
205
  changed = true;
169
206
  }
170
207
  }
208
+ if (to === 'IFC2X3' && record.type === 'IFCPROPERTYBOUNDEDVALUE' && !holdsValue(slots[2]) && !holdsValue(slots[3])) {
209
+ // Leaving out the record could strand references from property sets or other resources.
210
+ const instance = line.slice(0, head.eq).trim();
211
+ throw new Error(`Cannot convert ${instance} (IfcPropertyBoundedValue) to IFC2X3: WR22 requires UpperBoundValue or LowerBoundValue, and neither bound can be carried.`);
212
+ }
171
213
  return changed ? `${record.prefix}${slots.join(',')}${record.suffix}` : line;
172
214
  }
215
+ omitStoreyAttributes(type, values, source, target) {
216
+ source.forEach((name, i) => {
217
+ if (!target.includes(name) && holdsValue(values[i] ?? ''))
218
+ this.count(this.dropped, `${type}.${name}`, 1);
219
+ });
220
+ }
173
221
  count(into, where, n) {
174
222
  into.set(where, (into.get(where) ?? 0) + n);
175
223
  }
176
224
  /** One warning per kind, naming every slot a value was dropped from (#10847). */
177
225
  warnings() {
178
- const line = (where, what) => {
179
- const total = [...where.values()].reduce((a, b) => a + b, 0);
180
- return where.size ? [`${total} value(s) of a type the target slot does not accept ${what}: ${[...where.keys()].sort().join(', ')} (#10847).`] : [];
181
- };
226
+ const sites = (where, what) => where.size ? [what([...where.values()].reduce((a, b) => a + b, 0), [...where.keys()].sort().join(', '))] : [];
227
+ const line = (where, what) => sites(where, (total, list) => `${total} value(s) of a type the target slot does not accept ${what}: ${list} (#10847).`);
182
228
  return [
183
229
  ...line(this.dropped, 'were dropped'),
184
230
  ...line(this.emptied, 'left a slot the target requires as $, so the file is not valid against its header'),
231
+ ...this.dates.warnings(),
232
+ ...sites(this.narrowedDates, (total, list) => `${total} date value(s) kept the calendar date and dropped the time and any timezone: ${list} (#10879).`),
233
+ ...sites(this.filledDates, (total, list) => `${total} time value(s) wrote an unset minute or second as 00, a precision the IFC2X3 source does not state: ${list} (#11199).`),
234
+ ...this.durations.warnings(),
185
235
  ];
186
236
  }
187
237
  }
@@ -1 +1 @@
1
- {"version":3,"file":"schema-converter-value-forms.js","sourceRoot":"","sources":["../src/schema-converter-value-forms.ts"],"names":[],"mappings":"AAAA;;+DAE+D;AAE/D;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,sBAAsB,EAAE,2BAA2B,EAAkC,MAAM,kBAAkB,CAAC;AACvH,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAC5E,OAAO,EAAE,WAAW,EAAE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K,EAAE,IAAI,EAAE,EAAE,CAAC,GAAG,KAAK,uGAAuG,IAAI,YAAY,CAAC;YAC5K,GAAG,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE;SAC7B,CAAC;IACJ,CAAC;CACF"}
@@ -4,8 +4,7 @@
4
4
  * Handles entity type renaming and attribute rewriting when converting
5
5
  * between IFC schema versions (IFC2X3, IFC4, IFC4X3, IFC5).
6
6
  *
7
- * This module works at the STEP text level: it rewrites entity type names
8
- * and adjusts attribute counts via regex replacement on raw STEP lines.
7
+ * Rewrites entity type names and slot layouts in STEP text.
9
8
  */
10
9
  import { type RandomSource } from '@ifc-lite/encoding';
11
10
  import { Ifc2x3SlotFill } from './schema-converter-ifc2x3-slots.js';
@@ -36,22 +35,19 @@ export declare function attrNameTable(schema: IfcSchemaVersion): Map<string, rea
36
35
  * @param toSchema - Target schema version
37
36
  * @param random - Optional seeded `RandomSource` for the GlobalId of any IFCPROXY
38
37
  * placeholder minted here; pass one when output must be byte-reproducible.
39
- * @param slots - This package's exporters pass one; it carries the owner
40
- * history they reuse (#4686) and collects what they could not settle.
41
- * Omitted, a throwaway stands in, so the generated table's own defaults are
42
- * still written but the OwnerHistory reuse and both counts are lost.
43
- * @param ifc4Slots - Counts IFC4-required slots left `$` (IFC4X3/IFC5 → IFC4, #5202; mapped or structural IFC2X3 → IFC4, #10763).
38
+ * @param slots - Reuses OwnerHistory (#4686) and counts unsettled slots.
39
+ * Without a collector, required-slot filling uses the generated defaults.
40
+ * @param ifc4Slots - Counts required slots left `$` against the target (IFC4X3/IFC5 → IFC4, #5202; mapped or structural IFC2X3 → IFC4, #10763, or → IFC4X3, #11135).
44
41
  * @param enums - Resolves enum members the target lacks and reports losses (#5365).
45
42
  * @param withheldRefIds - Express ids this export is OMITTING outright
46
43
  * ({@link computeWithheldRefIds}, #4206) — a record whose attributes name
47
44
  * one is redirected to the same "no representation" resolution as its own
48
45
  * unmapped type would get, so it cannot ship a now-dangling `#N`.
49
- * @returns Converted line (entities without valid target representation become
50
- * IFCPROXY placeholders), or `null` when this record itself is one of the
51
- * narrow set `resolveUnrepresentedEntity` can safely OMIT rather than throw
52
- * for — the caller must not write a `null` result.
46
+ * @param maxReferenceId - Bound for remapped STEP ids; source conversion uses the parser's u32 bound.
47
+ * @returns A converted STEP line (possibly an IFCPROXY), or null for an omitted record, including unbound
48
+ * space boundaries on upgrade and IfcMaterialProperties without a single material (#10763).
53
49
  */
54
- export declare function convertStepLine(line: string, fromSchema: IfcSchemaVersion, toSchema: IfcSchemaVersion, random?: RandomSource, slots?: Ifc2x3SlotFill, withheldRefIds?: ReadonlySet<number>, ifc4Slots?: Ifc4SlotCheck, enums?: EnumReconciliation): string | null;
50
+ export declare function convertStepLine(line: string, fromSchema: IfcSchemaVersion, toSchema: IfcSchemaVersion, random?: RandomSource, slots?: Ifc2x3SlotFill, withheldRefIds?: ReadonlySet<number>, ifc4Slots?: Ifc4SlotCheck, enums?: EnumReconciliation, maxReferenceId?: number): string | null;
55
51
  /**
56
52
  * Check if an entity type should be skipped for the target schema: these
57
53
  * IFC4X3 types have no STEP representation in IFC2X3 or IFC4, so they are
@@ -1 +1 @@
1
- {"version":3,"file":"schema-converter.d.ts","sourceRoot":"","sources":["../src/schema-converter.ts"],"names":[],"mappings":"AAGA;;;;;;;;GAQG;AAGH,OAAO,EAAmB,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAOxE,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AACtE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,6BAA6B,CAAC;AAStE,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AAEnE,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,GAAG,MAAM,CAAC;AAsHrE;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAC/B,UAAU,EAAE,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rE;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAC/B,UAAU,EAAE,MAAM,EAClB,UAAU,EAAE,gBAAgB,EAC5B,QAAQ,EAAE,gBAAgB,GACzB,MAAM,CAWR;AA6DD,wBAAgB,aAAa,CAAC,MAAM,EAAE,gBAAgB,GAAG,GAAG,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC,GAAG,IAAI,CAU7F;AAUD;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,MAAM,EACZ,UAAU,EAAE,gBAAgB,EAC5B,QAAQ,EAAE,gBAAgB,EAC1B,MAAM,CAAC,EAAE,YAAY,EACrB,KAAK,CAAC,EAAE,cAAc,EACtB,cAAc,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,EACpC,SAAS,CAAC,EAAE,aAAa,EACzB,KAAK,CAAC,EAAE,kBAAkB,EAC1B,cAAc,CAAC,EAAE,MAAM,GACtB,MAAM,GAAG,IAAI,CAcf;AAqID;;;;;;;;;;GAUG;AACH,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAExF;AAUD,sFAAsF;AACtF,wBAAgB,eAAe,CAC7B,UAAU,EAAE,gBAAgB,EAC5B,QAAQ,EAAE,gBAAgB,GACzB,OAAO,CAET"}
@@ -7,33 +7,29 @@
7
7
  * Handles entity type renaming and attribute rewriting when converting
8
8
  * between IFC schema versions (IFC2X3, IFC4, IFC4X3, IFC5).
9
9
  *
10
- * This module works at the STEP text level: it rewrites entity type names
11
- * and adjusts attribute counts via regex replacement on raw STEP lines.
10
+ * Rewrites entity type names and slot layouts in STEP text.
12
11
  */
12
+ import { withoutComments } from './step-comment-skip.js';
13
+ import { needsUpgradeSlotMap, remapUpgradeSlots, upgradeNamedType } from './schema-converter-ifc4x3-upgrade.js';
13
14
  import { structuralAttributes } from './schema-converter-structural.js';
14
15
  import { generateIfcGuid } from '@ifc-lite/encoding';
15
16
  import { deterministicGlobalId, getSchemaRegistryForVersion } from '@ifc-lite/parser';
16
- import { resolveUnrepresentedEntity } from './schema-untranslatable.js';
17
+ import { missingTypeRoute, resolveUnrepresentedEntity } from './schema-untranslatable.js';
17
18
  import { BY_NAME_ATTR_REMAP_TYPES, isGridPlacementInSourceLayout, remapRenamedAttributesByName } from './schema-converter-attr-remap.js';
18
19
  import { splitTopLevelStepArguments } from './step-argument-parser.js';
19
20
  import { frameArgs, stepRecordFrame } from './step-record-frame.js';
20
21
  import { skipStepTrivia } from './step-slot-grammar.js';
21
22
  import { Ifc2x3SlotFill } from './schema-converter-ifc2x3-slots.js';
23
+ import { MaterialReferents } from './schema-converter-material-referent.js';
24
+ import { SpaceBoundaryElements } from './schema-converter-space-boundary.js';
22
25
  import { referencesAnyExpressId } from './step-ref-scan.js';
23
26
  import { productProxy } from './schema-converter-product-proxy.js';
24
27
  import { MEP_IFC2X3_TYPES } from './schema-converter-mep.js';
25
28
  import { isStrictAttrPrefix, replacedSlot } from './schema-converter-renames.js';
26
29
  import { carryUserDefinedLabel } from './schema-converter-userdefined-label.js';
27
- import { attrMapFor, remapByAttrMap, upgradeCountsIfc4Slots } from './schema-converter-attr-maps.js';
30
+ import { attrMapFor, DELETED_SUBTYPES, remapByAttrMap, upgradeCountsSlots, upgradeRename } from './schema-converter-attr-maps.js';
28
31
  import { retypeInPlace } from './schema-converter-retyped.js';
29
32
  export { computeWithheldRefIds } from './schema-untranslatable.js';
30
- /**
31
- * Entity type name mappings between schema versions.
32
- *
33
- * Maps (sourceSchema, entityType) → targetEntityType.
34
- * Only entries that actually differ are listed — types that are the same
35
- * across all schemas are passed through unchanged.
36
- */
37
33
  // ─── IFC2X3 → IFC4 type renames ────────────────────────────────────────────
38
34
  const IFC2X3_TO_IFC4 = new Map([
39
35
  ['IFCELECTRICDISTRIBUTIONPOINT', 'IFCELECTRICDISTRIBUTIONBOARD'],
@@ -41,6 +37,7 @@ const IFC2X3_TO_IFC4 = new Map([
41
37
  ['IFCEQUIPMENTELEMENT', 'IFCBUILDINGELEMENTPROXY'],
42
38
  ['IFCRELCONNECTSSTRUCTURALELEMENT', 'IFCRELASSIGNSTOPRODUCT'],
43
39
  ]);
40
+ const IFC2X3_UP = new Map([...IFC2X3_TO_IFC4, ...DELETED_SUBTYPES]); // + the subtypes IFC4 deleted, not for IFC5 (#10902)
44
41
  // ─── IFC4 → IFC2X3 type renames (reverse) ──────────────────────────────────
45
42
  const IFC4_TO_IFC2X3 = new Map([
46
43
  ['IFCBURNERTYPE', 'IFCGASTERMINALTYPE'],
@@ -83,7 +80,8 @@ const IFC4_TO_IFC2X3 = new Map([
83
80
  // of the other — `BY_NAME_ATTR_REMAP_TYPES` reconciles both by name.
84
81
  ['IFCSTRUCTURALCURVEACTION', 'IFCSTRUCTURALLINEARACTION'],
85
82
  ['IFCSTRUCTURALSURFACEACTION', 'IFCSTRUCTURALPLANARACTION'],
86
- // #10763: IFC4 deleted this subtype for the now-concrete supertype (see the reviewed attribute map).
83
+ // #10763: IFC4 deleted these subtypes for their now-concrete supertypes (see the reviewed attribute maps).
84
+ ['IFCMATERIALPROPERTIES', 'IFCEXTENDEDMATERIALPROPERTIES'],
87
85
  ['IFCPROFILEPROPERTIES', 'IFCGENERALPROFILEPROPERTIES'],
88
86
  // IFC4X3 spatial structure → IFC2X3 equivalents
89
87
  ['IFCFACILITY', 'IFCBUILDING'],
@@ -105,6 +103,7 @@ const IFC4_TO_IFC4X3 = new Map([
105
103
  // IfcBuildingElement → IfcBuiltElement (IFC4X3 rename)
106
104
  // Note: both exist in IFC4X3 for backwards compat, but IfcBuiltElement is canonical
107
105
  ]);
106
+ let ifc2x3ToIfc4x3, ifc2x3ToIfc5;
108
107
  // ─── IFC4X3 → IFC4 type renames ────────────────────────────────────────────
109
108
  const IFC4X3_TO_IFC4 = new Map([
110
109
  // IFC4X3-specific types that have no IFC4 equivalent → fallback
@@ -152,9 +151,12 @@ export function convertEntityType(entityType, fromSchema, toSchema) {
152
151
  if (fromSchema === toSchema)
153
152
  return entityType;
154
153
  const upper = entityType.toUpperCase();
155
- const mepTarget = toSchema === 'IFC2X3' ? MEP_IFC2X3_TYPES.get(upper) : undefined;
156
- if (mepTarget)
157
- return mepTarget;
154
+ const upgraded = upgradeNamedType(upper, fromSchema, toSchema);
155
+ if (upgraded)
156
+ return upgraded;
157
+ const target = (toSchema === 'IFC2X3' ? MEP_IFC2X3_TYPES.get(upper) : undefined) ?? upgradeRename(upper, fromSchema, toSchema);
158
+ if (target)
159
+ return target;
158
160
  const map = getConversionMap(fromSchema, toSchema);
159
161
  return map?.get(upper) ?? upper;
160
162
  }
@@ -164,7 +166,7 @@ export function convertEntityType(entityType, fromSchema, toSchema) {
164
166
  */
165
167
  function getConversionMap(from, to) {
166
168
  if (from === 'IFC2X3' && to === 'IFC4')
167
- return IFC2X3_TO_IFC4;
169
+ return IFC2X3_UP;
168
170
  if (from === 'IFC4' && to === 'IFC2X3')
169
171
  return IFC4_TO_IFC2X3;
170
172
  if (from === 'IFC4' && to === 'IFC4X3')
@@ -181,9 +183,10 @@ function getConversionMap(from, to) {
181
183
  if (from === 'IFC4' && to === 'IFC5')
182
184
  return IFC4_TO_IFC4X3;
183
185
  // Multi-step: IFC2X3 → IFC4X3 = IFC2X3 → IFC4 → IFC4X3
184
- if (from === 'IFC2X3' && (to === 'IFC4X3' || to === 'IFC5')) {
185
- return chainMaps(IFC2X3_TO_IFC4, IFC4_TO_IFC4X3);
186
- }
186
+ if (from === 'IFC2X3' && to === 'IFC4X3')
187
+ return ifc2x3ToIfc4x3 ??= chainMaps(IFC2X3_UP, IFC4_TO_IFC4X3);
188
+ if (from === 'IFC2X3' && to === 'IFC5')
189
+ return ifc2x3ToIfc5 ??= chainMaps(IFC2X3_TO_IFC4, IFC4_TO_IFC4X3);
187
190
  // Multi-step: IFC4X3 → IFC2X3 = IFC4X3 → IFC4 → IFC2X3
188
191
  if ((from === 'IFC4X3' || from === 'IFC5') && to === 'IFC2X3') {
189
192
  return chainMaps(IFC4X3_TO_IFC4, IFC4_TO_IFC2X3);
@@ -226,8 +229,8 @@ export function attrNameTable(schema) {
226
229
  }
227
230
  /** Count top-level (comma-separated) STEP attributes, respecting nested
228
231
  * parentheses and single-quoted strings. Empty list → 0. */
229
- function requireTopLevelAttributes(attrsRaw) {
230
- const attrs = splitTopLevelStepArguments(attrsRaw);
232
+ function requireTopLevelAttributes(attrsRaw, maxReferenceId) {
233
+ const attrs = splitTopLevelStepArguments(attrsRaw, maxReferenceId);
231
234
  if (attrs === null)
232
235
  throw new Error('Schema conversion refused an invalid STEP argument list.');
233
236
  return attrs;
@@ -245,39 +248,42 @@ function requireTopLevelAttributes(attrsRaw) {
245
248
  * @param toSchema - Target schema version
246
249
  * @param random - Optional seeded `RandomSource` for the GlobalId of any IFCPROXY
247
250
  * placeholder minted here; pass one when output must be byte-reproducible.
248
- * @param slots - This package's exporters pass one; it carries the owner
249
- * history they reuse (#4686) and collects what they could not settle.
250
- * Omitted, a throwaway stands in, so the generated table's own defaults are
251
- * still written but the OwnerHistory reuse and both counts are lost.
252
- * @param ifc4Slots - Counts IFC4-required slots left `$` (IFC4X3/IFC5 → IFC4, #5202; mapped or structural IFC2X3 → IFC4, #10763).
251
+ * @param slots - Reuses OwnerHistory (#4686) and counts unsettled slots.
252
+ * Without a collector, required-slot filling uses the generated defaults.
253
+ * @param ifc4Slots - Counts required slots left `$` against the target (IFC4X3/IFC5 → IFC4, #5202; mapped or structural IFC2X3 → IFC4, #10763, or → IFC4X3, #11135).
253
254
  * @param enums - Resolves enum members the target lacks and reports losses (#5365).
254
255
  * @param withheldRefIds - Express ids this export is OMITTING outright
255
256
  * ({@link computeWithheldRefIds}, #4206) — a record whose attributes name
256
257
  * one is redirected to the same "no representation" resolution as its own
257
258
  * unmapped type would get, so it cannot ship a now-dangling `#N`.
258
- * @returns Converted line (entities without valid target representation become
259
- * IFCPROXY placeholders), or `null` when this record itself is one of the
260
- * narrow set `resolveUnrepresentedEntity` can safely OMIT rather than throw
261
- * for — the caller must not write a `null` result.
259
+ * @param maxReferenceId - Bound for remapped STEP ids; source conversion uses the parser's u32 bound.
260
+ * @returns A converted STEP line (possibly an IFCPROXY), or null for an omitted record, including unbound
261
+ * space boundaries on upgrade and IfcMaterialProperties without a single material (#10763).
262
262
  */
263
- export function convertStepLine(line, fromSchema, toSchema, random, slots, withheldRefIds, ifc4Slots, enums) {
263
+ export function convertStepLine(line, fromSchema, toSchema, random, slots, withheldRefIds, ifc4Slots, enums, maxReferenceId) {
264
264
  if (fromSchema === toSchema)
265
265
  return line;
266
- let converted = retypeInPlace(convertRecord(line, fromSchema, toSchema, random, withheldRefIds, fromSchema === 'IFC2X3' && toSchema === 'IFC4' ? enums?.structural.axes.axis(line) : undefined, enums?.structural), fromSchema, toSchema); // #10778
267
- converted = carryUserDefinedLabel(line, converted, fromSchema, toSchema); // #10824
266
+ if ((enums?.boundaries ?? new SpaceBoundaryElements()).apply(line, fromSchema, toSchema) === null)
267
+ return null; // an IfcRelSpaceBoundary IFC4 cannot take without its element
268
+ const kept = (enums?.materials ?? new MaterialReferents()).apply(line, fromSchema, toSchema); // #10763: null when Material names no one IfcMaterial
269
+ let converted = kept === null ? null : retypeInPlace(convertRecord(kept, fromSchema, toSchema, random, withheldRefIds, fromSchema === 'IFC2X3' && toSchema === 'IFC4' ? enums?.structural.axes.axis(kept) : undefined, enums, maxReferenceId), fromSchema, toSchema);
270
+ converted = carryUserDefinedLabel(line, converted, fromSchema, toSchema, maxReferenceId); // #10824
268
271
  if (converted === null)
269
272
  return null;
270
273
  if (enums && toSchema !== 'IFC5')
271
- converted = enums.structural.after(enums.documents.apply(enums.apply(enums.forms.apply(converted, fromSchema, toSchema), toSchema)), withheldRefIds);
274
+ converted = enums.structural.after(enums.documents.apply(enums.apply(enums.forms.apply(converted, fromSchema, toSchema, maxReferenceId), toSchema, maxReferenceId, line, fromSchema), maxReferenceId), withheldRefIds);
272
275
  if (toSchema === 'IFC2X3')
273
- return (slots ?? new Ifc2x3SlotFill()).apply(converted);
274
- if (ifc4Slots && toSchema === 'IFC4' && (fromSchema !== 'IFC2X3' || upgradeCountsIfc4Slots(converted)))
275
- ifc4Slots.apply(converted);
276
+ return (slots ?? new Ifc2x3SlotFill()).apply(converted, maxReferenceId);
277
+ if (enums?.typedProperties.capture(line, converted, fromSchema, toSchema, maxReferenceId))
278
+ return converted;
279
+ // Every record to IFC4; an IFC2X3 upgrade's mapped records to IFC4 or IFC4X3, each against its own target (#11135).
280
+ const target = toSchema === 'IFC4' || toSchema === 'IFC4X3' ? toSchema : undefined;
281
+ if (ifc4Slots && target && (fromSchema === 'IFC2X3' ? upgradeCountsSlots(converted, target) : target === 'IFC4'))
282
+ ifc4Slots.apply(converted, target);
276
283
  return converted;
277
284
  }
278
- /** {@link convertStepLine} before the IFC2X3 required-slot fills, between two
279
- * different schemas. */
280
- function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, structuralAxis, structuralDiagnostics) {
285
+ /** Convert before applying required-slot fills. */
286
+ function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, structuralAxis, diagnostics, maxReferenceId) {
281
287
  const frame = stepRecordFrame(line, { allowMissingSemicolon: true });
282
288
  if (frame === null)
283
289
  return line;
@@ -288,11 +294,11 @@ function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, struc
288
294
  // Validate before choosing any conversion branch. A malformed slot list
289
295
  // must not still receive a type rename, proxy replacement, trim, or padding:
290
296
  // that would partially convert a record whose positions are untrustworthy.
291
- const args = requireTopLevelAttributes(attrsRaw);
297
+ const args = requireTopLevelAttributes(attrsRaw, maxReferenceId);
292
298
  const newType = convertEntityType(entityType, fromSchema, toSchema);
293
299
  // A structural rewrite replaces the withheld reference it was written for (an IFC4
294
300
  // load configuration); one still naming a withheld id falls to the check below.
295
- const rewritten = structuralDiagnostics?.rewrite(expressId, entityType, args, withheldRefIds);
301
+ const rewritten = diagnostics?.structural.rewrite(expressId, entityType, args, withheldRefIds);
296
302
  if (rewritten !== undefined)
297
303
  return rewritten === null ? null : `${prefix}${rewritten};`;
298
304
  // A record whose attribute list references an id this export is OMITTING
@@ -302,9 +308,9 @@ function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, struc
302
308
  // proxy. Checked before `shouldSkipEntity` and the attribute-table lookup
303
309
  // below so it wins over both.
304
310
  if (withheldRefIds && withheldRefIds.size > 0 && referencesAnyExpressId(attrsRaw, withheldRefIds)) {
305
- return resolveUnrepresentedEntity(prefix, entityType, attrsRaw, toSchema, random, withheldRefIds !== undefined);
311
+ return resolveUnrepresentedEntity(prefix, entityType, attrsRaw, args, toSchema, expressId, true);
306
312
  }
307
- structuralDiagnostics?.inspect(expressId, line, fromSchema, toSchema);
313
+ diagnostics?.structural.inspect(expressId, line, fromSchema, toSchema);
308
314
  if (structuralAxis)
309
315
  return `${prefix}${newType}(${args.join(',')},${structuralAxis});`;
310
316
  const structural = structuralAttributes(entityType, args, fromSchema, toSchema);
@@ -356,30 +362,25 @@ function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, struc
356
362
  // [Name, Description, Properties, Material]), and trimming the tail or
357
363
  // appending `$` there would leave values in the wrong, type-invalid slots.
358
364
  // Those take a reviewed attribute map (#10763) or are left alone.
359
- // Appended attributes are optional, so `$` is a valid pad.
360
- //
361
- // Source attrs keyed on the ORIGINAL type; target on the (possibly renamed) type.
362
365
  let finalAttrs = attrsRaw;
363
366
  const targetTable = attrNameTable(toSchema);
364
367
  const srcAttrs = attrNameTable(fromSchema)?.get(entityType);
365
368
  const tgtAttrs = targetTable?.get(newType);
366
369
  // `shouldSkipEntity` above only catches its hand-listed alignment types;
367
- // a type entirely unknown to `targetTable` (not merely a strict-prefix
368
- // attribute mismatch, handled below) has no representation in `toSchema` at
369
- // all — see `resolveUnrepresentedEntity` for why it can't just pass through.
370
- // On IFC2X3 even with no source entry, as Rust's `has_representation`: a
371
- // non-entity head (`#1=IFCLABEL('x');`) fails closed (#7683, D3).
372
- if (targetTable && !tgtAttrs && (toSchema === 'IFC2X3' || (toSchema === 'IFC4' && fromSchema === 'IFC4X3' && srcAttrs))) {
373
- return resolveUnrepresentedEntity(prefix, entityType, attrsRaw, toSchema, random, withheldRefIds !== undefined);
370
+ // The same missing-type policy governs exports and loss previews (#10902).
371
+ if (missingTypeRoute(entityType, fromSchema, toSchema, srcAttrs !== undefined, !targetTable || tgtAttrs !== undefined) === 'unrepresented') {
372
+ return resolveUnrepresentedEntity(prefix, entityType, attrsRaw, args, toSchema, expressId, withheldRefIds !== undefined);
374
373
  }
375
374
  if (srcAttrs && tgtAttrs) {
376
375
  const mapped = args.length > 0 ? attrMapFor(entityType, newType, fromSchema, toSchema) : undefined; // #10763
377
376
  const replaced = mapped ? undefined : replacedSlot(entityType, srcAttrs, tgtAttrs); // #10758: no value carries there
378
- if (replaced !== undefined && replaced < args.length && args[replaced].trim() !== '$') {
377
+ if (replaced !== undefined && replaced < args.length && withoutComments(args[replaced]) !== '$') {
379
378
  args[replaced] = '$';
380
379
  finalAttrs = args.join(',');
381
380
  }
382
- if (mapped)
381
+ if (entityType !== newType && needsUpgradeSlotMap(entityType, fromSchema, toSchema))
382
+ finalAttrs = remapUpgradeSlots(entityType, srcAttrs, tgtAttrs, args);
383
+ else if (mapped)
383
384
  finalAttrs = remapByAttrMap(mapped.map, mapped.up, args, srcAttrs, tgtAttrs);
384
385
  else if (isStrictAttrPrefix(tgtAttrs, srcAttrs, entityType)) {
385
386
  finalAttrs = trimAttributes(attrsRaw, args, tgtAttrs.length);
@@ -391,9 +392,11 @@ function convertRecord(line, fromSchema, toSchema, random, withheldRefIds, struc
391
392
  }
392
393
  }
393
394
  else if (isGridPlacementInSourceLayout(entityType, args.length, tgtAttrs.length) || (entityType !== newType
394
- && (BY_NAME_ATTR_REMAP_TYPES.has(entityType) || (toSchema === 'IFC2X3' && MEP_IFC2X3_TYPES.has(entityType))))) {
395
+ && (newType === 'IFCBUILDINGSTOREY' || BY_NAME_ATTR_REMAP_TYPES.has(entityType) || (toSchema === 'IFC2X3' && MEP_IFC2X3_TYPES.has(entityType))))) {
395
396
  // MEP controls need ControlElementId, never the source PredefinedType (#8019).
396
- const remapped = remapRenamedAttributesByName(finalAttrs, srcAttrs, tgtAttrs);
397
+ if (newType === 'IFCBUILDINGSTOREY')
398
+ diagnostics?.forms.omitStoreyAttributes(entityType, args, srcAttrs, tgtAttrs);
399
+ const remapped = remapRenamedAttributesByName(finalAttrs, srcAttrs, tgtAttrs, maxReferenceId);
397
400
  if (remapped === null)
398
401
  throw new Error('Schema conversion refused an invalid STEP argument list.');
399
402
  finalAttrs = remapped;