|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jscape.util.ByteArrayStream
public class ByteArrayStream
The byte array stream.
Constructor Summary | |
---|---|
ByteArrayStream()
Creates a new stream intance with default initial capacity. |
|
ByteArrayStream(byte[] data)
Creates a new stream intance. |
|
ByteArrayStream(int initialCapacity)
Creates a new stream intance. |
Method Summary | |
---|---|
int |
available()
Returns the stream available bytes. |
int |
read()
Reads a byte from the stream. |
int |
read(byte[] b)
Reads the stream data into specified buffer. |
int |
read(byte[] b,
int off,
int len)
Reads the stream data into specified buffer. |
void |
write(byte[] b)
Writes an array of bytes to the stream. |
void |
write(byte[] b,
int off,
int len)
Writes an array of bytes to the stream. |
void |
write(int b)
Writes one byte to the stream. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ByteArrayStream(byte[] data)
data
- the initial stream datapublic ByteArrayStream(int initialCapacity)
initialCapacity
- the initial buffer capacitypublic ByteArrayStream()
Method Detail |
---|
public int available()
public void write(int b)
b
- the byte to writepublic void write(byte[] b, int off, int len)
b
- the array to writeoff
- the array offsetlen
- the data lengthpublic void write(byte[] b)
b
- the array to writepublic int read()
public int read(byte[] b, int off, int len)
b
- the data bufferoff
- the buffer offsetlen
- the requested data length
public int read(byte[] b)
b
- the data buffer
|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |