GET library
|
Go to the source code of this file.
Functions | |
int | GETCfgSetData (u_short &data, DOMElement *node) |
int | GETCfgSetData (double &data, DOMElement *node) |
int | GETCfgSetData (u_short &data, const string &value, const string &range) |
int | GETCfgSetEnum (u_short &data, const string &value, int nv, const string list[]) |
int | GETCfgSetLogic (bool &data, DOMElement *node) |
int | GETCfgSetLogic (bool &data, const string &value) |
Variables | |
static const string | GETCfgLogicId [2] = { "false", "true" } |
String identifying logic values ("true", "false") in configuration files. | |
static const bool | GETCfgLogicValue [2] = { false, true } |
Logic values ("true", "false") in configuration files. | |
Include file for GET configuration files tools.
int GETCfgSetData | ( | u_short & | data, |
DOMElement * | node | ||
) |
Set a data value from a DOM tree node. This function search if the node contains a range attribute, either as an integer range, either as a list of (text) identifiers. In the latter case, the value set is the index of the text element in the list. If no range is specified, the value is read from the node.
data | data to be set |
node | DOM tree element node |
References GETCfgSetData().
Referenced by GETCfgSetData(), GETCfgChannel::GetXMLConfig(), GETCfgAsAd::GetXMLConfigGenerator(), GETCfgAGet::GetXMLConfigGlobal(), and GETCfgAGet::GetXMLConfigGlobalReg1().
int GETCfgSetData | ( | double & | data, |
DOMElement * | node | ||
) |
Set a data value from a DOM tree node. This function search if the node contains a range attribute, either as an integer range, either as a list of (text) identifiers. In the latter case, the value set is the index of the text element in the list. If no range is specified, the value is read from the node.
data | data to be set |
node | DOM tree element node |
int GETCfgSetData | ( | u_short & | data, |
const string & | value, | ||
const string & | range | ||
) |
Set a data value from a string value and a range of values. The range can be defined either as an interger interval [min,max], either as a list of text identifiers {id0,id1,id2,...}.
data | data to be set |
value | string value to extract |
range | accepted values definition (interval or list of identifiers) |
References GETCfgSetEnum().
int GETCfgSetEnum | ( | u_short & | data, |
const string & | value, | ||
int | nv, | ||
const string | list[] | ||
) |
Function setting an integer value from a string (read in configuration file) that should contain an element from the argument list. The function returns 0 if the data was set. In case of error, the data value is not modified.
data | data to be set |
value | configuration file string value |
nv | number of list elements |
list | list of data identifiers |
Referenced by GETCfgSetData().
int GETCfgSetLogic | ( | bool & | data, |
DOMElement * | node | ||
) |
Function setting a logic value from DOM tree node that should contain either "true" or "false". The function returns 0 if the data was set. In case of error, the data value is not modified.
data | data to be set |
node | DOM tree element node |
References GETCfgSetLogic().
Referenced by GETCfgSetLogic(), GETCfgAGet::GetXMLConfig(), GETCfgAsAd::GetXMLConfig(), GETCfgChannel::GetXMLConfig(), and GETCfgAsAd::GetXMLConfigGenerator().
int GETCfgSetLogic | ( | bool & | data, |
const string & | value | ||
) |
Function setting a logic value from a string (read in configuration file) that should contain either "true" or "false". The function returns 0 if the data was set. In case of error, the data value is not modified.
data | data to be set |
value | configuration file string value |
References GETCfgLogicId.