Interface Table

All Superinterfaces:
Deflatable<Table>, LivenessManager, LivenessNode, LivenessReferent, LongSizedDataStructure
All Known Subinterfaces:
DynamicTable, LazySnapshotTable, RemoteTableHandle.TableProxy, TableMapProxyHandler.TableMapProxy
All Known Implementing Classes:
AppendOnlyArrayBackedMutableTable, BaseTable, ConnectionAwareRemoteTable, DeferredViewTable, HierarchicalTable, InitialSnapshotTable, InMemoryTable, KeyedArrayBackedMutableTable, LiveQueryTable, NestedPartitionedDiskBackedTable, PartitionAwareSourceTable, PreemptiveUpdatesTable, QueryReplayGroupedTable, QueryTable, QueryTable.FilteredTable, RedefinableTable, ReplayGroupedFullTable, ReplayLastByGroupedTable, ReplayTable, ReplicatedTable, SimpleSourceTable, SourceTable, SplayedDiskBackedTable, SubscriptionSnapshotTable, TimeTable, UncoalescedTable, UpdatableTable, WrappedDelegatingTable

public interface Table extends Deflatable<Table>, LongSizedDataStructure, LivenessNode
A Deephaven table.
  • Field Details

  • Method Details

    • getDefinition

      TableDefinition getDefinition()
    • getMeta

      default Table getMeta()
      Provides column metadata in Table form. Convenience method, behaves exactly the same as getDefinition().getColumnDefinitionsTable().
      Returns:
      A Table of metadata about this Table's columns.
    • getDescription

      String getDescription()
    • hasColumns

      default boolean hasColumns(String... columnNames)
      Determines whether this Table contains a column for each string in the specified array of columnNames.
      Parameters:
      columnNames - The array of column names to be checked for inclusion in this table. Must not be null.
      Returns:
      true if this Table contains a column for each and every string in the columnNames array; false if any element of columnNames is not the name of a column in this table
    • hasColumns

      default boolean hasColumns(Collection<String> columnNames)
      Determines whether this Table contains a column for each string in the specified collection of columnNames.
      Parameters:
      columnNames - The collection of column names to be checked for inclusion in this table. Must not be null.
      Returns:
      true if this Table contains a column for each and every string in the columnNames collection; false if any element of columnNames is not the name of a column in this table
    • setAttribute

      void setAttribute(@NotNull String key, @Nullable Object object)
      Set the value of an attribute.
      Parameters:
      key - the name of the attribute
      object - the value
    • getAttribute

      @Nullable Object getAttribute(@NotNull String key)
      Get the value of the specified attribute.
      Parameters:
      key - the name of the attribute
      Returns:
      the value, or null if there was none.
    • getAttributeNames

      @NotNull Set<String> getAttributeNames()
      Get a set of all the attributes that have values for this table.
      Returns:
      a set of names
    • hasAttribute

      boolean hasAttribute(@NotNull String name)
      Check if the specified attribute exists in this table.
      Parameters:
      name - the name of the attribute
      Returns:
      true if the attribute exists
    • getAttributes

      default Map<String,Object> getAttributes()
      Get all of the attributes from the table.
      Returns:
      A map containing all of the attributes.
    • getAttributes

      Map<String,Object> getAttributes(Collection<String> excluded)
      Get all attributes from the desired table except the items that appear in excluded.
      Parameters:
      excluded - A set of attributes to exclude from the result
      Returns:
      All of the table's attributes except the ones present in excluded
    • isLive

      default boolean isLive()
    • coalesce

      default Table coalesce()
      Explicitly ensure that any work needed to make a table indexable, iterable, or queryable has been done, and return the coalesced child table if appropriate.
      Returns:
      This table, or a fully-coalesced child
    • getIndex

      Index getIndex()
    • sizeForInstrumentation

      default long sizeForInstrumentation()
    • isEmpty

      default boolean isEmpty()
      Returns true if this table has no rows (i.e. size() == 0).
      Returns:
      true if this table has no rows
    • getColumnSource

      ColumnSource getColumnSource(String sourceName)
    • getColumnSource

      default <T> ColumnSource<T> getColumnSource(String sourceName, Class<? extends T> clazz)
      Retrieves a ColumnSource and casts is to to the target class clazz.
      Type Parameters:
      T - The target type, as a type parameter. Intended to be inferred from clazz.
      Parameters:
      sourceName - The name of the column.
      clazz - The target type.
      Returns:
      The column source for sourceName, parameterized by T.
    • getColumnSourceMap

      Map<String,? extends ColumnSource> getColumnSourceMap()
    • getColumnSources

      Collection<? extends ColumnSource> getColumnSources()
    • getColumns

      default DataColumn[] getColumns()
    • getColumn

      default DataColumn getColumn(int columnIndex)
    • getColumn

      DataColumn getColumn(String columnName)
    • columnIterator

      default <TYPE> Iterator<TYPE> columnIterator(@NotNull String columnName)
    • byteColumnIterator

      default ByteColumnIterator byteColumnIterator(@NotNull String columnName)
    • characterColumnIterator

      default CharacterColumnIterator characterColumnIterator(@NotNull String columnName)
    • doubleColumnIterator

      default DoubleColumnIterator doubleColumnIterator(@NotNull String columnName)
    • floatColumnIterator

      default FloatColumnIterator floatColumnIterator(@NotNull String columnName)
    • integerColumnIterator

      default IntegerColumnIterator integerColumnIterator(@NotNull String columnName)
    • longColumnIterator

      default LongColumnIterator longColumnIterator(@NotNull String columnName)
    • shortColumnIterator

      default ShortColumnIterator shortColumnIterator(@NotNull String columnName)
    • getRecord

      Object[] getRecord(long rowNo, String... columnNames)
      Returns an object array populated with the column values at the specified rowNo. The ordering of columns in the object array is based on the columnNames array provided or by default the column ordering is based on TableDefinition.
      Parameters:
      rowNo - The row whose values are needed. This should be a value between 0 and (table.size() - 1)
      columnNames - Optional parameter of column names whose values are needed in the returned object array
    • where

      Table where(SelectFilter... filters)
    • where

      default Table where(String... filters)
    • where

      default Table where(Collection<String> filters)
    • where

      default Table where()
    • wouldMatch

      default Table wouldMatch(String... expressions)
    • wouldMatch

      Table wouldMatch(WouldMatchPair... matchers)
      A table operation that applies the supplied predicate to each row in the table and produces columns containing the pass/fail result of the predicate application. This is similar to where(String...) except that instead of selecting only rows that meet the criteria, new columns are added with the result of the comparison.
      Returns:
      a table with new columns containing the filter result for each row.
    • whereIn

      Table whereIn(Table rightTable, boolean inclusion, MatchPair... columnsToMatch)
      Filters this table based on the set of values in the rightTable. Note that when the right table ticks, all of the rows in the left table are going to be re-evaluated, thus the intention is that the right table is fairly slow moving compared with the left table.
      Parameters:
      rightTable - the filtering table.
      inclusion - whether things included in rightTable should be passed through (they are exluded if false)
      columnsToMatch - the columns to match between the two tables
      Returns:
      a new table filtered on right table
    • whereIn

      default Table whereIn(Table rightTable, boolean inclusion, String... columnsToMatch)
    • whereIn

      default Table whereIn(Table rightTable, String... columnsToMatch)
    • whereIn

      default Table whereIn(Table rightTable, MatchPair... columnsToMatch)
    • whereNotIn

      default Table whereNotIn(Table rightTable, String... columnsToMatch)
    • whereNotIn

      default Table whereNotIn(Table rightTable, MatchPair... columnsToMatch)
    • whereOneOf

      default Table whereOneOf(Collection<SelectFilter>... filtersToApply)
      Filters according to an expression in disjunctive normal form.

      The input is an array of clauses, which in turn are a collection of filters.

      Parameters:
      filtersToApply - each inner collection is a set of filters, all of must which match for the clause to be true. If any one of the collections in the array evaluates to true, the row is part of the output table.
      Returns:
      a new table, with the filters applied.
    • whereOneOf

      default Table whereOneOf(String... filtersToApplyStrings)
      Applies the provided filters to the table disjunctively.
      Parameters:
      filtersToApplyStrings - an Array of filters to apply
      Returns:
      a new table, with the filters applied
    • whereOneOf

      default Table whereOneOf()
    • getSubTable

      Table getSubTable(Index index)
    • select

      Table select(SelectColumn... columns)
    • select

      default Table select(String... columns)
    • select

      default Table select(Collection<String> columns)
    • select

      default Table select()
    • selectDistinct

      Table selectDistinct(SelectColumn... columns)
    • selectDistinct

      default Table selectDistinct(String... columns)
    • selectDistinct

      default Table selectDistinct(Collection<String> columns)
    • selectDistinct

      default Table selectDistinct()
    • update

      Table update(SelectColumn... newColumns)
    • update

      default Table update(String... newColumns)
    • update

      default Table update(Collection<String> newColumns)
    • validateSelect

      @InternalUseOnly default SelectValidationResult validateSelect(String... columns)
      DO NOT USE -- this API is in flux and may change or disappear in the future.
    • validateSelect

      DO NOT USE -- this API is in flux and may change or disappear in the future.
    • lazyUpdate

      Table lazyUpdate(SelectColumn... newColumns)
      Compute column formulas on demand.

      Lazy update defers computation until required for a set of values, and caches the results for a set of input values. This uses less RAM than an update statement when you have a smaller set of unique values. Less computation than an updateView is needed, because the results are saved in a cache.

      If you have many unique values, you should instead use an update statement, which will have more memory efficient structures. Values are never removed from the lazyUpdate cache, so it should be used judiciously on a ticking table.

      Parameters:
      newColumns - the columns to add
      Returns:
      a new Table with the columns added; to be computed on demand
    • lazyUpdate

      default Table lazyUpdate(String... newColumns)
    • lazyUpdate

      default Table lazyUpdate(Collection<String> newColumns)
    • view

      Table view(SelectColumn... columns)
    • view

      default Table view(String... columns)
    • view

      default Table view(Collection<String> columns)
    • updateView

      Table updateView(SelectColumn... newColumns)
    • updateView

      default Table updateView(String... newColumns)
    • updateView

      default Table updateView(Collection<String> newColumns)
    • dropColumns

      Table dropColumns(String... columnNames)
    • dropColumnFormats

      default Table dropColumnFormats()
    • dropColumns

      default Table dropColumns(Collection<String> columnNames)
    • renameColumns

      Table renameColumns(MatchPair... pairs)
    • renameColumns

      default Table renameColumns(String... columns)
    • renameColumns

      default Table renameColumns(Collection<String> columns)
    • renameAllColumns

      default Table renameAllColumns(Table.RenameFunction renameFunction)
    • moveUpColumns

      default Table moveUpColumns(String... columnsToMove)
      Produce a new table with the specified columns moved to the leftmost position. Columns can be renamed with the usual syntax, i.e. "NewColumnName=OldColumnName").
      Parameters:
      columnsToMove - The columns to move to the left (and, optionally, to rename)
      Returns:
      The new table, with the columns rearranged as explained above moveColumns(int, String...)
    • moveDownColumns

      default Table moveDownColumns(String... columnsToMove)
      Produce a new table with the specified columns moved to the rightmost position. Columns can be renamed with the usual syntax, i.e. "NewColumnName=OldColumnName").
      Parameters:
      columnsToMove - The columns to move to the right (and, optionally, to rename)
      Returns:
      The new table, with the columns rearranged as explained above moveColumns(int, String...)
    • moveColumns

      default Table moveColumns(int index, String... columnsToMove)
      Produce a new table with the specified columns moved to the specified index. Column indices begin at 0. Columns can be renamed with the usual syntax, i.e. "NewColumnName=OldColumnName").
      Parameters:
      index - The index to which the specified columns should be moved
      columnsToMove - The columns to move to the specified index (and, optionally, to rename)
      Returns:
      The new table, with the columns rearranged as explained above
    • moveColumns

      default Table moveColumns(int index, boolean moveToEnd, String... columnsToMove)
    • formatColumns

      default Table formatColumns(String... columnFormats)
    • formatRowWhere

      default Table formatRowWhere(String condition, String formula)
    • formatColumnWhere

      default Table formatColumnWhere(String columnName, String condition, String formula)
    • dateTimeColumnAsNanos

      default Table dateTimeColumnAsNanos(String dateTimeColumnName, String nanosColumnName)
      Produce a new table with the same columns as this table, but with a new column presenting the specified DBDateTime column as a Long column (with each DBDateTime represented instead as the corresponding number of nanos since the epoch).

      NOTE: This is a really just an updateView(), and behaves accordingly for column ordering and (re)placement. This doesn't work on data that has been brought fully into memory (e.g. via select()). Use a view instead.

      Parameters:
      dateTimeColumnName -
      nanosColumnName -
      Returns:
      The new table, constructed as explained above.
    • dateTimeColumnAsNanos

      default Table dateTimeColumnAsNanos(String columnName)
      Parameters:
      columnName -
      Returns:
      The result of dateTimeColumnAsNanos(columnName, columnName).
    • head

      Table head(long size)
    • tail

      Table tail(long size)
    • slice

      Table slice(long firstPositionInclusive, long lastPositionExclusive)
      Extracts a subset of a table by row position. If both firstPosition and lastPosition are positive, then the rows are counted from the beginning of the table. The firstPosition is inclusive, and the lastPosition is exclusive. The head(long)(N) call is equivalent to slice(0, N). The firstPosition must be less than or equal to the lastPosition. If firstPosition is positive and lastPosition is negative, then the firstRow is counted from the beginning of the table, inclusively. The lastPosition is counted from the end of the table. For example, slice(1, -1) includes all rows but the first and last. If the lastPosition would be before the firstRow, the result is an emptyTable. If firstPosition is negative, and lastPosition is zero, then the firstRow is counted from the end of the table, and the end of the slice is the size of the table. slice(-N, 0) is equivalent to tail(long)(N). If the firstPosition is nega tive and the lastPosition is negative, they are both counted from the end of the table. For example, slice(-2, -1) returns the second to last row of the table.
      Parameters:
      firstPositionInclusive - the first position to include in the result
      lastPositionExclusive - the last position to include in the result
      Returns:
      a new Table, which is the request subset of rows from the original table
    • headPct

      Table headPct(double percent)
      Provides a head that selects a dynamic number of rows based on a percent.
      Parameters:
      percent - the fraction of the table to return (0..1), the number of rows will be rounded up. For example if there are 3 rows, headPct(50) returns the first two rows.
    • tailPct

      Table tailPct(double percent)
    • leftJoin

      Table leftJoin(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - An array of match pair conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - An array of the columns from the right side be added to the left side as a result of the match. If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • leftJoin

      default Table leftJoin(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      When columnsToMatch is empty, then all rows of the right table are joined to all rows of the left table.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A collections with the columns from the right side to be added to the left side as a result of the match. The column may be optionally renamed with "NewName=NameInRight". If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • leftJoin

      default Table leftJoin(Table rightTable, Collection<String> columnsToMatch)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      When columnsToMatch is empty, then all rows of the right table are joined to all rows of the left table.

      All columns from the right are added to the result without renames.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • leftJoin

      default Table leftJoin(Table rightTable, String columnsToMatch, String columnsToAdd)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      When columnsToMatch is empty, then all rows of the right table are joined to all rows of the left table.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the right side that need to be added to the left side as a result of the match. The column may be optionally renamed with "NewName=NameInRight". If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • leftJoin

      default Table leftJoin(Table rightTable, String columnsToMatch)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      When columnsToMatch is empty, then all rows of the right table are joined to all rows of the left table.

      All columns from the right are added to the result without renames.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • leftJoin

      default Table leftJoin(Table rightTable)
      Augments this table with array columns of right-hand side matches.

      The leftJoin() method returns the exact rows of the leftTable. The data joined in from the rightTable are grouped into arrays of data. When no right-hand side data is found, the right hand columns are null.

      All rows and columns of the right table are joined to all rows of the left table.

      Parameters:
      rightTable - The right side table on the join.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • exactJoin

      Table exactJoin(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Identical to naturalJoin, but fail if the right side does not produce a match.
    • exactJoin

      default Table exactJoin(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Identical to naturalJoin, but fail if the right side does not produce a match.
    • exactJoin

      default Table exactJoin(Table rightTable, Collection<String> columnsToMatch)
      Identical to naturalJoin, but fail if the right side does not produce a match.
    • exactJoin

      default Table exactJoin(Table rightTable, String columnsToMatch, String columnsToAdd)
      Identical to naturalJoin, but fail if the right side does not produce a match.
    • exactJoin

      default Table exactJoin(Table rightTable, String columnsToMatch)
      Identical to naturalJoin, but fail if the right side does not produce a match.
    • aj

      Table aj(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd, Table.AsOfMatchRule asOfMatchRule)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • aj

      default Table aj(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • aj

      default Table aj(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • aj

      default Table aj(Table rightTable, Collection<String> columnsToMatch)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with all the columns from rightTable.
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • aj

      default Table aj(Table rightTable, String columnsToMatch, String columnsToAdd)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • aj

      default Table aj(Table rightTable, String columnsToMatch)
      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with all the columns from rightTable.
      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      Table raj(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd, Table.AsOfMatchRule asOfMatchRule)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      default Table raj(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      default Table raj(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      default Table raj(Table rightTable, Collection<String> columnsToMatch)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the all columns from rightTable.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      default Table raj(Table rightTable, String columnsToMatch, String columnsToAdd)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the columns from rightTable defined in a comma separated list "columnsToAdd"

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the left side that need to be added to the right side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • raj

      default Table raj(Table rightTable, String columnsToMatch)
      Just like .aj(), but the matching on the last column is in reverse order, so that you find the row after the given timestamp instead of the row before.

      Looks up the columns in the rightTable that meet the match conditions in the columnsToMatch list. Matching is done exactly for the first n-1 columns and via a binary search for the last match pair. The columns of the original table are returned intact, together with the all columns from rightTable.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • naturalJoin

      Table naturalJoin(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Augment this table with zero or one row from the right table.

      The result is somewhat like an Excel vlookup or SQL leftJoin.

      • The leftTable always retains the same number of rows and the same columns with which it started.
      • If there are no matching values for a row, the appended cell(s) from the rightTable will contain NULL values.
      • The right side table can only have one row for each key of the join. If duplicate rows exist on the right side, then the operation's initialization or update results in an error.

      When columnsToMatch is empty, then no join keys are used. If there is a row in the right table, it is joined to all rows of the left table. If there are no rows in the right table, then the right columns are null. If there are multiple rows in the right table then there is an error.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - An array of match pair conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - An array of the columns from the right side be added to the left side as a result of the match. If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • naturalJoin

      default Table naturalJoin(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Augment this table with zero or one row from the right table.

      The result is somewhat like an Excel vlookup or SQL leftJoin.

      • The leftTable always retains the same number of rows and the same columns with which it started.
      • If there are no matching values for a row, the appended cell(s) from the rightTable will contain NULL values.
      • The right side table can only have one row for each key of the join. If duplicate rows exist on the right side, then the operation's initialization or update results in an error.

      When columnsToMatch is empty, then no join keys are used. If there is a row in the right table, it is joined to all rows of the left table. If there are no rows in the right table, then the right columns are null. If there are multiple rows in the right table then there is an error.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A collection of the columns from the right side that need to be added to the left side as a result of the match. The column may be optionally renamed with "NewName=NameInRight". If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • naturalJoin

      default Table naturalJoin(Table rightTable, Collection<String> columnsToMatch)
      Augment this table with zero or one row from the right table.

      The result is somewhat like an Excel vlookup or SQL leftJoin.

      • The leftTable always retains the same number of rows and the same columns with which it started.
      • If there are no matching values for a row, the appended cell(s) from the rightTable will contain NULL values.
      • The right side table can only have one row for each key of the join. If duplicate rows exist on the right side, then the operation's initialization or update results in an error.

      When columnsToMatch is empty, then no join keys are used. If there is a row in the right table, it is joined to all rows of the left table. If there are no rows in the right table, then the right columns are null. If there are multiple rows in the right table then there is an error.

      All columns from the right are added to the result without renames.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • naturalJoin

      default Table naturalJoin(Table rightTable, String columnsToMatch, String columnsToAdd)
      Augment this table with zero or one row from the right table.

      The result is somewhat like an Excel vlookup or SQL leftJoin.

      • The leftTable always retains the same number of rows and the same columns with which it started.
      • If there are no matching values for a row, the appended cell(s) from the rightTable will contain NULL values.
      • The right side table can only have one row for each key of the join. If duplicate rows exist on the right side, then the operation's initialization or update results in an error.

      When columnsToMatch is empty, then no join keys are used. If there is a row in the right table, it is joined to all rows of the left table. If there are no rows in the right table, then the right columns are null. If there are multiple rows in the right table then there is an error.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the right side that need to be added to the left side as a result of the match. The column may be optionally renamed with "NewName=NameInRight". If empty, then all columns from the right table are added to the result.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • naturalJoin

      default Table naturalJoin(Table rightTable, String columnsToMatch)
      Augment this table with zero or one row from the right table.

      The result is somewhat like an Excel vlookup or SQL leftJoin.

      • The leftTable always retains the same number of rows and the same columns with which it started.
      • If there are no matching values for a row, the appended cell(s) from the rightTable will contain NULL values.
      • The right side table can only have one row for each key of the join. If duplicate rows exist on the right side, then the operation's initialization or update results in an error.

      When columnsToMatch is empty, then no join keys are used. If there is a row in the right table, it is joined to all rows of the left table. If there are no rows in the right table, then the right columns are null. If there are multiple rows in the right table then there is an error.

      All columns from the right are added to the result without renames.

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth").
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      default Table join(Table rightTable)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns. The rows are ordered first by the left table then by the right table.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      Returns:
      a new table joined according to the specification with zero key-columns and includes all right columns
    • join

      default Table join(Table rightTable, int numRightBitsToReserve)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns. The rows are ordered first by the left table then by the right table.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      numRightBitsToReserve - The number of bits to reserve for rightTable groups.
      Returns:
      a new table joined according to the specification with zero key-columns and includes all right columns
    • join

      default Table join(Table rightTable, String columnsToMatch)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are not key-columns. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      Returns:
      a new table joined according to the specification in columnsToMatch and includes all non-key-columns from the right table
    • join

      default Table join(Table rightTable, String columnsToMatch, int numRightBitsToReserve)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are not key-columns. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      numRightBitsToReserve - The number of bits to reserve for rightTable groups.
      Returns:
      a new table joined according to the specification in columnsToMatch and includes all non-key-columns from the right table
    • join

      default Table join(Table rightTable, String columnsToMatch, String columnsToAdd)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the right side that need to be added to the left side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      default Table join(Table rightTable, String columnsToMatch, String columnsToAdd, int numRightBitsToReserve)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A comma separated list of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A comma separated list with the columns from the right side that need to be added to the left side as a result of the match.
      numRightBitsToReserve - The number of bits to reserve for rightTable groups.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      default Table join(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A collection of the columns from the right side that need to be added to the left side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      default Table join(Table rightTable, Collection<String> columnsToMatch, Collection<String> columnsToAdd, int numRightBitsToReserve)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - A collection of match conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - A collection of the columns from the right side that need to be added to the left side as a result of the match.
      numRightBitsToReserve - The number of bits to reserve for rightTable groups.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      default Table join(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - An array of match pair conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - An array of the columns from the right side that need to be added to the left side as a result of the match.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • join

      Table join(Table rightTable, MatchPair[] columnsToMatch, MatchPair[] columnsToAdd, int numRightBitsToReserve)
      Perform a cross join with the right table.

      Returns a table that is the cartesian product of left rows X right rows, with one column for each of the left table's columns, and one column corresponding to each of the right table's columns that are included in the columnsToAdd argument. The rows are ordered first by the left table then by the right table. If columnsToMatch is non-empty then the product is filtered by the supplied match conditions.

      To efficiently produce updates, the bits that represent a key for a given row are split into two. Unless specified, join reserves 16 bits to represent a right row. When there are too few bits to represent all of the right rows for a given aggregation group the table will shift a bit from the left side to the right side. The default of 16 bits was carefully chosen because it results in an efficient implementation to process live updates.

      An OutOfKeySpaceException is thrown when the total number of bits needed to express the result table exceeds that needed to represent Long.MAX_VALUE. There are a few work arounds: - If the left table is sparse, consider flattening the left table. - If there are no key-columns and the right table is sparse, consider flattening the right table. - If the maximum size of a right table's group is small, you can reserve fewer bits by setting numRightBitsToReserve on initialization.

      Note: If you can prove that a given group has at most one right-row then you should prefer using naturalJoin(com.illumon.iris.db.tables.Table, com.illumon.iris.db.tables.select.MatchPair[], com.illumon.iris.db.tables.select.MatchPair[]).

      Parameters:
      rightTable - The right side table on the join.
      columnsToMatch - An array of match pair conditions ("leftColumn=rightColumn" or "columnFoundInBoth")
      columnsToAdd - An array of the columns from the right side that need to be added to the left side as a result of the match.
      numRightBitsToReserve - The number of bits to reserve for rightTable groups.
      Returns:
      a new table joined according to the specification in columnsToMatch and columnsToAdd
    • by

      Table by(AggregationStateFactory aggregationStateFactory, SelectColumn... groupByColumns)
    • by

      default Table by(AggregationStateFactory aggregationStateFactory, String... groupByColumns)
    • by

      default Table by(AggregationStateFactory aggregationStateFactory)
    • by

      default Table by(SelectColumn... groupByColumns)
    • by

      default Table by(String... groupByColumns)
    • by

      default Table by(Collection<String> groupByColumns)
    • by

      default Table by()
    • headBy

      default Table headBy(long nRows, SelectColumn... groupByColumns)
    • headBy

      Table headBy(long nRows, String... groupByColumns)
    • headBy

      default Table headBy(long nRows, Collection<String> groupByColumns)
    • tailBy

      default Table tailBy(long nRows, SelectColumn... groupByColumns)
    • tailBy

      Table tailBy(long nRows, String... groupByColumns)
    • tailBy

      default Table tailBy(long nRows, Collection<String> groupByColumns)
    • applyToAllBy

      Table applyToAllBy(String formulaColumn, String columnParamName, SelectColumn... groupByColumns)
      Groups data according to groupByColumns and applies formulaColumn to each of columns not altered by the grouping operation. columnParamName is used as place-holder for the name of each column inside formulaColumn.
      Parameters:
      formulaColumn - Formula applied to each column
      columnParamName - The parameter name used as a placeholder for each column
      groupByColumns - The grouping columns by(SelectColumn[])
    • applyToAllBy

      default Table applyToAllBy(String formulaColumn, SelectColumn... groupByColumns)
      Groups data according to groupByColumns and applies formulaColumn to each of columns not altered by the grouping operation.
      Parameters:
      formulaColumn - Formula applied to each column, uses parameter each to refer to each colum it being applied to
      groupByColumns - The grouping columns by(SelectColumn...)
    • applyToAllBy

      default Table applyToAllBy(String formulaColumn, String... groupByColumns)
      Groups data according to groupByColumns and applies formulaColumn to each of columns not altered by the grouping operation.
      Parameters:
      formulaColumn - Formula applied to each column, uses parameter each to refer to each colum it being applied to
      groupByColumns - The grouping columns by(String...)
    • applyToAllBy

      default Table applyToAllBy(String formulaColumn, String groupByColumn)
    • sumBy

      Table sumBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the sum for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • sumBy

      default Table sumBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the sum for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • sumBy

      default Table sumBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the sum for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • sumBy

      default Table sumBy()
      Produces a single row table with the sum of each column. When the input table is empty, zero output rows are produced.
    • absSumBy

      Table absSumBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the sum of the absolute values for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • absSumBy

      default Table absSumBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the sum of the absolute values for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • absSumBy

      default Table absSumBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the sum of the absolute values for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • absSumBy

      default Table absSumBy()
      Produces a single row table with the absolute sum of each column. When the input table is empty, zero output rows are produced.
    • avgBy

      Table avgBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the average for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • avgBy

      default Table avgBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the average for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • avgBy

      default Table avgBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the average for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • avgBy

      default Table avgBy()
      Produces a single row table with the average of each column. When the input table is empty, zero output rows are produced.
    • wavgBy

      Table wavgBy(String weightColumn, SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted average using weightColumn for the rest of the fields
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • wavgBy

      default Table wavgBy(String weightColumn, String... groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted average using weightColumn for the rest of the fields
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • wavgBy

      default Table wavgBy(String weightColumn, Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted average using weightColumn for the rest of the fields
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • wavgBy

      default Table wavgBy(String weightColumn)
      Produces a single row table with the weighted average using weightColumn for the rest of the fields When the input table is empty, zero output rows are produced.
      Parameters:
      weightColumn - the column to use for the weight
    • wsumBy

      Table wsumBy(String weightColumn, SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted sum using weightColumn for the rest of the fields If the weight column is a floating point type, all result columns will be doubles. If the weight column is an integral type, all integral input columns will have long results and all floating point input columns will have double results.
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • wsumBy

      default Table wsumBy(String weightColumn)
      Computes the weighted sum for all rows in the table using weightColumn for the rest of the fields If the weight column is a floating point type, all result columns will be doubles. If the weight column is an integral type, all integral input columns will have long results and all floating point input columns will have double results.
      Parameters:
      weightColumn - the column to use for the weight
    • wsumBy

      default Table wsumBy(String weightColumn, String... groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted sum using weightColumn for the rest of the fields If the weight column is a floating point type, all result columns will be doubles. If the weight column is an integral type, all integral input columns will have long results and all floating point input columns will have double results.
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • wsumBy

      default Table wsumBy(String weightColumn, Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the weighted sum using weightColumn for the rest of the fields If the weight column is a floating point type, all result columns will be doubles. If the weight column is an integral type, all integral input columns will have long results and all floating point input columns will have double results.
      Parameters:
      weightColumn - the column to use for the weight
      groupByColumns - The grouping columns by(String...)
    • stdBy

      Table stdBy(SelectColumn... groupByColumns)
    • stdBy

      default Table stdBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the standard deviation for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • stdBy

      default Table stdBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the standard deviation for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • stdBy

      default Table stdBy()
      Produces a single row table with the standard deviation of each column. When the input table is empty, zero output rows are produced.
    • varBy

      Table varBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the variance for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • varBy

      default Table varBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the variance for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • varBy

      default Table varBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the variance for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • varBy

      default Table varBy()
      Produces a single row table with the variance of each column. When the input table is empty, zero output rows are produced.
    • lastBy

      Table lastBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and retrieves the last for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • lastBy

      default Table lastBy(String... groupByColumns)
      Groups the data column according to groupByColumns and retrieves the last for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • lastBy

      default Table lastBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and retrieves the last for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • lastBy

      default Table lastBy()
      Returns the last row of the given table.
    • firstBy

      Table firstBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and retrieves the first for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • firstBy

      default Table firstBy(String... groupByColumns)
      Groups the data column according to groupByColumns and retrieves the first for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • firstBy

      default Table firstBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and retrieves the first for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • firstBy

      default Table firstBy()
      Returns the first row of the given table.
    • minBy

      Table minBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the min for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • minBy

      default Table minBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the min for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • minBy

      default Table minBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the min for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...)
    • minBy

      default Table minBy()
      Produces a single row table with the minimum of each column. When the input table is empty, zero output rows are produced.
    • maxBy

      Table maxBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the max for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • maxBy

      default Table maxBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the max for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • maxBy

      default Table maxBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the max for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • maxBy

      default Table maxBy()
      Produces a single row table with the maximum of each column. When the input table is empty, zero output rows are produced.
    • medianBy

      Table medianBy(SelectColumn... groupByColumns)
      Groups the data column according to groupByColumns and computes the median for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • medianBy

      default Table medianBy(String... groupByColumns)
      Groups the data column according to groupByColumns and computes the median for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • medianBy

      default Table medianBy(Collection<String> groupByColumns)
      Groups the data column according to groupByColumns and computes the median for the rest of the fields
      Parameters:
      groupByColumns - The grouping columns by(String...) }
    • medianBy

      default Table medianBy()
      Produces a single row table with the median of each column. When the input table is empty, zero output rows are produced.
    • countBy

      Table countBy(String countColumnName, SelectColumn... groupByColumns)
    • countBy

      default Table countBy(String countColumnName, String... groupByColumns)
    • countBy

      default Table countBy(String countColumnName, Collection<String> groupByColumns)
    • countBy

      default Table countBy(String countColumnName)
    • ungroup

      Table ungroup(boolean nullFill, String... columnsToUngroup)
      Ungroups a table by converting arrays into columns.
      Parameters:
      nullFill - indicates if the ungrouped table should allow disparate sized arrays filling shorter columns with null values. If set to false, then all arrays should be the same length.
      columnsToUngroup - the columns to ungroup
      Returns:
      the ungrouped table
    • ungroup

      default Table ungroup(String... columnsToUngroup)
    • ungroupAllBut

      default Table ungroupAllBut(String... columnsNotToUngroup)
    • ungroup

      default Table ungroup()
    • ungroup

      default Table ungroup(boolean nullFill)
    • byExternal

      TableMap byExternal(boolean dropKeys, String... keyColumnNames)
      Create a TableMap from this table, keyed by the specified columns.

      The returned TableMap contains each row in this table in exactly one of the tables within the map. If you have exactly one key column the TableMap is keyed by the value in that column. If you have zero key columns, then the TableMap is keyed by com.fishlib.datastructures.util.SmartKey.EMPTY (and will contain this table as the value). If you have multiple key columns, then the TableMap is keyed by a com.fishlib.datastructures.util.SmartKey. The SmartKey will have one value for each of your column values, in the order specified by keyColumnNames.

      For example if you have a Table keyed by a String column named USym, and a DBDateTime column named Expiry; a value could be retrieved from the TableMap with tableMap.get(new SmartKey("SPY";, DBTimeUtils.convertDateTime("2020-06-19T16:15:00 NY"))). For a table with an Integer column named Bucket, you simply use the desired value as in tableMap.get(1).

      Parameters:
      dropKeys - if true, drop key columns in the output Tables
      keyColumnNames - the name of the key columns to use.
      Returns:
      a TableMap keyed by keyColumnNames
    • byExternal

      default TableMap byExternal(String... keyColumnNames)
      Create a TableMap from this table, keyed by the specified columns.

      The returned TableMap contains each row in this table in exactly one of the tables within the map. If you have exactly one key column the TableMap is keyed by the value in that column. If you have zero key columns, then the TableMap is keyed by com.fishlib.datastructures.util.SmartKey.EMPTY (and will contain this table as the value). If you have multiple key columns, then the TableMap is keyed by a com.fishlib.datastructures.util.SmartKey. The SmartKey will have one value for each of your column values, in the order specified by keyColumnNames.

      For example if you have a Table keyed by a String column named USym, and a DBDateTime column named Expiry; a value could be retrieved from the TableMap with tableMap.get(new SmartKey("SPY";, DBTimeUtils.convertDateTime("2020-06-19T16:15:00 NY"))). For a table with an Integer column named Bucket, you simply use the desired value as in tableMap.get(1).

      Parameters:
      keyColumnNames - the name of the key columns to use.
      Returns:
      a TableMap keyed by keyColumnNames
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, Collection<String> columns)
      Create a rollup table. A rollup table aggregates by the specified columns, and then creates a hierarchical table which re-aggregates using one less aggregation column on each level. The column that is no longer part of the aggregation key is replaced with null on each level.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      columns - the columns to group by
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, boolean includeConstituents, Collection<String> columns)
      Create a rollup table. A rollup table aggregates by the specified columns, and then creates a hierarchical table which re-aggregates using one less aggregation column on each level. The column that is no longer part of the aggregation key is replaced with null on each level.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      includeConstituents - set to true to include the constituent rows at the leaf level
      columns - the columns to group by
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, String... columns)
      Create a rollup table. A rollup table aggregates by the specified columns, and then creates a hierarchical table which re-aggregates using one less aggregation column on each level. The column that is no longer part of the aggregation key is replaced with null on each level.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      columns - the columns to group by
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, boolean includeConstituents, String... columns)
      Create a rollup table. A rollup table aggregates by the specified columns, and then creates a hierarchical table which re-aggregates using one less aggregation column on each level. The column that is no longer part of the aggregation key is replaced with null on each level.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      columns - the columns to group by
      includeConstituents - set to true to include the constituent rows at the leaf level
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, SelectColumn... columns)
      Create a rollup table. A rollup table aggregates by the specified columns, and then creates a hierarchical table which re-aggregates using one less aggregation column on each level. The column that is no longer part of the aggregation key is replaced with null on each level.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      columns - the columns to group by
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory)
      Create a rollup table. A rollup table aggregates all rows of the table.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      default HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, boolean includeConstituents)
      Create a rollup table. A rollup table aggregates all rows of the table.
      Parameters:
      comboAggregateFactory - the ComboAggregateFactory describing the aggregation
      includeConstituents - set to true to include the constituent rows at the leaf level
      Returns:
      a hierarchical table with the rollup applied
    • rollup

      HierarchicalTable rollup(ComboAggregateFactory comboAggregateFactory, boolean includeConstituents, SelectColumn... columns)
    • treeTable

      HierarchicalTable treeTable(String idColumn, String parentColumn)
      Create a hierarchical tree table. The structure of the table is encoded by an "id" and a "parent" column. The id column should represent a unique identifier for a given row, and the parent column indicates which row is the parent for a given row. Rows that have a null parent, are shown in the main table. It is possible for rows to be "orphaned", if their parent reference is non-null and does not exist in the table.
      Parameters:
      idColumn - the name of a column containing a unique identifier for a particular row in the table
      parentColumn - the name of a column containing the parent's identifier, null for elements that are part of the root table
      Returns:
      a hierarchical table grouped according to the parentColumn
    • updateBy

      Table updateBy(@NotNull UpdateByControl control, @NotNull Collection<UpdateByClause> operations, MatchPair... byColumns)

      Create a table with the same index as it's parent that will perform the specified set of row based operations to it. As opposed to update(String...) these operations are more restricted but are capable of processing state between rows. This operation will group the table by the specified set of keys if provided before applying the operation.

      Parameters:
      operations - the operations to apply to the table.
      byColumns - the columns to group by before applying.
      Returns:
      a table with the same index, with the specified operations applied to each group defined by the byColumns
    • updateBy

      @FinalDefault default Table updateBy(@NotNull Collection<UpdateByClause> operations, String... byColumns)

      Create a table with the same index as it's parent that will perform the specified set of row based operations to it. As opposed to update(String...) these operations are more restricted but are capable of processing state between rows.This operation will group the table by the specified set of keys if provided

      Parameters:
      operations - the operations to apply to the table.
      byColumns - the columns to group by before applying.
      Returns:
      a table with the same index, with the specified operations applied to each group defined by the byColumns
    • updateBy

      @FinalDefault default Table updateBy(@NotNull Collection<UpdateByClause> operations)

      Create a table with the same index as it's parent that will perform the specified set of row based operations to it. As opposed to update(String...) these operations are more restricted but are capable of processing state between rows.

      Parameters:
      operations - the operations to apply to the table.
      Returns:
      a table with the same index, with the specified operations applied to the entire table.
    • updateBy

      @FinalDefault default Table updateBy(@NotNull UpdateByClause operation, MatchPair... byColumns)

      Create a table with the same index as it's parent that will perform the specified row based operation to it. This operation will additionally group the table by a set of keys before applying the operation.

      Parameters:
      operation - the operation to apply to the table.
      byColumns - the columns to group by before applying.
      Returns:
      a table with the same index, with the specified operations applied to each group defined by the byColumns
    • updateBy

      @FinalDefault default Table updateBy(@NotNull UpdateByClause operation, String... byColumns)

      Create a table with the same index as it's parent that will perform the specified row based operation to it. This operation will additionally group the table by a set of keys before applying the operation.

      Parameters:
      operation - the operation to apply to the table.
      byColumns - the columns to group by before applying.
      Returns:
      a table with the same index, with the specified operations applied to each group defined by the byColumns
    • updateBy

      @FinalDefault default Table updateBy(@NotNull UpdateByClause operation)

      Create a table with the same index as it's parent that will perform the specified set of row based operation to it.

      Parameters:
      operation - the operation to apply to the table.
      Returns:
      a table with the same index, with the specified operations applied to the entire table
    • sort

      Table sort(SortPair... sortPairs)
    • sort

      default Table sort(String... columnsToSortBy)
    • sort

      default Table sort(List<String> columnsToSortBy)
    • sortDescending

      default Table sortDescending(String... columnsToSortBy)
    • sortDescending

      default Table sortDescending(List<String> columnsToSortBy)
    • reverse

      Table reverse()
    • restrictSortTo

      Table restrictSortTo(String... allowedSortingColumns)

      Disallow sorting on all but the specified columns.

      Parameters:
      allowedSortingColumns - The columns on which sorting is allowed.
      Returns:
      The same table this was invoked on.
    • clearSortingRestrictions

      Table clearSortingRestrictions()

      Clear all sorting restrictions that was applied to the current table.

      Note that this table operates on the table it was invoked on and does not create a new table. So in the following code T1 = baseTable.where(...) T2 = T1.restrictSortTo("C1") T3 = T2.clearSortingRestrictions() T1 == T2 == T3 and the result has no restrictions on sorting.

      Returns:
      The same table this was invoked on.
    • snapshot

      Table snapshot(Table rightTable, boolean doInitialSnapshot, String... stampColumns)
      Snapshot "rightTable", triggered by "this" Table, and return a new Table as a result. "this" Table is the triggering table, i.e. the table whose change events cause a new snapshot to be taken. The result table includes a "snapshot key" which is a subset (possibly all) of this Table's columns. The remaining columns in the result table come from "rightTable", the table being snapshotted.
      Parameters:
      rightTable - The table to be snapshotted
      doInitialSnapshot - Take the first snapshot now (otherwise wait for a change event)
      stampColumns - The columns forming the "snapshot key", i.e. some subset of this Table's columns to be included in the result at snapshot time. As a special case, an empty stampColumns is taken to mean "include all columns".
      Returns:
      The result table
    • snapshot

      default Table snapshot(Table rightTable, String... stampColumns)
    • snapshotIncremental

      Table snapshotIncremental(Table rightTable, boolean doInitialSnapshot, String... stampColumns)
    • snapshotIncremental

      default Table snapshotIncremental(Table rightTable, String... stampColumns)
    • snapshotHistory

      Table snapshotHistory(Table rightTable)
    • apply

      default <R> R apply(com.fishlib.base.Function.Unary<R,Table> function)
      Applies a function to this table.

      This is useful if you have a reference to a table, or a proxy; but not the database and want to run a series of operations against the table without each individual operation resulting in an RMI.

      Type Parameters:
      R - the return type of function
      Parameters:
      function - the function to run, its single argument will be this table
      Returns:
      the return value of function
      ImplNote:
      If the LTM is not required the Function.Unary.call(Object) method should be annotated with AsyncMethod.
    • isFlat

      boolean isFlat()
      Return true if this table is guaranteed to be flat. The index of a flat table will be from 0...numRows-1.
    • flatten

      Table flatten()
      Creates a version of this table with a flat index (V2 only).
    • withKeys

      Table withKeys(String... columns)
      Set the table's key columns.
      Returns:
      The same table this method was invoked on, with the keyColumns attribute set
    • withUniqueKeys

      Table withUniqueKeys(String... columns)
      Set the table's key columns and indicate that each key set will be unique.
      Returns:
      The same table this method was invoked on, with the keyColumns and unique attributes set
    • layoutHints

      Table layoutHints(String hints)
    • layoutHints

      default Table layoutHints(LayoutHintBuilder builder)
    • withTableDescription

      Table withTableDescription(String description)
    • withColumnDescription

      default Table withColumnDescription(String column, String description)
      Add a description for a specific column. You may use withColumnDescription(Map) to set several descriptions at once.
      Parameters:
      column - the name of the column
      description - the column description
      Returns:
      a copy of the source table with the description applied
    • withColumnDescription

      Table withColumnDescription(Map<String,String> descriptions)
      Add a set of column descriptions to the table.
      Parameters:
      descriptions - a map of Column name to Column description.
      Returns:
      a copy of the table with the descriptions applied.
    • setTotalsTable

      Table setTotalsTable(TotalsTableBuilder builder)
      Sets parameters for the default totals table display.
      Parameters:
      builder - a TotalsTableBuilder object
      Returns:
      a table with the totals applied
    • setColumnRenderers

      Table setColumnRenderers(ColumnRenderersBuilder builder)
      Sets renderers for columns.
      Parameters:
      builder - a builder that creates the packed string for the attribute
      Returns:
      The same table with the ColumnRenderes attribute set
    • close

      default void close()
      Release resources held by this table, possibly destructively. This may render the table unsuitable or unsafe for further use.
      ApiNote:
      In practice, implementations usually just invoke releaseCachedResources().
    • releaseCachedResources

      default void releaseCachedResources()
      Attempt to release cached resources held by this table. Unlike close(), this must not render the table unusable for subsequent read operations. Implementations should be sure to call super.releaseCachedResources().
    • preemptiveUpdatesTable

      Table preemptiveUpdatesTable(long updateInterval)
    • preemptiveSnapshotTable

      Table preemptiveSnapshotTable(long updateInterval)
    • preemptiveSnapshotTable

      default Table preemptiveSnapshotTable()
    • subscribeToPreemptiveUpdates

      default Table subscribeToPreemptiveUpdates()
      Called on client side of a preemptive table to create the replicated table which represents the server side preemptive table.
    • getViewPort

      default Table getViewPort()
      Called on client side of a preemptive table to create the replicated table which represents the server side preemptive table, but instead of looking at the whole table, we're just interested in the slice we can see on the screen.
    • supportsPreemptiveSubscription

      default boolean supportsPreemptiveSubscription()
      Returns true for client side tables where subscribeToPreemptiveUpdates should return a ReplicatedTable.
    • deflate

      default Inflatable<Table> deflate(@NotNull ExportedObjectClient client)
      Description copied from interface: Deflatable
      Convert this object into an Inflatable suitable for serialization.
      Specified by:
      deflate in interface Deflatable<Table>
      Parameters:
      client - the ExportedObjectClient we are deflating for.
      Returns:
      an Inflatable for serializing to the client
    • deflate

      default Inflatable<Table> deflate(@NotNull ExportedObjectClient client, boolean preSubscribed, boolean preSubscribedViewport)
      Deflate, but provide an extra boolean telling us whether we are presubscribing this preemptive table.
      Parameters:
      client - the client that we are deflating for
      preSubscribed - if the resultant table will have a preemptive subscription right off the bat
      preSubscribedViewport - if the pre-subscription is a viewport (otherwise it is a full subscription)
      Returns:
      an inflatable that maybe be presubscribed