Dune::FiniteStack< T, n > Class Template Reference
[Common (foundation classes)]

A stack with static memory allocation. More...

#include <dune/common/finitestack.hh>

List of all members.

Public Member Functions

bool empty () const
 Returns true if the stack is empty.
bool full () const
 Returns true if the stack is full.
void push (const T &t)
 Puts a new object onto the stack.
pop ()
 Removes and returns the uppermost object from the stack.
top () const
 Returns the uppermost object on the stack.
int size () const
 Dynamic stacksize.
 FiniteStack ()
 Makes empty stack.

Detailed Description

template<class T, int n>
class Dune::FiniteStack< T, n >

A stack with static memory allocation.

This class implements a very efficient stack where the maximum depth is known in advance. Note that no error checking is performed!

Parameters:
n Maximum number of stack entries

Member Function Documentation

template<class T , int n>
bool Dune::FiniteStack< T, n >::empty (  )  const [inline]

Returns true if the stack is empty.

Referenced by Dune::FiniteStack< T, n >::pop(), and Dune::FiniteStack< T, n >::top().


The documentation for this class was generated from the following file:
Generated on Mon Apr 26 10:45:23 2010 for dune-common by  doxygen 1.6.3