Model.hm_ce_generatenamefromsubsystem#

Model.hm_ce_generatenamefromsubsystem(connector, base_name)#

Returns a name using a base name and connector subsystem ID.

This returns a string like <base_name>_ss<ID> where ID is the subsystem ID of the connector.

Parameters:
  • connector (Entity) – The object describing the connector entity to query.

  • base_name (hwString) – The base name to append.

Returns:

Examples#

Generate a name for connector with ID 2 and the base “ hexa_comp “#
import hm
import hm.entities as ent

model = hm.Model()

_, result = model.hm_ce_generatenamefromsubsystem(
  connector=ent.Connector(model, 2),
  base_name="hexa_comp"
)

print("Generated Name: ", result.generatedName)