Sets of Statistics

Each library (and the client, if you so choose) may have its own collection of statistics. To enable rapid addition and modifying of the counters kept, a Perl script takes a brief description of the statistics and genenerates a series of files for including in your source code.

Output

The Perl script stats.pl in tools/ takes a file (usually named something like xxx_stats.dat) of the form:
 name1 name2 = mask class {
    type STATNAME    Descriptive string
    type STATNAME    Descriptive string
     ...
    type STATNAME    Descriptive string
    }

Output

for each class this script creates:

Use as follows:

  class \<class\> {
  public:
  #include "<class\>_struct_gen.h"
      <class>() { ... }
      ~<class>() { ... }
      void clear() {
          memset((void *)this, '\0', sizeof(*this));
      }
  };

  #include "\<class\>_inc_gen.cpp"
  #include "\<class\>_dec_gen.cpp"
  #include "\<class\>_out_gen.cpp"

  const char *<class>::stat_names[] = {
  #include "\<class\>_msg_gen.h"
  }

Generated on Wed Jul 7 17:22:33 2010 for Shore Storage Manager by  doxygen 1.4.7