jodd.db.oom
Class DbMetaUtil

java.lang.Object
  extended by jodd.db.oom.DbMetaUtil

public class DbMetaUtil
extends java.lang.Object

Few meta resolving utils.


Constructor Summary
DbMetaUtil()
           
 
Method Summary
static boolean resolveIsAnnotated(java.lang.Class<?> type)
          Returns true if class is annotated with DbTable annotation.
static java.lang.String resolveSchemaName(java.lang.Class<?> type, java.lang.String defaultSchemaName)
          Resolves schema name.
static java.lang.String resolveTableName(java.lang.Class<?> type, java.lang.String tableNamePrefix, java.lang.String tableNameSuffix, boolean toUpperCase)
          Resolves table name from a type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DbMetaUtil

public DbMetaUtil()
Method Detail

resolveTableName

public static java.lang.String resolveTableName(java.lang.Class<?> type,
                                                java.lang.String tableNamePrefix,
                                                java.lang.String tableNameSuffix,
                                                boolean toUpperCase)
Resolves table name from a type. If type is annotated, table name will be read from annotation value. If this value is empty or if type is not annotated, table name will be set to wildcard pattern '*' (to match all tables).


resolveSchemaName

public static java.lang.String resolveSchemaName(java.lang.Class<?> type,
                                                 java.lang.String defaultSchemaName)
Resolves schema name. Uses default schema name if not specified.


resolveIsAnnotated

public static boolean resolveIsAnnotated(java.lang.Class<?> type)
Returns true if class is annotated with DbTable annotation.



Copyright © 2003-2012 Jodd Team