Class ColumnarIterator.Row

java.lang.Object
org.tribuo.data.columnar.ColumnarIterator.Row
Enclosing class:
ColumnarIterator

public static class ColumnarIterator.Row extends Object
A representation of a row of untyped data from a columnar data source. In addition to its row data it stores a canonical field list and its index (from 0) in the original data source. It should be immutable once constructed. It is the responsibility of the implementor of ColumnarIterator to ensure that the passed field list is immutable.
  • Constructor Details

    • Row

      public Row(long index, List<String> fields, Map<String,String> rowData)
      Constructs a row from a columnar source.
      Parameters:
      index - The row index.
      fields - The field names, assumed to be immutable.
      rowData - The row data.
  • Method Details

    • getFields

      public List<String> getFields()
      Gets the field headers.
      Returns:
      The field headers.
    • getIndex

      public long getIndex()
      Gets the row index.
      Returns:
      The row index.
    • getRowData

      public Map<String,String> getRowData()
      Gets the row data.
      Returns:
      The row data.
    • toString

      public String toString()
      Overrides:
      toString in class Object