CharacteristicList Class¶
-
class
NXOpen.Routing.
CharacteristicList
¶ Bases:
NXOpen.TransientObject
Contains a list of characteristics.
A characteristics is a name-value pair where the value can be an integer, real or string.
New in version NX4.0.0.
Methods¶
Method | Description |
---|---|
DeleteCharacteristic | Removes a characteristic from the characteristic list. |
Dispose | Frees the memory associated with this object. |
GetCharacteristicTitlesByType | Returns the titles of all characteristics that have the specified type. |
GetIntegerCharacteristic | Gets the value of an integer characteristic. |
GetRealCharacteristic | Gets the value of a real characteristic. |
GetStringCharacteristic | Gets the value of a string characteristic |
SetCharacteristic | Sets the value of an integer characteristic associated with the input name. |
Structs¶
CharacteristicListCharacteristicInformation_Struct Struct | Contains the type and name of a characteristic |
Method Detail¶
DeleteCharacteristic¶
-
CharacteristicList.
DeleteCharacteristic
¶ Removes a characteristic from the characteristic list.
Signature
DeleteCharacteristic(name, type)
Parameters: - name (str) – The name of the characteristic
- type (
NXOpen.NXObjectAttributeType
) – The type of the characteristic.:py:class:NXOpen.NXObjectAttributeType.Any <NXOpen.NXObjectAttributeType> is not valid. SeeNXOpen.NXObjectAttributeType
for more information.
New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
Dispose¶
-
CharacteristicList.
Dispose
¶ Frees the memory associated with this object.
Signature
Dispose()
New in version NX4.0.0.
License requirements: None.
GetCharacteristicTitlesByType¶
-
CharacteristicList.
GetCharacteristicTitlesByType
¶ Returns the titles of all characteristics that have the specified type.
Signature
GetCharacteristicTitlesByType(type)
Parameters: type ( NXOpen.NXObjectAttributeType
) – The characteristic type.SpecifyingNXOpen.NXObjectAttributeType.Any
returns the titles of all characteristics in the list. SeeNXOpen.NXObjectAttributeType
for more information.Returns: The list of characteristic names. Return type: list of NXOpen.Routing.CharacteristicListCharacteristicInformation_Struct
New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
GetIntegerCharacteristic¶
-
CharacteristicList.
GetIntegerCharacteristic
¶ Gets the value of an integer characteristic.
Signature
GetIntegerCharacteristic(name)
Parameters: name (str) – The name of the characteristic. Returns: The integer value of the characteristic. Return type: int New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
GetRealCharacteristic¶
-
CharacteristicList.
GetRealCharacteristic
¶ Gets the value of a real characteristic.
Signature
GetRealCharacteristic(name)
Parameters: name (str) – The name of the characteristic Returns: The real value of the characteristic Return type: float New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
GetStringCharacteristic¶
-
CharacteristicList.
GetStringCharacteristic
¶ Gets the value of a string characteristic
Signature
GetStringCharacteristic(name)
Parameters: name (str) – The name of the characteristic Returns: The string value of the characteristic Return type: str New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
SetCharacteristic¶
-
CharacteristicList.
SetCharacteristic
¶ Overloaded method SetCharacteristic
SetCharacteristic(name, value)
SetCharacteristic(name, value)
SetCharacteristic(name, value)
SetCharacteristic(name, value, type)
-------------------------------------
Sets the value of an integer characteristic associated with the input name. The method adds a new characteristic to the list if one does not exist already or converts the type of an existing characteristic to integer if necessary.
Signature
SetCharacteristic(name, value)
Parameters: - name (str) – The name of the characteristic
- value (int) – The integer value of the characteristic
New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
-------------------------------------
Sets the value of an real characteristic associated with the input name. The method adds a new characteristic to the list if one doesn’t exist already or converts the type of an existing characteristic to real if necessary.
Signature
SetCharacteristic(name, value)
Parameters: - name (str) – The name of the characteristic
- value (float) – The real value of the characteristic
New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
-------------------------------------
Sets the value of an string characteristic. The method adds a new characteristic to the list if one does not exist already or converts the type of an existing characteristic to string if necessary.
Signature
SetCharacteristic(name, value)
Parameters: - name (str) – The name of the characteristic
- value (str) – The string value of the characteristic
New in version NX4.0.0.
License requirements: routing_base (“Routing Basic”)
-------------------------------------
Sets the value of a string or reference characteristic. The method adds a new characteristic to the list if one does not exist already or converts the type of an existing characteristic to string or reference if necessary.
Signature
SetCharacteristic(name, value, type)
Parameters: - name (str) – The name of the characteristic
- value (str) – The string value of the characteristic
- type (
NXOpen.NXObjectAttributeType
) – The type of the characteristic, either string or reference type.:py:class:NXOpen.NXObjectAttributeType.Any <NXOpen.NXObjectAttributeType> is not valid. SeeNXOpen.NXObjectAttributeType
for more information.
New in version NX6.0.2.
License requirements: routing_base (“Routing Basic”)
-------------------------------------