Embedded Template Library  1.0
 All Classes Files Functions Variables Typedefs Friends Modules Pages
etl::stack< T, SIZE > Class Template Reference

#include <stack.h>

Public Member Functions

 stack ()
 Default constructor.
 
void swap (stack &other)
 Swap.
 
- Public Member Functions inherited from etl::istack< T >
reference top ()
 
void push (parameter_t item)
 
reference push ()
 
const_reference top () const
 
- Public Member Functions inherited from etl::stack_base
bool empty () const
 
bool full () const
 
size_type size () const
 Returns the current number of items top the stack.
 
size_type capacity () const
 Returns the maximum number of items that can be stacked.
 
size_type max_size () const
 Returns the maximum number of items that can be stacked.
 
size_t available () const
 
void clear ()
 Clears the stack to the empty state.
 
void pop ()
 

Additional Inherited Members

- Public Types inherited from etl::istack< T >
typedef T value_type
 The type stored in the stack.
 
typedef T & reference
 A reference to the type used in the stack.
 
typedef const T & const_reference
 A const reference to the type used in the stack.
 
typedef T * pointer
 A pointer to the type used in the stack.
 
typedef const T * const_pointer
 A const pointer to the type used in the stack.
 
typedef stack_base::size_type size_type
 The type used for determining the size of the stack.
 
- Public Types inherited from etl::stack_base
typedef size_t size_type
 The type used for determining the size of stack.
 
- Protected Member Functions inherited from etl::istack< T >
 istack (T *buffer, size_type max_size)
 The constructor that is called from derived classes.
 
- Protected Member Functions inherited from etl::stack_base
 stack_base (size_type max_size)
 The constructor that is called from derived classes.
 
- Protected Attributes inherited from etl::stack_base
size_type top_index
 The index of the top of the stack.
 
size_type current_size
 The number of items in the stack.
 
const size_type MAX_SIZE
 The maximum number of items in the stack.
 

Detailed Description

template<typename T, const size_t SIZE>
class etl::stack< T, SIZE >

A fixed capacity stack. This stack does not support concurrent access by different threads.

Note
Uses a predefined array, so MAX_SIZE_ elements will be always be constructed.
Template Parameters
TThe type this stack should support.
SIZEThe maximum capacity of the stack.

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