Class FunctionItemProcessor<I,O>
java.lang.Object
org.springframework.batch.item.function.FunctionItemProcessor<I,O>
- All Implemented Interfaces:
ItemProcessor<I,O>
An
ItemProcessor implementation that delegates to a Function- Since:
- 4.0
- Author:
- Michael Minella
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
FunctionItemProcessor
- Parameters:
function- the delegate. Must not be null
-
-
Method Details
-
process
Description copied from interface:ItemProcessorProcess the provided item, returning a potentially modified or new item for continued processing. If the returned result isnull, it is assumed that processing of the item should not continue.A
nullitem will never reach this method because the only possible sources are:- an
ItemReader(which indicates no more items) - a previous
ItemProcessorin a composite processor (which indicates a filtered item)
- Specified by:
processin interfaceItemProcessor<I,O> - Parameters:
item- to be processed, nevernull.- Returns:
- potentially modified or new item for continued processing,
nullif processing of the provided item should not continue. - Throws:
Exception- thrown if exception occurs during processing.
- an
-