Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feat]: Create IFC compliant GUIDs when using IfcGloballyUniqueId #905

Open
HoyosJuan opened this issue Jul 5, 2024 · 0 comments
Open
Assignees
Labels
enhancement New feature or request

Comments

@HoyosJuan
Copy link
Member

HoyosJuan commented Jul 5, 2024

What is your idea?

Let's say I am creating a new entity. In many cases, the constructor requires the GUID of the element, which one creates by using new IfcGloballyUniqueId(). Right now, IfcGloballyUniqueId() expects the user to provide ID. However, GUIDs in the IFC schema are not anything the user like, but something that complies with this. The problem is, we can't let users fight with knowing how to correctly compress IDs to comply with the schema, it's something the same library should care about.

Proposal

Let the IfcGloballyUniqueId() to optionally accept a UUID v4. If the UUID is provided, then the class compress it based on the requirements from the schema. If the UUID is not provided, then the class creates a random GUID that is compressed based on the schema.

@HoyosJuan HoyosJuan added the enhancement New feature or request label Jul 5, 2024
@beachtom beachtom self-assigned this Jul 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants