Package ru.yandex.clickhouse.util
Class ClickHouseRowBinaryInputStream
- java.lang.Object
-
- ru.yandex.clickhouse.util.ClickHouseRowBinaryInputStream
-
- All Implemented Interfaces:
Closeable,AutoCloseable
public class ClickHouseRowBinaryInputStream extends Object implements Closeable
-
-
Constructor Summary
Constructors Constructor Description ClickHouseRowBinaryInputStream(InputStream is, TimeZone timeZone, ClickHouseProperties properties)ClickHouseRowBinaryInputStream(InputStream is, TimeZone timeZone, ClickHouseProperties properties, boolean hasColumnInfo)
-
Method Summary
-
-
-
Constructor Detail
-
ClickHouseRowBinaryInputStream
public ClickHouseRowBinaryInputStream(InputStream is, TimeZone timeZone, ClickHouseProperties properties) throws IOException
- Throws:
IOException
-
ClickHouseRowBinaryInputStream
public ClickHouseRowBinaryInputStream(InputStream is, TimeZone timeZone, ClickHouseProperties properties, boolean hasColumnInfo) throws IOException
- Throws:
IOException
-
-
Method Detail
-
getColumns
public List<ClickHouseColumnInfo> getColumns()
-
readUnsignedLeb128
public int readUnsignedLeb128() throws IOException- Throws:
IOException
-
readBytes
public void readBytes(byte[] bytes) throws IOException- Throws:
IOException
-
readBytes
public void readBytes(byte[] bytes, int offset, int length) throws IOException- Throws:
IOException
-
readByte
public int readByte() throws IOException- Throws:
IOException
-
readIsNull
public boolean readIsNull() throws IOException- Throws:
IOException
-
readString
public String readString() throws IOException
- Throws:
IOException
-
readFixedString
public String readFixedString(int length) throws IOException
- Throws:
IOException
-
readBoolean
public boolean readBoolean() throws IOException- Throws:
IOException
-
readUInt8
public short readUInt8() throws IOException- Throws:
IOException
-
readUInt8AsByte
public byte readUInt8AsByte() throws IOExceptionWarning: the result is negative in Java if UInt8 > 0x7f- Returns:
- next UInt8 value as a byte
- Throws:
IOException- in case if an I/O error occurs
-
readInt8
public byte readInt8() throws IOException- Throws:
IOException
-
readUInt16
public int readUInt16() throws IOException- Throws:
IOException
-
readUInt16AsShort
public short readUInt16AsShort() throws IOExceptionWarning: the result is negative in Java if UInt16 > 0x7fff- Returns:
- next UInt16 value as a short
- Throws:
IOException- in case if an I/O error occurs
-
readInt16
public short readInt16() throws IOException- Throws:
IOException
-
readUInt32
public long readUInt32() throws IOException- Throws:
IOException
-
readUInt32AsInt
public int readUInt32AsInt() throws IOExceptionWarning: the result is negative in Java if UInt32 > 0x7fffffff- Returns:
- next UInt32 value as an int
- Throws:
IOException- in case if an I/O error occurs
-
readInt32
public int readInt32() throws IOException- Throws:
IOException
-
readUInt64AsLong
public long readUInt64AsLong() throws IOExceptionWarning: the result is negative in Java if UInt64 > 0x7fffffffffffffff- Returns:
- next UInt64 value as a long
- Throws:
IOException- in case if an I/O error occurs
-
readUInt64
public BigInteger readUInt64() throws IOException
- Throws:
IOException
-
readInt64
public long readInt64() throws IOException- Throws:
IOException
-
readInt128
public BigInteger readInt128() throws IOException
- Throws:
IOException
-
writeUInt128
public BigInteger writeUInt128() throws IOException
- Throws:
IOException
-
writeInt256
public BigInteger writeInt256() throws IOException
- Throws:
IOException
-
writeUInt256
public BigInteger writeUInt256() throws IOException
- Throws:
IOException
-
readDateTime
public Timestamp readDateTime() throws IOException
- Throws:
IOException
-
readDate
public Date readDate() throws IOException
- Throws:
IOException
-
readFloat32
public float readFloat32() throws IOException- Throws:
IOException
-
readFloat64
public double readFloat64() throws IOException- Throws:
IOException
-
readDateArray
public Date[] readDateArray() throws IOException
- Throws:
IOException
-
readDateTimeArray
public Timestamp[] readDateTimeArray() throws IOException
- Throws:
IOException
-
readStringArray
public String[] readStringArray() throws IOException
- Throws:
IOException
-
readInt8Array
public byte[] readInt8Array() throws IOException- Throws:
IOException
-
readUInt8ArrayAsByte
public byte[] readUInt8ArrayAsByte() throws IOException- Throws:
IOException
-
readUInt8Array
public short[] readUInt8Array() throws IOException- Throws:
IOException
-
readInt16Array
public short[] readInt16Array() throws IOException- Throws:
IOException
-
readUInt16ArrayAsShort
public short[] readUInt16ArrayAsShort() throws IOException- Throws:
IOException
-
readUInt16Array
public int[] readUInt16Array() throws IOException- Throws:
IOException
-
readInt32Array
public int[] readInt32Array() throws IOException- Throws:
IOException
-
readUInt32ArrayAsInt
public int[] readUInt32ArrayAsInt() throws IOException- Throws:
IOException
-
readUInt32Array
public long[] readUInt32Array() throws IOException- Throws:
IOException
-
readInt64Array
public long[] readInt64Array() throws IOException- Throws:
IOException
-
readUInt64ArrayAsLong
public long[] readUInt64ArrayAsLong() throws IOException- Throws:
IOException
-
readUInt64Array
public BigInteger[] readUInt64Array() throws IOException
- Throws:
IOException
-
readFloat32Array
public float[] readFloat32Array() throws IOException- Throws:
IOException
-
readFloat64Array
public double[] readFloat64Array() throws IOException- Throws:
IOException
-
readUUID
public UUID readUUID() throws IOException
- Throws:
IOException
-
readUUIDArray
public UUID[] readUUIDArray() throws IOException
- Throws:
IOException
-
readDecimal32
public BigDecimal readDecimal32(int scale) throws IOException
- Throws:
IOException
-
readDecimal64
public BigDecimal readDecimal64(int scale) throws IOException
- Throws:
IOException
-
readDecimal128
public BigDecimal readDecimal128(int scale) throws IOException
- Throws:
IOException
-
readDecimal256
public BigDecimal readDecimal256(int scale) throws IOException
- Throws:
IOException
-
readBitmap
public ClickHouseBitmap readBitmap(ClickHouseDataType innerType) throws IOException
- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-
-