Package com.lowagie.text.pdf
Class FdfReader
java.lang.Object
com.lowagie.text.pdf.PdfReader
com.lowagie.text.pdf.FdfReader
- All Implemented Interfaces:
PdfViewerPreferences
,Closeable
,AutoCloseable
Reads an FDF form and makes the fields available
-
Nested Class Summary
Nested classes/interfaces inherited from class com.lowagie.text.pdf.PdfReader
PdfReader.PageRefs
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) PdfName
private Map
<String, PdfDictionary> private String
Fields inherited from class com.lowagie.text.pdf.PdfReader
acroForm, acroFormParsed, catalog, certificate, certificateKey, certificateKeyProvider, consolidateNamedDestinations, decrypt, encrypted, eofPos, freeXref, lastXref, newXrefType, objStmMark, objStmToOffset, pageInhCandidates, pageRefs, password, pdfVersion, pValue, rebuilt, remoteToLocalNamedDestinations, rootPages, rValue, sharedStreams, strings, tampered, tokens, trailer, xref
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets all the fields.Gets the field dictionary.getFieldValue
(String name) Gets the field value ornull
if the field does not exist or has no value defined.Gets the PDF file specification contained in the FDF.protected void
kidNode
(PdfDictionary merged, String name) protected void
protected void
readPdf()
Methods inherited from class com.lowagie.text.pdf.PdfReader
addPdfObject, addViewerPreference, ASCII85Decode, ASCIIHexDecode, close, computeUserPassword, consolidateNamedDestinations, convertPdfNull, createFakeFontSubsets, decodePredictor, dumpPerc, duplicatePdfDictionary, duplicatePdfObject, eliminateSharedStreams, FlateDecode, FlateDecode, getAcroFields, getAcroForm, getBoxSize, getCatalog, getCertificationLevel, getCropBox, getCryptoMode, getCryptoRef, getDecrypt, getDocumentId, getEofPos, getFileLength, getFontNameFromDescriptor, getInfo, getJavaScript, getJavaScript, getLastXref, getLinks, getMetadata, getNamedDestination, getNamedDestination, getNamedDestinationFromNames, getNamedDestinationFromNames, getNamedDestinationFromStrings, getNormalizedRectangle, getNumberOfPages, getPageContent, getPageContent, getPageN, getPageNRelease, getPageOrigRef, getPageRotation, getPageRotation, getPageSize, getPageSize, getPageSizeWithRotation, getPageSizeWithRotation, getPageSizeWithRotation, getPdfObject, getPdfObject, getPdfObject, getPdfObjectNullConverting, getPdfObjectRelease, getPdfObjectRelease, getPdfObjectRelease, getPdfObjectReleaseNullConverting, getPdfReaderInstance, getPdfVersion, getPermissions, getSafeFile, getSimpleViewerPreferences, getStreamBytes, getStreamBytes, getStreamBytesRaw, getStreamBytesRaw, getTrailer, getXrefSize, is128Key, isAppendable, isEncrypted, isFontSubset, isHybridXref, isMetadataEncrypted, isModificationlowedWithoutOwnerPassword, isNewXrefType, isOpenedWithFullPermissions, isOwnerPasswordUsed, isRebuilt, isTampered, killIndirect, killXref, LZWDecode, makeRemoteNamedDestinationsLocal, readArray, readDictionary, readDocObj, readDocObjPartial, readObjStm, readOneObjStm, readPages, readPdfPartial, readPRObject, readSingleObject, readXref, readXrefSection, readXRefStream, rebuildXref, releaseLastXrefPartial, releaseLastXrefPartial, releasePage, removeAnnotations, removeFields, removeUnusedNode, removeUnusedObjects, removeUsageRights, resetLastXrefPartial, resetReleasePage, selectPages, selectPages, setAppendable, setModificationAllowedWithoutOwnerPassword, setPageContent, setPageContent, setPermissions, setTampered, setViewerPreferences, setViewerPreferences, shuffleSubsetNames
-
Field Details
-
encoding
PdfName encoding -
fields
-
fileSpec
-
-
Constructor Details
-
FdfReader
Reads an FDF form.- Parameters:
filename
- the file name of the form- Throws:
IOException
- on error
-
FdfReader
Reads an FDF form.- Parameters:
pdfIn
- the byte array with the form- Throws:
IOException
- on error
-
FdfReader
Reads an FDF form.- Parameters:
url
- the URL of the document- Throws:
IOException
- on error
-
FdfReader
Reads an FDF form.- Parameters:
is
- theInputStream
containing the document. The stream is read to the end but is not closed- Throws:
IOException
- on error
-
-
Method Details
-
readPdf
- Overrides:
readPdf
in classPdfReader
- Throws:
IOException
-
kidNode
-
readFields
protected void readFields() -
getAllFields
Gets all the fields. The map is keyed by the fully qualified field name and the value is a mergedPdfDictionary
with the field content.- Returns:
- all the fields
-
getField
Gets the field dictionary.- Parameters:
name
- the fully qualified field name- Returns:
- the field dictionary
-
getFieldValue
Gets the field value ornull
if the field does not exist or has no value defined.- Parameters:
name
- the fully qualified field name- Returns:
- the field value or
null
-
getFileSpec
Gets the PDF file specification contained in the FDF.- Returns:
- the PDF file specification contained in the FDF
-