Google

template<class T> class osg::fast_back_stack

Simple stack implementation that keeps the back() cached locally for fast access rather than at the back of the vector which is the traditional stack implementation.

Public Fields

[more]T _value
[more]std::vector<T> _stack
[more]unsigned int _size

Public Methods

[more]inline fast_back_stack()
[more]inline fast_back_stack(const fast_back_stack& fbs)
[more]inline fast_back_stack(const T& value)
[more]fast_back_stack& operator = (const fast_back_stack& fbs)
[more]inline void clear()
[more]inline bool empty() const
[more]inline unsigned int size() const
[more]inline T& back()
[more]inline const T& back() const
[more]inline void push_back()
[more]inline void push_back(const T& value)
[more]inline void pop_back()


Documentation

Simple stack implementation that keeps the back() cached locally for fast access rather than at the back of the vector which is the traditional stack implementation. A conventional std::vector<> stores the rest of the stack. The fast_back_stack although contains a stl container it only implments the back push_back(),pop_back() and back() methods so is not as general purpose as stl stack implementation. The focus of the fast_back_stack is purly to maximize the speed at which the back can be accessed.
oinline fast_back_stack()

oinline fast_back_stack(const fast_back_stack& fbs)

oinline fast_back_stack(const T& value)

ofast_back_stack& operator = (const fast_back_stack& fbs)

oinline void clear()

oinline bool empty() const

oinline unsigned int size() const

oinline T& back()

oinline const T& back() const

oinline void push_back()

oinline void push_back(const T& value)

oinline void pop_back()

oT _value

ostd::vector<T> _stack

ounsigned int _size


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.