~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to client/drizzledump_data.h

  • Committer: Mark Atwood
  • Date: 2011-11-14 07:30:41 UTC
  • Revision ID: me@mark.atwood.name-20111114073041-mo2hgg8ouseo2kpu
releaseĀ 2011.11.29

Show diffs side-by-side

added added

removed removed

Lines of Context:
212
212
class DrizzleDumpConnection
213
213
{
214
214
  private:
215
 
    drizzle_st *drizzle;
216
 
    drizzle_con_st *connection;
 
215
    drizzle_st drizzle;
 
216
    drizzle_con_st connection;
217
217
    std::string hostName;
218
218
    bool drizzleProtocol;
219
219
    ServerDetect::server_type serverType;
220
220
    std::string serverVersion;
221
221
 
222
222
  public:
223
 
    DrizzleDumpConnection(std::string &host,
224
 
                          uint16_t port,
225
 
                          std::string &username,
226
 
                          std::string &password,
227
 
                          bool drizzle_protocol);
228
 
 
 
223
    DrizzleDumpConnection(std::string &host, uint16_t port,
 
224
      std::string &username, std::string &password, bool drizzle_protocol);
229
225
    ~DrizzleDumpConnection();
230
 
 
231
226
    void errorHandler(drizzle_result_st *res,  drizzle_return_t ret, const char *when);
232
227
    drizzle_result_st* query(std::string &str_query);
233
228
    bool queryNoResult(std::string &str_query);
237
232
      std::string str_query(ch_query);
238
233
      return query(str_query);
239
234
    }
240
 
 
241
235
    bool queryNoResult(const char* ch_query)
242
236
    {
243
237
      std::string str_query(ch_query);
269
263
    void writeString(std::string &str)
270
264
    {
271
265
      if (not connection->queryNoResult(str))
272
 
      {
273
266
        throw std::exception();
274
 
      }
275
267
    }
276
268
 
277
269
    void setConnection(DrizzleDumpConnection *conn) { connection= conn; }