DatabaseAttributeManager Class

class NXOpen.PDM.DatabaseAttributeManager

Bases: NXOpen.TransientObject

This class is responsible for setting and getting NX Manager database attribute.

Use PDM.PartBuilder.NewDatabaseAttributeManager() or PDM.PdmPart.NewDatabaseAttributeManager() to get the instance of this class.

New in version NX4.0.0.

Methods

Method Description
Dispose Free resources associated with the instance.
GetAttribute Gets the value of a writable database attribute.
LoadAttributes Load the Database Attributes from Teamcenter.
LoadAttributesRecursively Recursively load the Database Attributes of this part and all its partially or fully loaded components from Teamcenter.
RefreshAttributes Force load the Database Attributes from Teamcenter.
SetAttribute Sets the value of a writable database attribute.
StoreAttributes Register DB_PART_NAME and DB_PART_DESC attributes with values set in the attribute_manager

Method Detail

Dispose

DatabaseAttributeManager.Dispose

Free resources associated with the instance.

After this method is called, it is illegal to use the object. In .NET, this method is automatically called when the object is deleted by the garbage collector.

Signature Dispose()

New in version NX4.0.0.

License requirements: None.

GetAttribute

DatabaseAttributeManager.GetAttribute

Gets the value of a writable database attribute.

Signature GetAttribute(attributeTitle)

Parameters:attributeTitle (str) – the title of the attribute
Returns:the value of the attribute
Return type:str

New in version NX4.0.0.

License requirements: None.

LoadAttributes

DatabaseAttributeManager.LoadAttributes

Load the Database Attributes from Teamcenter.

This operation will not discard any changes made in this session that aren’t committed to Teamcenter. If ‘reload’ is set to ‘true’, attributes that have already been loaded will be loaded again, if otherwise allowed.

Signature LoadAttributes(reload)

Parameters:reload (bool) – Reload attributes that have already been loaded, if otherwise allowed.

New in version NX8.0.0.

License requirements: None.

LoadAttributesRecursively

DatabaseAttributeManager.LoadAttributesRecursively

Recursively load the Database Attributes of this part and all its partially or fully loaded components from Teamcenter.

This operation will not discard any changes made in this session that aren’t committed to Teamcenter.

Signature LoadAttributesRecursively(reload)

Parameters:reload (bool) – Reload attributes that have already been loaded, if otherwise allowed.

New in version NX8.0.0.

License requirements: None.

RefreshAttributes

DatabaseAttributeManager.RefreshAttributes

Force load the Database Attributes from Teamcenter.

This removes changes to values made in NX.

Signature RefreshAttributes()

New in version NX6.0.0.

License requirements: None.

SetAttribute

DatabaseAttributeManager.SetAttribute

Sets the value of a writable database attribute.

Signature SetAttribute(attributeTitle, attributeValue)

Parameters:
  • attributeTitle (str) – the title of the attribute to be set
  • attributeValue (str) – the new value the attribute is to be set to

New in version NX4.0.0.

License requirements: None.

StoreAttributes

DatabaseAttributeManager.StoreAttributes

Register DB_PART_NAME and DB_PART_DESC attributes with values set in the attribute_manager

Signature StoreAttributes()

New in version NX4.0.0.

License requirements: None.