class BufferedStreamOutput : StreamOutput
The decorator of StreamOutput for buffering.
Author
Alexander Kornilov (akornilov.82@gmail.com).
<init> |
The decorator of StreamOutput for buffering. BufferedStreamOutput(stream: StreamOutput, bufferSize: Int = 4096) |
defaultByteOrder |
Default byte order of the stream. val defaultByteOrder: ByteOrder |
defaultStringEncoding |
Default string encoding of the stream. val defaultStringEncoding: StringEncoding |
isClosed |
Indicate that stream is closed. val isClosed: Boolean |
isFixedSize |
Indicates that stream has fixed size. val isFixedSize: Boolean |
isNetwork |
Indicates that stream is network based (pipe, socket etc). val isNetwork: Boolean |
isSeekable |
Indicates that position of the stream can be changed. val isSeekable: Boolean |
isSupportLimit |
Indicates that stream support validation of the limit field. val isSupportLimit: Boolean |
limit |
The limit position of the stream for read and write. If someone try to read or write out of this bound (position >= limit) the LimitOutOfBoundsException should be thrown. val limit: Long |
position |
Current position in the stream. Has negative value if seek is not supported or information about current position is not available at moment. val position: Long |
size |
Current stream size in bytes or negative value if size isn't available at moment. val size: Long |
close |
fun close(): Unit |
flush |
fun flush(): Unit |
writeByte |
Writes Byte into the stream. fun writeByte(value: Byte): Unit |
writeBytes |
Writes size bytes of buffer starting from offset into the stream. fun writeBytes(buffer: ByteArray, size: Int, offset: Int): Unit |
writeInt |
Writes value with size in bytes with specified byteOrder into the stream. The bytes should be in 1..8 range. fun writeInt(value: Long, bytes: Int, byteOrder: ByteOrder): Unit |
writeLong |
Writes value with size in bytes with specified byteOrder into the stream. fun writeLong(value: BigInteger, bytes: Int, byteOrder: ByteOrder): Unit |
writeULong |
Writes ULong with specified byteOrder into the stream. fun writeULong(value: ULong, byteOrder: ByteOrder): Unit |