RequirementUtils Class — NXOpen Python API Reference 12.0.0 documentation

# RequirementUtils Class

class `NXOpen.PDM.``RequirementUtils`

  Bases: `object`

  Collection of PDM utility methods

  To obtain an instance of this class, refer to `NXOpen.Session`

  New in version NX6.0.3.

# Methods

Method | Description
--- | ---
CreateTraceLinks | Creates Trace Links from :py:class:`NXOpen.Validate.Requirement`s to :py:class:`NXOpen.Part`s For the input requirement_item_numbers: In case of Default Domain: it is Teamcenter item ID.
NewTracelinkQuery | Returns a Tracelink query object
RemoveTraceLinks | Removes Trace Links between :py:class:`NXOpen.Validate.Requirement`s and :py:class:`NXOpen.Part`s For the input requirement_item_numbers: In case of Default Domain: it is Teamcenter item ID.

# Method Detail

## CreateTraceLinks

`RequirementUtils.``CreateTraceLinks`

  Creates Trace Links from :py:class:`NXOpen.Validate.Requirement`s to :py:class:`NXOpen.Part`s For the input requirement_item_numbers: In case of Default Domain: it is Teamcenter item ID.

  In case of non-Default Domain: it is the multifield key. e.g. %#MFK#%,=item_id=001, object_type=SupplierPart, supplier_code=x And the encoded part filename would be containing the MFK.

  Signature `CreateTraceLinks(requirementItemNumbers, requirementRevisions, parts)`

  Parameters:

  - requirementItemNumbers (list of str) – requirement multifield key
  - requirementRevisions (list of str) – requirement item revisions. Must be same size as the item number array
  - parts (list of str) – part CLI names

  New in version NX8.5.0.

  License requirements: None.

## NewTracelinkQuery

`RequirementUtils.``NewTracelinkQuery`

  Returns a Tracelink query object

  Signature `NewTracelinkQuery()`

  Returns: |
  Return type: | `NXOpen.PDM.TracelinkQuery`

  New in version NX6.0.3.

  License requirements: None.

## RemoveTraceLinks

`RequirementUtils.``RemoveTraceLinks`

  Removes Trace Links between :py:class:`NXOpen.Validate.Requirement`s and :py:class:`NXOpen.Part`s For the input requirement_item_numbers: In case of Default Domain: it is Teamcenter item ID.

  In case of non-Default Domain: it is the multifield key. e.g. %#MFK#%,=item_id=001, object_type=SupplierPart, supplier_code=x And the encoded part filename would be containing the MFK.

  Signature `RemoveTraceLinks(requirementItemNumbers, requirementRevisions, parts)`

  Parameters:

  - requirementItemNumbers (list of str) – requirement multifield Key
  - requirementRevisions (list of str) – requirement item revisions. Must be same size as the item number array
  - parts (list of str) – part CLI names

  New in version NX8.5.0.

  License requirements: None.