|
PDF Clown 0.1.2 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IBuffer
Buffer interface.
Its pivotal concept is the array index.
| Nested Class Summary | |
|---|---|
static interface |
IBuffer.IListener
Buffer listener. |
| Method Summary | |
|---|---|
void |
addListener(IBuffer.IListener listener)
Adds the specified listener. |
IBuffer |
append(byte data)
Appends a byte to the buffer. |
IBuffer |
append(byte[] data)
Appends a byte array to the buffer. |
IBuffer |
append(byte[] data,
int offset,
int length)
Appends a byte range to the buffer. |
IBuffer |
append(IInputStream data)
Appends an IInputStream to the buffer. |
IBuffer |
append(String data)
Appends a string to the buffer. |
IBuffer |
clone()
Gets a clone of the buffer. |
void |
decode(Filter filter,
PdfDictionary parameters)
Applies the specified filter to decode the buffer. |
void |
delete(int index,
int length)
Deletes a byte chunk from the buffer. |
byte[] |
encode(Filter filter,
PdfDictionary parameters)
Applies the specified filter to encode the buffer. |
int |
getByte(int index)
Gets the byte at a specified location. |
byte[] |
getByteArray(int index,
int length)
Gets the byte range beginning at a specified location. |
int |
getCapacity()
Gets the allocated buffer size. |
String |
getString(int index,
int length)
Gets the string beginning at a specified location. |
void |
insert(int index,
byte[] data)
Inserts a byte array into the buffer. |
void |
insert(int index,
byte[] data,
int offset,
int length)
Inserts a byte range into the buffer. |
void |
insert(int index,
IInputStream data)
Inserts an IInputStream into the buffer. |
void |
insert(int index,
String data)
Inserts a string into the buffer. |
boolean |
isDirty()
Gets whether this buffer has changed. |
boolean |
removeListener(IBuffer.IListener listener)
Removes the specified listener. |
void |
replace(int index,
byte[] data)
Replaces the buffer contents with a byte array. |
void |
replace(int index,
byte[] data,
int offset,
int length)
Replaces the buffer contents with a byte range. |
void |
replace(int index,
IInputStream data)
Replaces the buffer contents with an IInputStream. |
void |
replace(int index,
String data)
Replaces the buffer contents with a string. |
void |
setDirty(boolean value)
|
void |
setLength(int value)
Sets the used buffer size. |
void |
writeTo(IOutputStream stream)
Writes the buffer data to a stream. |
| Methods inherited from interface org.pdfclown.bytes.IInputStream |
|---|
getByteOrder, getPosition, hashCode, read, read, readByte, readInt, readInt, readLine, readShort, readString, readUnsignedByte, readUnsignedShort, seek, setByteOrder, setPosition, skip |
| Methods inherited from interface org.pdfclown.util.IDataWrapper |
|---|
toByteArray |
| Methods inherited from interface org.pdfclown.bytes.IOutputStream |
|---|
write, write, write, write |
| Methods inherited from interface org.pdfclown.bytes.IStream |
|---|
getLength |
| Methods inherited from interface java.io.Closeable |
|---|
close |
| Method Detail |
|---|
void addListener(IBuffer.IListener listener)
listener - Listener to add.IBuffer append(byte data)
data - Byte to copy.
IBuffer append(byte[] data)
data - Byte array to copy.
IBuffer append(byte[] data,
int offset,
int length)
data - Byte array from which the byte range has to be copied.offset - Location in the byte array at which copying begins.length - Number of bytes to copy.
IBuffer append(String data)
data - String to copy.
IBuffer append(IInputStream data)
data - Source data to copy.
IBuffer clone()
void decode(Filter filter,
PdfDictionary parameters)
filter - Filter to use for decoding the buffer.parameters - Decoding parameters.
void delete(int index,
int length)
index - Location at which deletion has to begin.length - Number of bytes to delete.
byte[] encode(Filter filter,
PdfDictionary parameters)
filter - Filter to use for encoding the buffer.parameters - Encoding parameters.
int getByte(int index)
index - A location in the buffer.
byte[] getByteArray(int index,
int length)
index - Location at which the byte range has to begin.length - Number of bytes to copy.
String getString(int index,
int length)
index - Location at which the string has to begin.length - Number of bytes to convert.
int getCapacity()
void insert(int index,
byte[] data)
index - Location at which the byte array has to be inserted.data - Byte array to insert.
void insert(int index,
byte[] data,
int offset,
int length)
index - Location at which the byte range has to be inserted.data - Byte array from which the byte range has to be copied.offset - Location in the byte array at which copying begins.length - Number of bytes to copy.
void insert(int index,
String data)
index - Location at which the string has to be inserted.data - String to insert.
void insert(int index,
IInputStream data)
index - Location at which the IInputStream has to be inserted.data - Source data to copy.boolean isDirty()
boolean removeListener(IBuffer.IListener listener)
listener - Listener to remove.
void replace(int index,
byte[] data)
index - Location at which the byte array has to be copied.data - Byte array to copy.
void replace(int index,
byte[] data,
int offset,
int length)
index - Location at which the byte range has to be copied.data - Byte array from which the byte range has to be copied.offset - Location in the byte array at which copying begins.length - Number of bytes to copy.
void replace(int index,
String data)
index - Location at which the string has to be copied.data - String to copy.
void replace(int index,
IInputStream data)
index - Location at which the IInputStream has to be copied.data - Source data to copy.void setDirty(boolean value)
isDirty()void setLength(int value)
value - New length.void writeTo(IOutputStream stream)
stream - Target stream.
|
PDF Clown 0.1.2 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||