Class JDFResource

java.lang.Object
org.apache.xerces.dom.NodeImpl
org.apache.xerces.dom.ChildNode
org.apache.xerces.dom.ParentNode
org.apache.xerces.dom.ElementImpl
org.apache.xerces.dom.ElementNSImpl
All Implemented Interfaces:
Serializable, Cloneable, IStreamWriter, Element, ElementTraversal, EventTarget, Node, NodeList, TypeInfo
Direct Known Subclasses:
JDFArtDeliveryType, JDFAutoAddress, JDFAutoAdhesiveBindingParams, JDFAutoand, JDFAutoApprovalParams, JDFAutoApprovalSuccess, JDFAutoAssembly, JDFAutoAssetListCreationParams, JDFAutoBendingParams, JDFAutoBinderySignature, JDFAutoBlockPreparationParams, JDFAutoBooleanEvaluation, JDFAutoBooleanState, JDFAutoBoxFoldingParams, JDFAutoBoxPackingParams, JDFAutoBufferParams, JDFAutoBundle, JDFAutoBundlingParams, JDFAutoByteMap, JDFAutoCaseMakingParams, JDFAutoCasingInParams, JDFAutoChannelBindingParams, JDFAutoCIELABMeasuringField, JDFAutoCoilBindingParams, JDFAutoCollectingParams, JDFAutoColor, JDFAutoColorantAlias, JDFAutoColorantControl, JDFAutoColorControlStrip, JDFAutoColorCorrectionParams, JDFAutoColorMeasurementConditions, JDFAutoColorPool, JDFAutoColorSpaceConversionParams, JDFAutoComChannel, JDFAutoCompany, JDFAutoComponent, JDFAutoContact, JDFAutoContactCopyParams, JDFAutoContentList, JDFAutoConventionalPrintingParams, JDFAutoCoverApplicationParams, JDFAutoCreasingParams, JDFAutoCustomerInfo, JDFAutoCutBlock, JDFAutoCutMark, JDFAutoCuttingParams, JDFAutoCylinderLayout, JDFAutoCylinderLayoutPreparationParams, JDFAutoDateTimeEvaluation, JDFAutoDateTimeState, JDFAutoDBMergeParams, JDFAutoDBRules, JDFAutoDBSchema, JDFAutoDBSelection, JDFAutoDeliveryParams, JDFAutoDensityMeasuringField, JDFAutoDevelopingParams, JDFAutoDevice, JDFAutoDieLayout, JDFAutoDieLayoutProductionParams, JDFAutoDigitalDeliveryParams, JDFAutoDigitalMedia, JDFAutoDigitalPrintingParams, JDFAutoDividingParams, JDFAutoDurationEvaluation, JDFAutoDurationState, JDFAutoElementColorParams, JDFAutoEmbossingParams, JDFAutoEmployee, JDFAutoEndSheetGluingParams, JDFAutoEnumerationEvaluation, JDFAutoEnumerationState, JDFAutoExposedMedia, JDFAutoExternalImpositionTemplate, JDFAutoFeedingParams, JDFAutoFileSpec, JDFAutoFoldingParams, JDFAutoFontParams, JDFAutoFontPolicy, JDFAutoFormatConversionParams, JDFAutoGangPreparationParams, JDFAutoGatheringParams, JDFAutoGlueApplication, JDFAutoGlueLine, JDFAutoGluingParams, JDFAutoHeadBandApplicationParams, JDFAutoHoleList, JDFAutoHoleMakingParams, JDFAutoIdentificationField, JDFAutoIDPrintingParams, JDFAutoImageCompressionParams, JDFAutoImageEnhancementParams, JDFAutoImageReplacementParams, JDFAutoImageSetterParams, JDFAutoInk, JDFAutoInkZoneCalculationParams, JDFAutoInkZoneProfile, JDFAutoInsertingParams, JDFAutoInsertSheet, JDFAutoIntegerEvaluation, JDFAutoIntegerState, JDFAutoIntentResource, JDFAutoInterpretedPDLData, JDFAutoInterpretingParams, JDFAutoIsPresentEvaluation, JDFAutoJacketingParams, JDFAutoLabelingParams, JDFAutoLaminatingParams, JDFAutoLayout, JDFAutoLayoutElement, JDFAutoLayoutElementProductionParams, JDFAutoLayoutPreparationParams, JDFAutoLayoutShift, JDFAutoLongitudinalRibbonOperationParams, JDFAutoManualLaborParams, JDFAutoMatrixEvaluation, JDFAutoMatrixState, JDFAutoMedia, JDFAutoMediaSource, JDFAutoMiscConsumable, JDFAutoNameEvaluation, JDFAutoNameState, JDFAutoNodeInfo, JDFAutonot, JDFAutoNumberEvaluation, JDFAutoNumberingParams, JDFAutoNumberState, JDFAutoor, JDFAutoOrderingParams, JDFAutoPackingParams, JDFAutoPageAssignParams, JDFAutoPageList, JDFAutoPallet, JDFAutoPalletizingParams, JDFAutoPDFPathEvaluation, JDFAutoPDFPathState, JDFAutoPDFToPSConversionParams, JDFAutoPDLCreationParams, JDFAutoPDLResourceAlias, JDFAutoPerforatingParams, JDFAutoPerson, JDFAutoPlaceHolderResource, JDFAutoPlasticCombBindingParams, JDFAutoPlateCopyParams, JDFAutoPreflightAnalysis, JDFAutoPreflightInventory, JDFAutoPreflightParams, JDFAutoPreflightProfile, JDFAutoPreflightReport, JDFAutoPreflightReportRulePool, JDFAutoPreview, JDFAutoPreviewGenerationParams, JDFAutoPrintCondition, JDFAutoPrintRollingParams, JDFAutoProductionPath, JDFAutoProofingParams, JDFAutoPSToPDFConversionParams, JDFAutoQualityControlParams, JDFAutoQualityControlResult, JDFAutoRasterReadingParams, JDFAutoRectangleEvaluation, JDFAutoRectangleState, JDFAutoRegisterMark, JDFAutoRegisterRibbon, JDFAutoRenderingParams, JDFAutoResourceDefinitionParams, JDFAutoRingBindingParams, JDFAutoRollStand, JDFAutoRunList, JDFAutoSaddleStitchingParams, JDFAutoScanParams, JDFAutoScavengerArea, JDFAutoScreeningParams, JDFAutoSeparationControlParams, JDFAutoShapeCuttingParams, JDFAutoShapeDef, JDFAutoShapeDefProductionParams, JDFAutoShapeElement, JDFAutoShapeEvaluation, JDFAutoShapeState, JDFAutoSheetOptimizingParams, JDFAutoShrinkingParams, JDFAutoSideSewingParams, JDFAutoSpinePreparationParams, JDFAutoSpineTapingParams, JDFAutoStackingParams, JDFAutoStaticBlockingParams, JDFAutoStitchingParams, JDFAutoStrap, JDFAutoStrappingParams, JDFAutoStringEvaluation, JDFAutoStringState, JDFAutoStripBindingParams, JDFAutoStrippingParams, JDFAutoTestRef, JDFAutoThreadSealingParams, JDFAutoThreadSewingParams, JDFAutoTile, JDFAutoTool, JDFAutoTransferCurve, JDFAutoTransferCurvePool, JDFAutoTransferFunctionControl, JDFAutoTrappingDetails, JDFAutoTrappingParams, JDFAutoTrapRegion, JDFAutoTrigger, JDFAutoTrimmingParams, JDFAutoUsageCounter, JDFAutoVarnishingParams, JDFAutoVerificationParams, JDFAutoWebInlineFinishingParams, JDFAutoWindingParams, JDFAutoWireCombBindingParams, JDFAutoWrappingParams, JDFAutoxor, JDFAutoXYPairEvaluation, JDFAutoXYPairState, JDFColorsResultsPool, JDFColorsUsed, JDFConstraintValue, JDFCover, JDFCoverColor, JDFDimensions, JDFDocumentResultsPool, JDFFileTypeResultsPool, JDFFontsResultsPool, JDFImagesResultsPool, JDFIntentResource, JDFJobSheet, JDFPages, JDFPagesResultsPool, JDFSealing, JDFVeloBinding, JDFWeight

