53 virtual int size(
void)
const = 0;
56 virtual const type_info *
const *
columnTypes(
void)
const = 0;
68 virtual void set(
IRowBase * i_row,
int i_column,
const void * i_value)
const = 0;
104 DbValue(
unsigned int i_value) :
DbValue(static_cast<unsigned long long>(i_value)) { }
110 DbValue(
unsigned long i_value) :
DbValue(static_cast<unsigned long long>(i_value)) { }
175 virtual const char *
formatValue(
const void * i_value,
bool i_isNull =
false) = 0;
row factory and setter interface to select row from database
Definition: dbCommon.h:45
virtual IRowBase * createRow(void) const =0
create new row (tuple, struct or array) initialized with default field values
virtual void set(IRowBase *i_row, int i_column, const void *i_value) const =0
field value setter: i_row[i_column] = *i_value
virtual int size(void) const =0
return row size: number of columns
virtual const type_info *const * columnTypes(void) const =0
array[rowSize] of type_info for each column, used to convert from db-type to target type
public interafce for row processing during select, ie: select and append to row list
Definition: dbCommon.h:181
virtual void processRow(IRowBaseUptr &i_row)=0
process row, ie: append to row list or aggregate.
openM++ exceptions
Definition: omError.h:19
openM++ namespace
Definition: log.h:32
const char * MSSQL_DB_PROVIDER
MS SQL db-provider name.
Definition: dbExec.cpp:23
const char * SQLITE_DB_PROVIDER
SQLite db-provider name.
Definition: dbExec.cpp:14
const char * MYSQL_DB_PROVIDER
MySQL and MariaDB db-provider name.
Definition: dbExec.cpp:17
OpenmException< 4000, dbUnknownErrorMessage > DbException
db-exception
Definition: dbCommon.h:41
std::unique_ptr< IRowBase > IRowBaseUptr
unique pointer to db row
Definition: omHelper.h:236
const char dbUnknownErrorMessage[]
db-exception default error message: "unknown db error"
Definition: dbExec.cpp:38
const char * DB2_DB_PROVIDER
DB2 db-provider name.
Definition: dbExec.cpp:29
const char * PGSQL_DB_PROVIDER
PostgreSQL db-provider name.
Definition: dbExec.cpp:20
const char * ORACLE_DB_PROVIDER
Oracle db-provider name.
Definition: dbExec.cpp:26
OpenM++: public interface for errors and exceptions.
db-row abstract base
Definition: omHelper.h:231
union to pass value to database methods
Definition: dbCommon.h:73
unsigned long long ullVal
value of unsigned integer type
Definition: dbCommon.h:80
DbValue(double i_value)
value initialized by supplied double
Definition: dbCommon.h:131
DbValue(unsigned long i_value)
value initialized by supplied unsigned long
Definition: dbCommon.h:110
DbValue(bool i_value)
value initialized by supplied boolean
Definition: dbCommon.h:143
DbValue(unsigned long long i_value)
value initialized by supplied unsigned long
Definition: dbCommon.h:119
long long llVal
value of integer type
Definition: dbCommon.h:77
DbValue(unsigned int i_value)
value initialized by supplied unsigned integer
Definition: dbCommon.h:104
DbValue(int i_value)
value initialized by supplied integer
Definition: dbCommon.h:101
DbValue(long double i_value)
value initialized by supplied long double
Definition: dbCommon.h:137
DbValue(float i_value)
value initialized by supplied float
Definition: dbCommon.h:125
bool isVal
value of boolean type
Definition: dbCommon.h:83
static TDst castDouble(const DbValue &i_value)
cast between float, double and long double
double dVal
value of double type
Definition: dbCommon.h:89
DbValue(const char *i_value)
value initialized by supplied c-style string
Definition: dbCommon.h:149
void clear(void)
clear value with zeros
Definition: dbValue.cpp:12
DbValue(long long i_value)
value initialized by supplied long
Definition: dbCommon.h:113
const char * szVal
c-style string
Definition: dbCommon.h:95
DbValue(long i_value)
value initialized by supplied long
Definition: dbCommon.h:107
DbValue(void)
zero initialized value
Definition: dbCommon.h:98
long double dlVal
value of long double type
Definition: dbCommon.h:92
float fVal
value of float type
Definition: dbCommon.h:86