public class ExportStd extends InterruptibleProcess
ImportStd
Modifier and Type | Field and Description |
---|---|
protected AliveConfirmer |
aliveConfirmer |
protected java.lang.String |
charsetName |
protected int |
exportedColumns |
protected java.lang.String |
fileName |
protected java.io.BufferedWriter |
fileWriter |
protected DataObject |
mainDataObject |
static java.lang.String |
standardCsvCharsetName |
sessionResources
Constructor and Description |
---|
ExportStd(AliveConfirmer aliveConfirmer,
DataObject mainDataObject,
java.lang.String fileName)
Constructs a new ExportStd.
|
ExportStd(AliveConfirmer aliveConfirmer,
DataObject mainDataObject,
java.lang.String fileName,
java.lang.String charsetName)
Constructs a new ExportStd.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addField(java.lang.StringBuffer line,
java.lang.String columnName) |
protected void |
addValue(java.lang.StringBuffer line,
java.lang.String value)
Adds a column value to a line buffer.
|
protected void |
addValue(java.lang.StringBuffer line,
java.lang.String value,
boolean forceQuotes)
Adds a column value to a line buffer.
|
protected void |
exportRow() |
protected boolean |
isFieldToIgnore(java.lang.String columnName) |
void |
processExport() |
void |
setFieldSelection(java.lang.String fieldSelection)
Sets the field selection.
|
void |
setWhereCondition(java.lang.String whereCondition) |
protected void |
writeColumnHeader() |
getConflictInfos, hasConflict, isToRun, setAliveConfirmer, setConflictInfo, setConflictInfo, setStatusInfoPresenter, setStatusInformation
public static java.lang.String standardCsvCharsetName
protected DataObject mainDataObject
protected AliveConfirmer aliveConfirmer
protected java.lang.String fileName
protected java.lang.String charsetName
protected java.io.BufferedWriter fileWriter
protected int exportedColumns
public ExportStd(AliveConfirmer aliveConfirmer, DataObject mainDataObject, java.lang.String fileName)
aliveConfirmer
- the alive confirmer to interrupt the process.mainDataObject
- the main source data objectfileName
- the name of the target filepublic ExportStd(AliveConfirmer aliveConfirmer, DataObject mainDataObject, java.lang.String fileName, java.lang.String charsetName)
aliveConfirmer
- the alive confirmer to interrupt the process.mainDataObject
- the main source data objectfileName
- the name of the target filecharset
- the charset to writepublic void setFieldSelection(java.lang.String fieldSelection)
fieldSelection
- the field select to use instead of "*";public void setWhereCondition(java.lang.String whereCondition)
public void processExport() throws java.io.IOException
java.io.IOException
protected void writeColumnHeader() throws java.io.IOException
java.io.IOException
protected void exportRow() throws java.io.IOException
java.io.IOException
protected boolean isFieldToIgnore(java.lang.String columnName)
protected void addField(java.lang.StringBuffer line, java.lang.String columnName)
protected void addValue(java.lang.StringBuffer line, java.lang.String value)
line
- the line buffer to be filledvalue
- the value to be added to the line bufferprotected void addValue(java.lang.StringBuffer line, java.lang.String value, boolean forceQuotes)
line
- the line buffer to be filledvalue
- the value to be added to the line bufferforceQuotes
- whether or not surrounding quotes are forcedCopyright 1998-2023 Christoph Mueller, Kaerntner Str. 56, D-70469 Stuttgart, Germany, https://www.perpus.de