1 |
#ifndef _ZCONSREADER_H_
|
2 |
#define _ZCONSREADER_H_
|
3 |
|
4 |
#include <fstream>
|
5 |
#include <string>
|
6 |
#include <vector>
|
7 |
|
8 |
#include "brains/SimInfo.hpp"
|
9 |
|
10 |
namespace oopse {
|
11 |
|
12 |
/**
|
13 |
* @class ZConsReader
|
14 |
* @todo document
|
15 |
*/
|
16 |
class ZConsReader{
|
17 |
public:
|
18 |
|
19 |
ZConsReader(SimInfo* info);
|
20 |
ZConsReader(const std::string& filename);
|
21 |
~ZConsReader();
|
22 |
|
23 |
void readHeader();
|
24 |
void readNextFrame();
|
25 |
bool hasNextFrame();
|
26 |
int getNumZMol();
|
27 |
std::vector<int> getZConsIndex();
|
28 |
std::vector<double> getZConsPos();
|
29 |
//vector<double> getKRatio();
|
30 |
|
31 |
std::vector<double> getCurZPos();
|
32 |
std::vector<double> getCurFZ();
|
33 |
double getCurTime();
|
34 |
|
35 |
private:
|
36 |
|
37 |
std::ifstream* istream;
|
38 |
SimInfo* info;
|
39 |
std::string zconsFileName;
|
40 |
|
41 |
int nZMol;
|
42 |
std::vector<int> index;
|
43 |
std::vector<double> zconsPos;
|
44 |
//vector<double> kRatio;
|
45 |
|
46 |
double curTime;
|
47 |
std::vector<double> curFZ;
|
48 |
std::vector<double> curZPos;
|
49 |
|
50 |
};
|
51 |
|
52 |
}
|
53 |
#endif
|