Package com.clickhouse.client.stream
Class WrappedOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- com.clickhouse.client.ClickHouseOutputStream
-
- com.clickhouse.client.stream.AbstractByteArrayOutputStream
-
- com.clickhouse.client.stream.WrappedOutputStream
-
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
public class WrappedOutputStream extends AbstractByteArrayOutputStream
Wrapper ofOutputStream.
-
-
Field Summary
-
Fields inherited from class com.clickhouse.client.stream.AbstractByteArrayOutputStream
buffer, position
-
Fields inherited from class com.clickhouse.client.ClickHouseOutputStream
closed, ERROR_INCOMPLETE_READ, ERROR_NULL_BYTES, ERROR_REUSE_BUFFER, ERROR_STREAM_CLOSED, file, postCloseAction
-
-
Constructor Summary
Constructors Constructor Description WrappedOutputStream(ClickHouseFile file, OutputStream stream, int bufferSize, Runnable postCloseAction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidflush()protected voidflushBuffer(byte[] bytes, int offset, int length)-
Methods inherited from class com.clickhouse.client.stream.AbstractByteArrayOutputStream
flushBuffer, transferBytes, writeByte, writeBytes, writeCustom
-
Methods inherited from class com.clickhouse.client.ClickHouseOutputStream
close, empty, ensureOpen, getUnderlyingFile, isClosed, of, of, of, of, transferBytes, transferBytes, write, write, write, writeAsciiString, writeBuffer, writeBytes, writeBytes, writeString, writeUnicodeString, writeUnsignedVarInt, writeVarInt
-
Methods inherited from class java.io.OutputStream
nullOutputStream
-
-
-
-
Constructor Detail
-
WrappedOutputStream
public WrappedOutputStream(ClickHouseFile file, OutputStream stream, int bufferSize, Runnable postCloseAction)
-
-
Method Detail
-
flushBuffer
protected void flushBuffer(byte[] bytes, int offset, int length) throws IOException- Specified by:
flushBufferin classAbstractByteArrayOutputStream- Throws:
IOException
-
flush
public void flush() throws IOException- Specified by:
flushin interfaceFlushable- Overrides:
flushin classOutputStream- Throws:
IOException
-
-