org.apache.fop.render.pdf

## Class PDFRenderingContext

- java.lang.Object
- - org.apache.fop.render.AbstractRenderingContext
  - - org.apache.fop.render.pdf.PDFRenderingContext

- All Implemented Interfaces:
    RenderingContext

      public class PDFRenderingContext
      extends AbstractRenderingContext

  Rendering context for PDF production.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `PDFRenderingContext(FOUserAgent userAgent, PDFContentGenerator generator, PDFPage page, FontInfo fontInfo)` Main constructor.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `PDFStructElem` | `getCurrentSessionStructElem()`
    `FontInfo` | `getFontInfo()` Returns the font list.
    `PDFContentGenerator` | `getGenerator()` Returns the PDF content generator.
    `String` | `getMimeType()` Returns the MIME type associated with the current output format.
    `PDFPage` | `getPage()` Returns the current PDF page.
    `Map<Integer,PDFArray>` | `getPageNumbers()`
    `PDFLogicalStructureHandler` | `getPdfLogicalStructureHandler()`
    `Map<String,Object>` | `getUsedFieldNames()`
    `void` | `setCurrentSessionStructElem(PDFStructElem currentSessionStructElem)`
    `void` | `setPageNumbers(Map<Integer,PDFArray> pageNumbers)`
    `void` | `setPdfLogicalStructureHandler(PDFLogicalStructureHandler pdfLogicalStructureHandler)`
    `void` | `setUsedFieldNames(Map<String,Object> usedFieldNames)`

    - ### Methods inherited from class org.apache.fop.render.AbstractRenderingContext

      `getHint, getHints, getUserAgent, putHint, putHints`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### PDFRenderingContext

          public PDFRenderingContext(FOUserAgent userAgent,
                                     PDFContentGenerator generator,
                                     PDFPage page,
                                     FontInfo fontInfo)

      Main constructor.
      Parameters:
        `userAgent` - the user agent
        `generator` - the PDF content generator
        `page` - the current PDF page
        `fontInfo` - the font list

  - ### Method Detail

    - #### getMimeType

          public String getMimeType()

      Returns the MIME type associated with the current output format.
      Returns:
        the MIME type (ex. application/pdf)

    - #### getGenerator

          public PDFContentGenerator getGenerator()

      Returns the PDF content generator.
      Returns:
        the PDF content generator

    - #### getPage

          public PDFPage getPage()

      Returns the current PDF page.
      Returns:
        the PDF page

    - #### getFontInfo

          public FontInfo getFontInfo()

      Returns the font list.
      Returns:
        the font list

    - #### getUsedFieldNames

          public Map<String,Object> getUsedFieldNames()

    - #### setUsedFieldNames

          public void setUsedFieldNames(Map<String,Object> usedFieldNames)

    - #### getPageNumbers

          public Map<Integer,PDFArray> getPageNumbers()

    - #### setPageNumbers

          public void setPageNumbers(Map<Integer,PDFArray> pageNumbers)

    - #### getPdfLogicalStructureHandler

          public PDFLogicalStructureHandler getPdfLogicalStructureHandler()

    - #### setPdfLogicalStructureHandler

          public void setPdfLogicalStructureHandler(PDFLogicalStructureHandler pdfLogicalStructureHandler)

    - #### getCurrentSessionStructElem

          public PDFStructElem getCurrentSessionStructElem()

    - #### setCurrentSessionStructElem

          public void setCurrentSessionStructElem(PDFStructElem currentSessionStructElem)

Copyright © 2025 Apache Software Foundation. All rights reserved.