Interface RawItemBuilder<T extends de.hybris.platform.servicelayer.model.AbstractItemModel>
- Type Parameters:
T-
- All Known Implementing Classes:
AbstractRawItemBuilder,DefaultOrderCancelRequestBuilder,DefaultRawHybrisOrderBuilder
public interface RawItemBuilder<T extends de.hybris.platform.servicelayer.model.AbstractItemModel>
Converter from a hybris item model to a CSV string. Depends on
RawItemContributor instances defining the
columns and extracting the values. The CsvBuilder creates the header rows and data rows and takes care for escaping.-
Method Summary
Modifier and TypeMethodDescriptionvoidrowsAsNameValuePairs(T model) voidsetContributors(List<RawItemContributor<T>> contributors) Inject the list of contributors to the CSV string to be built.
-
Method Details
-
setContributors
Inject the list of contributors to the CSV string to be built. To be called before method @seerowsAsNameValuePairs(AbstractItemModel)is called- Parameters:
contributors-
-
getContributors
List<RawItemContributor<T>> getContributors()- Returns:
- Contributors to the CSV creation
-
rowsAsNameValuePairs
- Parameters:
model- item model for which the raw item shall be assembled- Returns:
- Columns of the CSV according to the registered contributors
-
getColumns
- Returns:
- the union of all column names used the the registered contributors
-
addContributor
- Parameters:
c- contributor to add
-