|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.io.InputStream
org.opcfoundation.ua.utils.bytebuffer.OrderedByteBufferInputStream
public class OrderedByteBufferInputStream
Input stream with a sequence of ByteBuffers as backend. ByteBuffers can be submitted in random order. Input stream sleeps until data becomes available. Sequence number determines the order of how the data becomes visible to the input stream.
| Constructor Summary | |
|---|---|
OrderedByteBufferInputStream()
Constructor for OrderedByteBufferInputStream. |
|
| Method Summary | |
|---|---|
int |
available()
|
void |
close()
close. |
void |
close(int sequenceNumber)
close. |
void |
forceClose()
forceClose. |
void |
offer(ByteBuffer buf)
Submits a byte buffer for the input stream to use |
void |
offer(int sequenceNumber,
ByteBuffer buf)
Submits a byte buffer to the use of input stream |
int |
read()
|
int |
read(byte[] b,
int off,
int len)
|
| Methods inherited from class java.io.InputStream |
|---|
mark, markSupported, read, reset, skip |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public OrderedByteBufferInputStream()
Constructor for OrderedByteBufferInputStream.
| Method Detail |
|---|
public void offer(int sequenceNumber,
ByteBuffer buf)
sequenceNumber - a int.buf - a ByteBuffer object.public void offer(ByteBuffer buf)
buf - a ByteBuffer object.public void close()
close.
close in interface Closeableclose in class InputStreampublic void close(int sequenceNumber)
close.
sequenceNumber - a int.public void forceClose()
forceClose.
public int read()
throws IOException
read in class InputStreamIOException
public int read(byte[] b,
int off,
int len)
throws IOException
read in class InputStreamIOException
public int available()
throws IOException
available in class InputStreamIOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||