public class SimpleHibernateBatchOperationManager extends Object implements BatchOperationManager
Warning: using this batcher will clear the current session!
| Constructor and Description |
|---|
SimpleHibernateBatchOperationManager(HibernateSessionManager sessionManager) |
| Modifier and Type | Method and Description |
|---|---|
<I,O> Iterable<O> |
performAsBatch(Iterable<I> input,
int expectedTotal,
com.google.common.base.Function<I,O> task) |
<I,O> Iterable<O> |
performInChunks(Iterable<I> input,
int chunkSize,
int sizeToCollect,
com.google.common.base.Function<List<I>,List<O>> task)
Processes a collection of items in chunks until a given number of processed items is reached, the processed items are then returned.
|
public SimpleHibernateBatchOperationManager(HibernateSessionManager sessionManager)
public <I,O> Iterable<O> performAsBatch(Iterable<I> input, int expectedTotal, com.google.common.base.Function<I,O> task)
performAsBatch in interface BatchOperationManagerpublic <I,O> Iterable<O> performInChunks(Iterable<I> input, int chunkSize, int sizeToCollect, com.google.common.base.Function<List<I>,List<O>> task)
BatchOperationManagerperformInChunks in interface BatchOperationManagerinput - the items to processchunkSize - the size of the batchsizeToCollect - the number of processed items to returntask - a function to process the itemsCopyright © 2003–2017 Atlassian. All rights reserved.