A helper class for the enumeration SourceModel.
More...
#include <CSourceModel.h>
|
static int | version () |
| Return the major version number as an int. More...
|
|
static std::string | revision () |
| Return the revision as a string. More...
|
|
static unsigned int | size () |
| Return the number of enumerators declared in SourceModelMod::SourceModel. More...
|
|
static std::string | name (const SourceModelMod::SourceModel &e) |
| Returns an enumerator as a string. More...
|
|
static std::string | toString (const SourceModelMod::SourceModel &f) |
| Equivalent to the name method. More...
|
|
static const std::vector
< std::string > | names () |
| Returns vector of all the enumerators as strings. More...
|
|
static SourceModelMod::SourceModel | newSourceModel (const std::string &name) |
| Create a SourceModel enumeration object by specifying its name. More...
|
|
static SourceModelMod::SourceModel | literal (const std::string &name) |
|
static SourceModelMod::SourceModel | from_int (unsigned int i) |
|
|
static const std::string & | sGAUSSIAN |
| Enumerators as strings. More...
|
|
static const std::string & | sPOINT |
|
static const std::string & | sDISK |
|
|
static std::string | badString (const std::string &name) |
|
static std::string | badInt (unsigned int i) |
|
A helper class for the enumeration SourceModel.
Definition at line 85 of file CSourceModel.h.
CSourceModel::CSourceModel |
( |
| ) |
|
|
private |
static std::string CSourceModel::badInt |
( |
unsigned int |
i | ) |
|
|
staticprivate |
static std::string CSourceModel::badString |
( |
const std::string & |
name | ) |
|
|
staticprivate |
static SourceModelMod::SourceModel CSourceModel::from_int |
( |
unsigned int |
i | ) |
|
|
static |
Return a SourceModel's enumerator given an unsigned int.
- Parameters
-
i | the index of the enumerator in SourceModelMod::SourceModel. |
- Returns
- a SourceModelMod::SourceModel's enumerator.
- Exceptions
-
a | string containing an error message if no enumerator could be found for this integer. |
static SourceModelMod::SourceModel CSourceModel::literal |
( |
const std::string & |
name | ) |
|
|
static |
Return a SourceModel's enumerator given a string.
- Parameters
-
name | the string representation of the enumerator. |
- Returns
- a SourceModelMod::SourceModel's enumerator.
- Exceptions
-
a | string containing an error message if no enumerator could be found for this name. |
static std::string CSourceModel::name |
( |
const SourceModelMod::SourceModel & |
e | ) |
|
|
static |
Returns an enumerator as a string.
- Parameters
-
e | an enumerator of SourceModelMod::SourceModel. |
- Returns
- a string.
static const std::vector<std::string> CSourceModel::names |
( |
| ) |
|
|
static |
Returns vector of all the enumerators as strings.
The strings are stored in the vector in the same order than the enumerators are declared in the enumeration.
- Returns
- a vector of string.
static SourceModelMod::SourceModel CSourceModel::newSourceModel |
( |
const std::string & |
name | ) |
|
|
static |
Create a SourceModel enumeration object by specifying its name.
static std::string CSourceModel::revision |
( |
| ) |
|
|
static |
Return the revision as a string.
- Returns
- a string
static unsigned int CSourceModel::size |
( |
| ) |
|
|
static |
Return the number of enumerators declared in SourceModelMod::SourceModel.
- Returns
- an unsigned int.
static std::string CSourceModel::toString |
( |
const SourceModelMod::SourceModel & |
f | ) |
|
|
inlinestatic |
static int CSourceModel::version |
( |
| ) |
|
|
static |
Return the major version number as an int.
- Returns
- an int.
const std::string& CSourceModel::sDISK |
|
static |
const std::string& CSourceModel::sGAUSSIAN |
|
static |
Enumerators as strings.
A const string equal to "GAUSSIAN".
Definition at line 92 of file CSourceModel.h.
const std::string& CSourceModel::sPOINT |
|
static |
The documentation for this class was generated from the following file: