GigaSpaces XAP 9.5 API

org.openspaces.persistency.hibernate
Class DefaultHibernateSpaceSynchronizationEndpointFactoryBean

java.lang.Object
  extended by org.openspaces.persistency.hibernate.DefaultHibernateSpaceSynchronizationEndpointFactoryBean
All Implemented Interfaces:
FactoryBean<DefaultHibernateSpaceSynchronizationEndpoint>, InitializingBean

public class DefaultHibernateSpaceSynchronizationEndpointFactoryBean
extends Object
implements FactoryBean<DefaultHibernateSpaceSynchronizationEndpoint>, InitializingBean

A factory bean which creates DefaultHibernateSpaceSynchronizationEndpoint

Since:
9.5
Author:
eitany

Constructor Summary
DefaultHibernateSpaceSynchronizationEndpointFactoryBean()
           
 
Method Summary
 void afterPropertiesSet()
           
protected  DefaultHibernateSpaceSynchronizationEndpointConfigurer getConfigurer()
           
 DefaultHibernateSpaceSynchronizationEndpoint getObject()
           
 Class<?> getObjectType()
           
 boolean isSingleton()
           
 void setDeleteById(boolean deleteById)
          If set to true the object will be deleted using only its id.
 void setManagedEntries(String... entries)
          Sets all the entries this Hibernate synchronization endpoint interceptor will work with.
 void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
          Injects the Hibernate SessionFactory to be used with this synchronization endpoint interceptor.
 void setUseMerge(boolean useMerge)
          If set to true, will use Hibernate merge to perform the create/update, and will merge before calling delete.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultHibernateSpaceSynchronizationEndpointFactoryBean

public DefaultHibernateSpaceSynchronizationEndpointFactoryBean()
Method Detail

getConfigurer

protected DefaultHibernateSpaceSynchronizationEndpointConfigurer getConfigurer()

setUseMerge

public void setUseMerge(boolean useMerge)
If set to true, will use Hibernate merge to perform the create/update, and will merge before calling delete. This might be required for complex mappings (depends on Hibernate) at the expense of slower performance. Defaults to false.


setDeleteById

public void setDeleteById(boolean deleteById)
If set to true the object will be deleted using only its id. If set to false the object will be deleted using the whole object. Defaults to true.

Parameters:
deleteById -

setSessionFactory

public void setSessionFactory(org.hibernate.SessionFactory sessionFactory)
Injects the Hibernate SessionFactory to be used with this synchronization endpoint interceptor.


setManagedEntries

public void setManagedEntries(String... entries)
Sets all the entries this Hibernate synchronization endpoint interceptor will work with. By default, will use Hibernate meta data API in order to get the list of all the given entities it handles.

This list is used to filter out entities when performing all synchronization endpoint interceptor operations.

Usually, there is no need to explicitly set this.


afterPropertiesSet

public void afterPropertiesSet()
                        throws Exception
Specified by:
afterPropertiesSet in interface InitializingBean
Throws:
Exception

getObject

public DefaultHibernateSpaceSynchronizationEndpoint getObject()
                                                       throws Exception
Specified by:
getObject in interface FactoryBean<DefaultHibernateSpaceSynchronizationEndpoint>
Throws:
Exception

getObjectType

public Class<?> getObjectType()
Specified by:
getObjectType in interface FactoryBean<DefaultHibernateSpaceSynchronizationEndpoint>

isSingleton

public boolean isSingleton()
Specified by:
isSingleton in interface FactoryBean<DefaultHibernateSpaceSynchronizationEndpoint>

GigaSpaces XAP 9.5 API

Copyright © GigaSpaces.