org.hibernate.dialect.resolver
Class DialectFactory
java.lang.Object
org.hibernate.dialect.resolver.DialectFactory
public class DialectFactory
- extends Object
A factory for generating Dialect instances.
- Author:
- Steve Ebersole, Tomoto Shimizu Washio
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DialectFactory
public DialectFactory()
buildDialect
public static Dialect buildDialect(Properties properties,
Connection connection)
throws HibernateException
- Builds an appropriate Dialect instance.
If a dialect is explicitly named in the incoming properties, it is used. Otherwise, it is
determined by dialect resolvers based on the passed connection.
An exception is thrown if a dialect was not explicitly set and no resolver could make
the determination from the given connection.
- Parameters:
properties
- The configuration properties.connection
- The configured connection.
- Returns:
- The appropriate dialect instance.
- Throws:
HibernateException
- No dialect specified and no resolver could make the determination.
buildDialect
public static Dialect buildDialect(Properties properties)
constructDialect
public static Dialect constructDialect(String dialectName)
- Returns a dialect instance given the name of the class to use.
- Parameters:
dialectName
- The name of the dialect class.
- Returns:
- The dialect instance.
Copyright © null-null Red Hat Middleware, LLC. All Rights Reserved