Antiprism 0.23

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Member Functions

# mu::ParserStack< TValueType > Class Template Reference

Parser stack implementation. More...

`#include <muParserStack.h>`

List of all members.

## Public Member Functions
TValueType | pop ()
| Pop a value from the stack.
void | push (const TValueType &a_Val)
| Push an object into the stack.
unsigned | size () const
| Return the number of stored elements.
bool | empty () const
| Returns true if stack is empty false otherwise.
TValueType & | top ()
| Return reference to the top object in the stack.

## Detailed Description

### template<typename TValueType>
class mu::ParserStack< TValueType >

Parser stack implementation.

Stack implementation based on a std::stack. The behaviour of pop() had been slightly changed in order to get an error code if the stack is empty. The stack is used within the Parser both as a value stack and as an operator stack.

Author:
  (C) 2004-2011 Ingo Berg

## Member Function Documentation

template<typename TValueType >

TValueType mu::ParserStack< TValueType >::pop | ( |  | ) | `[inline]`

Pop a value from the stack.

Unlike the standard implementation this function will return the value that is going to be taken from the stack.

Exceptions:

  ParserException | in case the stack is empty.

See also:
  pop(int &a_iErrc)

template<typename TValueType >

void mu::ParserStack< TValueType >::push | ( | const TValueType & | a_Val | ) | `[inline]`

Push an object into the stack.

Parameters:

  a_Val | object to push into the stack.

Exceptions:

  nothrow |

template<typename TValueType >

TValueType& mu::ParserStack< TValueType >::top | ( |  | ) | `[inline]`

Return reference to the top object in the stack.

The top object is the one pushed most recently.

The documentation for this class was generated from the following file:

- base/muparser/muParserStack.h