Calculator
Extensible stack-based calculator primarily in library form
|
Container of Calculator resources. More...
Namespaces | |
Error | |
Error / Return values of Stack Operations to ensure consistency. | |
Factories | |
Classes | |
class | StackIteratorPimpl |
class | StackPimpl |
class | StackOperatorFactoryPimpl |
class | VariableSetPimpl |
class | BinaryMathOperator |
Stack Modifier for Binary Math Operations. More... | |
class | BinaryMathCreator |
Create BinaryMathOperation from a string. More... | |
class | Executive |
Drivable class to run the calculator with a variable factory per process call to support changing command sets. More... | |
class | FixedOperatorExecutive |
Drivable class to run the calculator with a single set of commands. More... | |
class | Number |
StackItem representing a number. More... | |
class | NumberCreator |
Creates Numbers from strings that convert to numbers. More... | |
class | Result |
Collection of Result information for an operation. More... | |
class | StackIterator |
Iterator over a Stack from top to bottom. More... | |
class | Stack |
Stack of values to process from. More... | |
class | StackItem |
Base class of all items that can be on the stack. More... | |
class | StackManipulator |
Stack Modifier for Stack Operations. More... | |
class | StackManipulatorCreator |
Create StackManipulator from a string. More... | |
class | StackOperator |
Base class for all operators. More... | |
class | StackOperatorCreator |
Factory creators of StackOperator::Ptrs. More... | |
class | StackOperatorFactory |
Factory to create StackOperators and help from StackOperatorCreators. More... | |
class | Variable |
StackItem representing a variable. More... | |
class | VariableCreator |
Creates Variables from strings that convert to variables. More... | |
class | VariableManipulator |
Variable Modifier for Variable Operations. More... | |
class | VariableManipulatorCreator |
Create VariableManipulator from a string. More... | |
class | VariableSet |
All variables belonging to a Stack. More... | |
Functions | |
StackIterator & | operator>> (StackIterator &iter, StackIterator::Hint hint) |
Set the iter's hint and return the iter. More... | |
StackIterator & | operator>> (StackIterator &iter, StackItem::Ptr &t) |
StackIterator & | operator>> (StackIterator &iter, std::shared_ptr< StackItem > &t) |
Set t to *iter and return iter. More... | |
template<typename T > | |
StackIterator & | operator>> (StackIterator &iter, T &t) |
Convenience function to read the current value of iter by the template as() (respecting the current hint) and set to t. More... | |
Container of Calculator resources.
StackIterator& Calculator::operator>> | ( | StackIterator & | iter, |
StackItem::Ptr & | t | ||
) |
StackIterator & Calculator::operator>> | ( | StackIterator & | iter, |
StackIterator::Hint | hint | ||
) |
StackIterator& Calculator::operator>> | ( | StackIterator & | iter, |
std::shared_ptr< StackItem > & | t | ||
) |
Set t to *iter and return iter.
iter | to read from |
t | to set *iter into |
StackIterator& Calculator::operator>> | ( | StackIterator & | iter, |
T & | t | ||
) |
Convenience function to read the current value of iter by the template as() (respecting the current hint) and set to t.
If the cast fails in t, the set value is empty
T | desired type to cast the value to |
iter | to read from |
t | to set iter.as<T>() into |