Package com.itextpdf.text.pdf
Class PdfWriter.PdfBody.PdfCrossReference
java.lang.Object
com.itextpdf.text.pdf.PdfWriter.PdfBody.PdfCrossReference
- All Implemented Interfaces:
Comparable<PdfWriter.PdfBody.PdfCrossReference>
- Enclosing class:
- PdfWriter.PdfBody
public static class PdfWriter.PdfBody.PdfCrossReference
extends Object
implements Comparable<PdfWriter.PdfBody.PdfCrossReference>
PdfCrossReference
is an entry in the PDF Cross-Reference table.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
generation of the object.private final long
Byte offset in the PDF file.private final int
private final int
-
Constructor Summary
ConstructorsConstructorDescriptionPdfCrossReference
(int type, int refnum, long offset, int generation) PdfCrossReference
(int refnum, long offset) Constructs a cross-reference element for a PdfIndirectObject.PdfCrossReference
(int refnum, long offset, int generation) Constructs a cross-reference element for a PdfIndirectObject. -
Method Summary
Modifier and TypeMethodDescriptionint
boolean
int
int
hashCode()
void
toPdf
(int midSize, OutputStream os) Writes PDF syntax to the OutputStreamvoid
toPdf
(OutputStream os) Returns the PDF representation of thisPdfObject
.
-
Field Details
-
type
private final int type -
offset
private final long offsetByte offset in the PDF file. -
refnum
private final int refnum -
generation
private final int generationgeneration of the object.
-
-
Constructor Details
-
PdfCrossReference
public PdfCrossReference(int refnum, long offset, int generation) Constructs a cross-reference element for a PdfIndirectObject.- Parameters:
refnum
-offset
- byte offset of the objectgeneration
- generation number of the object
-
PdfCrossReference
public PdfCrossReference(int refnum, long offset) Constructs a cross-reference element for a PdfIndirectObject.- Parameters:
refnum
-offset
- byte offset of the object
-
PdfCrossReference
public PdfCrossReference(int type, int refnum, long offset, int generation)
-
-
Method Details
-
getRefnum
public int getRefnum() -
toPdf
Returns the PDF representation of thisPdfObject
.- Parameters:
os
-- Throws:
IOException
-
toPdf
Writes PDF syntax to the OutputStream- Parameters:
midSize
-os
-- Throws:
IOException
-
compareTo
- Specified by:
compareTo
in interfaceComparable<PdfWriter.PdfBody.PdfCrossReference>
- See Also:
-
equals
-
hashCode
public int hashCode()
-