paramxx
1.0.7
|
#include <Par.h>
Public Types | |
enum | ParFileDelimit { DELIMIT =',' } |
enum | ParType { PARNAME, PARTYPE, PARMODE, PARVALUE, PARMINIMUM, PARMAXIMUM, PARPROMPT } |
enum | ParamMode { AUTOS ='a', BATCH ='b', hIDDEN ='h', HIDDEN ='H', QUERRY ='q', LEARN ='l' } |
enum | ParamType { BOOLEAN ='b', COMMENT ='c', INTEGER ='i', REAL ='r', STRING ='s' } |
enum | NumTokens { NUMTOKENS =7 } |
Public Member Functions | |
virtual | ~Par (void) |
Par (void) | |
Par (ParTxt &par) | |
int | check_value (const char *str) const |
virtual void | plist (ostream &os) const |
string | get_name (void) const |
string | get_mode (void) const |
string | get_prompt (void) const |
string | get_value (void) const |
virtual bool | pgetb (void) const throw ( ParFileException ) |
virtual double | pgetd (void) const throw ( ParFileException ) |
only defined in BoolPar More... | |
virtual int | pgeti (void) const throw ( ParFileException ) |
only defined in RealPar More... | |
virtual long | pgetl (void) const throw ( ParFileException ) |
only defined in LongPar More... | |
virtual void | pgetstr (char result[], size_t size) const throw ( ParFileException ) |
only defined in LongPar More... | |
virtual string | pgetstring (void) const throw ( ParFileException ) |
only defined in StringPar More... | |
virtual void | print (ostream &os) const |
only defined in StringPar More... | |
virtual void | set_val (const string &str) throw ( ParFileException, Exception ) |
Protected Member Functions | |
void | not_between_limits (char str[], const char *left, const string &left_val, const char *right, const string &right_val) const |
Protected Attributes | |
vector< string > | parameter |
Friends | |
ostream & | operator<< (ostream &os, Par &par) |
ostream & | operator<< (ostream &os, Par *par) |
The base class for the boolean, double, integer and string parameters.
enum Par::ParFileDelimit |
The delimit within the par file
enum Par::ParType |
The position of the parameters.
|
inlinevirtual |
The destructor.
|
inline |
The default constructor.
|
inline |
Get the mode of the parameter file
Referenced by ParFile::pgetstring().
|
inline |
Get the name member of the class.
|
inline |
Get the prompt of the parameter
Referenced by ParFile::print().
|
virtual |
The user is trying to get the boolean value of a parameter which is anything but a boolean.
Reimplemented in BoolPar.
Referenced by ParFile::pgetb().
|
virtual |
only defined in BoolPar
The user is trying to get the double value of a parameter which is anything but a double.
Reimplemented in RealPar.
Referenced by ParFile::pgetd().
|
virtual |
|
virtual |
|
virtual |
|
virtual |
only defined in StringPar
Reimplemented in StringPar.
Referenced by ParFile::pgetstr(), and ParFile::pgetstring().
|
virtual |
All the derived Par class, with the exception of the comment class, will call this function to print on the screen the parameters with the format name = val prompt
Reimplemented in CommentPar.
|
virtual |
only defined in StringPar
To output the parameter of the form: name,type,mode,val,min,max,prompt
Reimplemented in StringPar.
Referenced by CommentPar::plist().
|
friend |
This operator outputs the contents of the object.
|
friend |
This operator outputs the contents of the object.