Class PdfDocument.PdfCatalog
- java.lang.Object
-
- com.gitlab.pdftk_java.com.lowagie.text.pdf.PdfObject
-
- com.gitlab.pdftk_java.com.lowagie.text.pdf.PdfDictionary
-
- com.gitlab.pdftk_java.com.lowagie.text.pdf.PdfDocument.PdfCatalog
-
- Enclosing class:
- PdfDocument
static class PdfDocument.PdfCatalog extends PdfDictionary
PdfCatalog
is the PDF Catalog-object.The Catalog is a dictionary that is the root node of the document. It contains a reference to the tree of pages contained in the document, a reference to the tree of objects representing the document's outline, a reference to the document's article threads, and the list of named destinations. In addition, the Catalog indicates whether the document's outline or thumbnail page images should be displayed automatically when the document is viewed and wether some location other than the first page should be shown when the document is opened.
In this class however, only the reference to the tree of pages is implemented.
This object is described in the 'Portable Document Format Reference Manual version 1.3' section 6.2 (page 67-71)
-
-
Constructor Summary
Constructors Constructor Description PdfCatalog(PdfIndirectReference pages, PdfIndirectReference outlines, PdfWriter writer)
Constructs aPdfCatalog
.PdfCatalog(PdfIndirectReference pages, PdfWriter writer)
Constructs aPdfCatalog
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
addNames(java.util.TreeMap localDestinations, java.util.ArrayList documentJavaScript, PdfWriter writer)
Adds the names of the named destinations to the catalog.(package private) void
setAcroForm(PdfObject fields)
(package private) void
setAdditionalActions(PdfDictionary actions)
Sets the document level additional actions.(package private) void
setOpenAction(PdfAction action)
Sets the viewer preferences as the sum of several constants.(package private) void
setPageLabels(PdfPageLabels pageLabels)
-
Methods inherited from class com.gitlab.pdftk_java.com.lowagie.text.pdf.PdfDictionary
contains, get, getAsArray, getAsBoolean, getAsDict, getAsIndirectObject, getAsName, getAsNumber, getAsStream, getAsString, getDirectObject, getKeys, isCatalog, isDictionaryType, isFont, isOutlineTree, isPage, isPages, merge, mergeDifferent, put, putAll, putDel, putEx, remove, size, toPdf
-
Methods inherited from class com.gitlab.pdftk_java.com.lowagie.text.pdf.PdfObject
canBeInObjStm, getBytes, getIndRef, isArray, isBoolean, isDictionary, isIndirect, isName, isNull, isNumber, isStream, isString, length, setContent, setIndRef, toString, type
-
-
-
-
Field Detail
-
writer
PdfWriter writer
-
-
Constructor Detail
-
PdfCatalog
PdfCatalog(PdfIndirectReference pages, PdfWriter writer)
Constructs aPdfCatalog
.- Parameters:
pages
- an indirect reference to the root of the document's Pages tree.writer
- the writer the catalog applies to
-
PdfCatalog
PdfCatalog(PdfIndirectReference pages, PdfIndirectReference outlines, PdfWriter writer)
Constructs aPdfCatalog
.- Parameters:
pages
- an indirect reference to the root of the document's Pages tree.outlines
- an indirect reference to the outline tree.writer
- the writer the catalog applies to
-
-
Method Detail
-
addNames
void addNames(java.util.TreeMap localDestinations, java.util.ArrayList documentJavaScript, PdfWriter writer)
Adds the names of the named destinations to the catalog.- Parameters:
localDestinations
- the local destinationsdocumentJavaScript
- the javascript used in the documentwriter
- the writer the catalog applies to
-
setOpenAction
void setOpenAction(PdfAction action)
Sets the viewer preferences as the sum of several constants.- Parameters:
preferences
- the viewer preferences- See Also:
PdfWriter.setViewerPreferences(int)
-
setAdditionalActions
void setAdditionalActions(PdfDictionary actions)
Sets the document level additional actions.- Parameters:
actions
- dictionary of actions
-
setPageLabels
void setPageLabels(PdfPageLabels pageLabels)
-
setAcroForm
void setAcroForm(PdfObject fields)
-
-