net.sf.farrago.ddl
Class DdlImportForeignSchemaStmt.ImportSink
java.lang.Object
net.sf.farrago.namespace.util.MedAbstractMetadataSink
net.sf.farrago.ddl.DdlImportForeignSchemaStmt.ImportSink
- All Implemented Interfaces:
- FarragoMedMetadataSink
- Enclosing class:
- DdlImportForeignSchemaStmt
private class DdlImportForeignSchemaStmt.ImportSink
- extends MedAbstractMetadataSink
ImportSink implements FarragoMedMetadataSink
by creating catalog
descriptors for imported foreign tables and columns.
Method Summary |
private FemBaseColumnSet |
createTable(String tableName)
|
(package private) void |
dropStragglers()
|
(package private) Set |
getImportedTableNames()
|
private void |
setStorageOptions(FemElementWithStorageOptions element,
Properties props)
|
boolean |
writeColumnDescriptor(String tableName,
String columnName,
int ordinal,
RelDataType type,
String remarks,
String defaultValue,
Properties properties)
Writes a descriptor for a column. |
boolean |
writeObjectDescriptor(String name,
String typeName,
String remarks,
Properties properties)
Writes a generic descriptor for an object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ddlValidator
private final FarragoSessionDdlValidator ddlValidator
tableMap
private final Map<String,FemBaseColumnSet> tableMap
medHandler
private DdlMedHandler medHandler
directory
private FarragoMedNameDirectory directory
DdlImportForeignSchemaStmt.ImportSink
DdlImportForeignSchemaStmt.ImportSink(FarragoSessionDdlValidator ddlValidator,
FarragoMedMetadataQuery query,
FarragoMedNameDirectory directory)
writeObjectDescriptor
public boolean writeObjectDescriptor(String name,
String typeName,
String remarks,
Properties properties)
- Description copied from interface:
FarragoMedMetadataSink
- Writes a generic descriptor for an object. Some objects (such as columns)
have more specific write methods.
- Parameters:
name
- unqualified object nameremarks
- object description, or null for noneproperties
- storage options
- Returns:
- true if object was accepted; false if object was filtered out
writeColumnDescriptor
public boolean writeColumnDescriptor(String tableName,
String columnName,
int ordinal,
RelDataType type,
String remarks,
String defaultValue,
Properties properties)
- Description copied from interface:
FarragoMedMetadataSink
- Writes a descriptor for a column.
- Parameters:
tableName
- unqualified table namecolumnName
- unqualified column nameordinal
- 0-based ordinal of column within tabletype
- column datatyperemarks
- column description, or null for nonedefaultValue
- column default value, or null for noneproperties
- storage options
- Returns:
- true if object was accepted; false if object was filtered out
getImportedTableNames
Set getImportedTableNames()
dropStragglers
void dropStragglers()
createTable
private FemBaseColumnSet createTable(String tableName)
setStorageOptions
private void setStorageOptions(FemElementWithStorageOptions element,
Properties props)