Class LoadAssociativityLinks

java.lang.Object
wt.associativity.LoadAssociativityLinks

public class LoadAssociativityLinks extends Object
Loader for the AssociativityLinks

Supported API: true

Extendable: false
  • Method Details

    • createEquivalenceLink

      public static boolean createEquivalenceLink(Hashtable nv, Hashtable cmd_line, Vector return_objects)
      Processes the "csvCreateEquivalenceLink" directive in the xml load file. Creates a EquivalenceLink between an UpStream Part and DownStream Part.

      XML Format

      <csvCreateEquivalenceLink handler="wt.associativity.LoadAssociativityLinks.createEquivalenceLink" >
        <csvtypedef> typedef </csvtypedef>
        <csvparentNumber> parent number </csvparentNumber>
        <csvparentVersion> parent version </csvparentVersion>
        <csvparentIteration> parent iteration </csvparentIteration>
        <csvparentView> parent view </csvparentView>
        <csvchildNumber> child number </csvchildNumber>
        <csvchildVersion> child version </csvchildVersion>
        <csvchildIteration> child iteration </csvchildIteration>
        <csvchildView> child view </csvchildView>
        <csvdescription> description </csvdescription>
        <csvupstreamContext> upstream view </csvupstreamContext>
        <csvdownstreamContext> downstream view </csvdownstreamContext>
        <csvconsumable> is consumable </csvconsumable>
        <csvequivalenceLinkAnnotations> equivalenceLinkAnnotations </csvequivalenceLinkAnnotations>
      </csvCreateEquivalenceLink>

      Tag Definitions

      parent number This tag specifies the Number of DownStream Part. This is a required field.
         
      parent version This tag specifies the Version of DownStream Part. If left blank, it is defaulted to the latest version/iteration.
         
      parent iteration This tag specifies the Iteration of DownStream Part. If left blank, it is defaulted to the latest version/iteration.
         
      parent view This tag specifies the View of DownStream Part. This is not a required field.
         
      child number This tag specifies the Number of UpStream Part. This is a required field.
         
      child vesrion This tag specifies the Version of UpStream Part. If left blank, it is defaulted to the latest version/iteration.
         
      child iteration This tag specifies the Iteration of UpStream Part. If left blank, it is defaulted to the latest version/iteration.
         
      child view This tag specifies the View of UpStream Part. This is a required field.
         
      description This tag specifies the description of the link. This is not a required field.
         
      upstream view This tag specifies the upstream context view for the link. This is not a required field.
         
      downstream view This tag specifies the downstream context view for the link. This is not a required field.
         
      is consumable This tag specifies whether consumption link can be created or not. This is a required field and can have boolean values
      annotantion This tag specifies annotantion to be set on link. This is optional field.
         
      typedef This contains the identifier string of a com.ptc.core.meta.common.TypeIdentifier.

      i.e. wt.associativity.EquivalenceLink|com.mycompany.SoftLink2

      This would create a soft typed part. This currently supports the following modeled types:

      This currently does not handle custom modeled types. If there is a need for one of these, then a custom loader needs to be created.

      This value is optional and defaults to wt.associativity.EquivalenceLink.



      Supported API: true

      Parameters:
      nv - hashtable with the values from the xml data file
      cmd_line - hashtable with values from the command line
      return_objects - NOT USED
      Returns:
      true if link has been successfully created, false otherwise
    • beginEquivalenceLink

      public static boolean beginEquivalenceLink(Hashtable nv, Hashtable cmd_line, Vector return_objects)
      Processes the "csvBeginEquivalenceLink" directive in the XML load file. Creates an EquivalenceLink object, persists it in the database, checks it out, applies the default attribute values associated with the specified type definition, persists the link, checks it back in, and caches it in the loader's memory.

      XML Format

      <csvBeginEquivalenceLink handler="wt.associativity.LoadAssociativityLinks.beginEquivalenceLink" >
      Same as createEquivalenceLink

      Supported API: true

      Parameters:
      nv - hashtable with the values from the xml data file
      cmd_line - hashtable with values from the command line
      return_objects - NOT USED
      Returns:
      true if link has successfully begun, false otherwise
      See Also:
    • endEquivalenceLink

      public static boolean endEquivalenceLink(Hashtable nv, Hashtable cmd_line, Vector return_objects)
      Processes the "csvEndEquivalenceLink" directive in the xml load file. Associates soft attributes from preceding IBAValue load file lines with the cached EquivalenceLink, applies the default attribute values associated with the specified type definition, persists the links, and caches it in the loader's memory.

      XML Format

      <csvEndEquivalenceLink handler="wt.associativity.LoadAssociativityLinks.endEquivalenceLink" />


      Supported API: true

      Parameters:
      nv - hashtable with the values from the xml data file
      cmd_line - hashtable with values from the command line
      return_objects - NOT USED
      Returns:
      true if the link has been ended, false otherwise
    • createConsumptionLink

      public static boolean createConsumptionLink(Hashtable nv, Hashtable cmd_line, Vector return_objects)
      Processes the "csvCreateConsumptionLink" directive in the xml load file. Construct a ConsumptionLink in the context of an Equivalence Link.

      XML Format

      <csvCreateConsumptionLink handler="wt.associativity.LoadAssociativityLinks.createConsumptionLink" >
        <csvdownStreamRootPartNumber> downstream root part number </csvdownStreamRootPartNumber>
        <csvdownStreamPath> downstream path </csvdownStreamPath>
        <csvdownStreamLeafPartView> downstream leaf part view </csvdownStreamLeafPartView>
        <csvupStreamRootPartNumber> upstream root part number </csvupStreamRootPartNumber>
        <csvupStreamPath> downstream path </csvupStreamPath>
        <csvupStreamLeafPartView> upstream leaf part view </csvupStreamLeafPartView>
      </csvCreateConsumptionLink>
      Pre Requisites :
      • An EquivalenceLink should exist between DownStream Root Part and UpStream Root Part
      • An EquivalenceLink should exist between DownStream Leaf Part and UpStream Leaf Part

      Tag Definitions

      downstream parent part number This tag specifies the Number of DownStream Root Part. This is a required field.
         
      downstream path This tag specifies the path info of DownStream Part. This is a required field. Reference designator is name attribute on PartUsesOccurrence.
         
      downstream leaf part view This tag specifies the view of the downstream leaf part. This is not a required field.
         
      upstream root part number This tag specifies the Number of UpStream Root Part. This is a required field.
         
      upstream path This tag specifies the path info of UpStream Part. This is a required field. Reference designator is name attribute on PartUsesOccurrence.
         
      upstream view This tag specifies the view of the upstream leaf part. This is not a required field.
      Path Info is specified as combination of Part Numbers, Part Views and Reference Designators delimited by a "/".
      Sample :
      <csvdownStreamPath>RootPartNumber/RootPartView/MRefDes1/Level1PartNumber/Level1PartView/MRefDes3/ Level2PartNumber/Level2PartView/MRefDes5</csvdownStreamPath>

      Supported API: true

      Parameters:
      nv - hashtable with the values from the xml data file
      cmd_line - hashtable with values from the command line
      return_objects - NOT USED
      Returns:
      true if the consumption link has been successfully created, false otherwise