public interface IStreamThrottler
| Modifier and Type | Method and Description |
|---|---|
void |
closeStream()
Note the stream being closed.
|
boolean |
obtainReadPermission(int byteCount)
Obtain permission to read a block of bytes.
|
boolean |
obtainReadPermission(int byteCount,
IBreakCheck breakCheck)
Obtain permission to read a block of bytes.
|
void |
releaseReadPermission(int origByteCount,
int actualByteCount)
Note the completion of the read of a block of bytes.
|
static final String _rcsid
boolean obtainReadPermission(int byteCount)
throws InterruptedException
byteCount - is the number of bytes to get permissions to read.InterruptedExceptionboolean obtainReadPermission(int byteCount,
IBreakCheck breakCheck)
throws InterruptedException,
BreakException
byteCount - is the number of bytes to get permissions to read.InterruptedExceptionBreakExceptionvoid releaseReadPermission(int origByteCount,
int actualByteCount)
origByteCount - is the originally requested number of bytes to get permissions to read.actualByteCount - is the number of bytes actually read.void closeStream()