public class DatabaseTableConfig<T> extends Object
DatabaseTable annotation.| Constructor and Description | 
|---|
| DatabaseTableConfig() | 
| DatabaseTableConfig(Class<T> dataClass,
                   String tableName,
                   List<DatabaseFieldConfig> fieldConfigs)Setup a table config associated with the dataClass, table-name, and field configurations. | 
| DatabaseTableConfig(Class<T> dataClass,
                   String schemaName,
                   String tableName,
                   List<DatabaseFieldConfig> fieldConfigs)Setup a table config associated with the dataClass, schema-name, table-name, and field configurations. | 
| DatabaseTableConfig(DatabaseType databaseType,
                   Class<T> dataClass,
                   List<DatabaseFieldConfig> fieldConfigs)Setup a table config associated with the dataClass and field configurations. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | extractFieldTypes(DatabaseType databaseType)Extract the field types from the fieldConfigs if they have not already been configured. | 
| static <T> String | extractSchemaName(Class<T> clazz) | 
| static <T> String | extractTableName(DatabaseType databaseType,
                Class<T> clazz)Extract and return the table name for a class. | 
| static <T> DatabaseTableConfig<T> | fromClass(DatabaseType databaseType,
         Class<T> clazz)Extract the DatabaseTableConfig for a particular class by looking for class and field annotations. | 
| Class<T> | getDataClass() | 
| List<DatabaseFieldConfig> | getFieldConfigs() | 
| FieldType[] | getFieldTypes(DatabaseType databaseType)Return the field types associated with this configuration. | 
| String | getSchemaName() | 
| String | getTableName() | 
| void | initialize()Initialize the class if this is being called with Spring. | 
| void | setDatabaseType(DatabaseType databaseType)Optional setting. | 
| void | setDataClass(Class<T> dataClass) | 
| void | setFieldConfigs(List<DatabaseFieldConfig> fieldConfigs) | 
| void | setSchemaName(String schemaName) | 
| void | setTableName(String tableName)Set the table name. | 
public DatabaseTableConfig()
public DatabaseTableConfig(DatabaseType databaseType, Class<T> dataClass, List<DatabaseFieldConfig> fieldConfigs)
public DatabaseTableConfig(Class<T> dataClass, String tableName, List<DatabaseFieldConfig> fieldConfigs)
public void initialize()
public void setDatabaseType(DatabaseType databaseType)
public String getTableName()
public String getSchemaName()
public void setTableName(String tableName)
public void setSchemaName(String schemaName)
public void setFieldConfigs(List<DatabaseFieldConfig> fieldConfigs)
public void extractFieldTypes(DatabaseType databaseType) throws SQLException
SQLExceptionpublic FieldType[] getFieldTypes(DatabaseType databaseType) throws SQLException
SQLExceptionpublic List<DatabaseFieldConfig> getFieldConfigs()
public static <T> DatabaseTableConfig<T> fromClass(DatabaseType databaseType, Class<T> clazz) throws SQLException
SQLExceptionpublic static <T> String extractTableName(DatabaseType databaseType, Class<T> clazz)
This documentation is licensed by Gray Watson under the Creative Commons Attribution-Share Alike 3.0 License.