Interface SymbolTableSource<SYMBOL_TYPE>

All Superinterfaces:
ChunkSource<Values>, ChunkSource.WithPrev<Values>, ColumnSource<SYMBOL_TYPE>, ElementSource<SYMBOL_TYPE>, FillContextMaker, GetContextMaker, Releasable, TupleExporter<SYMBOL_TYPE>, TupleSource<SYMBOL_TYPE>

public interface SymbolTableSource<SYMBOL_TYPE> extends ColumnSource<SYMBOL_TYPE>

Interface for ColumnSources that can provide a Table view of their symbol tables, providing a many:1 or 1:1 mapping of unique long identifiers to the symbol values in this source.

Such sources are also expected to be reinterpretable (ColumnSource.allowsReinterpret(Class)) as long ColumnSources of the same identifiers.

  • Field Details

    • ID_COLUMN_NAME

      static final String ID_COLUMN_NAME
      The name for the column of long identifiers.
      See Also:
    • SYMBOL_COLUMN_NAME

      static final String SYMBOL_COLUMN_NAME
      The name for the column of symbol values, which will have the same data type as this column source.
      See Also:
  • Method Details

    • hasSymbolTable

      boolean hasSymbolTable(@NotNull @NotNull RowSet sourceRowSet)
      Parameters:
      sourceRowSet - The RowSet whose keys must be mappable
      Returns:
      Whether this SymbolTableSource can provide a symbol table that covers all keys in sourceRowSet.
    • getStaticSymbolTable

      Table getStaticSymbolTable(@NotNull @NotNull RowSet sourceRowSet, boolean useLookupCaching)

      Get a static Table view of this SymbolTableSource's symbol table, providing a many:1 or 1:1 mapping of unique long identifiers to the symbol values in this source.

      Parameters:
      sourceRowSet - The RowSet whose keys must be mappable via the result Table's identifier column
      useLookupCaching - Hint whether symbol lookups performed to generate the symbol table should apply caching. Implementations may ignore this hint.
      Returns:
      The symbol table
    • getSymbolTable

      Table getSymbolTable(@NotNull @NotNull QueryTable sourceTable, boolean useLookupCaching)

      Get a Table view of this SymbolTableSource's symbol table, providing a many:1 or 1:1 mapping of unique long identifiers to the symbol values in this source.

      The result will be refreshing if table is refreshing.

      Parameters:
      sourceTable - The QueryTable whose row keys must be mappable via the result Table's identifier column
      useLookupCaching - Hint whether symbol lookups performed to generate the symbol table should apply caching. Implementations may ignore this hint.
      Returns:
      The symbol table
    • hasSymbolTable

      static boolean hasSymbolTable(@NotNull @NotNull ColumnSource<?> source, @NotNull @NotNull RowSet rowSet)
      Check if the specified ColumnSource supports a symbol table for the entirety of the supplied RowSet.
      Parameters:
      source - The column source
      rowSet - The RowSet for inspection.
      Returns:
      True if the column source can provide a complete symbol table for the provided RowSet.