OpenJAUS SAE SDK  6.0.0
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
openjaus::system::AbstractQueue< Type > Class Template Referenceabstract

#include <Queue.h>

Inherits openjaus::system::IQueue< Type >.

Inherited by openjaus::system::Queue< Type >.

Public Member Functions

 AbstractQueue ()
 
virtual ~AbstractQueue ()
 
bool isEmpty () const
 
int getSize () const
 
void push (Type item)
 
Type pop ()
 
bool timedWait_ms (int value)
 
void wakeAll ()
 Wake up all threads that might be in a timedWait state. More...
 
void flush ()
 
- Public Member Functions inherited from openjaus::system::IQueue< Type >
 IQueue ()
 
virtual ~IQueue ()
 

Protected Member Functions

virtual void pushInternal (Type item, std::list< Type > &objects)
 
virtual void flushInternal (std::list< Type > &objects)=0
 

Private Attributes

Mutex mutex
 
Condition condition
 
std::list< Type > objects
 

Constructor & Destructor Documentation

◆ AbstractQueue()

template<typename Type>
openjaus::system::AbstractQueue< Type >::AbstractQueue ( )
inline

◆ ~AbstractQueue()

template<typename Type>
virtual openjaus::system::AbstractQueue< Type >::~AbstractQueue ( )
inlinevirtual

Member Function Documentation

◆ flush()

template<typename Type>
void openjaus::system::AbstractQueue< Type >::flush ( )
inlinevirtual

◆ flushInternal()

template<typename Type>
virtual void openjaus::system::AbstractQueue< Type >::flushInternal ( std::list< Type > &  objects)
protectedpure virtual

◆ getSize()

template<typename Type>
int openjaus::system::AbstractQueue< Type >::getSize ( ) const
inlinevirtual

◆ isEmpty()

template<typename Type>
bool openjaus::system::AbstractQueue< Type >::isEmpty ( ) const
inlinevirtual

◆ pop()

template<typename Type>
Type openjaus::system::AbstractQueue< Type >::pop ( )
inlinevirtual

◆ push()

template<typename Type>
void openjaus::system::AbstractQueue< Type >::push ( Type  item)
inlinevirtual

◆ pushInternal()

template<typename Type>
virtual void openjaus::system::AbstractQueue< Type >::pushInternal ( Type  item,
std::list< Type > &  objects 
)
inlineprotectedvirtual

◆ timedWait_ms()

template<typename Type>
bool openjaus::system::AbstractQueue< Type >::timedWait_ms ( int  value)
inlinevirtual

◆ wakeAll()

template<typename Type>
void openjaus::system::AbstractQueue< Type >::wakeAll ( )
inlinevirtual

Member Data Documentation

◆ condition

template<typename Type>
Condition openjaus::system::AbstractQueue< Type >::condition
private

◆ mutex

template<typename Type>
Mutex openjaus::system::AbstractQueue< Type >::mutex
private

◆ objects

template<typename Type>
std::list<Type> openjaus::system::AbstractQueue< Type >::objects
private

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