-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathConfigFile.h
More file actions
executable file
·53 lines (43 loc) · 1.35 KB
/
Copy pathConfigFile.h
File metadata and controls
executable file
·53 lines (43 loc) · 1.35 KB
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
#ifndef __CONFIG_FILE_H__
#define __CONFIG_FILE_H__
#include <string>
#include <map>
using namespace std;
/**
* @brief Classe permettant de lire un fichier et de la parcourir rapidement
* @author Arnaud Sevin <Arnaud.Sevin@obspm.fr>
* @version 1.0
* @date 02/06/2008
*/
class ConfigFile {
///Ensemble des objets trouvés
map<string,string> content_;
public:
/**
* Permet de lancer l'analyser un fichier
* @param configFile Emplacement du fichier à analyser
*/
ConfigFile(string const& configFile);
/**
* Permet d'accéder à la valeur entière de l'entrée
* @param section Section où se trouve l'entrée
* @param entry Le nom de l'entrée
* @return La valeur entière de l'entrée
*/
long int const ValueI(string const& section, string const& entry) const;
/**
* Permet d'accéder à la valeur flottante de l'entrée
* @param section Section où se trouve l'entrée
* @param entry Le nom de l'entrée
* @return La valeur flottante de l'entrée
*/
double const ValueD(string const& section, string const& entry) const;
/**
* Permet d'accéder à la valeur de l'entrée
* @param section Section où se trouve l'entrée
* @param entry Le nom de l'entrée
* @return La valeur de l'entrée
*/
string const& ValueS(string const& section, string const& entry) const;
};
#endif