Package net.anwiba.commons.jdbc.type
Enum DatabaseType
- java.lang.Object
-
- java.lang.Enum<DatabaseType>
-
- net.anwiba.commons.jdbc.type.DatabaseType
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Comparable<DatabaseType>
public enum DatabaseType extends java.lang.Enum<DatabaseType>
-
-
Enum Constant Summary
Enum Constants Enum Constant Description ARRAYBIGINTBINARYBITBLOBBOOLEANCHARCLOBDATALINKDATEDECIMALDISTINCTDOUBLEFLOATINTEGERJAVA_OBJECTLONGNVARCHARLONGVARBINARYLONGVARCHARNCHARNCLOBNULLNUMERICNVARCHAROTHERREALREFROWIDSMALLINTSQLXMLSTRUCTTIMETIMESTAMPTINYINTUNKNOWNVARBINARYVARCHAR
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract <T,E extends java.lang.Exception>
Taccept(IDatabaseTypeVisitor<T,E> visitor)static DatabaseTypegetByName(java.lang.String name)static DatabaseTypegetByTypeId(int code)intgetCode()static DatabaseTypevalueOf(java.lang.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.
-
-
-
Enum Constant Detail
-
BIT
public static final DatabaseType BIT
-
TINYINT
public static final DatabaseType TINYINT
-
SMALLINT
public static final DatabaseType SMALLINT
-
INTEGER
public static final DatabaseType INTEGER
-
BIGINT
public static final DatabaseType BIGINT
-
FLOAT
public static final DatabaseType FLOAT
-
REAL
public static final DatabaseType REAL
-
DOUBLE
public static final DatabaseType DOUBLE
-
NUMERIC
public static final DatabaseType NUMERIC
-
DECIMAL
public static final DatabaseType DECIMAL
-
CHAR
public static final DatabaseType CHAR
-
VARCHAR
public static final DatabaseType VARCHAR
-
LONGVARCHAR
public static final DatabaseType LONGVARCHAR
-
DATE
public static final DatabaseType DATE
-
TIME
public static final DatabaseType TIME
-
TIMESTAMP
public static final DatabaseType TIMESTAMP
-
BINARY
public static final DatabaseType BINARY
-
VARBINARY
public static final DatabaseType VARBINARY
-
LONGVARBINARY
public static final DatabaseType LONGVARBINARY
-
NULL
public static final DatabaseType NULL
-
OTHER
public static final DatabaseType OTHER
-
JAVA_OBJECT
public static final DatabaseType JAVA_OBJECT
-
DISTINCT
public static final DatabaseType DISTINCT
-
STRUCT
public static final DatabaseType STRUCT
-
ARRAY
public static final DatabaseType ARRAY
-
BLOB
public static final DatabaseType BLOB
-
CLOB
public static final DatabaseType CLOB
-
REF
public static final DatabaseType REF
-
DATALINK
public static final DatabaseType DATALINK
-
BOOLEAN
public static final DatabaseType BOOLEAN
-
ROWID
public static final DatabaseType ROWID
-
NCHAR
public static final DatabaseType NCHAR
-
NVARCHAR
public static final DatabaseType NVARCHAR
-
LONGNVARCHAR
public static final DatabaseType LONGNVARCHAR
-
NCLOB
public static final DatabaseType NCLOB
-
SQLXML
public static final DatabaseType SQLXML
-
UNKNOWN
public static final DatabaseType UNKNOWN
-
-
Method Detail
-
values
public static DatabaseType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (DatabaseType c : DatabaseType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static DatabaseType valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException- if this enum type has no constant with the specified namejava.lang.NullPointerException- if the argument is null
-
getByTypeId
public static DatabaseType getByTypeId(int code)
-
getCode
public int getCode()
-
getByName
public static DatabaseType getByName(java.lang.String name)
-
accept
public abstract <T,E extends java.lang.Exception> T accept(IDatabaseTypeVisitor<T,E> visitor) throws E extends java.lang.Exception
- Throws:
E extends java.lang.Exception
-
-