Java Code Examples for org.hibernate.persister.collection.CollectionPersister#getBatchSize()

The following examples show how to use org.hibernate.persister.collection.CollectionPersister#getBatchSize() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: StatefulPersistenceContext.java    From lams with GNU General Public License v2.0 5 votes vote down vote up
@Override
public void addUninitializedCollection(CollectionPersister persister, PersistentCollection collection, Serializable id) {
	final CollectionEntry ce = new CollectionEntry( collection, persister, id, flushing );
	addCollection( collection, ce, id );
	if ( persister.getBatchSize() > 1 ) {
		getBatchFetchQueue().addBatchLoadableCollection( collection, ce );
	}
}
 
Example 2
Source File: StatefulPersistenceContext.java    From lams with GNU General Public License v2.0 5 votes vote down vote up
@Override
public void addUninitializedDetachedCollection(CollectionPersister persister, PersistentCollection collection) {
	final CollectionEntry ce = new CollectionEntry( persister, collection.getKey() );
	addCollection( collection, ce, collection.getKey() );
	if ( persister.getBatchSize() > 1 ) {
		getBatchFetchQueue().addBatchLoadableCollection( collection, ce );
	}
}