Package com.helger.pdflayout.render
Class PreparationContextGlobal
- java.lang.Object
-
- com.helger.pdflayout.render.PreparationContextGlobal
-
@NotThreadSafe public final class PreparationContextGlobal extends Object
The current global context for preparing an element. This object must be the same for all prepared elements. It keeps all loaded fonts so that they are not included more than once.- Author:
- Philip Helger
-
-
Constructor Summary
Constructors Constructor Description PreparationContextGlobal(org.apache.pdfbox.pdmodel.PDDocument aDoc)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.pdfbox.pdmodel.PDDocumentgetDocument()LoadedFontgetLoadedFont(FontSpec aFontSpec)
-
-
-
Constructor Detail
-
PreparationContextGlobal
public PreparationContextGlobal(@Nonnull org.apache.pdfbox.pdmodel.PDDocument aDoc)
Constructor- Parameters:
aDoc- ThePDDocumentworked upon
-
-
Method Detail
-
getDocument
@Nonnull public org.apache.pdfbox.pdmodel.PDDocument getDocument()
- Returns:
- The
PDDocumentas provided in the constructor. Nevernull.
-
getLoadedFont
@Nonnull public LoadedFont getLoadedFont(@Nonnull FontSpec aFontSpec) throws IOException
- Throws:
IOException
-
-