Class JDFRunList

java.lang.Object
org.apache.xerces.dom.NodeImpl
org.apache.xerces.dom.ChildNode
org.apache.xerces.dom.ParentNode
org.apache.xerces.dom.ElementImpl
All Implemented Interfaces:
Serializable, Cloneable, IStreamWriter, Element, ElementTraversal, EventTarget, Node, NodeList, TypeInfo

public class JDFRunList extends JDFAutoRunList
Wrapper around a JDF RunList
See Also:
  • Constructor Details

    • JDFRunList

      public JDFRunList(org.apache.xerces.dom.CoreDocumentImpl myOwnerDocument, String qualifiedName) throws DOMException
      Constructor for JDFRunList
      Parameters:
      myOwnerDocument -
      qualifiedName -
      Throws:
      DOMException
    • JDFRunList

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

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

    • getTheAttributeInfo

      protected AttributeInfo getTheAttributeInfo()
      Overrides:
      getTheAttributeInfo in class JDFAutoRunList
      Returns:
    • toString

      public String toString()
      toString
      Overrides:
      toString in class KElement
      Returns:
      String
      See Also:
    • addRun

      @Deprecated public JDFRunList addRun(String fileName)
      Deprecated.
      addRun
      Parameters:
      fileName -
      Returns:
      JDFRunList
    • addRun

      @Deprecated public JDFRunList addRun(String fileName, int first)
      Deprecated.
      addRun
      Parameters:
      fileName -
      first -
      Returns:
      JDFRunList
    • addRun

      public JDFRunList addRun(String fileName, int first, int last)
      addRun
      Parameters:
      fileName -
      first -
      last -
      Returns:
      JDFRunList
    • addPDF

      @Deprecated public JDFRunList addPDF(String fileName)
      Deprecated.
      addPDF
      Parameters:
      fileName -
      Returns:
      JDFRunList
    • addPDF

      @Deprecated public JDFRunList addPDF(String fileName, int first)
      Deprecated.
      addPDF
      Parameters:
      fileName -
      first -
      Returns:
      JDFRunList
    • addPDF

      public JDFRunList addPDF(String fileName, int first, int last)
      addPDF add a pdf file to this RunList
      Parameters:
      fileName - the URL (!) of the file
      first - 0 based first page in the file
      last - 0 based last page in the file
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(Vector fileNames, Vector sepNames)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(Vector fileNames, Vector sepNames, int first)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(Vector fileNames, Vector sepNames, int first, int n)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      n -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(Vector fileNames, Vector sepNames, int first, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(Vector fileNames, Vector sepNames, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      public JDFRunList addSepRun(Vector fileNames, Vector sepNames, int first, int n, boolean pageMajor)
      add a run separation
      Parameters:
      fileNames - vector of file names for the URL attribute of the FileSpec in the LayoutElement
      sepNames - parallel vector of separation names.
      first - index of the first page in the file - Sets the RunList FirstPage attribute
      n - the number of logical pages in this run
      pageMajor - if true, separations are ordered as page Major, i.e CMYKCMYK
      if false, ordering is CCMMYYKK
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames, int first)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames, int first, int n)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      n -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames, int first, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(VElement fileSpec, Vector sepNames, int first, int n, boolean pageMajor)
      Deprecated.
      060503 use the version with VString VString
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      n -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, int n)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      n -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, int n, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      n -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(JDFResource fileSpec, String sepNames, int first, int n, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileSpec -
      sepNames -
      first -
      n -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, int n)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      n -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, boolean pageMajor)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      pageMajor -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, int n, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      n -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • addSepRun

      @Deprecated public JDFRunList addSepRun(String fileNames, String sepNames, int first, int n, boolean pageMajor, String sep)
      Deprecated.
      addSepRun
      Parameters:
      fileNames -
      sepNames -
      first -
      n -
      pageMajor -
      sep -
      Returns:
      JDFRunList
    • setFileURL

      public boolean setFileURL(String url)
      set RunList/LayoutElement/FileSpec/@URL
      Parameters:
      url - the url to set
      Returns:
      true if ok
    • setFileSpecURL

      public boolean setFileSpecURL(String url)
      set RunList/FileSpec/@URL - only for 2.0
      Parameters:
      url - the url to set
      Returns:
      true if ok
    • getCreateFileSpec

      public JDFFileSpec getCreateFileSpec()
      (25) getCreateFileSpec
      Returns:
      JDFFileSpec the element
    • setByteMapURL

      public boolean setByteMapURL(String url)
      set RunList/ByteMap/FileSpec/@URL
      Parameters:
      url - the url to set
      Returns:
      true if ok
    • getFileURL

      public String getFileURL()
      get RunList/LayoutElement/FileSpec/@URL also evaluate RunList/@directory and concatinate Directory + URL in case URL is a relative URL
      Returns:
      URL if a URL or Directory attribute exists, else null
    • setPages

      public void setPages(JDFIntegerRangeList value)
      (36) set attribute Pages
      Overrides:
      setPages in class JDFAutoRunList
      Parameters:
      value - : the value to set the attribute to
    • getFileMimeType

      public String getFileMimeType()
      get RunList/LayoutElement/FileSpec/@MimeType
      Returns:
      MIMEType if it exists, else null
    • getFileSpec

      public JDFFileSpec getFileSpec()
      get RunList/LayoutElement/FileSpec or RunList/FileSpec in case of XJDF
      Returns:
      JDFFileSpec FileSpec if it exists, else null
    • getCommonURLFileSpecMap

      public HashMap<String,VJDFAttributeMap> getCommonURLFileSpecMap()
      get a map of VJDFAttributeMap that are sorted by the fileSpec URL key
      each url key maps the leaves that share the same URL
      Returns:
      fileSpecMap a map of VJDFAttributeMap
    • getImplicitPartitions

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

      public Iterator<JDFRunList.JDFRunData> getPageIterator()
      Returns:
    • getFirstIndex

      public int getFirstIndex()
      gets the first logical RunIndex for this partition
      Returns:
      the first RunIndex that this RunList partition specifies
    • getFirstIndex

      protected int getFirstIndex(JDFRunList.JDFRunData last)
      gets the first logical RunIndex for this partition
      Parameters:
      last -
      Returns:
      the first RunIndex that this RunList partition specifies
    • getPageLeaves

      public VElement getPageLeaves()
      get the list of RunList Leaves with IsPage=true
      Returns:
    • getLastIndex

      public int getLastIndex()
      gets the last logical RunIndex for this partition
      Returns:
      the last RunIndex that this RunList partition specifies
    • getLastIndex

      protected int getLastIndex(JDFRunList.JDFRunData last)
      gets the last logical RunIndex for this partition
      Parameters:
      last -
      Returns:
      the last RunIndex that this RunList partition specifies
    • getNPage

      public int getNPage()
      calculates nPage from the leaves if possible - else does the standard stuff
      Overrides:
      getNPage in class JDFAutoRunList
      Returns:
      int the value of the attribute
      See Also:
    • getIndexPartition

      public JDFRunList getIndexPartition(int index)
      get the Partition that corresponds to a given runIndex
      Parameters:
      index - the runIndex to search for
      Returns:
      JDFRunList the partition that contains this index. use @see getPageInFile to find the correct page warning blindly calling this from inside a loop may cause performance issues - use the getPageIterator if you need performance optimized access
    • getPageInFile

      public int getPageInFile(int runIndex)
      get the 0 based page number in the specified file
      Parameters:
      runIndex -
      Returns:
      the page number in the file; -1 if ot of range
    • collapse

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

      public void expand(boolean bDeleteFromNode)
      Description copied from class: JDFResource
      Expand so that each leaf is complete (except for ID)
      Overrides:
      expand in class JDFResource
      Parameters:
      bDeleteFromNode - if true, removes all intermediate elements and attributes
      See Also:
    • fixNPage

      public void fixNPage()
      write NPage into all leaves with IsPage=true and write the appropriate value into the lower level nodes
    • getTruePage

      public JDFRunList getTruePage()
      get the first matching parent or this with IsPage==true
      Returns:
    • isPageLeaf

      public boolean isPageLeaf()
      get the first matching parent or this with IsPage==true
      Returns:
    • getPages

      public JDFIntegerRangeList getPages()
      Description copied from class: JDFAutoRunList
      (20) get JDFIntegerRangeList attribute Pages
      Overrides:
      getPages in class JDFAutoRunList
      Returns:
      JDFIntegerRangeList the value of the attribute, null if a the attribute value is not a valid to create a JDFIntegerRangeList
      See Also:
    • getFileSpecNPage

      public int getFileSpecNPage()
    • getPageListIndex

      public JDFIntegerRangeList getPageListIndex()
      get the pageListIndex with a reasonable def for number of pages
      first try the pagelist, then do for local npage
      Overrides:
      getPageListIndex in class JDFAutoRunList
      Returns:
      JDFIntegerRangeList the value of the attribute, null if a the attribute value is not a valid to create a JDFIntegerRangeList
      See Also: