Assembly#
- class Assembly(element_id: ansys.api.modelcenter.v0.element_messages_pb2.ElementId, engine: ansys.modelcenter.workflow.grpc_modelcenter.engine.Engine)#
Bases: ansys.modelcenter.workflow.grpc_modelcenter.abstract_control_statement.AbstractControlStatement
, ansys.modelcenter.workflow.api.IAssembly
Represents an assembly in ModelCenter.
Note
This class should not be directly instantiated by clients. Get a
Workflow
object from an instantiatedEngine
instance and use it to get a valid instance of this object.
Overview#
Create a datapin on the assembly. |
|
Delete a given datapin. |
|
Create a subassembly with a specific type and position. |
Parent elementβs ID. |
Return self==value. |
Import detail#
from ansys.modelcenter.workflow.grpc_modelcenter.assembly import Assembly
Property detail#
Method detail#
- Assembly.__eq__(other)#
Return self==value.
- Assembly.add_datapin(name: str, mc_type: ansys.tools.variableinterop.VariableType) ansys.modelcenter.workflow.api.IDatapin #
Create a datapin on the assembly.
- Assembly.delete_datapin(name: str) bool #
Delete a given datapin.
Variable objects that represent the given datapin become invalid. If there is no datapin with the given name, no error is raised.
- Assembly.add_assembly(name: str, av_pos: Tuple[int, int] | None = None, assembly_type: ansys.modelcenter.workflow.api.AssemblyType | None = None) ansys.modelcenter.workflow.api.IAssembly #
Create a subassembly with a specific type and position.
- Parameters:
- name
str
Name of the subassembly.
- av_pos
Tuple
[int,int],optional
Position of the subassembly in the parent assemblyβs analysis view. The default is
None
.- assembly_type
AssemblyType
,optional
Type of assembly to create. The default is
None
, in which case a regular data-dependency assembly is created. (This is the same as passingAssemblyType.ASSEMBLY
.)
- name
- Returns:
IAssembly
Created assembly object.