|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
java.lang.Object java.lang.Enum<DatabaseType> org.springframework.batch.support.DatabaseType
public enum DatabaseType
Enum representing a database type, such as DB2 or oracle. The type also contains a product name, which is expected to be the same as the product name provided by the database driver's metadata.
Enum Constant Summary | |
---|---|
DB2
|
|
DB2ZOS
|
|
DERBY
|
|
H2
|
|
HSQL
|
|
MYSQL
|
|
ORACLE
|
|
POSTGRES
|
|
SQLSERVER
|
|
SYBASE
|
Method Summary | |
---|---|
static DatabaseType |
fromMetaData(DataSource dataSource)
Convenience method that pulls a database product name from the DataSource's metadata. |
static DatabaseType |
fromProductName(String productName)
Static method to obtain a DatabaseType from the provided product name. |
String |
getProductName()
|
static DatabaseType |
valueOf(String name)
Returns the enum constant of this type with the specified name. |
static DatabaseType[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Enum Constant Detail |
---|
public static final DatabaseType DERBY
public static final DatabaseType DB2
public static final DatabaseType DB2ZOS
public static final DatabaseType HSQL
public static final DatabaseType SQLSERVER
public static final DatabaseType MYSQL
public static final DatabaseType ORACLE
public static final DatabaseType POSTGRES
public static final DatabaseType SYBASE
public static final DatabaseType H2
Method Detail |
---|
public static DatabaseType[] values()
for (DatabaseType c : DatabaseType.values()) System.out.println(c);
public static DatabaseType valueOf(String name)
name
- the name of the enum constant to be returned.
IllegalArgumentException
- if this enum type has no constant
with the specified name
NullPointerException
- if the argument is nullpublic String getProductName()
public static DatabaseType fromProductName(String productName)
productName
-
IllegalArgumentException
- if none is found.public static DatabaseType fromMetaData(DataSource dataSource) throws MetaDataAccessException
dataSource
-
MetaDataAccessException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |