-
成员变量 修饰符和类 成员变量描述 byte[]
array
The array backing the output stream.static int
DEFAULT_INITIAL_CAPACITY
The array backing the output stream.int
length
The number of valid bytes inarray
.static long
ONEOVERPHI
-
构造函数 构造函数描述 FastByteArrayOutputStream()
Creates a new array output stream with an initial capacity ofDEFAULT_INITIAL_CAPACITY
bytes.FastByteArrayOutputStream(byte[] a)
Creates a new array output stream wrapping a given byte array.FastByteArrayOutputStream(int initialCapacity)
Creates a new array output stream with a given initial capacity.
-
All Methods Static Methods Instance Methods Concrete Methods 修饰符和类 成员函数描述 static void
ensureOffsetLength(int arrayLength, int offset, int length)
static byte[]
grow(byte[] array, int length)
static byte[]
grow(byte[] array, int length, int preserve)
long
length()
long
position()
void
position(long newPosition)
FastByteArrayOutputStream
reset()
Marks this array output stream as empty.byte[]
toByteArray()
void
write(byte[] b, int off, int len)
void
write(int b)