public class PrimaryKeyFilter extends AbstractTableFilter
| Modifier and Type | Class and Description |
|---|---|
static class |
PrimaryKeyFilter.PkTableMap
Map that associates a table with a set of primary key objects.
|
| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
logger |
| Constructor and Description |
|---|
PrimaryKeyFilter(IDatabaseConnection connection,
PrimaryKeyFilter.PkTableMap allowedPKs,
boolean reverseDependency)
Default constructor, it takes as input a map with desired rows in a final
dataset; the filter will ensure that the rows necessary by these initial rows
are also allowed (and so on...).
|
| Modifier and Type | Method and Description |
|---|---|
void |
edgeAdded(ForeignKeyRelationshipEdge edge) |
boolean |
isValidName(String tableName)
Returns
true if specified table is allowed by this filter. |
ITableIterator |
iterator(IDataSet dataSet,
boolean reversed)
Returns iterator of tables allowed by this filter from the specified dataset.
|
void |
nodeAdded(Object node) |
String |
toString() |
accept, getTableNamespublic PrimaryKeyFilter(IDatabaseConnection connection, PrimaryKeyFilter.PkTableMap allowedPKs, boolean reverseDependency)
connection - database connectionallowedPKs - map of allowed rows, based on the primary keys (key is the name
of a table; value is a Set with allowed primary keys for that table)reverseDependency - flag indicating if the rows that depend on a row should
also be allowed by the filterpublic void nodeAdded(Object node)
public void edgeAdded(ForeignKeyRelationshipEdge edge)
public boolean isValidName(String tableName) throws DataSetException
AbstractTableFiltertrue if specified table is allowed by this filter.
This legacy method, now replaced by accept, still exist for compatibily
with older environmentisValidName in class AbstractTableFilterDataSetExceptionAbstractTableFilterpublic ITableIterator iterator(IDataSet dataSet, boolean reversed) throws DataSetException
ITableFilteriterator in interface ITableFilteriterator in class AbstractTableFilterdataSet - the filtered datasetDataSetExceptionCopyright © 2002-2017. All Rights Reserved.