~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/memcached_stats/stats_table.h

  • Committer: Brian Aker
  • Date: 2009-12-03 01:17:53 UTC
  • mto: (1237.3.2 push)
  • mto: This revision was merged to the branch mainline in revision 1238.
  • Revision ID: brian@gaz-20091203011753-159h2no5m5c5dt9b
Small cleanups, did in MERGE table only engine flag.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
 
1
/* 
2
2
 * Copyright (c) 2009, Padraig O'Sullivan
3
3
 * All rights reserved.
4
4
 *
27
27
 * THE POSSIBILITY OF SUCH DAMAGE.
28
28
 */
29
29
 
30
 
 
31
30
#ifndef PLUGIN_MEMCACHED_STATS_STATS_TABLE_H
32
31
#define PLUGIN_MEMCACHED_STATS_STATS_TABLE_H
33
32
 
34
 
#include "drizzled/plugin/table_function.h"
35
 
#include "drizzled/field.h"
36
 
 
37
 
#include <libmemcached/memcached.h>
38
 
 
39
 
class StatsTableTool : public drizzled::plugin::TableFunction
 
33
#include "drizzled/plugin/info_schema_table.h"
 
34
 
 
35
#include <vector>
 
36
 
 
37
class MemcachedStatsISMethods : public drizzled::plugin::InfoSchemaMethods
40
38
{
41
39
public:
42
 
 
43
 
  StatsTableTool();
44
 
 
45
 
  class Generator : public drizzled::plugin::TableFunction::Generator
46
 
  {
47
 
  public:
48
 
    Generator(drizzled::Field **arg);
49
 
 
50
 
    ~Generator();
51
 
 
52
 
    bool populate();
53
 
  private:
54
 
    uint32_t host_number;
55
 
    uint32_t number_of_hosts;
56
 
    memcached_st *memc;
57
 
  };
58
 
 
59
 
  Generator *generator(drizzled::Field **arg)
60
 
  {
61
 
    return new Generator(arg);
62
 
  }
 
40
  virtual int fillTable(Session *session,
 
41
                        Table *table,
 
42
                        drizzled::plugin::InfoSchemaTable *schema_table);
63
43
};
64
44
 
 
45
bool createMemcachedStatsColumns(std::vector<const drizzled::plugin::ColumnInfo *> &cols);
 
46
 
 
47
void clearMemcachedColumns(std::vector<const drizzled::plugin::ColumnInfo *> &cols);
 
48
 
65
49
#endif /* PLUGIN_MEMCACHED_STATS_STATS_TABLE_H */