pulse - the web application framework Get pulse at SourceForge.net. Fast, secure and Free Open Source software downloads Ohloh project report for pulse-java

org.torweg.pulse.util
Interface HibernateDataSource

All Known Implementing Classes:
HibernateDataSourceImpl

public interface HibernateDataSource

The Interface for the HibernateDataSource.

Session obtained via the createNewSession() method have to be closed by the calling class itself.

Version:
$Revision: 2050 $
Author:
Thomas Weber

Method Summary
 org.hibernate.search.FullTextSession createNewSession()
          returns a newly created Session.
 void evict(java.lang.Class<?> persistentClass)
          evicts all entries from the second-level cache.
 void evict(java.lang.Class<?> persistentClass, java.io.Serializable id)
          evicts an entry from the second-level cache.
 void evictCollection(java.lang.String roleName)
          evicts all entries from the second-level cache.
 void evictCollection(java.lang.String roleName, java.io.Serializable id)
          evicts an entry from the second-level cache.
 void evictEntity(java.lang.String entityName)
          evicts all entries from the second-level cache.
 void evictEntity(java.lang.String entityName, java.io.Serializable id)
          evicts an entry from the second-level cache.
 org.hibernate.stat.Statistics getStatistics()
          returns the Statistics of the HibernateTM session factory.
 

Method Detail

createNewSession

org.hibernate.search.FullTextSession createNewSession()
returns a newly created Session.The calling class is responsible for closing this Session!

Returns:
returns a newly created Session.

getStatistics

org.hibernate.stat.Statistics getStatistics()
returns the Statistics of the HibernateTM session factory.

Returns:
the statistics

evict

void evict(java.lang.Class<?> persistentClass)
evicts all entries from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
persistentClass - the persistent class to be evicted
See Also:
SessionFactory.evict(Class)

evict

void evict(java.lang.Class<?> persistentClass,
           java.io.Serializable id)
evicts an entry from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
persistentClass - the persistent class to be evicted
id - the id of the entry
See Also:
SessionFactory.evict(Class,Serializable)

evictCollection

void evictCollection(java.lang.String roleName)
evicts all entries from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
roleName - the collection to be evicted (eg. "cat.kittens")
See Also:
SessionFactory.evictCollection(String)

evictCollection

void evictCollection(java.lang.String roleName,
                     java.io.Serializable id)
evicts an entry from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
roleName - the collection to be evicted (eg. "cat.kittens")
id - the id of the collection's parent
See Also:
SessionFactory.evictCollection(String,Serializable)

evictEntity

void evictEntity(java.lang.String entityName)
evicts all entries from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
entityName - the name of the entity to be removed (eg. "cat")
See Also:
SessionFactory.evictEntity(String)

evictEntity

void evictEntity(java.lang.String entityName,
                 java.io.Serializable id)
evicts an entry from the second-level cache.

This method occurs outside of any transaction; it performs an immediate "hard" remove, so does not respect any transaction isolation semantics of the usage strategy. Use with care.

Parameters:
entityName - the collection to be evicted (eg. "cat")
id - the id of the entity
See Also:
SessionFactory.evictEntity(String,Serializable)