-
Notifications
You must be signed in to change notification settings - Fork 0
/
TScoreboard.h
57 lines (34 loc) · 828 Bytes
/
TScoreboard.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
45
46
47
48
49
50
51
52
53
54
55
56
/**
* File: TScoreboard.h
* @author: Michal Haták
*
* Created on 29. prosinec 2011, 4:07
*/
#ifndef DISPLAY_H
#define DISPLAY_H
#include "Display.h"
#endif
#include "Racer.h"
#ifndef TSCOREBOARD_H
#define TSCOREBOARD_H
#include <vector>
using namespace std;
class TScoreboard { // model
private:
protected:
vector<Racer> m_items;
public:
TScoreboard(void);
int Add(string name);
Racer* getItem(int ItemKey);
void Clear(void);
int Count(void);
void Swap(int a, int b);
bool Cmp(int a, int b);
bool Sort(void);
void quicksort(int left, int right);
bool newScore(int id, float score);
Racer& operator [](int ItemKey);
string List(string delimiter);
};
#endif /* TSCOREBOARD_H */