forked from FLAME-HPC/flame_visualiser
-
Notifications
You must be signed in to change notification settings - Fork 0
/
zeroxmlreader.h
44 lines (40 loc) · 1.14 KB
/
zeroxmlreader.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*!
* \file zeroxmlreader.h
* \author Simon Coakley
* \date 2012
* \copyright Copyright (c) 2012 University of Sheffield
* \brief Header file for zero XML reader
*/
#ifndef ZEROXMLREADER_H_
#define ZEROXMLREADER_H_
#include <QXmlStreamReader>
#include <QHash>
#include "./agent.h"
#include "./agenttype.h"
#include "./visualsettingsmodel.h"
#include "./dimension.h"
class ZeroXMLReader : public QXmlStreamReader {
public:
ZeroXMLReader(QList<Agent*> * a, QList<AgentType> * at,
VisualSettingsModel * vsm, double r, Dimension * ad,
QStringList * sat, QHash<QString, int> * atc,
double xo, double yo, double zo);
bool read(QIODevice * device);
private:
void readUnknownElement();
void readEnvironmentXML();
void readAgentXML();
void readAgentsXML();
void readZeroXML();
QList<Agent*> * agents;
QList<AgentType> * agentTypes;
VisualSettingsModel * vsmodel;
double ratio;
Dimension * agentDimension;
QStringList * stringAgentTypes;
QHash<QString, int> * agentTypeCounts;
double xoffset;
double yoffset;
double zoffset;
};
#endif // ZEROXMLREADER_H_