Class VariantSpecRenderer

java.lang.Object
com.ptc.windchill.esi.rnd.BasicESIRenderer
com.ptc.windchill.esi.ov.VariantSpecRenderer
All Implemented Interfaces:
ESIRenderer

public class VariantSpecRenderer extends BasicESIRenderer
Renders an VariantSpec.The class is instantiated when publishing a BOM structure in the object-centric mode.

Supported API: true

Extendable: true
  • Method Details

    • setData

      public void setData(WTPart context, Collection<VariantSpec> variantSpec, ESITarget target, String auth, String adapter, VdbBuilder builder)
      Initializes this renderer instance appropriately.

      Supported API: true
      Parameters:
      context - - Object (part) that the VariantSpec is associated to.
      target - - Distribution target to which the VariantSpec is being processed.
      auth - - This parameter contains authentication information required for executing certain Windchill adapter webjects as part of the rendering process.
      paramsMap - - Can be used to pass additional data to this renderer. Currently this is not being used by Out-Of-box code.
      objectID - - The UFID of the option set being processed.
      Throws:
      WTException
    • setData

      public void setData(OptionSet context, Collection<VariantSpec> variantSpec, ESITarget target, String auth, String adapter, VdbBuilder builder)
      Initializes this renderer instance appropriately.

      Supported API: true
      Parameters:
      context - - Object (part) that the VariantSpec is associated to.
      target - - Distribution target to which the VariantSpec is being processed.
      auth - - This parameter contains authentication information required for executing certain Windchill adapter webjects as part of the rendering process.
      paramsMap - - Can be used to pass additional data to this renderer. Currently this is not being used by Out-Of-box code.
      objectID - - The UFID of the option set being processed.
      Throws:
      WTException
    • validate

      protected void validate() throws ESIRendererException
      Ensures that the data needed to execute this renderer is passed in correctly.

      Supported API: true
      Specified by:
      validate in class BasicESIRenderer
      Throws:
      ESIRendererException
    • buildGroups

      protected void buildGroups() throws ESIRendererException
      Renders the input VariantSpec and its related objects as added objects based on their release history.


      Supported API: true
      Specified by:
      buildGroups in class BasicESIRenderer
      Throws:
      ESIRendererException
    • adjustVariantSpecElement

      protected com.infoengine.object.factory.Element adjustVariantSpecElement(com.infoengine.object.factory.Element element, Persistable context, String groupName, VariantSpec variantSpec, Collection<ESITarget> targets)
      Allow subclasses to fix the contents of an element before it's added to the output group(s). Default behavior is to return the argument.

      Supported API: true
      Parameters:
      element - - The element to be updated.
      context - - Persistable object in the context of which this VariantSpec information needs to be rendered i.e Part object.
      groupName - - The logical name of the group to which the element will be added.
      variantSpec - - The VariantSpec that is being processed.
      targets - - The collection of ESITarget objects.
      Returns:
      updated element.
    • adjustModuleVariantInformationLinkElement

      protected com.infoengine.object.factory.Element adjustModuleVariantInformationLinkElement(com.infoengine.object.factory.Element element, Persistable context, String groupName, ModuleVariantInformationLink moduleVariantLink, Collection<ESITarget> targets)
      Allow subclasses to fix the contents of an element before it's added to the output group(s). Default behavior is to return the argument.

      Supported API: true
      Parameters:
      element - - The element to be updated.
      context - - Persistable object in the context of which ModuleVariantInformationLink information needs to be rendered i.e Part object.
      groupName - - The logical name of the group to which the element will be added.
      moduleVariantLink - - The ModuleVariantInformationLink that is being processed.
      targets - - The collection of ESITarget objects.
      Returns:
      updated element.
    • adjustNavigationCriteriaElement

      protected com.infoengine.object.factory.Element adjustNavigationCriteriaElement(com.infoengine.object.factory.Element element, Persistable context, String groupName, NavigationCriteria navCriteria, Collection<ESITarget> targets)
      Allow subclasses to fix the contents of an element before it's added to the output group(s). Default behavior is to return the argument.

      Supported API: true
      Parameters:
      element - - The element to be updated.
      context - - Persistable object in the context of which this VariantSpec information needs to be rendered i.e Part object.
      groupName - - The logical name of the group to which the element will be added.
      navCriteria - - The NavigationCriteria that is being processed.
      targets - - The collection of ESITarget objects.
      Returns:
      updated element.
    • getPreviousExportedIterationAssociations

      protected Map<PreviousExportedIterationKey,Collection<ESITargetAssociation>> getPreviousExportedIterationAssociations(WTPart part, Collection<ESITargetAssociation> tgtAssociations) throws WTException
      Computes the previous exported iteration for the input target associations. Invokes the API
      invalid reference
      ESITransactionUtility#latestBOMExport(Collection)
      .

      Computing a previous exported iteration is target sensitive because each target is not guaranteed to have the same previously exported iteration. For example, an assembly could be associated with target 1, then exported, then associated with target 2, and exported a second time. In the case of the second export, target 1 has a previous exported iteration, while target 2 does not. Therefore, the output map contains a previous exported iteration mapped to collection of targets.

      Supported API: true

      Parameters:
      part - - BOM header being processed. Could be the top level BOM header or a Sub BOM Header. Currently not used. But this may be useful for customizers.
      tgtAssociations - - Collection of distribution target associations. Typically the target association between the input part and current distribution target being processed.
      Returns:
      - a map whose key is a previous Exported Iteration and the value is a collection of distribution target associations.
      Throws:
      WTException
    • adjustDeletedMVLink

      protected com.infoengine.object.factory.Element adjustDeletedMVLink(String groupName, com.infoengine.object.factory.Element element, String attribute, ESITarget target) throws WTException
      Allow subclasses to fix the contents of an element before it's added to the output group(s). Default behavior is to return the argument.

      Supported API: true
      Parameters:
      groupName - - The logical name of the group to which the element will be added.
      element - - I*E element containing the input attributes that are to be mapped to the output Element.
      attribute - - Attribute value information retrieved from previously published ModuleVariantInformationLink.
      target - - Collection of ESITarget instances.
      Throws:
      WTException