 |
Qore CsvUtil Module Reference
1.7
|
145 "block": C_OPT1|C_OPT2,
147 "date_format": C_OPT1|C_OPT2,
148 "date-format": C_OPT1|C_OPT2,
149 "encoding": C_OPT1|C_OPT2,
150 "eol": C_OPT1|C_OPT2,
153 "header_reorder": C_OPT1,
154 "info_log": C_OPT1|C_OPT2,
155 "number_format": C_OPT1|C_OPT2,
156 "optimal_quotes": C_OPT1|C_OPT2,
157 "optimal-quotes": C_OPT1|C_OPT2,
158 "quote": C_OPT1|C_OPT2,
159 "quote_escape": C_OPT1|C_OPT2,
160 "separator": C_OPT1|C_OPT2,
161 "verify_columns": C_OPT1|C_OPT2,
162 "verify-columns": C_OPT1|C_OPT2,
163 "write_headers": C_OPT1|C_OPT2,
164 "write-headers": C_OPT1|C_OPT2,
230 constructor(
string n_errname, hash<auto> spec, hash<auto> n_opts);
343 string prepareRawLineIntern(list<auto> values);
writeLine(list< auto > values)
Write a line with a list of values; data are checked against column rules.
const Options
valid options for the object (a hash for quick lookups of valid keys)
Definition: AbstractCsvWriter.qc.dox.h:144
string encoding
output file character encoding
Definition: AbstractCsvWriter.qc.dox.h:168
write(Qore::AbstractIterator iterator)
Stream an iterator into the output.
string m_quoteEscapeChar
quote escape character
Definition: AbstractCsvWriter.qc.dox.h:177
abstract writeRawLine(list< auto > values)
This method must be overridden in child classes to provide the output implementation.
*hash< string, AbstractDataField > getRecordType()
Returns the description of the record type, if any.
writeHeaders()
Write csv headers.
hash m_out_by_name
mapping output field by name
Definition: AbstractCsvWriter.qc.dox.h:204
bool checkElementCounts
verify the column count for every row; if a row does not match, then throw a CSVFILEITERATOR-DATA-ERR...
Definition: AbstractCsvWriter.qc.dox.h:183
the CsvUtil namespace. All classes used in the CsvUtil module should be inside this namespace
Definition: AbstractCsvIterator.qc.dox.h:28
string prepareRawLine(list< auto > values)
Prepare a string (line with EOF) with formatting and escaping.
hash m_out_by_idx
mapping output field by index
Definition: AbstractCsvWriter.qc.dox.h:207
The AbstractCsvWriter class provides a parent for all CSV writers.
Definition: AbstractCsvWriter.qc.dox.h:139
bool write_headers
this flag determines if any stored headers are output
Definition: AbstractCsvWriter.qc.dox.h:195
const EOL_UNIX
Unix end of line character sequence (for new OS X too)
Definition: CsvUtil.qm.dox.h:316
string quote
field content delimiter
Definition: AbstractCsvWriter.qc.dox.h:174
bool optimal_quotes
stores the optimal quotes option
Definition: AbstractCsvWriter.qc.dox.h:198
string separator
field separator
Definition: AbstractCsvWriter.qc.dox.h:171
int block
block size for bulk DML
Definition: AbstractCsvWriter.qc.dox.h:189
int lineNo
the latest line number
Definition: AbstractCsvWriter.qc.dox.h:186
string baseTemplate
base template for value format
Definition: AbstractCsvWriter.qc.dox.h:192
hash< auto > hash(object obj)
processSpec()
Process specification and set internal variable for mapping.
string eol
end of line sequence
Definition: AbstractCsvWriter.qc.dox.h:180
*code info_log
a closure/call reference for informational logging when using write(SQLStatement)
Definition: AbstractCsvWriter.qc.dox.h:201
constructor(string n_errname, *hash< auto > n_opts)
Creates the AbstractCsvWriter in single-type mode.
processCommonOptions(*hash< auto > n_opts, int C_OPTx)
Process options and set internal variables.