Package com.clickhouse.client.stream
Class Lz4OutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- com.clickhouse.client.ClickHouseOutputStream
-
- com.clickhouse.client.stream.AbstractByteArrayOutputStream
-
- com.clickhouse.client.stream.Lz4OutputStream
-
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
public class Lz4OutputStream extends AbstractByteArrayOutputStream
-
-
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 Lz4OutputStream(ClickHouseFile file, OutputStream stream, int maxCompressBlockSize, Runnable postCloseAction)Lz4OutputStream(OutputStream stream, int maxCompressBlockSize, Runnable postCloseAction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidflush()protected voidflushBuffer()protected voidflushBuffer(byte[] bytes, int offset, int length)-
Methods inherited from class com.clickhouse.client.stream.AbstractByteArrayOutputStream
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
-
Lz4OutputStream
public Lz4OutputStream(OutputStream stream, int maxCompressBlockSize, Runnable postCloseAction)
-
Lz4OutputStream
public Lz4OutputStream(ClickHouseFile file, OutputStream stream, int maxCompressBlockSize, Runnable postCloseAction)
-
-
Method Detail
-
flushBuffer
protected void flushBuffer() throws IOException- Overrides:
flushBufferin classAbstractByteArrayOutputStream- Throws:
IOException
-
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
-
-