Class PdfPage

  • All Implemented Interfaces:
    java.io.Serializable

    public class PdfPage
    extends PdfDictionary
    PdfPage is the PDF Page-object.

    A Page object is a dictionary whose keys describe a single page containing text, graphics, and images. A Page object is a leaf of the Pages tree.
    This object is described in the 'Portable Document Format Reference Manual version 1.3' section 6.4 (page 73-81)

    See Also:
    PdfPages, Serialized Form
    • Field Detail

      • boxStrings

        private static final java.lang.String[] boxStrings
      • boxNames

        private static final PdfName[] boxNames
      • PORTRAIT

        public static final PdfNumber PORTRAIT
        value of the Rotate key for a page in PORTRAIT
      • LANDSCAPE

        public static final PdfNumber LANDSCAPE
        value of the Rotate key for a page in LANDSCAPE
      • INVERTEDPORTRAIT

        public static final PdfNumber INVERTEDPORTRAIT
        value of the Rotate key for a page in INVERTEDPORTRAIT
      • SEASCAPE

        public static final PdfNumber SEASCAPE
        value of the Rotate key for a page in SEASCAPE
    • Method Detail

      • isParent

        public boolean isParent()
        Checks if this page element is a tree of pages.

        This method always returns false.

        Returns:
        false because this is a single page
      • add

        void add​(PdfIndirectReference contents)
        Adds an indirect reference pointing to a PdfContents-object.
        Parameters:
        contents - an indirect reference to a PdfContents-object
      • rotateMediaBox

        PdfRectangle rotateMediaBox()
        Rotates the mediabox, but not the text in it.
        Returns:
        a PdfRectangle
      • getMediaBox

        PdfRectangle getMediaBox()
        Returns the MediaBox of this Page.
        Returns:
        a PdfRectangle