Skip to content

Commit

Permalink
feat(core): allows to define a custom name to Classifier.bySpatialStr…
Browse files Browse the repository at this point in the history
…ucture
  • Loading branch information
HoyosJuan committed Nov 5, 2024
1 parent eb9e0cd commit a5d806a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/core/src/fragments/Classifier/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,11 @@ export class Classifier extends Component implements Disposable {
*/
async bySpatialStructure(
model: FRAGS.FragmentsGroup,
config: { useProperties?: boolean; isolate?: Set<number> } = {},
config: {
useProperties?: boolean;
isolate?: Set<number>;
systemName?: string;
} = {},
) {
const indexer = this.components.get(IfcRelationsIndexer);
const modelRelations = indexer.relationMaps[model.uuid];
Expand All @@ -374,7 +378,7 @@ export class Classifier extends Component implements Disposable {
`Classifier: model relations of ${model.name || model.uuid} have to exists to group by spatial structure.`,
);
}
const systemName = "spatialStructures";
const systemName = config.systemName ?? "spatialStructures";

// If useProperties is undefined, use properties by default
const noProps = config.useProperties === undefined;
Expand Down

0 comments on commit a5d806a

Please sign in to comment.