1 |
|
#include <iostream> |
2 |
|
#include <string> |
3 |
|
#include <stdlib.h> // used for system("XXSX") calls |
4 |
< |
#include "socket++-1.10/pipestream.h" // used to get calls to statgrab |
4 |
> |
#include "SubPipe.h" |
5 |
|
#include "Config.h" |
6 |
|
#ifndef XMLFORMATTER_H /* Has the file been INCLUDE'd already? */ |
7 |
|
#define XMLFORMATTER_H yes |
20 |
|
int collect(); // collect data for an averager |
21 |
|
string getData(); // return the data from averages, or a snapshot if no data is avaible |
22 |
|
int getSequence(){ return sequence; }; // inline |
23 |
+ |
void clearData(); // reset the data arrays |
24 |
|
|
25 |
|
private: |
26 |
+ |
SubPipe * p; |
27 |
|
int sequence; // sequence number for the packets |
28 |
|
int debug; // print debug info? |
29 |
< |
string titles[60]; // names for the packet info |
30 |
< |
string values[60]; // values for those packet infos |
29 |
> |
const static int maxTitles = 100; |
30 |
> |
string titles[maxTitles]; // names for the packet info |
31 |
> |
string values[maxTitles]; // values for those packet infos |
32 |
|
int titlepointer; // where have we got up to? |
33 |
|
int checks; // number of checks since the last packet |
34 |
|
}; // class |