|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.batch.item.support.AbstractItemReader org.springframework.batch.item.support.DelegatingItemReader
public class DelegatingItemReader
Simple wrapper around ItemReader
. The item reader is expected to
take care of open and close operations. If necessary it should be registered
as a step scoped bean to ensure that the lifecycle methods are called.
The implementation is thread-safe if the delegate is thread-safe.
Constructor Summary | |
---|---|
DelegatingItemReader()
Default constructor. |
|
DelegatingItemReader(ItemReader itemReader)
Convenience constructor for setting mandatory property. |
Method Summary | |
---|---|
void |
afterPropertiesSet()
|
void |
mark()
Mark the stream so that it can be reset later and the items backed out. Mark is called before reading a new chunk of items - in case of rollback mark will not be called again before re-processing the chunk. |
Object |
read()
Get the next object from the input source. |
void |
reset()
Reset the stream to the last mark. |
void |
setItemReader(ItemReader source)
Setter for input source. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DelegatingItemReader()
public DelegatingItemReader(ItemReader itemReader)
Method Detail |
---|
public void afterPropertiesSet() throws Exception
afterPropertiesSet
in interface InitializingBean
Exception
public Object read() throws Exception
read
in interface ItemReader
Exception
ItemReader.read()
public void setItemReader(ItemReader source)
source
- public void mark()
ItemReader
mark
in interface ItemReader
mark
in class AbstractItemReader
public void reset()
ItemReader
reset
in interface ItemReader
reset
in class AbstractItemReader
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |