ifcopenshell.api.owner.settings
¶
Module Contents¶
- ifcopenshell.api.owner.settings.factory_reset()¶
Reset the get_user and get_application functions to what came out of box
When you are developing a custom application, you will typically override the get_user and get_application function to your own needs. Sometimes you want to reset it to before you monkey-patched it. This function does that reset.
- ifcopenshell.api.owner.settings.get_application(ifc: ifcopenshell.file) ifcopenshell.entity_instance | None ¶
Returns the application representing the authoring software
It is expected for you to overload this function with your own IfcApplication. See ifcopenshell.api.owner.create_owner_history for details.
- Parameters:
ifc (ifcopenshell.file) – The IFC file object that is being edited.
- Returns:
The IfcApplication with metadata of the authoring software.
- Return type:
ifcopenshell.entity_instance
- ifcopenshell.api.owner.settings.get_user(ifc: ifcopenshell.file) ifcopenshell.entity_instance | None ¶
Returns the active authoring user
It is expected for you to overload this function with your own IfcApplication. See ifcopenshell.api.owner.create_owner_history for details.
- Parameters:
ifc (ifcopenshell.file) – The IFC file object that is being edited.
- Returns:
The IfcPersonAndOrganization with metadata of the authoring user.
- Return type:
ifcopenshell.entity_instance
- ifcopenshell.api.owner.settings.restore()¶
Restore the get_user and get_application function prior to a reset
In case you want to restore the monkey-patched version of get_user and get_application that existed before you applied a factory_reset(), this function will do that.
- ifcopenshell.api.owner.settings.get_application_backup¶
- ifcopenshell.api.owner.settings.get_application_factory¶
- ifcopenshell.api.owner.settings.get_user_backup¶
- ifcopenshell.api.owner.settings.get_user_factory¶