-
Notifications
You must be signed in to change notification settings - Fork 0
stack.h
Baptiste Thémine edited this page Feb 11, 2020
·
8 revisions
#include <JLC/stack.h>
Definition of LIFO container class extending Collection.
LIFO = Last In First Out. A stack is a constrained set of elements similar to a list but provides a subset of setter methods (push and pop) and gives only access to its last element. Zero-sized stacks are valid but cannot be dereferenced. Once modifications are completed, a stack can then be transformed into a stream to perform search and sorting operations.
- (Mandatory)
<cstdio>
,<cstdlib>
,<iostream>
,<iterator>
,<stdexcept>
,<JLC/debug.h>
,<JLC/functions.h>
and<JLC/collection.h>
must be included. - (Optional)
<functional>
and<initializer_list>
provide additional features from C++11.
Name | Description |
---|---|
stack | Defines the namespace stack and provides types, constants, exceptions and utility functions for stack manipulation. |
Stack | Defines the class Stack and provides stack methods. |
collectors | Provides classes for stream collect operations. |