ReferencePropertyBase#

class ReferencePropertyBase(element_id: ansys.api.modelcenter.v0.element_messages_pb2.ElementId, name: str, engine: ansys.modelcenter.workflow.grpc_modelcenter.engine.Engine)#

Bases: ansys.modelcenter.workflow.api.ireferenceproperty.IReferencePropertyBase

Defines the base class for reference properties that define common methods.

Note

This base class should not be used directly. Instead, use the ReferenceProperty or ReferenceArrayProperty class as required.

Overview#

get_value_type

Get the value type of the property.

get_metadata

Get the metadata for the property.

set_metadata

Set the metadata for the property.

is_input

Flag indicating if the property is an input or output.

name

Name of the property.

Import detail#

from ansys.modelcenter.workflow.grpc_modelcenter.reference_property import ReferencePropertyBase

Property detail#

property ReferencePropertyBase.is_input: bool#

Flag indicating if the property is an input or output.

Returns:
bool

True if this property is an input, False otherwise.

property ReferencePropertyBase.name: str#

Name of the property.

Returns:
str

Name of the property.

Method detail#

ReferencePropertyBase.get_value_type() ansys.tools.variableinterop.VariableType#

Get the value type of the property.

Returns:
atvi.VariableType

Type of the property.

ReferencePropertyBase.get_metadata() ansys.tools.variableinterop.CommonVariableMetadata#

Get the metadata for the property.

Returns:
atvi.CommonVariableMetadata

Value of the metadata.

ReferencePropertyBase.set_metadata(new_value: ansys.tools.variableinterop.CommonVariableMetadata)#

Set the metadata for the property.

Note that this method only has an effect for reference properties where the datatype is numeric, in which case the display format passed in is set.

Parameters:
new_valueatvi.CommonVariableMetadata

New value for the metadata.