Model.CE_ConvertByMark#

Model.CE_ConvertByMark(collection, source_style, target_style, reserved1, reserved2)#

Converts between bolt and spot connectors.

Parameters:
  • collection (Collection) – The collection containing the connector entities to convert.

  • source_style (hwString) – The source connector style. Valid values are “spot” and “bolt”.

  • target_style (hwString) – The target connector style. Valid values are “spot” and “bolt.”

  • reserved1 (int) – Reserved for future use. Must be set to 0.

  • reserved2 (int) – Reserved for future use. Must be set to 0.

Example#

Convert spot connectors with IDs 101 and 102 to bolt connectors#
import hm
import hm.entities as ent

model = hm.Model()

model.CE_ConvertByMark(
    collection=hm.Collection(model, ent.Connector, [101, 102]),
    source_style="spot",
    target_style="bolt",
    reserved1=0,
    reserved2=0,
)