public static class ByteQueue.InStream extends InputStream
| Modifier and Type | Field and Description |
|---|---|
protected ByteQueue |
byteQueue |
protected byte[] |
data |
protected long |
delay |
protected int |
pointer |
protected int |
readTimeout |
| Modifier and Type | Method and Description |
|---|---|
int |
available() |
void |
close() |
ByteQueue |
getByteQueue() |
long |
getDelay()
Указывает задержку в цикле чтения данных в нано секундах.
|
int |
getReadTimeout()
Указывает максимальное время ожидания поступления данных
|
boolean |
isClosed() |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] b) |
int |
read(byte[] b,
int off,
int len) |
protected byte[] |
readData() |
void |
setDelay(long d)
Указывает задержку в цикле чтения данных в нано секундах.
|
void |
setReadTimeout(int readTimeout)
Указывает максимальное время ожидания поступления данных
|
mark, reset, skipprotected ByteQueue byteQueue
protected byte[] data
protected int pointer
protected int readTimeout
protected long delay
public InStream(ByteQueue byteQueue)
public int getReadTimeout()
public void setReadTimeout(int readTimeout)
readTimeout - макс. время ожидания в милисекундах или -1 - бесколнечноpublic ByteQueue getByteQueue()
public int available()
throws IOException
available in class InputStreamIOExceptionpublic boolean isClosed()
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class InputStreamIOExceptionpublic boolean markSupported()
markSupported in class InputStreampublic long getDelay()
public void setDelay(long d)
d - задержкаprotected byte[] readData()
public int read(byte[] b,
int off,
int len)
throws IOException
read in class InputStreamIOExceptionpublic int read(byte[] b)
throws IOException
read in class InputStreamIOExceptionpublic int read()
throws IOException
read in class InputStreamIOExceptionCopyright © 2018. All rights reserved.