#include <stack.h>
Collaboration diagram for stack< stack_type, stack_max >:
Public Member Functions | |
stack (void) | |
bool | empty (void) |
void | reset (void) |
void | push (stack_type &val) |
stack_type | pop (void) |
Private Attributes | |
stack_type | stak [stack_max] |
unsigned int | ix |
This template is instantiated with the stack type and the stack size. For example:
stack<my_type, 128> my_stack;creates a stack that can hold up to 128 elements of my_type.
Definition at line 31 of file stack.h.
Constructor & Destructor Documentation
|
Definition at line 38 of file stack.h. References stack< stack_type, stack_max >::ix.
00038 { ix = stack_max; } |
|
Definition at line 40 of file stack.h. References stack< stack_type, stack_max >::ix.
00040 { return ix == stack_max; } |
|
Definition at line 51 of file stack.h. References stack< stack_type, stack_max >::ix, and stack< stack_type, stack_max >::stak.
|
|
Definition at line 44 of file stack.h. References stack< stack_type, stack_max >::ix, and stack< stack_type, stack_max >::stak.
|
|
Definition at line 42 of file stack.h. References stack< stack_type, stack_max >::ix.
00042 { ix = stack_max; } |
|
Definition at line 35 of file stack.h. Referenced by stack< stack_type, stack_max >::empty(), stack< stack_type, stack_max >::pop(), stack< stack_type, stack_max >::push(), stack< stack_type, stack_max >::reset(), and stack< stack_type, stack_max >::stack(). |
|
Definition at line 34 of file stack.h. Referenced by stack< stack_type, stack_max >::pop(), and stack< stack_type, stack_max >::push(). |