ClickHouse/libs/libmysqlxx/include/mysqlxx/ResultBase.h
2011-03-03 19:57:34 +00:00

36 lines
561 B
C++

#ifndef MYSQLXX_RESULTBASE_H
#define MYSQLXX_RESULTBASE_H
#include <boost/noncopyable.hpp>
#include <mysqlxx/Types.h>
namespace mysqlxx
{
class Connection;
class ResultBase
{
public:
ResultBase(MYSQL_RES & res_, Connection & conn_);
Connection & getConnection() { return conn; }
MYSQL_FIELDS getFields() { return fields; }
unsigned getNumFields() { return num_fields; }
MYSQL_RES & getRes() { return res; }
virtual ~ResultBase() {}
protected:
MYSQL_RES & res;
Connection & conn;
MYSQL_FIELDS fields;
unsigned num_fields;
};
}
#endif