Class DatabaseMetaDataDialectResolutionInfoAdapter
java.lang.Object
org.hibernate.engine.jdbc.dialect.spi.DatabaseMetaDataDialectResolutionInfoAdapter
- All Implemented Interfaces:
DatabaseVersion,DialectResolutionInfo
public class DatabaseMetaDataDialectResolutionInfoAdapter
extends Object
implements DialectResolutionInfo
An implementation of
DialectResolutionInfo that delegates calls to a wrapped DatabaseMetaData.
All SQLExceptions resulting from calls on the DatabaseMetaData are converted to the Hibernate
JDBCException hierarchy.
-
Field Summary
Fields inherited from interface org.hibernate.dialect.DatabaseVersion
NO_VERSION -
Constructor Summary
ConstructorsConstructorDescriptionDatabaseMetaDataDialectResolutionInfoAdapter(DatabaseMetaData databaseMetaData) -
Method Summary
Modifier and TypeMethodDescriptionintObtain access to the database major version, as returned fromDatabaseMetaData.getDatabaseMajorVersion()for the target database.Obtain access to theDatabaseMetaDataif it is available.intObtain access to the database minor version, as returned fromDatabaseMetaData.getDatabaseMinorVersion()for the target database.Obtain access to the database name, as returned fromDatabaseMetaData.getDatabaseProductName()for the target databaseObtain access to the database version, as returned fromDatabaseMetaData.getDatabaseProductVersion()for the target databaseintObtain access to the major version of the JDBC driver, as returned fromDatabaseMetaData.getDriverMajorVersion()()} for the target database.intObtain access to the minor version of the JDBC driver, as returned fromDatabaseMetaData.getDriverMinorVersion()for the target database.Obtain access to the name of the JDBC driver, as returned fromDatabaseMetaData.getDriverName()for the target databaseObtain access to the SQL keywords of the JDBC driver, as returned fromDatabaseMetaData.getSQLKeywords()for the target database.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.dialect.DatabaseVersion
getDatabaseMicroVersion, getMajor, getMicro, getMinor, isAfter, isAfter, isAfter, isAfter, isAfter, isBefore, isBefore, isBefore, isBefore, isBefore, isSame, isSame, isSame, isSame, isSameOrAfter, isSameOrAfter, isSameOrAfter, isSameOrAfter, isSameOrAfter, makeCopy, makeCopy, makeCopyOrDefaultMethods inherited from interface org.hibernate.engine.jdbc.dialect.spi.DialectResolutionInfo
getConfigurationValues
-
Constructor Details
-
DatabaseMetaDataDialectResolutionInfoAdapter
-
-
Method Details
-
getDatabaseName
Description copied from interface:DialectResolutionInfoObtain access to the database name, as returned fromDatabaseMetaData.getDatabaseProductName()for the target database- Specified by:
getDatabaseNamein interfaceDialectResolutionInfo- Returns:
- The database name
- See Also:
-
getDatabaseVersion
Description copied from interface:DialectResolutionInfoObtain access to the database version, as returned fromDatabaseMetaData.getDatabaseProductVersion()for the target database- Specified by:
getDatabaseVersionin interfaceDialectResolutionInfo- Returns:
- The database version
- See Also:
-
getDatabaseMajorVersion
public int getDatabaseMajorVersion()Description copied from interface:DatabaseVersionObtain access to the database major version, as returned fromDatabaseMetaData.getDatabaseMajorVersion()for the target database.- Specified by:
getDatabaseMajorVersionin interfaceDatabaseVersion- Returns:
- The database major version, or -9999 to indicate "no version information"
- See Also:
-
getDatabaseMinorVersion
public int getDatabaseMinorVersion()Description copied from interface:DatabaseVersionObtain access to the database minor version, as returned fromDatabaseMetaData.getDatabaseMinorVersion()for the target database.- Specified by:
getDatabaseMinorVersionin interfaceDatabaseVersion- Returns:
- The database minor version, or -9999 to indicate "no version information"
- See Also:
-
getDriverName
Description copied from interface:DialectResolutionInfoObtain access to the name of the JDBC driver, as returned fromDatabaseMetaData.getDriverName()for the target database- Specified by:
getDriverNamein interfaceDialectResolutionInfo- Returns:
- The JDBC driver name
- See Also:
-
getDriverMajorVersion
public int getDriverMajorVersion()Description copied from interface:DialectResolutionInfoObtain access to the major version of the JDBC driver, as returned fromDatabaseMetaData.getDriverMajorVersion()()} for the target database.- Specified by:
getDriverMajorVersionin interfaceDialectResolutionInfo- Returns:
- The JDBC driver major version, or -9999 to indicate "no version information"
- See Also:
-
getDriverMinorVersion
public int getDriverMinorVersion()Description copied from interface:DialectResolutionInfoObtain access to the minor version of the JDBC driver, as returned fromDatabaseMetaData.getDriverMinorVersion()for the target database.- Specified by:
getDriverMinorVersionin interfaceDialectResolutionInfo- Returns:
- The JDBC driver minor version, or -9999 to indicate "no version information"
- See Also:
-
getSQLKeywords
Description copied from interface:DialectResolutionInfoObtain access to the SQL keywords of the JDBC driver, as returned fromDatabaseMetaData.getSQLKeywords()for the target database.- Specified by:
getSQLKeywordsin interfaceDialectResolutionInfo- Returns:
- The JDBC driver keywords
- See Also:
-
getDatabaseMetadata
Description copied from interface:DialectResolutionInfoObtain access to theDatabaseMetaDataif it is available.- Specified by:
getDatabaseMetadatain interfaceDialectResolutionInfo- Returns:
- The
DatabaseMetaDataornullif not available
-
toString
-