@Component(value="blCsvPublisher") @Scope(value="prototype") public class CsvPublisher extends AbstractDataFeedPublisher
Modifier and Type | Field and Description |
---|---|
static String |
EMPTY_VALUE |
protected org.apache.commons.csv.CSVPrinter |
printer |
protected File |
tmpFile |
protected org.broadleafcommerce.common.file.domain.FileWorkArea |
workArea |
protected BufferedWriter |
writer |
broadleafFileService, LOG
Constructor and Description |
---|
CsvPublisher() |
Modifier and Type | Method and Description |
---|---|
boolean |
canPublish(ExportFormatType exportFormatType) |
void |
close(DataFeed dataFeed) |
protected void |
doAdditionalCloseAction(DataFeed dataFeed)
Hook point for including custom close actions
|
protected org.apache.commons.csv.CSVFormat |
getCsvFormat()
Hook point for defining a custom CSV format
|
void |
initialize(DataFeed dataFeed) |
void |
publishFeedItems(DataFeed dataFeed,
DataFeedDynamicList feedItems) |
protected String |
sanitizeProperty(String property,
String fieldName)
Hook point for including custom property sanitizing logic
|
public static final String EMPTY_VALUE
protected org.broadleafcommerce.common.file.domain.FileWorkArea workArea
protected File tmpFile
protected org.apache.commons.csv.CSVPrinter printer
protected BufferedWriter writer
public void initialize(DataFeed dataFeed) throws DataFeedException
DataFeedException
protected org.apache.commons.csv.CSVFormat getCsvFormat()
public void publishFeedItems(DataFeed dataFeed, DataFeedDynamicList feedItems) throws DataFeedException
DataFeedException
protected String sanitizeProperty(String property, String fieldName)
public void close(DataFeed dataFeed) throws DataFeedException
DataFeedException
protected void doAdditionalCloseAction(DataFeed dataFeed) throws DataFeedException
dataFeed
- DataFeedException
public boolean canPublish(ExportFormatType exportFormatType)
Copyright © 2020. All rights reserved.