public class HibernateDatastore extends AbstractHibernateDatastore implements MessageSourceAware
Datastore implementation that uses a Hibernate SessionFactory underneath.
| Modifiers | Name | Description |
|---|---|---|
protected java.util.Map<java.lang.String, HibernateDatastore> |
datastoresByConnectionSource |
|
protected ConfigurableApplicationEventPublisher |
eventPublisher |
|
protected HibernateGormEnhancer |
gormEnhancer |
|
protected org.hibernate.boot.Metadata |
metadata |
|
protected GrailsHibernateTransactionManager |
transactionManager |
| Constructor and description |
|---|
HibernateDatastore(ConnectionSources<org.hibernate.SessionFactory, HibernateConnectionSourceSettings> connectionSources, HibernateMappingContext mappingContext, ConfigurableApplicationEventPublisher eventPublisher)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(PropertyResolver configuration, HibernateConnectionSourceFactory connectionSourceFactory, ConfigurableApplicationEventPublisher eventPublisher)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(PropertyResolver configuration, HibernateConnectionSourceFactory connectionSourceFactory)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(PropertyResolver configuration, ConfigurableApplicationEventPublisher eventPublisher, java.lang.Class classes)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(javax.sql.DataSource dataSource, PropertyResolver configuration, ConfigurableApplicationEventPublisher eventPublisher, java.lang.Class classes)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(PropertyResolver configuration, ConfigurableApplicationEventPublisher eventPublisher, java.lang.Package packagesToScan)Construct a Hibernate datastore scanning the given packages |
HibernateDatastore(javax.sql.DataSource dataSource, PropertyResolver configuration, ConfigurableApplicationEventPublisher eventPublisher, java.lang.Package packagesToScan)Construct a Hibernate datastore scanning the given packages for the given datasource |
HibernateDatastore(PropertyResolver configuration, java.lang.Class classes)Create a new HibernateDatastore for the given connection sources and mapping context |
HibernateDatastore(PropertyResolver configuration, java.lang.Package packagesToScan)Construct a Hibernate datastore scanning the given packages |
HibernateDatastore(java.util.Map<java.lang.String, java.lang.Object> configuration, java.lang.Class classes)Constructor used purely for testing purposes. |
HibernateDatastore(java.util.Map<java.lang.String, java.lang.Object> configuration, java.lang.Package packagesToScan)Construct a Hibernate datastore scanning the given packages |
HibernateDatastore(java.lang.Class classes)Constructor used purely for testing purposes. |
HibernateDatastore(java.lang.Package packagesToScan)Construct a Hibernate datastore scanning the given packages |
HibernateDatastore(java.lang.Package packageToScan)Construct a Hibernate datastore scanning the given packages |
Create a new HibernateDatastore for the given connection sources and mapping context
connectionSources - The ConnectionSources instancemappingContext - The MappingContext instanceeventPublisher - The ConfigurableApplicationEventPublisher instanceCreate a new HibernateDatastore for the given connection sources and mapping context
configuration - The configurationconnectionSourceFactory - The HibernateConnectionSourceFactory instanceeventPublisher - The ConfigurableApplicationEventPublisher instanceCreate a new HibernateDatastore for the given connection sources and mapping context
configuration - The configurationconnectionSourceFactory - The HibernateConnectionSourceFactory instanceCreate a new HibernateDatastore for the given connection sources and mapping context
configuration - The configurationeventPublisher - The ConfigurableApplicationEventPublisher instanceclasses - The persistent classesCreate a new HibernateDatastore for the given connection sources and mapping context
configuration - The configurationeventPublisher - The ConfigurableApplicationEventPublisher instanceclasses - The persistent classesConstruct a Hibernate datastore scanning the given packages
configuration - The configurationeventPublisher - The event publisherpackagesToScan - The packages to scanConstruct a Hibernate datastore scanning the given packages for the given datasource
configuration - The configurationeventPublisher - The event publisherpackagesToScan - The packages to scanCreate a new HibernateDatastore for the given connection sources and mapping context
configuration - The configurationclasses - The persistent classesConstruct a Hibernate datastore scanning the given packages
configuration - The configurationpackagesToScan - The packages to scanConstructor used purely for testing purposes. Creates a datastore with an in-memory database and dbCreate set to 'create-drop'
classes - The classesConstruct a Hibernate datastore scanning the given packages
configuration - The configurationpackagesToScan - The packages to scanConstructor used purely for testing purposes. Creates a datastore with an in-memory database and dbCreate set to 'create-drop'
classes - The classesConstruct a Hibernate datastore scanning the given packages
packagesToScan - The packages to scanConstruct a Hibernate datastore scanning the given packages
packageToScan - The package to scanObtain a child HibernateDatastore by connection name
connectionName - The connection name