Orocos Real-Time Toolkit  2.8.3
Public Member Functions | Public Attributes | Protected Types | List of all members
RTT::os::rt_list< T, Alloc > Struct Template Reference

Implements a list with real-time insertion/removal of elements. More...

#include <rtt/os/rt_list.hpp>

Inheritance diagram for RTT::os::rt_list< T, Alloc >:

Public Member Functions

 ~rt_list ()
 
void rt_grow (std::size_t items)
 Grow memory pool for list elements. More...
 
void rt_shrink (std::size_t items)
 Shrink memory pool. More...
 

Public Attributes

elements
 STL member. More...
 

Protected Types

typedef std::list< T, local_allocator< T, Alloc > >::_Node ItemType
 

Detailed Description

template<class T, class Alloc = std::allocator<T>>
struct RTT::os::rt_list< T, Alloc >

Implements a list with real-time insertion/removal of elements.

All std::list<T> functions remain available, but use rt_ functions to grow or shrink a memory pool of list items.

Parameters
TThe value stored in the list.
AllocThe allocator which effectivily ( in the end ) allocates the memory.

Definition at line 56 of file rt_list.hpp.

Member Typedef Documentation

template<class T , class Alloc = std::allocator<T>>
typedef std::list<T, local_allocator<T,Alloc> >::_Node RTT::os::rt_list< T, Alloc >::ItemType
protected

Definition at line 60 of file rt_list.hpp.

Constructor & Destructor Documentation

template<class T , class Alloc = std::allocator<T>>
RTT::os::rt_list< T, Alloc >::~rt_list ( )
inline

Definition at line 62 of file rt_list.hpp.

References RTT::os::rt_list< T, Alloc >::rt_shrink().

Member Function Documentation

template<class T , class Alloc = std::allocator<T>>
void RTT::os::rt_list< T, Alloc >::rt_grow ( std::size_t  items)
inline

Grow memory pool for list elements.

Exceptions
bad_allocif no more memory available.

Definition at line 71 of file rt_list.hpp.

References RTT::os::local_allocator< T, Alloc >::grow().

template<class T , class Alloc = std::allocator<T>>
void RTT::os::rt_list< T, Alloc >::rt_shrink ( std::size_t  items)
inline

Shrink memory pool.

Definition at line 80 of file rt_list.hpp.

References RTT::os::local_allocator< T, Alloc >::shrink().

Referenced by RTT::os::rt_list< T, Alloc >::~rt_list().

Member Data Documentation

T std::list< T >::elements
inherited

STL member.


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