public class JDFResource extends JDFElement
See Also:
  • Constructor Details

    • JDFResource

      public JDFResource(org.apache.xerces.dom.CoreDocumentImpl myOwnerDocument, String qualifiedName)
      Constructor for JDFResource
      Parameters:
      myOwnerDocument -
      qualifiedName -
    • JDFResource

      public JDFResource(org.apache.xerces.dom.CoreDocumentImpl myOwnerDocument, String myNamespaceURI, String qualifiedName)
      Constructor for JDFResource
      Parameters:
      myOwnerDocument -
      myNamespaceURI -
      qualifiedName -
    • JDFResource

      public JDFResource(org.apache.xerces.dom.CoreDocumentImpl myOwnerDocument, String myNamespaceURI, String qualifiedName, String myLocalName)
      Constructor for JDFResource
      Parameters:
      myOwnerDocument -
      myNamespaceURI -
      qualifiedName -
      myLocalName -
  • Method Details

    • getTheAttributeInfo

      protected AttributeInfo getTheAttributeInfo()
      Overrides:
      getTheAttributeInfo in class JDFElement
      Returns:
    • getTheElementInfo

      protected ElementInfo getTheElementInfo()
      Overrides:
      getTheElementInfo in class JDFElement
      Returns:
      the elementinfo
    • setAvailable

      @Deprecated public void setAvailable(boolean bAvailable)
      Deprecated.
      use SetStatus(EnumResStatus) default: setAvailable(true)
      Status related shorthand for really lazy people Sets Status of resource as Available if bAvailable=true or as Unavailable if bAvailable=false
      Parameters:
      bAvailable -
    • isAvailable

      @Deprecated public boolean isAvailable(boolean bRecurseRefs)
      Deprecated.
      use getStatus default: IsAvailable(false)
      Tests whether Status of resource is Available
      Parameters:
      bRecurseRefs - if bRecurseRefs is set to true, also recurses into all resources linked by rRefs and returns true if the minimum Status is Status_Available
      Returns:
      boolean true, if Status is Available
    • isRootElement

      public boolean isRootElement()
      Tests, whether 'this' is root of partition (i.e. there is no element with the same name over 'this')
      Returns:
      boolean true, if 'this' is a root
    • isQuantity

      public boolean isQuantity()
      Checks, whether this resourse is a quantity resource. For quantity resource the class of 'this' must be either Quantity or Consumable
      Returns:
      boolean true, if 'this' is a quantity resource
    • isParameter

      public boolean isParameter()
      Checks, whether this resourse is a parameter resource
      Returns:
      boolean true, if 'this' is a parameter resource
    • getLock

      @Deprecated public boolean getLock()
      Deprecated.
      [BLD009] use getLocked
      getLock
      Returns:
      boolean
    • lock

      @Deprecated public void lock(boolean bLock)
      Deprecated.
      [BLD009] use setLocked()
      Lock
      Parameters:
      bLock -
    • isPhysical

      public boolean isPhysical()
      Checks, whether the resource is one of the physical resource classes
      Returns:
      boolean true, if the resource is one of the physical resource classes
    • getResourceRoot

      public JDFResource getResourceRoot()
      Gets the root resource of 'this'
      Returns:
      JDFResource - the root resource element
      Throws:
      JDFException - if GetResourceRoot ran into the JDF node while searching
    • getResourceRoot

      public static JDFResource getResourceRoot(KElement elem)
      Gets the root resource of 'this'
      Parameters:
      elem - the element to get the root of
      Returns:
      JDFResource - the root resource element
      Throws:
      JDFException - if GetResourceRoot ran into the JDF node while searching
    • getPool

      @Deprecated public JDFResourcePool getPool()
      Deprecated.
      [BLD009] use GetResourcePool instead
      Gets the resourcepool that 'this' lives in
      Returns:
      JDFResourcePool: the ResourcePool where 'this' lives
    • init

      public boolean init()
      default initialization
      Overrides:
      init in class JDFElement
      Returns:
      boolean true, if successful
      See Also:
    • makeRootResource

      public JDFResource makeRootResource()
      Returns:
    • makeRootResource

      public JDFResource makeRootResource(String alias, JDFElement parentPool, boolean bLinkHere)
      Makes from 'this' resource subelement a root resource element (direct child) of the specified parentPool or (in default case) of ResourcePool, where it lives.
      The Status and SpawnStatus attribute values of the new root resource are taken from the old root resource.
      Parameters:
      alias - id attribute of the newly created resource
      parentPool - the pool where the newly created resource is stored
      if null the local pool is used. Must use JDFElement for the pool because of recursive #defines
      bLinkHere - if true, creates a refelement (link) to the newly created resource at the position where 'this' originally resided.
      Returns:
      JDFResource the moved resource
    • getCreator

      public VElement getCreator(boolean bCreate)
      Gets the creators (bCreate=true) or consumers (bCreate=false) of this resource
      Parameters:
      bCreate - switcher for getter: if true gets creators, otherwise gets consumers
      Returns:
      VElement list of JDF nodes that create or consume this resource
    • mergePartition

      @Deprecated public void mergePartition(JDFResource resToMerge, String spawnID, JDFResource.EnumAmountMerge amountPolicy, boolean bLocalResource)
      Deprecated.
      used only by merge - moved there
      Merges partitioned resources into this resource uses PartIDKey to identify the correct resources
      Parameters:
      resToMerge - the resource leaf to merge into this
      spawnID - the spawnID of the spawning that will now be merged
      amountPolicy - how to clean up the Resource amounts after merging
      bLocalResource - must be true for the local resources in a spawned node and its subnodes, which default to RW
      Throws:
      JDFException - if here is an attempt to merge incompatible resources
      JDFException - if here is an attempt to merge incompatible partitions
    • setPartIDKeys

      public void setPartIDKeys(VString partIDKeys)
      set the partIDKeys attribute of the root of this
      Parameters:
      partIDKeys - the value to set key to
    • setPartIDKeyList

      public void setPartIDKeyList(List<String> partIDKeys)
      Parameters:
      partIDKeys -
    • mergeCloneResource

      public JDFResource mergeCloneResource(JDFResource oldRes)
      Clone the resource element oldRes and merge it with this resource
      Parameters:
      oldRes - the resource element to clone and to merge with this resource
      Returns:
      JDFResource merged resource
    • getLinks

      @Deprecated public VElement getLinks(String linkName)
      Deprecated.
      [BLD009] use getLinks(linkName, null)
      Gets all elements with name linkName, which contain resource links that point to this resource
      Parameters:
      linkName - defaults to any
      Returns:
      VElement vector of all found elements
    • getLinks

      public VElement getLinks(String linkName, String nameSpaceURI)
      Gets all elements with name linkName, which contain id/idrefs that point to this resource
      Parameters:
      linkName - defaults to any
      nameSpaceURI - attribute namespace you are searching in
      Returns:
      VElement - vector of all found elements
    • getLinksAndRefs

      @Deprecated public VElement getLinksAndRefs()
      Deprecated.
      use getLinksAndRefs(true,true);
      Gets all resourcelinks and refelements that link to this
      Returns:
      VElement - vector of all found elements, null if none found
    • getLinksAndRefs

      public VElement getLinksAndRefs(boolean bLink, boolean bRef)
      Gets all resourcelinks and refelements that link to this
      note that this method may be tim consuming in a large loop
      - in case of massive cleanup, use LinkRefFinder and access the complete map of references from within the loop @see LinkRefFinder
      Parameters:
      bLink - if true, include resource links
      bRef - if true include resource refs
      Returns:
      VElement - vector of all found elements, null if none found
    • isResourceElement

      public boolean isResourceElement()
      Tests, if the first ancestor with a name different from the node name is not one of DropItemIntent,CustomerInfo,NodeInfo,ResourcePool,PipeParams, ResourceInfo,ResourceCmdParams.
      In other words: if this resource is a subelement, but not a resourceroot
      Returns:
      boolean true, if this is a subelement but not a root
    • getPartition

      @Deprecated public JDFResource getPartition(JDFAttributeMap m, boolean bIncomplete)
      Deprecated.
      use getPartition(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets the first part that matches mAttribute
      Parameters:
      m - the map of key-value partitions (where key - PartIDKey, value - its value)
      bIncomplete - if true, also accept nodes that are are not completely specified in the partmap,
      e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      JDFResource - the first matching resource leaf or node
    • getPartition

      public JDFResource getPartition(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets the first part that matches mAttribute
      Parameters:
      m - the map of key-value partitions (where key - PartIDKey, value - its value)
      partUsage - also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      JDFResource: the first matching resource leaf or node
    • getPartitionMap

      public HashMap<JDFAttributeMap,JDFResource> getPartitionMap()
      Returns:
    • getPartition

      @Deprecated public JDFResource getPartition(JDFResource.EnumPartIDKey key, String value, boolean bIncomplete)
      Deprecated.
      use getPartition(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets the first part that matches key-value pair
      Parameters:
      key - the PartIDKey attribute name
      value - the string value of the partition key
      bIncomplete - if true, also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      JDFResource the first matching resource leaf or node
    • clonePartitions

      public void clonePartitions(JDFResource r, VString partIDKeys)
      applies the partitioning of r to this.
      Ideally called only for unpartitioned resources, but will work on consistently partitioned resources
      Parameters:
      r - the resource from which to clone the partitioning
      partIDKeys - the partIDKeys to clone, if null use the existing list from r
      Throws:
      JDFException - if this is already inconsistently partitioned
    • reorderPartitions

      public void reorderPartitions(List<String> newPartIDKeys)
      Parameters:
      newPartIDKeys -
    • fillSparse

      public void fillSparse()
    • getCreatePartition

      public JDFResource getCreatePartition(JDFAttributeMap partMap, VString vPartKeys)
      Recursively adds the partition leaves defined in partMap
      Parameters:
      partMap - the map of part keys
      vPartKeys - the vector of partIDKeys strings of the resource. If empty (the default), the Resource PartIDKeys attribute is used
      Returns:
      JDFResource the last created partition leaf
      Throws:
      JDFException - if there are in the partMap not matching partitions
      JDFException - if there is an attempt to fill non-matching partIDKeys
      JDFException - if by adding of last partition key there is either non-continuous partmap or left more than one key
    • getCreatePartition

      public JDFResource getCreatePartition(JDFResource.EnumPartIDKey key, String value, VString vPartIDKeys)
      Gets the first part that matches key-value if it does not exist, create it
      Parameters:
      key - the PartIDKey attribute name
      value - the string value of the partition key
      vPartIDKeys - the vector of partIDKeys strings of the resource.
      Returns:
      JDFResource the matching resource
    • consistentPartIDKeys

      protected boolean consistentPartIDKeys(JDFResource.EnumPartIDKey key, JDFResource root, VString partIDKeys)
      Tests, if this leaf has a consistent PartIDKey as specified by key
      Parameters:
      key - the PartIDKey attribute name
      root -
      partIDKeys -
      Returns:
      boolean true, if key exists in this leaf is in PartIDKeys
    • consistentPartIDKeys

      public boolean consistentPartIDKeys(JDFResource.EnumPartIDKey key)
      Tests, if this leaf has a consistent PartIDKey as specified by key
      Parameters:
      key - the PartIDKey attribute name
      Returns:
      boolean true, if key exists in this leaf is in PartIDKeys
    • getDeepPart

      @Deprecated public JDFResource getDeepPart(JDFAttributeMap m, boolean bIncomplete)
      Deprecated.
      use the partUsage dependent version instead
      Gets a matching part from somewhere down there returns the closest ancestor of all matching elements within the target vector
      Parameters:
      m -
      bIncomplete -
      Returns:
      JDFResource
    • getDeepPart

      public JDFResource getDeepPart(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets a matching part from somewhere down there,
      returns the closest ancestor of all matching elements within the target vector
      Parameters:
      m - map of attributes that should fit
      partUsage - also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      the first found matching resource node or leaf
    • getLeaves

      public VElement getLeaves(boolean bAll)
      Gets a list of all direct leaves
      Parameters:
      bAll - if true include all intermediate and leaf nodes including this
      if false, include only the final leaves
      Returns:
      VElement - the vector of all leaves - never null
    • getLeafArray

      public List<JDFResource> getLeafArray(boolean bAll)
      Gets a list of all direct leaves
      Parameters:
      bAll - if true include all intermediate and leaf nodes including this
      if false, include only the final leaves
      Returns:
      VElement - the vector of all leaves - never null
    • getDirectPartitionVector

      public Vector<? extends KElement> getDirectPartitionVector()
      Returns:
    • getDirectPartitionArray

      public List<? extends KElement> getDirectPartitionArray()
      Returns:
    • getDirectPartition

      public JDFResource getDirectPartition(int i)
      Returns:
    • isLeaf

      public boolean isLeaf()
      Tests, whether 'this' is the end of a partition (i.e. there is no element with the same name directly below)
      Returns:
      boolean true, if 'this' is a leaf
    • getPartValues

      public VString getPartValues(JDFResource.EnumPartIDKey partType)
      Gets a list of the values for attribute part type within the leaves
      Parameters:
      partType - the PartIDKey attribute name
      Returns:
      Vector - a list of values of the specified partition key
    • getAttribute

      public String getAttribute(String attrib, String nameSpaceURI, String def)
      Gets an attribute value. Also follows partition parents to the resource root
      Overrides:
      getAttribute in class KElement
      Parameters:
      attrib - attribute name to get
      nameSpaceURI - namespace to search for
      def - attribute default that is returned if no attribute exists
      Returns:
      WString - attribute value
    • getChildrenByClass

      @Deprecated public <a extends KElement> Vector<a> getChildrenByClass(Class<a> clazz, boolean bRecurse, int nMax)
      Deprecated.
      use getChildArrayByClass
      Overrides:
      getChildrenByClass in class KElement
      Parameters:
      clazz -
      bRecurse -
      nMax -
      Returns:
    • getChildArrayByClass

      public <a extends KElement> List<a> getChildArrayByClass(Class<a> clazz, boolean bRecurse, int nMax)
      Description copied from class: KElement
      Get all children from the actual element matching the given conditions
      does NOT get refElement targets although the attributes are checked in the target elements in case of refElements never null
      Overrides:
      getChildArrayByClass in class KElement
      bRecurse - if true recurse through all children, grandchildren etc.
      nMax - maximum number to search - if 0 or negative, search all
      Returns:
      Vector vector with all found elements, never null
      See Also:
    • getChildWithAttribute

      public <A extends KElement> A getChildWithAttribute(Class<A> clazz, String attName, String attVal)
      Overrides:
      getChildWithAttribute in class KElement
    • getAttributeMap

      public JDFAttributeMap getAttributeMap()
      Get the Attribute Map of the actual element also following inheritance
      Overrides:
      getAttributeMap in class KElement
      Returns:
      JDFAttributeMap the attribute map of the actual element
    • hasAttribute

      public boolean hasAttribute(String attrib, String nameSpaceURI, boolean bInherit)
      Checks if the actual element has a specific attribute
      this version checks within the resource and its partitioned parent xml elements
      Overrides:
      hasAttribute in class KElement
      Parameters:
      attrib - the name of the attribute to look for
      nameSpaceURI - the nameSpace to look in
      bInherit - if true also check recursively in parent elements, regardless of partitioning
      Returns:
      boolean true, if the attribute is present
    • numChildElements

      public int numChildElements(String nodeName, String nameSpaceURI)
      The same as JDFElement.numChildElements but also follows References
      Overrides:
      numChildElements in class JDFElement
      Parameters:
      nodeName - the nodes to count
      nameSpaceURI - the nameSpace to look in
      Returns:
      int - the number of child elements
    • getCreateElement_JDFResource

      public KElement getCreateElement_JDFResource(String nodeName, String nameSpaceURI, int iSkip)
      Recursive GetElement that also checks parent nodes up to the part root this was added in order to implement the c++ JDFResource::GetCreateElement
      Parameters:
      nodeName - name of the child node to get
      nameSpaceURI - namespace to search for
      iSkip - get the iSkipth element that fits
      Returns:
      KElement - the matching element
    • getElement

      public KElement getElement(String nodeName, String nameSpaceURI, int iSkip)
      same as KElement.getElement, but also follows references and searches parents
      Overrides:
      getElement in class JDFElement
      Parameters:
      nodeName - name of the child node to get
      nameSpaceURI - namespace to search for
      iSkip - get the iSkipth element that fits
      Returns:
      KElement: the matching element default: getElement(nodeName, null, 0)
      See Also:
    • addPartitions

      public VElement addPartitions(JDFResource.EnumPartIDKey partType, VString values)
      Creates parts of part type 'partType' with values as defined in 'values'; the number of values is defined by the number of elements in 'values'
      Parameters:
      partType - part type of a new part
      values - its value
      Returns:
      VElement - vector of newly created parts
    • addPartition

      public JDFResource addPartition(JDFResource.EnumPartIDKey partType, org.apache.commons.lang.enums.ValuedEnum enumPart)
      Adds a new part to this node, also handles PartIDKeys in the root etc. convenience method to allow for partIDKey enums rather than strings
      Parameters:
      partType - part type of a new part
      enumPart - its value
      Returns:
      JDFResource - the newly created part
    • addPartition

      public JDFResource addPartition(JDFResource.EnumPartIDKey partType, String value)
      Adds a new part to this node, also handles PartIDKeys in the root etc.
      Parameters:
      partType - part type of a new part
      value - its value
      Returns:
      JDFResource - the newly created part
    • getAttributeVector

      public VString getAttributeVector()
      Gets all local attribute names as an vector of strings.
      Is called from KElement.getMissingAttributeVector() as a virtual method
      Overrides:
      getAttributeVector in class KElement
      Returns:
      VString - the vector of attribute names
    • getAttributeVector_JDFResource

      public VString getAttributeVector_JDFResource()
      Gets all local attribute names as an vector of strings
      Returns:
      VString the vector of attribute names
    • getAttributePart

      public JDFResource getAttributePart(String key)
      Gets the parent element that actually contains the attribute key in a partitioned resource
      Parameters:
      key - attribute key to look for
      Returns:
      JDFResource - the parent element that actually contains the attribute key
    • getAttributePartVector

      public VElement getAttributePartVector(String key)
      Gets a unique vector of resource leaf elements that actually contain the attribute key
      Parameters:
      key - attribute key to look for
      Returns:
      VElement a vector of resource leaf elements that actually contain the attribute key
    • buildXPath

      public String buildXPath(String relativeTo, int methCountSiblings)
      Gets the XPath full tree representation of 'this'
      Overrides:
      buildXPath in class KElement
      Parameters:
      relativeTo - relative path to which to create an xpath
      methCountSiblings - , if 1 count siblings, i.e. add '[n]' if 0, only specify the path of parents
      Returns:
      String the XPath representation of 'this' e.g. /root/parent/element
      null if parent of this is null (e.g. called on rootnode)
    • getLocalPartitionKey

      public String getLocalPartitionKey()
      get the local partition key of this leaf
      Returns:
      the key, if one exists, null otherwise
    • cleanResourceAttributes

      public void cleanResourceAttributes()
      remove any resource specific attribute when making this to an element
    • removeInheritedAttributes

      public void removeInheritedAttributes(String attrib, String nameSpaceURI)
      Removes all local and inherited attributes down to the resource root
      Parameters:
      attrib - the attribute key to remove
      nameSpaceURI - the attribute nameSpaceURI to remove
    • removeAttribute

      public void removeAttribute(String attrib, String nameSpaceURI)
      Removes local attributes
      Overrides:
      removeAttribute in class KElement
      Parameters:
      attrib - the attribute key to remove
      nameSpaceURI - the attribute nameSpaceURI to remove
    • removeAttributeFromLeaves

      public void removeAttributeFromLeaves(String attrib, String nameSpaceURI)
      Removes attributes, also removes overwrites in any child parts
      Parameters:
      attrib - the attribute key to remove
      nameSpaceURI - the attribute nameSpaceURI to remove
    • reducePartitions

      public void reducePartitions(VJDFAttributeMap vValidParts)
      Reduces partition so that only the parts that overlap with vResources remain
      Parameters:
      vValidParts - vector of partmaps that define the individual valid parts.
      The individual PartMaps are ored to define the final resource.
    • clearPartitions

      public void clearPartitions()
      make sure we don't have any old crap
    • reduceParts

      @Deprecated public void reduceParts(Vector vParts)
      Deprecated.
      [BLD009] not in C++ anymore, not used internally here
      reduceParts
      Parameters:
      vParts -
    • getPartMap

      public JDFAttributeMap getPartMap(List<String> partIDKeys)
      Gets a map of all partition key-value pairs for this leaf / node. This includes a recursion to the part root.
      Parameters:
      partIDKeys -
      Returns:
      the part attribute map for 'this' leaf / node - reused for performance enhancement; never null
    • getPartMap

      public JDFAttributeMap getPartMap()
      Gets a map of all partition key-value pairs for this leaf / node this includes a recursion to the part root; never null
      Overrides:
      getPartMap in class JDFElement
      Returns:
      JDFAttributeMap - the part attribute map for 'this' leaf / node
    • getLinkString

      public String getLinkString()
      Gets nodename of a ResourceLink that links to 'this'
      Returns:
      String - name of a link to 'this'
    • mergeSpawnIDs

      @Deprecated public void mergeSpawnIDs(JDFResource resToMerge, VString previousMergeIDs)
      Deprecated.
      use JDFMerge.mergeSpawnIDS
      Merges the spawnIDs of the various partitions
      also updates SpawnStatus, if necessary
      this routine is needed to correctly handle nested spawning and merging
      Parameters:
      resToMerge - the resource with potentially new spawnIDs
      previousMergeIDs - vector of already merged spawnIDs that may still be in a partition
    • expand

      public void expand(boolean bDeleteFromNode)
      Expand so that each leaf is complete (except for ID)
      Parameters:
      bDeleteFromNode - if true, removes all intermediate elements and attributes
    • expandLeaf

      public void expandLeaf()
      expand a leaf to contain the data of all intermediate leaves
    • getRootPartAtts

      public VString getRootPartAtts()
      get the list of attributes that are administrative only
      Returns:
      the VString that lists all adminstrative and partition keys
    • collapse

      @Deprecated public void collapse(boolean bCollapseToNode)
      Deprecated.
      - use 2 parameter version
      collapse all redundant attributes and elements
      Parameters:
      bCollapseToNode - only collapse redundant attriutes and elements that pre-exist in the nodes
    • collapse

      public void collapse(boolean bCollapseToNode, boolean bCollapseElements)
      collapse all redundant attributes and elements
      Parameters:
      bCollapseToNode - only collapse redundant attributes and elements that pre-exist in the nodes
      bCollapseElements - if true, collapse elements, else only collapse attributes
    • unpartition

      public boolean unpartition(boolean bForce)
      unpartition this resource by collapsing and removing any empty leaves
      Parameters:
      bForce - if true force collapse by removing non-identical elements
      Returns:
      true if successfully unpartitioned
    • spawnPart

      @Deprecated public void spawnPart(String spawnID, JDFResource.EnumSpawnStatus spawnStatus, VJDFAttributeMap vParts, boolean bStayInMain)
      Deprecated.
      use JDFSpawn.spawnPart
      Spawns a given partition for a given SpawnID
      Parameters:
      spawnID - the SpawnID that it was spawned with
      spawnStatus - SpawnStatus to spawn this resource with
      vParts - vector of partitions that it was spawned with
      bStayInMain - if true, the function is applied to the main JDF, else to the spawned JDF
    • unSpawnPart

      public void unSpawnPart(String spawnID, JDFResource.EnumSpawnStatus spawnStatus)
      Find the appropriate partition for a given SpawnID and undo the spawn procedure
      Parameters:
      spawnID - the SpawnID that it was spawned with
      spawnStatus - SpawnStatus this resource was spawned with
    • getNodesWithSpawnID

      public List<JDFResource> getNodesWithSpawnID(String spawnID)
      Gets of 'this' all leaves and intermediate nodes that have an explicit spawnID set
      Parameters:
      spawnID - the spawnID to look for
      Returns:
      VElement - the vector of nodes or leaves of 'this' that contain spawnID
    • getPartitionVector

      @Deprecated public VElement getPartitionVector(JDFAttributeMap m, boolean bIncomplete)
      Deprecated.
      use getPartitionVector(JDFAttributeMap m, EnumPartUsage partUsage)
      Gets the vector of parts (resource leaves or nodes) that match mAttribute
      Parameters:
      m - the map of key-value partitions (where key - PartIDKey, value - its value)
      bIncomplete - if true, also accept nodes that are are not completely specified in the partmap,
      e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      VElement - the vector of matching resource leaves or nodes
    • getPartitionVector

      public VElement getPartitionVector(VJDFAttributeMap vm, JDFResource.EnumPartUsage partUsage)
      Gets the vector of parts (resource leaves or nodes) that match mAttribute
      Parameters:
      vm - the map of key-value partitions (where key - PartIDKey, value - its value)
      partUsage - also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      VElement - the vector of matching resource leaves or nodes
    • getPartitionLeafVector

      public VElement getPartitionLeafVector(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets the vector of parts (resource leaves or nodes) that match mAttribute
      Parameters:
      m - the map of key-value partitions (where key - PartIDKey, value - its value)
      partUsage - also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      VElement - the vector of matching resource leaves or nodes
    • getPartitionVector

      public VElement getPartitionVector(JDFAttributeMap m, JDFResource.EnumPartUsage partUsage)
      Gets the vector of parts (resource leaves or nodes) that match mAttribute
      Parameters:
      m - the map of key-value partitions (where key - PartIDKey, value - its value)
      partUsage - also accept nodes that are are not completely specified in the partmap, e.g. if partitioned by run, RunPage and only Run is specified
      Returns:
      VElement - the vector of matching resource leaves or nodes
    • getPartitionVector

      @Deprecated public VElement getPartitionVector(JDFResource.EnumPartIDKey key, String value, boolean bIncomplete)
      Deprecated.
      use getPartitionVector(JDFAttributeMap m, EnumPartUsage partUsage)
      Gets the vector of parts that matches specified key-value pair
      Parameters:
      key - the PartIDKey attribute name
      value - the string value of the partition key
      bIncomplete -
      Returns:
      VElement - the vector matching resource leaves or nodes
    • getIDPrefix

      protected String getIDPrefix()
      gets a prefix for ID creation for the element
      Overrides:
      getIDPrefix in class KElement
      Returns:
      String - a prefix for ID creation
    • getPartMapVector

      public VJDFAttributeMap getPartMapVector(boolean bIntermediate)
      Gets a vector of maps of all partition attribute key-value pairs for this node and all its children
      Parameters:
      bIntermediate - if true also includes intermediate nodes including this
      Returns:
      VJDFAttributeMap - the vector of partition attribute maps for this leaf / node and all its children
    • reducePartVector

      public VJDFAttributeMap reducePartVector(VJDFAttributeMap vParts)
      Finds the canonical vector of parts that defines the vector of parts that fits to vParts. If all children of a parent node are in vParts, they are replaced by their parent.
      for example the canonical vector of all leaves is the root
      Parameters:
      vParts - the vector of parts to check against 'this'
      Returns:
      VJDFAttributeMap the canonical vector
    • newModifiedID

      public String newModifiedID()
      Generates the id of a modified resource
      Returns:
      String the new id
      Throws:
      JDFException - if there are too many equivalent modified resources
    • getResourcePool

      public JDFResourcePool getResourcePool()
      Gets the resourcepool that 'this' lives in
      Returns:
      JDFResourcePool the ResourcePool where 'this' lives
    • isResourceRoot

      public boolean isResourceRoot()
      Tests, whether the first ancestor of 'this' is in ValidParentNodeNames - must be one of: DropItemIntent,CustomerInfo,NodeInfo,ResourcePool,PipeParams ,ResourceInfo,ResourceCmdParams
      Returns:
      boolean true, if 'this' is a root resource
    • isResourceRootRoot

      public boolean isResourceRootRoot()
      Tests, whether the first ancestor of 'this' is in validRootParentNodeNames()
      must be one of: ResourcePool,PipeParams,ResourceInfo,ResourceCmdParams
      Returns:
      boolean - true if this lives as a root resource in the ResourcePool
    • updateAttributeFromLeaves

      public String updateAttributeFromLeaves(String attName, String nsURI, boolean bDirect)
      update vattribute value to the value of the attribute in the leaves
      Parameters:
      attName -
      nsURI -
      bDirect -
      Returns:
      the updated value, null in case they were not identical
    • updateAmounts

      public void updateAmounts(boolean keepPrevious)
      update the amount of a resource based on the connected resource links Only Condition="Good" is counted if no explicit partioning by condition is specified
      Parameters:
      keepPrevious - if true, the previous amounts etc. are retained, if false they are completely recalculated from the linkx
      Since:
      2011.1.15 note the change of interface. The prior usage of previousamount was inheritently flawed. Update note: if you used a previousAmount!=0, you probably want to use keepPrevious=false whereas a 0 value retains the orignal value (leepPrevious=true)
    • getChildElementVector

      public VElement getChildElementVector(String element, String nameSpaceURI, JDFAttributeMap mAttrib, boolean bAnd, int maxSize, boolean bResolveTarget)
      Gets all children from the actual element matching the given conditions also get the non-overwritten elements in the parents for partitioned resources
      Overrides:
      getChildElementVector in class JDFElement
      Parameters:
      element - elementname you are searching for
      nameSpaceURI - nameSpace you are searching for
      mAttrib - attributes you are lokking for
      bAnd - if true, a child is only added if it has all attributes specified in Attributes mAttrib
      maxSize - maximum size of the element vector
      bResolveTarget - if true, IDRef elements are followed, dummy at this level but needed in JDFElement
      Returns:
      VElement - vector with all found elements
      See Also:
    • getImplicitPartitions

      public Vector<JDFResource.EnumPartIDKey> getImplicitPartitions()
      Gets a list of all partition keys that this resource may be implicitly partitioned by, e.g. RunIndex for RunList...
      gets overridden in subclasses
      Returns:
      Vector of EnumPartIDKey
    • isPartitioningCompatible

      public boolean isPartitioningCompatible(JDFResource other)
      Tests if the given resources are compatible regarding their partitioning. The resources are compatible if the PartIDKeys for the common start sequence of the PartIDKeys vectors are the same. The resources are not compatible if one has PartIDKeys and the other not.
      Parameters:
      other - the other resource to check.
      Returns:
      boolean - true if partitioning of the other resource is compatible with this resource.
    • isPartitioningCompatible

      public boolean isPartitioningCompatible(VString vsPartitions)
      Tests if the resource is compatible with the given partition keys. The resource is compatible if all PartIDKeys in vsPartitions are contained in this, regardless of sequence The resource is not compatible if one has PartIDKeys and the other not.
      Parameters:
      vsPartitions - the given partition keys to compare
      Returns:
      boolean - true if partitioning is compatible with this resource.
    • isSpawnAllowed

      public boolean isSpawnAllowed()
      Tests if a spawn of the given partition of the resource is allowed (by means of the JDF specification).
      Returns:
      boolean - true if spawn is allowed.
    • getCreateContact

      public JDFContact getCreateContact()
      Gets of 'this' child Contact element, optionally creates it, if it doesn't exist.
      Returns:
      JDFContact - the matching Contact element
    • getContact

      public JDFContact getContact()
      Gets of 'this' an existing child Contact element
      Returns:
      JDFContact the matching Contact element
    • appendContact

      public JDFContact appendContact()
      Appends new Contact element to the end of 'this'
      Returns:
      JDFContact - newly created child Contact element
    • getCreateLocationElement

      public JDFLocation getCreateLocationElement()
      Gets of 'this' child Location element, optionally creates it, if it doesn't exist.
      Returns:
      JDFLocation - the matching Location element
    • getLocationElement

      public JDFLocation getLocationElement()
      Gets of 'this' an existing child Location element
      Returns:
      JDFLocation - element Location
    • appendLocationElement

      public JDFLocation appendLocationElement()
      Appends new child Location element to the end of 'this'
      Returns:
      JDFLocation - newly created child Location element
    • createSourceResource

      public JDFSourceResource createSourceResource(JDFResource source)
      create a sourceresource element that pints to source
      Parameters:
      source - the resource to reference
      Returns:
      JDFSourceResource - the element
    • appendSourceResource

      public JDFSourceResource appendSourceResource()
      appends a new SourceResource element
      Returns:
      JDFSourceResource - the new sourceresource
    • getSourceResource

      public JDFSourceResource getSourceResource(int i)
      gets an existing SourceResource element
      Parameters:
      i - the i'th sourceResource to get, 0=first etc.
      Returns:
      JDFSourceResource - the sourceresource
    • getCreateIdentificationField

      public JDFIdentificationField getCreateIdentificationField(int iSkip)
      Gets of 'this' the iSkip-th IdentificationField element, optionally creates it, if it doesn't exist. If iSkip is more than one larger than the number of elements, only one will be created and appended.
      Parameters:
      iSkip - number of child IdentificationField elements to skip
      Returns:
      JDFIdentificationField - the matching IdentificationField element default: getIdentificationField(0)
    • getIdentificationField

      public JDFIdentificationField getIdentificationField(int iSkip)
      Gets of 'this' the iSkip-th child IdentificationField element
      Parameters:
      iSkip - number of child IdentificationField elements to skip, default=0
      Returns:
      JDFIdentificationField - the matching IdentificationField element
    • appendIdentificationField

      public JDFIdentificationField appendIdentificationField()
      Appends new child IdentificationField element to the end of 'this'
      Returns:
      JDFIdentificationField - newly created child IdentificationField element
    • getIdenticalMap

      public JDFAttributeMap getIdenticalMap()
      return the PartMap of ./Identical/Part, or null if it does not exist
      Returns:
      JDFAttributeMapthe - map of the part in the identical element
    • getIdentical

      public JDFIdentical getIdentical()
      get the identical element,
      Returns:
      JDFIdentical - the identical element, null if noen exists
    • getIdenticalTarget

      public JDFResource getIdenticalTarget()
      get the target of the identical element, this if no identical exists
      Returns:
      JDFResource - the resource referenced by the identical element, this resource if no identical exists
    • getCreateIdentical

      public JDFIdentical getCreateIdentical()
      get or create the identical element,
      Returns:
      JDFIdentical - the identical element
    • appendIdentical

      public JDFIdentical appendIdentical()
      append an identical element,
      Returns:
      JDFIdentical - the identical element
      Throws:
      JDFException - if an Identical already exists
    • setIdentical

      public void setIdentical(VJDFAttributeMap vPartMap)
      Sets the 1st-nth element as identical to the 0th elemennt ov vPartMap i.e. the partition leaves that match vPartMap[1]...vPartMap[size-1] are set identical to vPartMap[0]
      Parameters:
      vPartMap - VJDFAttributeMap to correspond to
    • setIdentical

      public void setIdentical(JDFResource target)
      Appends new child Identifical element that refers to target also removes all subelements and attributes If an identical already exists, the part element is overwritten
      Parameters:
      target - the resource leaf that this leaf should reference as identical
    • getCreateQualityControlResult

      public JDFQualityControlResult getCreateQualityControlResult(int iSkip)
      Gets of 'this' the iSkip-th QualityControlResult element, optionally creates it, if it doesn't exist. If iSkip is more than one larger that the number of elements, only one will be created and appended.
      Parameters:
      iSkip - number of child QualityControlResult elements to skip
      Returns:
      JDFQualityControlResult - the matching QualityControlResult element
    • getQualityControlResult

      public JDFQualityControlResult getQualityControlResult(int iSkip)
      Gets of 'this' the iSkip-th child QualityControlResult element
      Parameters:
      iSkip - number of child QualityControlResult elements to skip, default=0
      Returns:
      JDFQualityControlResult the matching QualityControlResult element
    • appendQualityControlResult

      public JDFQualityControlResult appendQualityControlResult()
      Appends new child QualityControlResult element to the end of 'this'
      Returns:
      JDFQualityControlResult - newly created child QualityControlResult element
    • getUpdate

      @Deprecated public JDFResource getUpdate(int iSkip)
      Deprecated.
      updates never really took off in JDF
      Gets of 'this' the iSkip-th child Update element
      Parameters:
      iSkip - number of child Update elements to skip
      Returns:
      JDFResource the matching Resource Update element
    • getUpdate

      @Deprecated public JDFResource getUpdate(String updateID)
      Deprecated.
      updates never really took off in JDF
      Gets of 'this' child Update element with an appropriate UpdateID
      Parameters:
      updateID - UpdateID of the element to get
      Returns:
      JDFResource the matching Update element
    • getUpdateVector

      @Deprecated public VElement getUpdateVector()
      Deprecated.
      updates never really took off in JDF
      Gets of 'this' a vector of all Update elements
      Returns:
      VElement vector of all Resource Update elements in 'this'
    • removeUpdate

      @Deprecated public void removeUpdate(String updateID)
      Deprecated.
      updates never really took off in JDF
      Removes of 'this' child Update element with an appropriate UpdateID
      Parameters:
      updateID - UpdateID of the element to remove
    • removeUpdate

      @Deprecated public void removeUpdate(int iSkip)
      Deprecated.
      updates never really took off in JDF
      Removes of 'this' the iSkip-th child Update element
      Parameters:
      iSkip - number of child Update elements to skip
    • appendUpdate

      @Deprecated public JDFResource appendUpdate(String updateID)
      Deprecated.
      updates never really took off in JDF
      Appends to 'this' a resource Update element with an appropriate UpdateID
      Parameters:
      updateID - updateID of the new Update element
      Returns:
      JDFResource newly created Resource Update element
      Throws:
      JDFException - if Update element with such ID already exists
    • numUpdates

      @Deprecated public int numUpdates()
      Deprecated.
      updates never really took off in JDF
      Gets of 'this' the number of child Update elements
      Returns:
      int - number of Update elements in 'this'
    • hasUpdate

      @Deprecated public boolean hasUpdate()
      Deprecated.
      updates never really took off in JDF
      Tests, whether in 'this' any child Update elements already exist
      Returns:
      boolean - true, if 'this' has already one or more Update elements
    • getUpdateName

      @Deprecated public String getUpdateName()
      Deprecated.
      updates never really took off in JDF
      Gets the qualified node name of resource Update based on 'this'
      Returns:
      String - the mangled node name
    • setAgentName

      public void setAgentName(String value)
      Sets attribute AgentName
      Parameters:
      value - the value to set the attribute to
    • getAgentName

      public String getAgentName()
      Gets string attribute AgentName
      Returns:
      String - the attribute value
    • setAgentVersion

      public void setAgentVersion(String value)
      Sets attribute AgentVersion
      Parameters:
      value - the value to set the attribute to
    • getAgentVersion

      public String getAgentVersion()
      Gets string attribute AgentVersion
      Returns:
      String the - attribute value
    • setAlternateBrand

      public void setAlternateBrand(String value)
      Sets attribute AlternateBrand
      Parameters:
      value - value to set the attribute to
    • getAlternateBrand

      public String getAlternateBrand()
      Gets string attribute AlternateBrand
      Returns:
      String - the attribute value
    • setAmount

      public void setAmount(double amount)
      Sets attribute Amount
      Parameters:
      amount - value to set the attribute to
    • getAmount

      public double getAmount()
      Gets double attribute Amount
      Returns:
      double - the attribute value
    • setAmountProduced

      public void setAmountProduced(double value)
      Sets attribute AmountProduced
      Parameters:
      value - value to set the attribute to
    • getAmountProduced

      public double getAmountProduced()
      Gets double attribute AmountProduced
      Returns:
      double - the attribute value
    • setAmountRequired

      public void setAmountRequired(double value)
      Sets attribute AmountRequired
      Parameters:
      value - value to set the attribute to
    • getAmountRequired

      public double getAmountRequired()
      Gets double attribute AmountRequired
      Returns:
      double - the attribute value
    • setAuthor

      public void setAuthor(String value)
      Sets attribute Author
      Parameters:
      value - the value to set the attribute to
    • getAuthor

      public String getAuthor()
      Gets string attribute Author
      Returns:
      String - the attribute value
    • setBatchID

      public void setBatchID(String value)
      Sets attribute BatchID
      Parameters:
      value - value to set the attribute to
    • getBatchID

      public String getBatchID()
      Gets string attribute BatchID
      Returns:
      String - the attribute value
    • setBinderySignatureName

      public void setBinderySignatureName(String value)
      Sets attribute BinderySignatureName
      Parameters:
      value - the value to set the attribute to
    • getBinderySignatureName

      public String getBinderySignatureName()
      Gets string attribute BinderySignatureName
      Returns:
      String - the attribute value
    • setBlockName

      public void setBlockName(String value)
      Sets attribute BlockName
      Parameters:
      value - the value to set the attribute to
    • getBlockName

      public String getBlockName()
      Gets string attribute BlockName
      Returns:
      String - the attribute value
    • setBrand

      public void setBrand(String value)
      Sets attribute Brand
      Parameters:
      value - value to set the attribute to
    • getBrand

      public String getBrand()
      Gets string attribute Brand
      Returns:
      String - the attribute value
    • setUnit

      public void setUnit(JDFElement.eUnit unit)
    • getUnitEnum

      public JDFElement.eUnit getUnitEnum()
      Returns:
    • setBundleItemIndex

      public void setBundleItemIndex(JDFIntegerRangeList value)
      Sets attribute BundleItemIndex
      Parameters:
      value - the value to set the attribute to
    • getBundleItemIndex

      public JDFIntegerRangeList getBundleItemIndex()
      Gets range attribute BundleItemIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setCatalogDetails

      public void setCatalogDetails(String value)
      Sets attribute CatalogDetails
      Parameters:
      value - the value to set the attribute to
    • getCatalogDetails

      public String getCatalogDetails()
      Gets string attribute CatalogDetails
      Returns:
      String - the attribute value
    • setCatalogID

      public void setCatalogID(String value)
      Sets attribute CatalogID
      Parameters:
      value - the value to set the attribute to
    • getCatalogID

      public String getCatalogID()
      Gets string attribute CatalogID
      Returns:
      String - the attribute value
    • setCellIndex

      public void setCellIndex(JDFIntegerRangeList value)
      Sets attribute CellIndex
      Parameters:
      value - the value to set the attribute to
    • getCellIndex

      public JDFIntegerRangeList getCellIndex()
      Gets range attribute CellIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setCondition

      public void setCondition(String value)
      Sets attribute Condition
      Parameters:
      value - the value to set the attribute to
    • getCondition

      public String getCondition()
      Gets string attribute Condition
      Returns:
      String - the attribute value
    • setDocCopies

      public void setDocCopies(JDFIntegerRangeList value)
      Sets attribute DocCopies
      Parameters:
      value - the value to set the attribute to
    • getDocCopies

      public JDFIntegerRangeList getDocCopies()
      Gets range attribute DocCopies
      Returns:
      JDFIntegerRangeList the attribute value
    • setDocIndex

      public void setDocIndex(JDFIntegerRangeList value)
      Sets attribute DocIndex
      Parameters:
      value - the value to set the attribute to
    • getDocIndex

      public JDFIntegerRangeList getDocIndex()
      Gets range attribute DocIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setDeliveryUnit

      public void setDeliveryUnit(int iUnit, String value)
      Sets attribute DeliveryUnit
      Parameters:
      iUnit - a value between 0 and 9 to set DeliveryUnit
      value - the value to set the attribute to
    • getDeliveryUnit

      public String getDeliveryUnit(int iUnit)
      Gets attribute DeliveryUnit
      Parameters:
      iUnit - a value between 0 and 9 to set DeliveryUnit
      Returns:
      String - the attribute value
    • setDocRunIndex

      public void setDocRunIndex(JDFIntegerRangeList value)
      Sets attribute DocRunIndex
      Parameters:
      value - the value to set the attribute to
    • getDocRunIndex

      public JDFIntegerRangeList getDocRunIndex()
      Gets range attribute DocRunIndex
      Returns:
      JDFIntegerRangeList the attribute value
    • setDocSheetIndex

      public void setDocSheetIndex(JDFIntegerRangeList value)
      Sets attribute DocSheetIndex
      Parameters:
      value - the value to set the attribute to
    • getDocSheetIndex

      public JDFIntegerRangeList getDocSheetIndex()
      Gets range attribute DocSheetIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setFountainNumber

      public void setFountainNumber(int value)
      Sets attribute FountainNumber
      Parameters:
      value - the value to set the attribute to
    • getFountainNumber

      public int getFountainNumber()
      Gets integer attribute FountainNumber
      Returns:
      int - the attribute value
    • setItemNames

      public void setItemNames(String value)
      Sets attribute ItemNames
      Parameters:
      value - the value to set the attribute to
    • getItemNames

      public String getItemNames()
      Gets string attribute ItemNames
      Returns:
      String - the attribute value
    • setLayerIDs

      public void setLayerIDs(JDFIntegerRangeList value)
      Sets attribute LayerIDs
      Parameters:
      value - the value to set the attribute to
    • getLayerIDs

      public JDFIntegerRangeList getLayerIDs()
      Gets range attribute LayerIDs
      Returns:
      JDFIntegerRangeList - the attribute value
    • setLocation

      public void setLocation(String value)
      Sets attribute Location
      Parameters:
      value - the value to set the attribute to
    • getLocation

      public String getLocation()
      Gets string attribute Location
      Returns:
      - String the attribute value
    • setLocked

      public void setLocked(boolean value)
      Sets attribute Locked
      Parameters:
      value - the value to set the attribute to
    • getLocked

      public boolean getLocked()
      Gets boolean attribute Locked; defaults to false.
      Returns:
      boolean the attribute value
    • setNoOp

      public void setNoOp(boolean value)
      Sets attribute NoOp
      Parameters:
      value - the value to set the attribute to
    • getNoOp

      public boolean getNoOp()
      Gets boolean attribute NoOp; defaults to false
      Returns:
      boolean - the attribute value
    • setOption

      public void setOption(String value)
      Sets attribute Option
      Parameters:
      value - the value to set the attribute to
    • getOption

      public String getOption()
      Gets string attribute Option
      Returns:
      String - the attribute value
    • setPageNumber

      public void setPageNumber(JDFIntegerRangeList value)
      Sets attribute PageNumber
      Parameters:
      value - the value to set the attribute to
    • getPageNumber

      public JDFIntegerRangeList getPageNumber()
      Gets range attribute PageNumber
      Returns:
      JDFIntegerRangeList - the attribute value
    • addPartIDKey

      public void addPartIDKey(JDFResource.EnumPartIDKey partType)
      Adds a new PartIDKey to the root first checks for existence
      Parameters:
      partType - new PartIDKey to add
      Throws:
      JDFException - if here is an attempt to add implicit partition
    • setPartIDKey

      public void setPartIDKey(JDFResource.EnumPartIDKey key, String value)
    • getParentPartition

      public JDFResource getParentPartition()
      get the intermediate or root partition of this, null if we are the root
      Returns:
    • getPartIDKeys

      public VString getPartIDKeys()
      Gets a list of all valid part keys for this resource
      Returns:
      VString - list of all PartIDKeys
    • getPartIDKeyList

      public StringArray getPartIDKeyList()
      Gets a list of all valid part keys for this resource
      Returns:
      VString - list of all PartIDKeys
    • setPartUsage

      public void setPartUsage(JDFResource.EnumPartUsage value)
      Sets attribute PartUsage
      Parameters:
      value - enumeration value of the attribute PartUsage to be set
    • setUnpartitiondImplicit

      public static void setUnpartitiondImplicit(boolean bUnpartitiondImplicit)
      if set to true, the default @PartUsage of unpartitioned resources is Implicit. Note: this is NOT according to the specification since the Specification defaults PartUsage to Explicit for all Resources.
      Parameters:
      bUnpartitiondImplicit - the bUnpartitiondImplicit to set
    • getPartUsage

      public JDFResource.EnumPartUsage getPartUsage()
      Gets typesafe enumerated value of attribute PartUsage; defaults to PartUsage_Explicit unless setUnpartitiondImplicit(true) has been called and the resource is not partitioned, in which case PartUsage_Implicit is called. Achtung - mieser Balkon!
      Returns:
      EnumPartUsage - attribute enumeration value
    • setLotControl

      public void setLotControl(JDFResource.EnumLotControl value)
      Sets attribute PartUsage
      Parameters:
      value - enumeration value of the attribute PartUsage to be set
    • getLotControl

      public JDFResource.EnumLotControl getLotControl()
      Gets typesafe enumerated value of attribute LotControl; defaults to LotControl_Explicit
      Returns:
      EnumLotControl - attribute enumeration value
    • setPartVersion

      public void setPartVersion(String value)
      Sets attribute PartVersion
      Parameters:
      value - the value to set the attribute to
    • getPartVersion

      public String getPartVersion()
      Gets string attribute PartVersion
      Returns:
      String - the attribute value
    • setPipeID

      public void setPipeID(String value)
      Sets attribute PipeID
      Parameters:
      value - the value to set the attribute to
    • getPipeID

      public String getPipeID()
      Gets string attribute PipeID
      Returns:
      String - the attribute value
    • hasPipePartIDKey

      public boolean hasPipePartIDKey(JDFResource.EnumPartIDKey key)
      Tests, if this leaf has a PipePartIDKey as specified by key
      Parameters:
      key - the PipePartIDKey attribute name
      Returns:
      boolean - true, if key exists in this leaf or below
      Throws:
      JDFException - if the specified key is illegal
    • consistentPipePartIDKeys

      public boolean consistentPipePartIDKeys(JDFResource.EnumPartIDKey key)
      Tests, if this leaf has a consistent PartIDKey as specified by key
      Parameters:
      key - the PipePartIDKey attribute name
      Returns:
      boolean - true, if key exists in this leaf is in PipePartIDKeys
    • containsData

      public boolean containsData()
      Returns:
      true if anything but id, class etc are specified.
    • addPipePartIDKey

      public void addPipePartIDKey(JDFResource.EnumPartIDKey partType)
      Adds a new PipePartIDKey to the root, first checks for existence
      Parameters:
      partType - new PipePartIDKey to add
      Throws:
      JDFException - if here is an attempt to add implicit partition
    • setPipePartIDKey

      public void setPipePartIDKey(JDFResource.EnumPartIDKey key, String value)
      Sets the value of attibute, specified by key
      Parameters:
      key - the PipePartIDKey attribute name
      value - the value to set key to
    • getPipePartIDKeysEnum

      public Vector<JDFResource.EnumPartIDKey> getPipePartIDKeysEnum()
      Gets a list of all valid pipe part key enums for this resource
      Returns:
      Vector - list of all PipePartIDKey enums
    • getPipePartIDKeys

      @Deprecated public VString getPipePartIDKeys()
      Deprecated.
      Gets a list of all valid pipe part keys for this resource
      Returns:
      VString list of all PipePartIDKeys
    • setPipeProtocol

      public void setPipeProtocol(String value)
      Set attribute PipeProtocol
      Parameters:
      value - the value to set the attribute to
    • getPipeProtocol

      public String getPipeProtocol()
      Get string attribute PipeProtocol
      Returns:
      String - the attribute value
    • setPipeURL

      public void setPipeURL(String value)
      Sets attribute PipeURL
      Parameters:
      value - the value to set the attribute to
    • getPipeURL

      public String getPipeURL()
      Gets string attribute PipeURL
      Returns:
      String - the attribute value
    • setPreflightRule

      public void setPreflightRule(String value)
      Sets attribute PreflightRule
      Parameters:
      value - the value to set the attribute to
    • getPreflightRule

      public String getPreflightRule()
      Gets string attribute PreflightRule
      Returns:
      String the attribute value
    • setPreviewType

      public void setPreviewType(JDFAutoPart.EnumPreviewType value)
      Sets attribute PreviewType
      Parameters:
      value - enumeration value of attribute PreviewType to be set
    • getPreviewType

      public JDFAutoPart.EnumPreviewType getPreviewType()
      Gets typesafe enumerated value of attribute PreviewType
      Returns:
      JDFPart.EnumPreviewType - the enumeration value of attribute
    • setProductID

      public void setProductID(String value)
      Sets attribute ProductID
      Parameters:
      value - value to set the attribute to
    • getProductID

      public String getProductID()
      Gets string attribute ProductID
      Returns:
      String - the attribute value
    • setResourceClass

      public void setResourceClass(JDFResource.EnumResourceClass value)
      Sets attribute Class corresponds to C++ JDFResource::SetClass()
      Parameters:
      value - enumeration value of the attribute Class to be set
      Throws:
      JDFException - if here is attempt to set value as Class_Unknown or invalid class value
    • getResourceClass

      public JDFResource.EnumResourceClass getResourceClass()
      Gets typesafe enumerated value of attribute Class corresponds to C++ JDFResource::GetClass(), getClass() already exists in Java
      Returns:
      EnumResourceClass - attribute enumeration value
    • validResourceClass

      public boolean validResourceClass(JDFElement.EnumValidationLevel level)
      Typesafe attribute validation of Class corresponds to C++ JDFResource::ValidClass()
      Parameters:
      level - level of attribute validation
      Returns:
      boolean - true, if valid
    • validClass

      public final boolean validClass()
      Typesafe attribute validation of Class corresponds to C++ JDFResource::ValidClass()
      Returns:
      boolean true, if valid
    • getValidClass

      public JDFResource.EnumResourceClass getValidClass()
      get the fixed class for this resource,
      Returns:
      EnumResourceClass - the class of this resource, null if no fixed class is known
    • setGrossWeight

      public void setGrossWeight(double value)
      Sets attribute GrossWeight
      Parameters:
      value - value to set the attribute to
    • getGrossWeight

      public double getGrossWeight()
      Gets double attribute GrossWeight
      Returns:
      double - the attribute value
    • setResourceWeight

      public void setResourceWeight(double value)
      Sets attribute ResourceWeight
      Parameters:
      value - value to set the attribute to
    • getResourceWeight

      public double getResourceWeight()
      Gets double attribute ResourceWeight
      Returns:
      double - the attribute value
    • setRibbonName

      public void setRibbonName(String value)
      Sets attribute RibbonName
      Parameters:
      value - the value to set the attribute to
    • getManufacturer

      public String getManufacturer()
      Gets string attribute Manufacturer
      Returns:
      String the - attribute value
    • setManufacturer

      public void setManufacturer(String value)
      Sets attribute Manufacturer
      Parameters:
      value - the value to set the attribute to
    • getRibbonName

      public String getRibbonName()
      Gets string attribute RibbonName
      Returns:
      String the - attribute value
    • setRun

      public void setRun(String value)
      Sets attribute Run
      Parameters:
      value - the value to set the attribute to
    • getRunSet

      public String getRunSet()
      Gets string attribute RunSet
      Returns:
      String - the attribute value
    • setRunSet

      public void setRunSet(String value)
      Sets attribute RunSet
      Parameters:
      value - the value to set the attribute to
    • getRun

      public String getRun()
      Gets string attribute Run
      Returns:
      String - the attribute value
    • setRunIndex

      public void setRunIndex(JDFIntegerRangeList value)
      Sets attribute RunIndex
      Parameters:
      value - the value to set the attribute to
    • getRunIndex

      public JDFIntegerRangeList getRunIndex()
      Gets range attribute RunIndex
      Returns:
      JDFIntegerRangeList the attribute value
    • setRunPage

      public void setRunPage(int value)
      Sets attribute RunPage
      Parameters:
      value - the value to set the attribute to
    • getRunPage

      public int getRunPage()
      Gets integer attribute RunPage
      Returns:
      int - the attribute value
    • setRunTags

      public void setRunTags(VString value)
      Sets attribute RunTags
      Parameters:
      value - the value to set the attribute to
    • getRunTags

      public VString getRunTags()
      Gets NMTOKENS attribute RunTags
      Returns:
      VString - the value of the attribute
    • setSectionIndex

      public void setSectionIndex(JDFIntegerRangeList value)
      Sets attribute SectionIndex
      Parameters:
      value - the value to set the attribute to
    • getSectionIndex

      public JDFIntegerRangeList getSectionIndex()
      Gets range attribute SectionIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSeparation

      public void setSeparation(String value)
      Sets attribute Separation
      Parameters:
      value - the value to set the attribute to
    • getSeparation

      public String getSeparation()
      Gets string attribute Separation
      Returns:
      String - the attribute value
    • setSetDocIndex

      public void setSetDocIndex(JDFIntegerRangeList value)
      Sets attribute SetDocIndex
      Parameters:
      value - the value to set the attribute to
    • getSetDocIndex

      public JDFIntegerRangeList getSetDocIndex()
      Gets range attribute SetDocIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSetIndex

      public void setSetIndex(JDFIntegerRangeList value)
      Sets attribute SetIndex
      Parameters:
      value - the value to set the attribute to
    • getSetIndex

      public JDFIntegerRangeList getSetIndex()
      Gets range attribute SetIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSetRunIndex

      public void setSetRunIndex(JDFIntegerRangeList value)
      Sets attribute SetRunIndex
      Parameters:
      value - the value to set the attribute to
    • getSetRunIndex

      public JDFIntegerRangeList getSetRunIndex()
      Gets range attribute SetRunIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSetSheetIndex

      public void setSetSheetIndex(JDFIntegerRangeList value)
      Sets attribute SetSheetIndex
      Parameters:
      value - the value to set the attribute to
    • getSetSheetIndex

      public JDFIntegerRangeList getSetSheetIndex()
      Gets range attribute SetSheetIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSheetIndex

      public void setSheetIndex(JDFIntegerRangeList value)
      Sets attribute SheetIndex
      Parameters:
      value - the value to set the attribute to
    • getSheetIndex

      public JDFIntegerRangeList getSheetIndex()
      Gets range attribute SheetIndex
      Returns:
      JDFIntegerRangeList - the attribute value
    • setSheetName

      public void setSheetName(String value)
      Sets attribute SheetName
      Parameters:
      value - the value to set the attribute to
    • getSheetName

      public String getSheetName()
      Gets string attribute SheetName
      Returns:
      String - the attribute value
    • setSide

      public void setSide(JDFAutoPart.EnumSide value)
      Sets attribute Side
      Parameters:
      value - enumeration value of attribute Side to be set
    • getSide

      public JDFAutoPart.EnumSide getSide()
      Gets typesafe enumerated value of attribute Side
      Returns:
      JDFPart.EnumSide - the enumeration value of the attribute
    • setSignatureName

      public void setSignatureName(String value)
      Sets attribute SignatureName
      Parameters:
      value - the value to set the attribute to
    • getSignatureName

      public String getSignatureName()
      Gets string attribute SignatureName
      Returns:
      String - the attribute value
    • getStationName

      public String getStationName()
      Gets string attribute StationName
      Returns:
      String - the attribute value
    • setStationName

      public void setStationName(String value)
      Sets attribute StationName
      Parameters:
      value - the value to set the attribute to
    • setSortAmount

      public void setSortAmount(boolean value)
      Sets attribute SortAmount
      Parameters:
      value - value to set the attribute to
    • getSortAmount

      public boolean getSortAmount()
      Gets boolean attribute SortAmount
      Returns:
      boolean - the attribute value
    • setSorting

      public void setSorting(JDFIntegerRangeList value)
      Sets attribute Sorting
      Parameters:
      value - the value to set the attribute to
    • getSorting

      public JDFIntegerRangeList getSorting()
      Gets range attribute Sorting
      Returns:
      JDFIntegerRangeList - the attribute value
    • appendSpawnIDs

      public void appendSpawnIDs(String value)
      Appends new SpawnID token ('value') to the list of values of SpawnIDs attribute, if it is not yet in the list
      Parameters:
      value - the SpawnID token to append
    • removeFromSpawnIDs

      public int removeFromSpawnIDs(String value)
      Removes SpawnID token ('value') from the list of values of SpawnIDs attribute, if it is in the list
      Parameters:
      value - the SpawnID token to remove from the NMTOKENS list
      Returns:
      int - the number of removed tokens
    • getSpawnIDs

      public VString getSpawnIDs(boolean bInherit)
      Gets string attribute SpawnIDs
      Parameters:
      bInherit - if true, searches through all leaves, else searches only this leaf/node
      Returns:
      VString the vector of SpawnIDs
    • setSpawnIDs

      public void setSpawnIDs(VString vStr)
      Sets attribute SpawnIDs
      Parameters:
      vStr - the value to set the attribute to
    • setSpawnIDs

      public void setSpawnIDs(String spawndID)
      Sets attribute SpawnIDs
      Parameters:
      spawndID - the value to set the attribute to
    • setSpawnStatus

      public void setSpawnStatus(JDFResource.EnumSpawnStatus s)
      Sets attribute SpawnStatus
      Parameters:
      s - enumeration value of the attribute SpawnStatus to be set
    • getSpawnStatus

      public JDFResource.EnumSpawnStatus getSpawnStatus()
      Gets typesafe enumerated value of attribute SpawnStatus
      Returns:
      EnumSpawnStatus - attribute enumeration value
    • setStatus

      @Deprecated public void setStatus(JDFResource.EnumResStatus value)
      Deprecated.
      use setResStatus(value, false)
      Sets attribute Status
      Parameters:
      value - enumeration value of the attribute Status to be set
    • setStatus

      @Deprecated public void setStatus(JDFResource.EnumResStatus value, boolean bCleanLeaves)
      Deprecated.
      use setResStatus(value, bCleanLeaves)
      Sets attribute Status
      Parameters:
      value - enumeration value of the attribute Status to be set
      bCleanLeaves - if true, remove Status attribute from any child leaves below this
    • getStatus

      @Deprecated public JDFResource.EnumResStatus getStatus(boolean bRecurseRefs)
      Deprecated.
      use getResStatus(bRecurseRefs)
      Gets typesafe enumerated value of attribute Status
      Parameters:
      bRecurseRefs - if bRecurseRefs is set, also recurse into all resources linked by rRefs and return the minimum status
      Returns:
      EnumResStatus attribute enumeration value
    • setResStatus

      public void setResStatus(JDFResource.EnumResStatus value, boolean bCleanLeaves)
      Sets attribute Status
      Parameters:
      value - enumeration value of the attribute Status to be set
      bCleanLeaves - if true, remove Status attribute from any child leaves below this
    • getResStatus

      public JDFResource.EnumResStatus getResStatus(boolean bRecurseRefs)
      Gets typesafe enumerated value of attribute Status
      Parameters:
      bRecurseRefs - if bRecurseRefs is set, also recurse into all resources linked by rRefs and return the minimum status
      Returns:
      EnumResStatus - attribute enumeration value
    • getStatusFromLeaves

      public JDFResource.EnumResStatus getStatusFromLeaves(boolean bAll)
      Gets the minimum typesafe enumerated value of attribute Status from the value of all leaves
      Parameters:
      bAll - if true, also evaluate intermediate partitions, else leaves only
      Returns:
      EnumResStatus - the minimum Status enumeration value
    • setTileID

      public void setTileID(JDFXYPair value)
      Sets attribute TileID
      Parameters:
      value - the value to set the attribute to
    • getTileID

      public JDFXYPair getTileID()
      Gets XYPair attribute TileID
      Returns:
      JDFXYPair - the attribute value
    • setUnit

      public void setUnit(String value)
      Sets attribute Unit
      Parameters:
      value - value to set the attribute to
    • getUnit

      public String getUnit()
      Gets string attribute Unit
      Returns:
      String - the attribute value
    • setUpdateID

      public void setUpdateID(String value)
      Sets attribute UpdateID
      Parameters:
      value - value to set the attribute to
    • getUpdateID

      public String getUpdateID()
      Gets string attribute UpdateID
      Returns:
      String - the attribute value
    • setWebName

      public void setWebName(String value)
      Sets attribute WebName
      Parameters:
      value - the value to set the attribute to
    • getWebName

      public String getWebName()
      Gets string attribute WebName
      Returns:
      String - the attribute value
    • setWebProduct

      public void setWebProduct(String value)
      Sets attribute WebProduct
      Parameters:
      value - the value to set the attribute to
    • getWebProduct

      public String getWebProduct()
      Gets string attribute WebProduct
      Returns:
      String the attribute value
    • setWebSetup

      public void setWebSetup(String value)
      Sets attribute WebSetup
      Parameters:
      value - the value to set the attribute to
    • getWebSetup

      public String getWebSetup()
      Gets string attribute WebSetup
      Returns:
      String the attribute value
    • createPartitions

      public VElement createPartitions(VJDFAttributeMap vPartMap, VString vPartIDKeys)
      Recursively adds the partition leaves defined in vPartMap
      Parameters:
      vPartMap - the vector of maps of part keys
      vPartIDKeys - the vector of partIDKeys strings of the resource. If empty (the default) the Resource PartIDKeys attribute is used
      Returns:
      VElement - vector of newly created partitions
      Throws:
      JDFException - if there are in the partMap not matching partitions
      JDFException - if there is an attempt to fill non-matching partIDKeys
      JDFException - if by adding of last partition key there is either non-continuous partmap or left more than one key
    • isValid

      public boolean isValid(JDFElement.EnumValidationLevel level)
      Validator of 'this'
      Overrides:
      isValid in class JDFElement
      Parameters:
      level - the valdation level
      Returns:
      boolean - true, if 'this' is valid
    • getInvalidAttributes

      public VString getInvalidAttributes(JDFElement.EnumValidationLevel level, boolean bIgnorePrivate, int nMax)
      Typesafe validator. Gets a vector of invalid attributes
      Overrides:
      getInvalidAttributes in class JDFElement
      Parameters:
      level - flag whether incomplete elements are valid
      bIgnorePrivate - if true, do not validate attributes in private name spaces
      nMax - maximum size of the returned vector. Stop validation after nMax invalid attributes
      Returns:
      vWString a vector of invalid attributes
    • deleteUnLinked

      public boolean deleteUnLinked()
      deletes this if it is no longer linked by either resource refs or resource links
      Returns:
      true if this has been deleted
    • getAutoAgent

      public static boolean getAutoAgent()
      Returns:
      the autoAgent
    • setAutoAgent

      public static void setAutoAgent(boolean _autoAgent)
      Parameters:
      _autoAgent - the autoAgent to set
    • matchesString

      public boolean matchesString(String namedResLink)
      check whether this resource matches a named resource string
      Parameters:
      namedResLink -
      Returns:
    • getAutoSubElementClass

      public static boolean getAutoSubElementClass()
      if true, subelements are initialized with a class attribute
      Returns:
    • setAutoSubElementClass

      public static void setAutoSubElementClass(boolean autoSubElementClass)
      if true, subelements are initialized with a class attribute
      Parameters:
      autoSubElementClass -
    • getLeaf

      public JDFResource getLeaf(int i)
      get a leaf, null if index out of bounds
      Parameters:
      i -
      Returns:
    • moveElement

      public KElement moveElement(KElement src, KElement beforeChild)
      Description copied from class: KElement
      Moves src node (including all attributes and subelements) from its parent node into 'this' and inserts it in front of beforeChild, if it exists. Otherwise appends src to 'this'.
      If src is null, an empty KElement is returned.
      src is removed from its parent node. if the actual document owner is the same as the document owner of src, src is appended to 'this' If the documents are different, then src is appended to 'this' in the actual document.

      default: moveElement(src, null)

      Overrides:
      moveElement in class KElement
      Parameters:
      src - node to move.
      beforeChild - child of 'this' to insert src before. If beforeChild is null, src is appended to 'this'
      Returns:
      KElement src element after moving, null if src is null
    • copyElement

      public KElement copyElement(KElement src, KElement beforeChild)
      Description copied from class: KElement
      Copies src node (including all attributes and subelements) and inserts the copy into 'this' in front of beforeChild, if it exists. Otherwise appends src node to 'this'.

      default: copyElement(src, null)

      Overrides:
      copyElement in class KElement
      Parameters:
      src - node to copy.
      beforeChild - child of 'this' to insert src before. If null, src is appended
      Returns:
      KElement the copied element, null if src is null.
    • replaceElement

      public KElement replaceElement(KElement src)
      Description copied from class: KElement
      Replaces 'this' with src.
      If the actual document is the same as the src document, 'this' is replaced by src.
      If the actual document and the src document are different, src is positioned at the position of 'this' in the current document and removed from the old parent document.
      Overrides:
      replaceElement in class KElement
      Parameters:
      src - node, that 'this' will be replaced with
      Returns:
      KElement the replaced element. If src is null or equal 'this', src is returned.
    • deleteNode

      public KElement deleteNode()
      Description copied from class: KElement
      Deletes itself from its parent
      Overrides:
      deleteNode in class KElement
      Returns:
      KElement - the deleted element, null if this has no parent node
      See Also:
    • mergeElement

      public KElement mergeElement(KElement kElem, boolean bDelete)
      Description copied from class: KElement
      merge nodes in a way that no duplicate elements are created
      attention !! this kills pools !! since elements in kElem overwrite those in *this
      Overrides:
      mergeElement in class KElement
      Parameters:
      kElem - the node element to merge with the current node
      bDelete - if true KElement kElem will be deleted
      Returns:
      KElement the merged node element
    • insertBefore

      public Node insertBefore(Node src, Node arg1) throws DOMException
      Specified by:
      insertBefore in interface Node
      Overrides:
      insertBefore in class KElement
      Throws:
      DOMException
      See Also:
    • copyInto

      public KElement copyInto(KElement src, boolean bRemove)
      Description copied from class: JDFElement
      copies a node into this, ignoring identical node names i.e. duplicating elements
      Overrides:
      copyInto in class JDFElement
      bRemove - if true, remove existing information, else retain and overwrite / merge
      Returns:
      this
      See Also:
    • appendElement

      public KElement appendElement(String elementName, String nameSpaceURI)
      Overrides:
      appendElement in class JDFElement
      Parameters:
      elementName - the elementname with namespace prefix "xyz:abc"
      nameSpaceURI - the namespace of the element "null" is valid if the namespace was specified already above. The method will lookup the namespace for you. Performance wise its better to add it nevertheless.
      Returns:
      KElement the appended element or null
      See Also:
    • setAttribute

      public void setAttribute(String key, String value, String nameSpaceURI)
      Description copied from class: KElement
      Mother of all Attribute setters
      Sets a new attribute. If an attribute with that name is already present in the element, its value is changed to be that of the value parameter. This value is a simple string; it is not parsed as it is being set. So any markup (such as syntax to be recognized as an entity reference) is treated as literal text, and needs to be appropriately escaped by the implementation when it is written out. In order to assign an attribute value that contains entity references, the user must create an Attr node plus any Text and EntityReference nodes, build the appropriate subtree, and use setAttributeNode to assign it as the value of an attribute. To set an attribute with a qualified name and namespace URI, use the setAttributeNS method.
      Overrides:
      setAttribute in class KElement
      Parameters:
      key - the qualified name of the attribute to create or alter.
      value - the value to set in string form. If null, the attribute is removed
      nameSpaceURI - the namespace the element is in
      See Also: