org.hibernate.spatial.integration
Class SpatialDialectFactory

java.lang.Object
  extended by org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl
      extended by org.hibernate.spatial.integration.SpatialDialectFactory
All Implemented Interfaces:
java.io.Serializable, org.hibernate.service.jdbc.dialect.spi.DialectFactory, org.hibernate.service.Service

public class SpatialDialectFactory
extends org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl

A DialectFactory that may inject configuration into SpatialDialects. This implementation extends the Standard Hibernate DialectFactory. It is currently only used for the OracleSpatial10gDialect.

See Also:
Serialized Form

Constructor Summary
SpatialDialectFactory(HibernateSpatialConfiguration configuration)
           
 
Method Summary
 org.hibernate.dialect.Dialect buildDialect(java.util.Map configValues, java.sql.Connection connection)
          Builds an appropriate Dialect instance.
 
Methods inherited from class org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl
setClassLoaderService, setDialectResolver
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpatialDialectFactory

public SpatialDialectFactory(HibernateSpatialConfiguration configuration)
Method Detail

buildDialect

public org.hibernate.dialect.Dialect buildDialect(java.util.Map configValues,
                                                  java.sql.Connection connection)
                                           throws org.hibernate.HibernateException
Description copied from interface: org.hibernate.service.jdbc.dialect.spi.DialectFactory
Builds an appropriate Dialect instance.

If a dialect is explicitly named in the incoming properties, it should 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.

Specified by:
buildDialect in interface org.hibernate.service.jdbc.dialect.spi.DialectFactory
Overrides:
buildDialect in class org.hibernate.service.jdbc.dialect.internal.DialectFactoryImpl
Parameters:
configValues - The configuration properties.
connection - The configured connection.
Returns:
The appropriate dialect instance.
Throws:
org.hibernate.HibernateException - No dialect specified and no resolver could make the determination.