Class PDFXrefEntry
java.lang.Object
com.sun.pdfview.PDFXrefEntry
An entry found in a PDFFile's xref table or xref streams, identifying
the position of an object within the structure of a PDF, and the latest
generation number for a given object. May also indicate that
a given object number has been freed, and that references to objects
with that object number should be treated as references to the null
object.
-
Method Summary
Modifier and TypeMethodDescriptionintint[]intcom.sun.pdfview.PDFXrefEntry.TypegetType()booleanvoidCache a reference to the target object of this entryvoidsetObjectIndexOffsets(int[] objectIndexOffsets) For entries for object streams, set the offsets of each object in the stream, arranged by index number
-
Method Details
-
resolves
-
getOffset
public int getOffset()- Returns:
- the offset into the file for in-body references, or the index of the object within the given stream for in-stream references.
-
getStream
- Returns:
- the stream of the object for in-stream references;
nullfor other entry types
-
getType
public com.sun.pdfview.PDFXrefEntry.Type getType()- Returns:
- the type of entry
-
getGeneration
public int getGeneration()- Returns:
- the generation number of the object this entry is for
-
getObject
- Returns:
- any cached reference to the object that his entry refers to;
nullif this entry has yet to be looked at, or its target has been garbage collected
-
setObject
Cache a reference to the target object of this entry- Parameters:
obj- the object to cache
-
getObjectIndexOffsets
public int[] getObjectIndexOffsets()- Returns:
- for entries for object streams, the offsets of each object in the stream, arranged by index number
-
setObjectIndexOffsets
public void setObjectIndexOffsets(int[] objectIndexOffsets) For entries for object streams, set the offsets of each object in the stream, arranged by index number- Parameters:
objectIndexOffsets- the object index offsets
-