Model.CE_Lock#

Model.CE_Lock(ce_markmask, option)#

Locks or unlocks selected connectors. Unrealized connectors selected for locking will be automatically realized.

Parameters:
  • ce_markmask (Collection) – The collection containing the connector entities to be locked or unlocked.

  • option (int) –

    The option to lock or unlock the selected connectors.

    • 0 - Unlock the selected connectors.

    • 1 - Lock the selected connectors.

Example#

Realize and lock unrealized connectors with ID 1 and 2#
import hm
import hm.entities as ent

model = hm.Model()

connector_col = hm.Collection(model,ent.Connector,[1,2])

model.CE_Lock(connector_col,option=1)