From 445b07eae68f4b0031899f8798b8f829a08bc2e3 Mon Sep 17 00:00:00 2001 From: Juan Hoyos Date: Tue, 27 Aug 2024 16:21:10 -0500 Subject: [PATCH] chore: restructure files --- .../src/ifc/IfcPropertiesManager/src/index.ts | 3 +- .../ifc/IfcPropertiesManager/src/rel-attrs.ts | 28 +++++++++++++++++++ .../src/{rels-builder.ts => rel-names.ts} | 27 ------------------ 3 files changed, 30 insertions(+), 28 deletions(-) create mode 100644 packages/core/src/ifc/IfcPropertiesManager/src/rel-attrs.ts rename packages/core/src/ifc/IfcPropertiesManager/src/{rels-builder.ts => rel-names.ts} (51%) diff --git a/packages/core/src/ifc/IfcPropertiesManager/src/index.ts b/packages/core/src/ifc/IfcPropertiesManager/src/index.ts index 5130109af..ac441ca68 100644 --- a/packages/core/src/ifc/IfcPropertiesManager/src/index.ts +++ b/packages/core/src/ifc/IfcPropertiesManager/src/index.ts @@ -1,2 +1,3 @@ -export * from "./rels-builder"; +export * from "./rel-attrs"; +export * from "./rel-names"; export * from "./types"; diff --git a/packages/core/src/ifc/IfcPropertiesManager/src/rel-attrs.ts b/packages/core/src/ifc/IfcPropertiesManager/src/rel-attrs.ts new file mode 100644 index 000000000..c04ad6dda --- /dev/null +++ b/packages/core/src/ifc/IfcPropertiesManager/src/rel-attrs.ts @@ -0,0 +1,28 @@ +import { IfcRelName } from "./types"; + +type IfcRelAttributePosition = { related: number; relating: number }; + +export const ifcRelAttrsPosition: Record = + { + // IfcRelAssigns + IfcRelAssignsToControl: { related: 5, relating: 7 }, + IfcRelAssignsToGroup: { related: 5, relating: 7 }, + IfcRelAssignsToProduct: { related: 5, relating: 7 }, + // IfcRelAssociates + IfcRelAssociatesClassification: { related: 5, relating: 6 }, + IfcRelAssociatesMaterial: { related: 5, relating: 6 }, + IfcRelAssociatesDocument: { related: 5, relating: 6 }, + // IfcRelConnects + IfcRelContainedInSpatialStructure: { related: 5, relating: 6 }, + IfcRelFlowControlElements: { related: 5, relating: 6 }, + IfcRelConnectsElements: { related: 7, relating: 6 }, + // IfcRelDeclares + IfcRelDeclares: { related: 6, relating: 5 }, + // IfcRelDecomposes + IfcRelAggregates: { related: 6, relating: 5 }, + IfcRelNests: { related: 6, relating: 5 }, + // IfcRelDefines + IfcRelDefinesByProperties: { related: 5, relating: 6 }, + IfcRelDefinesByType: { related: 5, relating: 6 }, + IfcRelDefinesByTemplate: { related: 5, relating: 6 }, + }; diff --git a/packages/core/src/ifc/IfcPropertiesManager/src/rels-builder.ts b/packages/core/src/ifc/IfcPropertiesManager/src/rel-names.ts similarity index 51% rename from packages/core/src/ifc/IfcPropertiesManager/src/rels-builder.ts rename to packages/core/src/ifc/IfcPropertiesManager/src/rel-names.ts index 24b87f51d..e7e6dfa6d 100644 --- a/packages/core/src/ifc/IfcPropertiesManager/src/rels-builder.ts +++ b/packages/core/src/ifc/IfcPropertiesManager/src/rel-names.ts @@ -2,33 +2,6 @@ import * as WEBIFC from "web-ifc"; import { IfcRelName } from "./types"; import { IfcRelation } from "../../IfcRelationsIndexer"; -type IfcRelAttributePosition = { related: number; relating: number }; - -export const ifcRelAttrsPosition: Record = - { - // IfcRelAssigns - IfcRelAssignsToControl: { related: 5, relating: 7 }, - IfcRelAssignsToGroup: { related: 5, relating: 7 }, - IfcRelAssignsToProduct: { related: 5, relating: 7 }, - // IfcRelAssociates - IfcRelAssociatesClassification: { related: 5, relating: 6 }, - IfcRelAssociatesMaterial: { related: 5, relating: 6 }, - IfcRelAssociatesDocument: { related: 5, relating: 6 }, - // IfcRelConnects - IfcRelContainedInSpatialStructure: { related: 5, relating: 6 }, - IfcRelFlowControlElements: { related: 5, relating: 6 }, - IfcRelConnectsElements: { related: 7, relating: 6 }, - // IfcRelDeclares - IfcRelDeclares: { related: 6, relating: 5 }, - // IfcRelDecomposes - IfcRelAggregates: { related: 6, relating: 5 }, - IfcRelNests: { related: 6, relating: 5 }, - // IfcRelDefines - IfcRelDefinesByProperties: { related: 5, relating: 6 }, - IfcRelDefinesByType: { related: 5, relating: 6 }, - IfcRelDefinesByTemplate: { related: 5, relating: 6 }, - }; - export const ifcRelClassNames: Record = { // IfcRelAssigns [WEBIFC.IFCRELASSIGNSTOCONTROL]: "IfcRelAssignsToControl",