Package com.itextpdf.io.source
Class ByteBuffer
- java.lang.Object
-
- com.itextpdf.io.source.ByteBuffer
-
public class ByteBuffer extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ByteBuffer()
ByteBuffer(int size)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ByteBuffer
append(byte b)
ByteBuffer
append(byte[] b)
ByteBuffer
append(byte[] b, int off, int len)
ByteBuffer
append(int b)
ByteBuffer
append(java.lang.String str)
ByteBuffer
appendHex(byte b)
int
capacity()
byte
get(int index)
static int
getHex(int v)
byte[]
getInternalBuffer()
boolean
isEmpty()
(package private) ByteBuffer
prepend(byte b)
FillByteBuffer
from the end.(package private) ByteBuffer
prepend(byte[] b)
FillByteBuffer
from the end.ByteBuffer
reset()
int
size()
boolean
startsWith(byte[] b)
byte[]
toByteArray()
byte[]
toByteArray(int off, int len)
-
-
-
Method Detail
-
getHex
public static int getHex(int v)
-
append
public ByteBuffer append(byte b)
-
append
public ByteBuffer append(byte[] b, int off, int len)
-
append
public ByteBuffer append(byte[] b)
-
append
public ByteBuffer append(int b)
-
append
public ByteBuffer append(java.lang.String str)
-
appendHex
public ByteBuffer appendHex(byte b)
-
get
public byte get(int index)
-
getInternalBuffer
public byte[] getInternalBuffer()
-
size
public int size()
-
isEmpty
public boolean isEmpty()
-
capacity
public int capacity()
-
reset
public ByteBuffer reset()
-
toByteArray
public byte[] toByteArray(int off, int len)
-
toByteArray
public byte[] toByteArray()
-
startsWith
public boolean startsWith(byte[] b)
-
prepend
ByteBuffer prepend(byte b)
FillByteBuffer
from the end. Set byte atcapacity() - size() - 1
position.- Parameters:
b
-byte
.- Returns:
ByteBuffer
.
-
prepend
ByteBuffer prepend(byte[] b)
FillByteBuffer
from the end. Set bytes fromcapacity() - size() - b.length
position.- Parameters:
b
-byte
.- Returns:
ByteBuffer
.
-
-