~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/logging_stats/stats_schema.h

  • Committer: Joe Daly
  • Date: 2010-06-25 03:22:55 UTC
  • mto: This revision was merged to the branch mainline in revision 1656.
  • Revision ID: skinny.moey@gmail.com-20100625032255-bzj84xre67qldfpi
initial user stats impl

Show diffs side-by-side

added added

removed removed

Lines of Context:
153
153
  LoggingStats *outer_logging_stats;
154
154
};
155
155
 
 
156
class CumulativeUserStatsTool : public drizzled::plugin::TableFunction
 
157
{
 
158
public:
 
159
 
 
160
  CumulativeUserStatsTool(LoggingStats *logging_stats);
 
161
 
 
162
  class Generator : public drizzled::plugin::TableFunction::Generator
 
163
  {
 
164
  public:
 
165
    Generator(drizzled::Field **arg, LoggingStats *logging_stats);
 
166
 
 
167
    bool populate();
 
168
  private:
 
169
    LoggingStats *inner_logging_stats;
 
170
    int32_t record_number;
 
171
    int32_t last_valid_index;
 
172
  };
 
173
 
 
174
  Generator *generator(drizzled::Field **arg)
 
175
  {
 
176
    return new Generator(arg, outer_logging_stats);
 
177
  }
 
178
private:
 
179
  LoggingStats *outer_logging_stats;
 
180
};
 
181
 
156
182
#endif /* PLUGIN_LOGGING_STATS_STATS_SCHEMA_H */