mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-19 03:33:48 +00:00
Replace all ifcopenshell.api.run with ifcopenshell.api static functions.
This commit is contained in:
@@ -73,15 +73,15 @@ def add_prop_template(
|
||||
.. code:: python
|
||||
|
||||
# Create a simple template that may be applied to all types
|
||||
template = ifcopenshell.api.run("pset_template.add_pset_template", model, name="ABC_RiskFactors")
|
||||
template = ifcopenshell.api.pset_template.add_pset_template(model, name="ABC_RiskFactors")
|
||||
|
||||
# Here's one example property
|
||||
ifcopenshell.api.run("pset_template.add_prop_template", model, pset_template=template,
|
||||
ifcopenshell.api.pset_template.add_prop_template(model, pset_template=template,
|
||||
name="HighVoltage", description="Whether there is a risk of high voltage.",
|
||||
primary_measure_type="IfcBoolean")
|
||||
|
||||
# Here's another
|
||||
ifcopenshell.api.run("pset_template.add_prop_template", model, pset_template=template,
|
||||
ifcopenshell.api.pset_template.add_prop_template(model, pset_template=template,
|
||||
name="ChemicalType", description="The class of chemical spillage.",
|
||||
primary_measure_type="IfcLabel")
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user