3 #ifndef __ARC_DBINTERFACE_H__
4 #define __ARC_DBINTERFACE_H__
31 virtual bool connect(std::string& dbname, std::string& user,
32 std::string& password) = 0;
36 virtual void close() = 0;
43 virtual bool enable_ssl(
const std::string& keyfile =
"",
const std::string& certfile =
"",
44 const std::string& cafile =
"",
const std::string& capath =
"") = 0;
49 typedef std::vector<std::vector<std::string> > QueryArrayResult;
50 typedef std::vector<std::string> QueryRowResult;
73 virtual bool execute(
const std::string& sqlstr) = 0;
77 virtual QueryRowResult
get_row(
int row_number)
const = 0;
81 virtual QueryRowResult
get_row()
const = 0;
87 virtual std::string
get_row_field(
int row_number, std::string& field_name) = 0;
96 virtual bool get_array(std::string& sqlstr, QueryArrayResult& result, std::vector<std::string>& arguments) = 0;