#include <expandlib-vartype-numeric.h>
Inherits expander::expandvartype< StringType >< StringType >.
Inheritance diagram for expander::expvartype_numeric< StringType, NumType, NumTraits >:
Public Methods | |
expvartype_numeric () | |
Default contructor, inits the value to 0. | |
expvartype_numeric (const StringType &s) | |
Constructor with a parameter of type StringType, inits the value to 's' (converted). | |
expvartype_numeric (const _TCHAR *s) | |
Constructor with a C-style string as parameter, inits the value to 's' (converted). | |
expvartype_numeric (const NumType v) | |
Constructor with a number as parameter, inits the value to 's' (converted). | |
virtual void | AppendValue (StringType &dest) const throw () |
Appends the value of the var to a string. | |
virtual void | AppendValue (StringType &dest, const FParamVectorType ¶ms, const FVarMapType &vars, ExpandResultsType &results) const throw () |
Appends the value of the var to a string, using params and rvars, putting any expanding results into results. | |
virtual void | SetValue (const StringType &s) throw () |
Sets this variable to the string specified. | |
NumType | get_value () |
Returns the value. | |
void | set_value (const NumType v) |
Sets the value. | |
Protected Types | |
typedef ::std::vector< StringType > | FParamVectorType |
The type used for the parameter vectors (MSVC wouldn't allow me to use template arguments in these typedefs, or I don't know how it should be done). | |
typedef ::std::map< StringType, ::expander::expandvartype< StringType > * > | FVarMapType |
The type used for the map of variables (MSVC wouldn't allow me to use template arguments in these typedefs, or I don't know how it should be done). | |
Protected Attributes | |
NumType | val |
StringType | val_str |
This class can be used in the program using ExpandLib for simple numeric variables.
Definition at line 52 of file expandlib-vartype-numeric.h.
|
The type used for the parameter vectors (MSVC wouldn't allow me to use template arguments in these typedefs, or I don't know how it should be done).
Definition at line 52 of file expandlib-vartype.h. Referenced by expander::expvartype_list< StringType, ItemType >::AppendValue(). |
|
The type used for the map of variables (MSVC wouldn't allow me to use template arguments in these typedefs, or I don't know how it should be done).
Definition at line 53 of file expandlib-vartype.h. |
|
Default contructor, inits the value to 0.
Definition at line 60 of file expandlib-vartype-numeric.h. |
|
Constructor with a parameter of type StringType, inits the value to 's' (converted).
Definition at line 71 of file expandlib-vartype-numeric.h. References expander::expvartype_numeric< StringType, NumType, NumTraits >::set_value(). |
|
Constructor with a C-style string as parameter, inits the value to 's' (converted).
Definition at line 81 of file expandlib-vartype-numeric.h. References expander::expvartype_numeric< StringType, NumType, NumTraits >::set_value(). |
|
Constructor with a number as parameter, inits the value to 's' (converted).
Definition at line 91 of file expandlib-vartype-numeric.h. References expander::expvartype_numeric< StringType, NumType, NumTraits >::set_value(). |
|
Appends the value of the var to a string, using params and rvars, putting any expanding results into results. This is called directly from 'expandable<StringType>::expand', when a variable with parameters has been found. Implements expander::expandvartype< StringType >. Definition at line 98 of file expandlib-vartype-numeric.h. |
|
Appends the value of the var to a string. This is called by operator+=(StringType &s,::expander::expandvartype<StringType> *v), which is called by 'expandable<StringType>::expand' when a variable without parameters has been found. Implements expander::expandvartype< StringType >. Definition at line 93 of file expandlib-vartype-numeric.h. |
|
Returns the value.
Definition at line 113 of file expandlib-vartype-numeric.h. |
|
Sets the value.
Definition at line 116 of file expandlib-vartype-numeric.h. Referenced by expander::expvartype_numeric< StringType, NumType, NumTraits >::expvartype_numeric(), and expander::expvartype_numeric< StringType, NumType, NumTraits >::SetValue(). |
|
Sets this variable to the string specified. This isn't called from ExpandLib itself, but it can be used by other programs. Implements expander::expandvartype< StringType >. Definition at line 103 of file expandlib-vartype-numeric.h. References expander::expvartype_numeric< StringType, NumType, NumTraits >::set_value(). |
|
Definition at line 54 of file expandlib-vartype-numeric.h. |
|
Definition at line 55 of file expandlib-vartype-numeric.h. |