Class PdfMergeAttributes

java.lang.Object
org.jpedal.tools.PdfMergeAttributes

public class PdfMergeAttributes extends Object
Class to hold resource values to be used by the PdfMerge tool
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
    Attribute names used on the command line These attributes control the appearance and features of the various Pdf Merge options
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    Get the name of the font to be used in newly created content from the PdfMerge MergeOptions
    int
    Get the size of the font to be used in newly created content from the PdfMerge MergeOptions
    int
    Get the height of the footer to be created in newly created content from the PdfMerge MergeOptions
    Get the template used by ADD_FOOTER MergeOption.
    float[]
    Get the color of the text to be used in newly created content from the PdfMerge MergeOptions
    void
    Specify the font to use for new content created by PdfMerge MergeOptions.
    void
    setFontSize(int size)
    Specify the font size to use for new content created by PdfMerge MergeOptions.
    void
    setFooterHeight(int height)
    Specify the height of any footer generate created by PdfMerge MergeOptions.
    void
    Specify a template to be used with the ADD_FOOTER MergeOption.
    void
    setTextColor(float[] color)
    Specify the text color to use for new content created by PdfMerge MergeOptions.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PdfMergeAttributes

      public PdfMergeAttributes()
  • Method Details

    • setFontName

      public void setFontName(String name)
      Specify the font to use for new content created by PdfMerge MergeOptions.
      Parameters:
      name - the name of the base font to use. See BaseFont
    • setFontSize

      public void setFontSize(int size)
      Specify the font size to use for new content created by PdfMerge MergeOptions.
      Parameters:
      size - the font size to use when creating text
    • setFooterHeight

      public void setFooterHeight(int height)
      Specify the height of any footer generate created by PdfMerge MergeOptions.
      Parameters:
      height - the height of the Footer in PDF coordinates
    • setFooterTemplate

      public void setFooterTemplate(String template)
      Specify a template to be used with the ADD_FOOTER MergeOption. The template has 2 dynamic variables that will be replaced with document and page specific values. %FILENAME - is replaced with the original files name. %PAGENUMBER - is replaced with the original page number of this page in the original file.
      Parameters:
      template - the template to be used when generating a footer
    • setTextColor

      public void setTextColor(float[] color)
      Specify the text color to use for new content created by PdfMerge MergeOptions.
      Parameters:
      color - the color for text content as an array of 3 values to represent an RGB color The values must be between 0 - 1.
    • getFontName

      public String getFontName()
      Get the name of the font to be used in newly created content from the PdfMerge MergeOptions
      Returns:
      a String representing the name of the font to be used
    • getFontSize

      public int getFontSize()
      Get the size of the font to be used in newly created content from the PdfMerge MergeOptions
      Returns:
      an int representing the font size to be used
    • getFooterHeight

      public int getFooterHeight()
      Get the height of the footer to be created in newly created content from the PdfMerge MergeOptions
      Returns:
      an int representing the font size to be used
    • getFooterTemplate

      public String getFooterTemplate()
      Get the template used by ADD_FOOTER MergeOption.
      Returns:
      a String detailing what content to be added to the newly created footer.
    • getTextColor

      public float[] getTextColor()
      Get the color of the text to be used in newly created content from the PdfMerge MergeOptions
      Returns:
      A float array of 3 values between 0 - 1 that represent an RGB color