public abstract class JoinedTable extends Table
Modifier and Type | Field and Description |
---|---|
protected int[] |
column_filter
Gives a column filter to the given column to route correctly to the
ancestor.
|
protected SelectableScheme[] |
column_scheme
The schemes to describe the entity relation in the given column.
|
protected int[] |
column_table
Maps the column number in this table to the reference_list array to route
to.
|
protected Table[] |
reference_list
The list of tables that make up the join.
|
DEBUG_QUERY
Modifier | Constructor and Description |
---|---|
protected |
JoinedTable()
Protected constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
findFieldName(Variable v)
Given a fully qualified variable field name, ie.
|
TObject |
getCellContents(int column,
int row)
Returns an object that represents the information in the given cell
in the table.
|
int |
getColumnCount()
Returns the number of columns in the table.
|
Database |
getDatabase()
We simply pick the first table to resolve the Database object.
|
DataTableDef |
getDataTableDef()
Returns the DataTableDef object that describes the columns in this
table.
|
protected Table[] |
getReferenceTables()
Returns the list of Table objects that represent this VirtualTable.
|
Variable |
getResolvedVariable(int column)
Returns a fully qualified Variable object that represents the name of
the column at the given index.
|
boolean |
hasRootsLocked()
Returns true if the table has its row roots locked (via the lockRoot(int)
method.
|
protected void |
init(Table[] tables)
Helper function for initializing the variables in the joined table.
|
void |
lockRoot(int lock_key)
Locks the root table(s) of this table so that it is impossible to
overwrite the underlying rows that may appear in this table.
|
void |
printGraph(PrintStream out,
int indent)
Prints a graph of the table hierarchy to the stream.
|
protected abstract void |
resolveAllRowsForTableAt(IntegerVector row_set,
int table_num)
Given an IntegerVector that represents a list of pointers to rows in this
table, this resolves the rows to row indexes in the given parent table.
|
protected abstract int |
resolveRowForTableAt(int row_number,
int table_num)
Given a row and a table index (to a parent reference table), this will
return the row index in the given parent table for the given row.
|
RowEnumeration |
rowEnumeration()
Returns an Enumeration of the rows in this table.
|
void |
unlockRoot(int lock_key)
Unlocks the root tables so that the underlying rows may
once again be used if they are not locked and have been removed.
|
all, allColumnMatchesValue, any, columnContainsCell, columnContainsValue, columnMatchesValue, columnMerge, compareCells, Debug, distinct, distinct, dumpTo, emptySelect, exhaustiveSelect, fastFindFieldName, getColumnDefAt, getColumnScheme, getFirstCellContent, getFirstCellContent, getLastCellContent, getLastCellContent, getRowCount, getSingleCellContent, getSingleCellContent, getSystem, getTableAccessState, getTTypeForColumn, getTTypeForColumn, join, orderByColumn, orderByColumn, orderByColumn, orderByColumns, orderedRowList, outside, rangeSelect, selectAll, selectAll, selectFirst, selectLast, selectRange, selectRest, simpleJoin, simpleSelect, singleRowSelect, toMap, toString, union
protected Table[] reference_list
protected SelectableScheme[] column_scheme
protected int[] column_table
protected int[] column_filter
protected void init(Table[] tables)
public Database getDatabase()
getDatabase
in class Table
public int getColumnCount()
getColumnCount
in class Table
public int findFieldName(Variable v)
findFieldName
in class Table
public final Variable getResolvedVariable(int column)
getResolvedVariable
in class Table
protected final Table[] getReferenceTables()
public DataTableDef getDataTableDef()
getDataTableDef
in interface TableDataSource
getDataTableDef
in class Table
public TObject getCellContents(int column, int row)
getCellContents
in interface TableDataSource
getCellContents
in class Table
public RowEnumeration rowEnumeration()
rowEnumeration
in interface TableDataSource
rowEnumeration
in class Table
public void lockRoot(int lock_key)
public void unlockRoot(int lock_key)
unlockRoot
in class Table
public boolean hasRootsLocked()
hasRootsLocked
in class Table
public void printGraph(PrintStream out, int indent)
printGraph
in class Table
protected abstract int resolveRowForTableAt(int row_number, int table_num)
protected abstract void resolveAllRowsForTableAt(IntegerVector row_set, int table_num)
Copyright © 2015. All rights reserved.