Class OrderLineAggregator
- java.lang.Object
- org.springframework.batch.sample.domain.order.internal.OrderLineAggregator
- All Implemented Interfaces:
LineAggregator<Order>
public class OrderLineAggregator extends java.lang.Object implements LineAggregator<Order>
ConvertsOrder
object to a list of strings.- Author:
- Dave Syer, Dan Garrette
Constructor Summary
Constructors Constructor Description OrderLineAggregator()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
aggregate(Order order)
Create a string from the value provided.void
setAggregators(java.util.Map<java.lang.String,LineAggregator<java.lang.Object>> aggregators)
Set aggregators for all types of lines in the output file
Method Detail
aggregate
public java.lang.String aggregate(Order order)
Description copied from interface:LineAggregator
Create a string from the value provided.- Specified by:
aggregate
in interfaceLineAggregator<Order>
- Parameters:
order
- values to be converted- Returns:
- string
setAggregators
public void setAggregators(java.util.Map<java.lang.String,LineAggregator<java.lang.Object>> aggregators)
Set aggregators for all types of lines in the output file- Parameters:
aggregators
- Map of LineAggregators used to map the various record types for each order