-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathData.h
More file actions
51 lines (33 loc) · 782 Bytes
/
Data.h
File metadata and controls
51 lines (33 loc) · 782 Bytes
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
45
46
47
48
49
50
51
#ifndef DATA_H
#define DATA_H
#include<vector>
#include<string>
typedef unsigned int u_int32;
class Data
{
private:
std::vector<double> values;
public:
Data();
Data(u_int32 size);
Data(double k,u_int32 size);
bool IsEmpty() const;
u_int32 Size() const;
double Max() const;
double Min() const;
double obtainTotal() const;
void Append(double k,u_int32 count = 1);
void Pop(u_int32 count = 1);
double & operator[](u_int32 k) const;
void modIndex(u_int32 index,double value);
};
class chartItem : public Data{
private:
std::string label;
public:
chartItem();
chartItem(const std::string & name,const Data & a);
void setLabel(std::string text);
std::string getLabel() const;
};
#endif // DATA_H