example::slice< T, S > Class Template Reference

Present a slice of the top of a stack. More...

#include <stack.hh>

List of all members.

Public Member Functions

 slice (const S &stack, unsigned int range)
const T & operator[] (unsigned int i) const

Private Attributes

const S & stack_
unsigned int range_


Detailed Description

template<class T, class S = stack<T>>
class example::slice< T, S >

Present a slice of the top of a stack.

Definition at line 105 of file stack.hh.


Constructor & Destructor Documentation

template<class T, class S = stack<T>>
example::slice< T, S >::slice ( const S &  stack,
unsigned int  range 
) [inline]

Definition at line 109 of file stack.hh.


Member Function Documentation

template<class T, class S = stack<T>>
const T& example::slice< T, S >::operator[] ( unsigned int  i  )  const [inline]

Definition at line 117 of file stack.hh.

References example::slice< T, S >::range_, and example::slice< T, S >::stack_.


Member Data Documentation

template<class T, class S = stack<T>>
const S& example::slice< T, S >::stack_ [private]

Definition at line 124 of file stack.hh.

Referenced by example::slice< T, S >::operator[]().

template<class T, class S = stack<T>>
unsigned int example::slice< T, S >::range_ [private]

Definition at line 125 of file stack.hh.

Referenced by example::slice< T, S >::operator[]().


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

Generated on Thu Oct 23 11:13:54 2008 for Flex Bison C++ Example by  doxygen 1.5.6