public class AggregateItemReader<T> extends Object implements org.springframework.batch.item.ItemReader<List<T>>
ItemReader that delivers a list as its item, storing up objects
from the injected ItemReader until they are ready to be packed out as
a collection. This class must be used as a wrapper for a custom
ItemReader that can identify the record boundaries. The custom reader
should mark the beginning and end of records by returning an
AggregateItem which responds true to its query methods
is*().ItemReader is also thread safe.AggregateItem.isHeader(),
AggregateItem.isFooter()| Constructor and Description |
|---|
AggregateItemReader() |
| Modifier and Type | Method and Description |
|---|---|
List<T> |
read()
Get the next list of records.
|
void |
setItemReader(org.springframework.batch.item.ItemReader<AggregateItem<T>> itemReader) |
public void setItemReader(org.springframework.batch.item.ItemReader<AggregateItem<T>> itemReader)
Copyright © 2014. All Rights Reserved.