|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.teiid.metadata.MetadataFactory
public class MetadataFactory
Allows connectors to build metadata for use by the engine. TODO: add support for datatype import TODO: add support for unique constraints
| Constructor Summary | |
|---|---|
MetadataFactory(java.lang.String modelName,
java.util.Map<java.lang.String,Datatype> dataTypes,
java.util.Properties importProperties)
|
|
| Method Summary | |
|---|---|
KeyRecord |
addAccessPattern(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table table)
Adds an access pattern to the given table. |
Column |
addColumn(java.lang.String name,
java.lang.String type,
ColumnSet<?> table)
Adds a column to the table with the given name and type. |
ForeignKey |
addForiegnKey(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table pkTable,
Table table)
Adds a foreign key to the given table. |
FunctionMethod |
addFunction(java.lang.String name)
Add a function with the given name to the model. |
KeyRecord |
addIndex(java.lang.String name,
boolean nonUnique,
java.util.List<java.lang.String> columnNames,
Table table)
Adds an index to the given table. |
KeyRecord |
addPrimaryKey(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table table)
Adds a primary key to the given table. |
Procedure |
addProcedure(java.lang.String name)
Add a procedure with the given name to the model. |
ProcedureParameter |
addProcedureParameter(java.lang.String name,
java.lang.String type,
ProcedureParameter.Type parameterType,
Procedure procedure)
Add a procedure parameter. |
Column |
addProcedureResultSetColumn(java.lang.String name,
java.lang.String type,
Procedure procedure)
Add a procedure resultset column to the given procedure. |
Table |
addTable(java.lang.String name)
Add a table with the given name to the model. |
java.util.Properties |
getImportProperties()
|
MetadataStore |
getMetadataStore()
|
protected void |
setUUID(AbstractMetadataRecord record)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MetadataFactory(java.lang.String modelName,
java.util.Map<java.lang.String,Datatype> dataTypes,
java.util.Properties importProperties)
| Method Detail |
|---|
public MetadataStore getMetadataStore()
public java.util.Properties getImportProperties()
protected void setUUID(AbstractMetadataRecord record)
public Table addTable(java.lang.String name)
throws TranslatorException
name -
TranslatorException
public Column addColumn(java.lang.String name,
java.lang.String type,
ColumnSet<?> table)
throws TranslatorException
name - type - should be one of TypeFacility.RUNTIME_NAMEStable -
TranslatorException
public KeyRecord addPrimaryKey(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table table)
throws TranslatorException
name - columnNames - table -
TranslatorException
public KeyRecord addAccessPattern(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table table)
throws TranslatorException
name - columnNames - table -
TranslatorException
public KeyRecord addIndex(java.lang.String name,
boolean nonUnique,
java.util.List<java.lang.String> columnNames,
Table table)
throws TranslatorException
name - nonUnique - true indicates that an index is being added.columnNames - table -
TranslatorException
public ForeignKey addForiegnKey(java.lang.String name,
java.util.List<java.lang.String> columnNames,
Table pkTable,
Table table)
throws TranslatorException
name - columnNames - pkTable - table -
TranslatorException
public Procedure addProcedure(java.lang.String name)
throws TranslatorException
name -
TranslatorException
public ProcedureParameter addProcedureParameter(java.lang.String name,
java.lang.String type,
ProcedureParameter.Type parameterType,
Procedure procedure)
throws TranslatorException
name - type - should be one of TypeFacility.RUNTIME_NAMESparameterType - should be one of ProcedureParameter.Typeprocedure -
TranslatorException
public Column addProcedureResultSetColumn(java.lang.String name,
java.lang.String type,
Procedure procedure)
throws TranslatorException
name - type - should be one of TypeFacility.RUNTIME_NAMESprocedure -
TranslatorException
public FunctionMethod addFunction(java.lang.String name)
throws TranslatorException
name -
TranslatorException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||