public interface PDFContent
| Modifier and Type | Method and Description |
|---|---|
void |
append(byte[] addContent)
Append content to this PDF.
|
void |
close()
Close or release any resources that this object holds.
|
long |
length()
Get the length of the content.
|
int |
read(long position)
Set the current position of the content and read the next byte.
|
int |
read(long position,
byte[] buffer,
int offset,
int len)
Read the passed in number of bytes into a byte array.
|
void |
setBytes(byte[] content,
long position)
Modifies some of the content in the PDF content.
|
void |
writeContents(OutputStream outStream)
Write the contents to an output stream.
|
void |
writeContents(OutputStream outStream,
long start,
long length)
Write a section of the content to an output stream.
|
int read(long position)
throws IOException
position - IOExceptionint read(long position,
byte[] buffer,
int offset,
int len)
throws IOException
position - The location in the content at which to start reading.buffer - The byte array into which to insert the read bytes.offset - The offset in to the byte array at which to insert the read bytes.len - The number of bytes to read.IOExceptionlong length()
throws IOException
IOExceptionvoid writeContents(OutputStream outStream) throws IOException
outStream - IOExceptionvoid writeContents(OutputStream outStream, long start, long length) throws IOException
outStream - start - length - IOExceptionvoid setBytes(byte[] content,
long position)
throws IOException
content - The new contentposition - The position at which to update the PDF content.IOExceptionvoid append(byte[] addContent)
throws IOException
addContent - The additional content.IOExceptionvoid close()