1 |
|
|
/*************************************** |
2 |
|
|
Auteur : Pierre Aubert |
3 |
|
|
Mail : pierre.aubert@lapp.in2p3.fr |
4 |
|
|
Licence : CeCILL-C |
5 |
|
|
****************************************/ |
6 |
|
|
|
7 |
|
|
#ifndef __CONFIGPARSER_IMPL_H__ |
8 |
|
|
#define __CONFIGPARSER_IMPL_H__ |
9 |
|
|
|
10 |
|
|
#include "ConfigTemplate.h" |
11 |
|
|
#include "ConfigParser.h" |
12 |
|
|
|
13 |
|
|
///Add a variable to be parsed |
14 |
|
|
/** @param[out] data : data to be parsed |
15 |
|
|
* @param name : name of the variable to be set |
16 |
|
|
* @param documentation : documentation of the variable |
17 |
|
|
*/ |
18 |
|
|
template<typename T> |
19 |
|
3 |
void ConfigParser::addVariable(T & data, const std::string & name, const std::string & documentation){ |
20 |
✓✓ |
3 |
ConfigBase * ptr = new ConfigTemplate<T>(data, name, documentation); |
21 |
✓ |
3 |
p_vecVar.push_back(ptr); |
22 |
|
3 |
} |
23 |
|
|
|
24 |
|
|
|
25 |
|
|
|
26 |
|
|
#endif |
27 |
|
|
|