8#ifndef MODEL_SQL_WRITER_H
9#define MODEL_SQL_WRITER_H
38 void write(const
char * i_str);
44 void writeQuoted(const
string & i_str,
bool i_isAppendComma = false);
47 void writeTrimQuoted(const
string & i_str,
bool i_isAppendComma = false);
53 void writeQuoted(
string::const_iterator i_begin,
string::const_iterator i_end);
openM++ namespace
Definition: log.h:32
wrapper around file stream to write into sql script file.
Definition: modelSqlWriter.h:20
string outFilePath
sql script file path
Definition: modelSqlWriter.h:23
ofstream outFs
sql scrpit output stream
Definition: modelSqlWriter.h:26
~ModelSqlWriter() noexcept
close sql script file
Definition: modelSqlWriter.cpp:30
void writeQuoted(const string &i_str, bool i_isAppendComma=false)
write string value sql-quoted: O'Brien -> 'O''Brien'
Definition: modelSqlWriter.cpp:58
void writeTrimQuoted(const string &i_str, bool i_isAppendComma=false)
write string value space trimed and sql-quoted
Definition: modelSqlWriter.cpp:85
void throwOnFail(void) const
throw exception on output stream fail
Definition: modelSqlWriter.cpp:36
void writeLine(const string &i_line)
write line into sql script file
Definition: modelSqlWriter.cpp:51
ModelSqlWriter(const string &i_filePath)
create new sql script file
Definition: modelSqlWriter.cpp:12
void write(const char *i_str)
write string into sql script file
Definition: modelSqlWriter.cpp:42