Trippin Cyril
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Protected Member Functions | List of all members
trippingcyril::thread::JobThread Class Reference

A job queue that will run your jobs on a seperate thread. More...

#include <JobThread.h>

Inheritance diagram for trippingcyril::thread::JobThread:
[legend]
Collaboration diagram for trippingcyril::thread::JobThread:
[legend]

Public Member Functions

 JobThread (const String &pName, const Module *pModule)
 
virtual ~JobThread ()
 
void Add (Job *job)
 
void AddFront (Job *job)
 
- Public Member Functions inherited from trippingcyril::thread::Thread
 Thread (const String &pName, const Module *pModule)
 
virtual ~Thread ()
 
bool Start ()
 Starts the thread. More...
 
bool Join ()
 Does a join operation on the thread. More...
 
bool Detach ()
 Does a detach operation on the thread. More...
 
pthread_t Self () const
 Get the internal thread id. More...
 
void Stop ()
 Tells the thread to stop. More...
 
bool isRunning () const
 See if the thread is running or not. More...
 
void * getReturnedValue () const
 Receive the value returned from the thread after a Join operation. More...
 
const String GetName () const
 Receive the name of the thread. More...
 
- Public Member Functions inherited from trippingcyril::trippingcyril::Event
 Event (const Module *module)
 
virtual ~Event ()
 
const ModuleGetModule () const
 

Protected Member Functions

JobRemove ()
 
void * run ()
 The method that is actually executed on the thread, override this. More...
 
- Protected Member Functions inherited from trippingcyril::thread::Thread
bool shouldContinue () const
 Receive a hint about what you should do, continue or not? Depends mostly on the internal stop value set by Stop. More...
 
- Protected Member Functions inherited from trippingcyril::trippingcyril::Event
event_base * GetEventBase () const
 
evdns_base * GetDNSBase () const
 

Additional Inherited Members

- Protected Attributes inherited from trippingcyril::trippingcyril::Event
const Modulemodule
 

Detailed Description

A job queue that will run your jobs on a seperate thread.

Constructor & Destructor Documentation

trippingcyril::thread::JobThread::JobThread ( const String pName,
const Module pModule 
)

Constructor

virtual trippingcyril::thread::JobThread::~JobThread ( )
virtual

Deconstructor

Member Function Documentation

void trippingcyril::thread::JobThread::Add ( Job job)

Add a new job to our job queue

void trippingcyril::thread::JobThread::AddFront ( Job job)

Add a new job to the front of our job queue

Job* trippingcyril::thread::JobThread::Remove ( )
protected
void* trippingcyril::thread::JobThread::run ( )
protectedvirtual

The method that is actually executed on the thread, override this.

Implements trippingcyril::thread::Thread.


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