Package com.saperion.common.sql
Enum SqlDialect
- java.lang.Object
-
- java.lang.Enum<SqlDialect>
-
- com.saperion.common.sql.SqlDialect
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<SqlDialect>
public enum SqlDialect extends java.lang.Enum<SqlDialect>
SqlDialect
enumerates known SQL dialects ofDataSource
s.- Author:
- agz
- See Also:
DataSource
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MS_SQL_SERVER
SQL dialect of Microsoft SQL-Server.ORACLE
SQL dialect of Oracle.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static SqlDialect
fromDatabaseProductName(java.lang.String databaseProductName)
Returns theSqlDialect
corresponding to the specified database product name.static SqlDialect
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static SqlDialect[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
MS_SQL_SERVER
public static final SqlDialect MS_SQL_SERVER
SQL dialect of Microsoft SQL-Server.
-
ORACLE
public static final SqlDialect ORACLE
SQL dialect of Oracle.
-
-
Method Detail
-
values
public static SqlDialect[] 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 (SqlDialect c : SqlDialect.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static SqlDialect 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
-
fromDatabaseProductName
public static SqlDialect fromDatabaseProductName(java.lang.String databaseProductName)
Returns theSqlDialect
corresponding to the specified database product name. Throws anIllegalArgumentException
if the specified database product name is unknown/not recognized. The specified database product name must not benull
.- Parameters:
databaseProductName
- database product name to get theSqlDialect
for- Returns:
SqlDialect
for the specified database product name
-
-