|
|
|
NamedEnum Class Template ReferenceInheritance diagram for NamedEnum:![]() ![]() Detailed Descriptiontemplate<class Enum, int nEnum>
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Public Member Functions | |
| NamedEnum () | |
| Construct from names. | |
| const Enum | read (Istream &is) const |
| Read a word from Istream and return the corresponding. | |
| const Enum | operator[] (const char *name) const |
| Return the enumeration element corresponding to the given name. | |
| const Enum | operator[] (const word &name) const |
| Return the enumeration element corresponding to the given name. | |
| const char * | operator[] (const Enum e) const |
| Return the name or the given enumeration element. | |
Static Public Attributes | |
| static const char * | names [nEnum] |
| The set of names corresponding to the enumeration Enum. | |
| NamedEnum | ( | ) |
Construct from names.
| const Enum read | ( | Istream & | is | ) | const [inline] |
Read a word from Istream and return the corresponding.
enumeration element
Definition at line 90 of file NamedEnum.H.
| const Enum operator[] | ( | const char * | name | ) | const [inline] |
Return the enumeration element corresponding to the given name.
Definition at line 113 of file NamedEnum.H.
| const Enum operator[] | ( | const word & | name | ) | const [inline] |
Return the enumeration element corresponding to the given name.
Reimplemented from HashTable< int >.
Definition at line 119 of file NamedEnum.H.
| const char* operator[] | ( | const Enum | e | ) | const [inline] |
const char* names[nEnum] [static] |