Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

Stack Class Template Reference

Template class representing stack. More...

#include <stack.h>

Inheritance diagram for Stack:

Collection List of all members.

Public Methods

 Stack (void)
 A constructor. More...

virtual ~Stack (void)
 A destructor. More...

virtual T_ * top (void)
 Get the data from the top of the stack. More...

virtual void push (T_ *item)
 Push data. More...

virtual T_ * pop (void)
 Pop data. More...

virtual void clear (void)
 Empty the stack. More...


Protected Methods

virtual void initStack (void)
 Initialize the stack.


Protected Attributes

StackLinkedList< T_ > * topNode_
 Linked list of items of the stack.


Detailed Description

template<class T_>
class Stack< T_ >

Template class representing stack.

Definition at line 51 of file stack.h.


Constructor & Destructor Documentation

template<class T_>
Stack< T_ >::Stack void    [inline]
 

A constructor.

Calls initStack()

Definition at line 59 of file stack.h.

template<class T_>
virtual Stack< T_ >::~Stack void    [inline, virtual]
 

A destructor.

Calls clear()

Definition at line 66 of file stack.h.


Member Function Documentation

template<class T_>
virtual void Stack< T_ >::clear void    [inline, virtual]
 

Empty the stack.

If auto deletion is enabled, all data items will be removed from memory.

See also:
setAutoDelete()

Implements Collection.

Definition at line 149 of file stack.h.

Referenced by ElementModelEntropyCalculator::calculate, and Stack< ElementModelerInfo >::~Stack.

template<class T_>
virtual T_* Stack< T_ >::pop void    [inline, virtual]
 

Pop data.

Returns:
Pointer to data.

Definition at line 119 of file stack.h.

Referenced by ElementModelEntropyCalculator::calculate.

template<class T_>
virtual void Stack< T_ >::push T_ *    item [inline, virtual]
 

Push data.

Parameters:
item  Pointer to pushed data.

Definition at line 94 of file stack.h.

Referenced by ElementModelEntropyCalculator::calculate.

template<class T_>
virtual T_* Stack< T_ >::top void    [inline, virtual]
 

Get the data from the top of the stack.

Top item isn't tremoved.

Returns:
Pointer to the data.

Definition at line 77 of file stack.h.


The documentation for this class was generated from the following file:
Generated on Wed Feb 5 10:43:06 2003 for Exalt by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002