ISAAC
Overview :: Library Doc :: Server Doc :: JSON Commands

In Situ Animation of Accelerated Computations

Classes | Public Types | Public Member Functions | Public Attributes | List of all members
ThreadList< T > Class Template Reference

#include <ThreadList.hpp>

Collaboration diagram for ThreadList< T >:
Collaboration graph
[legend]

Classes

struct  ThreadListContainer_struct
 

Public Types

typedef struct ThreadList::ThreadListContainer_struct ThreadListContainer
 
typedef struct ThreadListContainer_structThreadListContainer_ptr
 

Public Member Functions

 ThreadList ()
 
void push_back (T t)
 
pop_front ()
 
int length ()
 
 ~ThreadList ()
 
ThreadListContainer_ptr getFront ()
 
remove (ThreadListContainer_ptr ptr)
 

Public Attributes

volatile ThreadListContainer_ptr front
 
volatile ThreadListContainer_ptr back
 
pthread_mutex_t remove_mutex
 
int l
 

Detailed Description

template<typename T>
class ThreadList< T >

This is a special list, where one (!) thread can push back while one (!) can pop_front with only one mutex needed and (hopefully) not too much busy waiting However there are some rules:

Definition at line 29 of file ThreadList.hpp.

Member Typedef Documentation

§ ThreadListContainer

template<typename T>
typedef struct ThreadList::ThreadListContainer_struct ThreadList< T >::ThreadListContainer

§ ThreadListContainer_ptr

template<typename T>
typedef struct ThreadListContainer_struct* ThreadList< T >::ThreadListContainer_ptr

Definition at line 37 of file ThreadList.hpp.

Constructor & Destructor Documentation

§ ThreadList()

template<typename T>
ThreadList< T >::ThreadList ( )
inline

Definition at line 38 of file ThreadList.hpp.

§ ~ThreadList()

template<typename T>
ThreadList< T >::~ThreadList ( )
inline

Definition at line 81 of file ThreadList.hpp.

Member Function Documentation

§ getFront()

template<typename T>
ThreadListContainer_ptr ThreadList< T >::getFront ( )
inline

Definition at line 87 of file ThreadList.hpp.

§ length()

template<typename T>
int ThreadList< T >::length ( )
inline

Definition at line 77 of file ThreadList.hpp.

§ pop_front()

template<typename T>
T ThreadList< T >::pop_front ( )
inline

Definition at line 59 of file ThreadList.hpp.

§ push_back()

template<typename T>
void ThreadList< T >::push_back ( t)
inline

Definition at line 45 of file ThreadList.hpp.

§ remove()

template<typename T>
T ThreadList< T >::remove ( ThreadListContainer_ptr  ptr)
inline

Definition at line 91 of file ThreadList.hpp.

Member Data Documentation

§ back

template<typename T>
volatile ThreadListContainer_ptr ThreadList< T >::back

Definition at line 125 of file ThreadList.hpp.

§ front

template<typename T>
volatile ThreadListContainer_ptr ThreadList< T >::front

Definition at line 124 of file ThreadList.hpp.

§ l

template<typename T>
int ThreadList< T >::l

Definition at line 127 of file ThreadList.hpp.

§ remove_mutex

template<typename T>
pthread_mutex_t ThreadList< T >::remove_mutex

Definition at line 126 of file ThreadList.hpp.


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