RoomAttributeListBuilder Class¶
-
class
NXOpen.Features.ShipDesign.
RoomAttributeListBuilder
¶ Bases:
NXOpen.TaggedObject
,NXOpen.GeometricUtilities.IComponentBuilder
The builder to define room attributes
New in version NX12.0.0.
Methods¶
Method | Description |
---|---|
InitFromObject | Initializes the builder from an object. |
SetAttribute | Sets the specific attribute name and value given the index in the list. |
SetRoomPurpose | Sets the room purpose. |
UpdateAttributes | Updates all attributes with new name and values. |
Validate | Validate whether the inputs to the component are sufficient for commit to be called. |
Method Detail¶
InitFromObject¶
-
RoomAttributeListBuilder.
InitFromObject
¶ Initializes the builder from an object.
Signature
InitFromObject(objectTag)
Parameters: objectTag ( NXOpen.TaggedObject
) – Body or ComponentNew in version NX12.0.0.
License requirements: nx_ship_gen_arrange (“Ship General Arrangement”)
SetAttribute¶
-
RoomAttributeListBuilder.
SetAttribute
¶ Sets the specific attribute name and value given the index in the list.
Signature
SetAttribute(index, attrName, attrValue)
Parameters: - index (int) –
- attrName (str) –
- attrValue (str) –
New in version NX12.0.0.
License requirements: nx_ship_gen_arrange (“Ship General Arrangement”)
SetRoomPurpose¶
-
RoomAttributeListBuilder.
SetRoomPurpose
¶ Sets the room purpose.
If room purpose changes, this will try to reconstruct the attribute list because different attributes are pre-defined for different room purposes.
Signature
SetRoomPurpose(roomPurpose)
Parameters: roomPurpose (str) – New in version NX12.0.0.
License requirements: nx_ship_gen_arrange (“Ship General Arrangement”)
UpdateAttributes¶
-
RoomAttributeListBuilder.
UpdateAttributes
¶ Updates all attributes with new name and values.
Signature
UpdateAttributes(attrNames, attrValues)
Parameters: - attrNames (list of str) –
- attrValues (list of str) –
New in version NX12.0.0.
License requirements: nx_ship_gen_arrange (“Ship General Arrangement”)
Validate¶
-
RoomAttributeListBuilder.
Validate
¶ Validate whether the inputs to the component are sufficient for commit to be called.
If the component is not in a state to commit then an exception is thrown. For example, if the component requires you to set some property, this method will throw an exception if you haven’t set it. This method throws a not-yet-implemented NXException for some components.
Signature
Validate()
Returns: Was self validation successful Return type: bool New in version NX3.0.1.
License requirements: None.