New ifcopenshell.api.run syntax, and rename create_product to create_entity. See #1399.

This commit is contained in:
Dion Moult
2021-03-27 22:52:52 +11:00
parent 62540f0b00
commit ce03742aab
44 changed files with 490 additions and 441 deletions
@@ -1,5 +1,5 @@
import ifcopenshell
import ifcopenshell.api.owner.create_owner_history as create_owner_history
import ifcopenshell.api
class Usecase:
@@ -12,7 +12,7 @@ class Usecase:
def execute(self):
self.file.create_entity("IfcRelVoidsElement", **{
"GlobalId": ifcopenshell.guid.new(),
"OwnerHistory": create_owner_history.Usecase(self.file).execute(),
"OwnerHistory": ifcopenshell.api.run("owner.create_owner_history", self.file),
"RelatingBuildingElement": self.settings["element"],
"RelatedOpeningElement": self.settings["opening"]
})