39 #include "vtkMySQLDatabase.h"
45 #include "QGoIOConfigure.h"
72 template<
typename T >
73 void SetField(
const std::string& key,
const T& value)
77 if ( it != m_MapRow.end() )
79 it->second = ConvertToString< T >(value);
83 std::cerr <<
"This field does not exist!!!" << std::endl;
94 void SetField(
const std::string& key,
const std::string& value);
100 std::string GetTableName();
106 std::string GetTableIDName();
112 std::string PrintValues();
118 std::string PrintColumnNames();
121 std::vector< std::string > PrintColumnsAndValues();
127 std::vector< std::string > GetVectorColumnNames();
133 std::string PrintColumnNamesWithValues();
139 StringMapConstIterator ConstMapBegin();
145 StringMapConstIterator ConstMapEnd();
151 StringMapIterator MapBegin();
157 StringMapIterator MapEnd();
166 std::string GetMapValue(
const std::string& key);
169 T GetMapValue(
const std::string& key)
171 std::string Value = this->GetMapValue(key);
172 return ss_atoi<T>(Value);
180 friend std::ostream & operator<<(std::ostream & os,
const GoDBRow & c)
186 os << it->first <<
" = " << it->second << std::endl;
199 virtual bool SetValuesForSpecificID(
int ID, vtkMySQLDatabase *iDatabaseConnector);
205 void DeleteFromDB(vtkMySQLDatabase *iDatabaseConnector);
212 virtual void InitializeMap() = 0;
220 void AddConditions(
const std::string& iNameOfField,
221 std::vector<FieldWithValue>& ioFieldWithValue);