Class InjectingPersisterFactory

java.lang.Object
ch.tocco.nice2.persist.core.impl.hibernate.AbstractInjectingFactory<org.hibernate.persister.internal.PersisterFactoryImpl>
ch.tocco.nice2.persist.core.impl.hibernate.InjectingPersisterFactory
All Implemented Interfaces:
Serializable, org.hibernate.persister.spi.PersisterFactory, org.hibernate.service.Service, org.hibernate.service.spi.ServiceRegistryAwareService

public class InjectingPersisterFactory extends AbstractInjectingFactory<org.hibernate.persister.internal.PersisterFactoryImpl> implements org.hibernate.persister.spi.PersisterFactory, org.hibernate.service.spi.ServiceRegistryAwareService
A PersisterFactory which delegates object creation to PersisterFactoryImpl and then injects services into the persisters if a suitable setter is found. The available services for injection are passed in the constructor.
See Also:
  • Field Summary

    Fields inherited from class ch.tocco.nice2.persist.core.impl.hibernate.AbstractInjectingFactory

    delegate, services
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.hibernate.persister.collection.CollectionPersister
    createCollectionPersister(org.hibernate.mapping.Collection collection, org.hibernate.cache.spi.access.CollectionDataAccess collectionDataAccess, org.hibernate.persister.spi.PersisterCreationContext persisterCreationContext)
     
    org.hibernate.persister.entity.EntityPersister
    createEntityPersister(org.hibernate.mapping.PersistentClass persistentClass, org.hibernate.cache.spi.access.EntityDataAccess entityDataAccess, org.hibernate.cache.spi.access.NaturalIdDataAccess naturalIdDataAccess, org.hibernate.persister.spi.PersisterCreationContext persisterCreationContext)
     

    Methods inherited from class ch.tocco.nice2.persist.core.impl.hibernate.AbstractInjectingFactory

    getBeanInfo, injectServices

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.hibernate.service.spi.ServiceRegistryAwareService

    injectServices
  • Constructor Details

    • InjectingPersisterFactory

      public InjectingPersisterFactory(Map<Class,Object> services)
  • Method Details

    • createEntityPersister

      public org.hibernate.persister.entity.EntityPersister createEntityPersister(org.hibernate.mapping.PersistentClass persistentClass, org.hibernate.cache.spi.access.EntityDataAccess entityDataAccess, org.hibernate.cache.spi.access.NaturalIdDataAccess naturalIdDataAccess, org.hibernate.persister.spi.PersisterCreationContext persisterCreationContext) throws org.hibernate.HibernateException
      Specified by:
      createEntityPersister in interface org.hibernate.persister.spi.PersisterFactory
      Throws:
      org.hibernate.HibernateException
    • createCollectionPersister

      public org.hibernate.persister.collection.CollectionPersister createCollectionPersister(org.hibernate.mapping.Collection collection, org.hibernate.cache.spi.access.CollectionDataAccess collectionDataAccess, org.hibernate.persister.spi.PersisterCreationContext persisterCreationContext) throws org.hibernate.HibernateException
      Specified by:
      createCollectionPersister in interface org.hibernate.persister.spi.PersisterFactory
      Throws:
      org.hibernate.HibernateException