ifcopenshell.api.alignment.add_stationing_referent

Module Contents

ifcopenshell.api.alignment.add_stationing_referent.add_stationing_referent(file: ifcopenshell.file, element: ifcopenshell.entity_instance, basis_curve: ifcopenshell.entity_instance, distance_along: float, station: float, name: str) ifcopenshell.entity_instance

Adds an IfcReferent to the element with the Pset_Stationing property set. If element is an IfcAlignment, IfcReferent.PredefinedType is set to “STATION”, otherwise “POSITION”

Parameters:
  • element – the element to receive the referent, expected to be an IfcAlignment or IfcAlignmentSegment

  • basis_curve – the basis curve for positining

  • distance_along – distance along the basis curve

  • station – station value

  • name – name to assign to IfcReferent.Name, typically a stringized version of the station value

Returns:

referent

Example:

alignment = model.by_type("IfcAlignment")[0]
basis_curve = ifcopenshell.api.alignment.get_basis_curve(alignment)
ifcopenshell.api.alignment.add_stationing_referent(model,entity=alignment,basis_curve=basis_curve,distance_along=0.0,station=100.0)