Package com.illumon.iris.binarystore
Class BinaryRowV2
java.lang.Object
com.illumon.iris.binarystore.BinaryRowV2
- All Implemented Interfaces:
Row
public class BinaryRowV2 extends Object implements Row
This class implements row writing for the V2 binary log format.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classBinaryRowV2.BinaryStoreRowSetter<T>classBinaryRowV2.FlagSetter -
Field Summary
Fields Modifier and Type Field Description protected ByteBufferdataBufferprotected Map<String,BinaryRowV2.BinaryStoreRowSetter>settersprotected BinaryStoreWriterV2writer -
Constructor Summary
Constructors Constructor Description BinaryRowV2(BinaryStoreWriterV2 writer, String[] columnNames, SupportedType[] columnTypes, Object[] typeMetadata) -
Method Summary
Modifier and Type Method Description StringgetColumnPartitionValue()For rows that are to be used with file managers that allow dynamic column partition selection, retrieve the column partition value.BinaryRowV2.FlagSettergetFlagSetter()RowSettergetSetter(String name)Gets a setter for a column.ByteBufferpopulateBuffer()Populate the internal data buffer with column values.voidsetColumnPartitionValue(String columnPartitionValue)For rows that are to be used with file managers that allow dynamic column partition selection, set the column partition value.voidsetFlags(Row.Flags flags)longsize()Deprecated.protected voidwriteAndReset()Write a row to the underlying stream and reset the internal buffer.voidwriteRow()Writes out a new row (values set using setters).
-
Field Details
-
Constructor Details
-
BinaryRowV2
public BinaryRowV2(BinaryStoreWriterV2 writer, String[] columnNames, SupportedType[] columnTypes, Object[] typeMetadata)
-
-
Method Details
-
getSetter
Description copied from interface:RowGets a setter for a column. -
populateBuffer
Populate the internal data buffer with column values. This assumes that all appropriate row setters have been called.- Returns:
- the data buffer just populated
- Throws:
IOException
-
writeRow
Description copied from interface:RowWrites out a new row (values set using setters).- Specified by:
writeRowin interfaceRow- Throws:
IOException- problem writing the row
-
writeAndReset
Write a row to the underlying stream and reset the internal buffer.populateBuffer()must have been previously called.- Throws:
IOException- if an error occurred during write.
-
size
Deprecated.Description copied from interface:RowNumber of rows written out. -
setFlags
-
setColumnPartitionValue
Description copied from interface:RowFor rows that are to be used with file managers that allow dynamic column partition selection, set the column partition value.- Specified by:
setColumnPartitionValuein interfaceRow- Parameters:
columnPartitionValue- the column partition value
-
getColumnPartitionValue
Description copied from interface:RowFor rows that are to be used with file managers that allow dynamic column partition selection, retrieve the column partition value.- Specified by:
getColumnPartitionValuein interfaceRow- Returns:
- the previously-set column partition value
-
getFlagSetter
-