libmoost
moost::thread::simple_job_batch Class Reference

#include <simple_job_scheduler.hpp>

Inheritance diagram for moost::thread::simple_job_batch:
Collaboration diagram for moost::thread::simple_job_batch:

List of all members.

Public Member Functions

 simple_job_batch ()
virtual void add (job_t job)
void run ()
size_t count () const
const std::vector< std::string > & errors () const

Private Attributes

size_t m_count
std::vector< std::string > m_errors

Detailed Description

Definition at line 44 of file simple_job_scheduler.hpp.


Constructor & Destructor Documentation


Member Function Documentation

virtual void moost::thread::simple_job_batch::add ( job_t  job) [inline, virtual]

Add a new job to the batch

This method adds a job to the concrete implementation. When this job gets run is determined by the implementation. However, new jobs may be added even while jobs from the current batch are being run as long as the batch doesn't run out of jobs. In particular, this means that it's always safe to add new jobs from within jobs of the current batch.

Parameters:
jobThe job to be added.

Implements moost::thread::job_batch.

Definition at line 53 of file simple_job_scheduler.hpp.

size_t moost::thread::simple_job_batch::count ( ) const [inline]

Definition at line 75 of file simple_job_scheduler.hpp.

const std::vector<std::string>& moost::thread::simple_job_batch::errors ( ) const [inline]

Definition at line 80 of file simple_job_scheduler.hpp.

Definition at line 71 of file simple_job_scheduler.hpp.


Member Data Documentation

Definition at line 86 of file simple_job_scheduler.hpp.

std::vector<std::string> moost::thread::simple_job_batch::m_errors [private]

Definition at line 87 of file simple_job_scheduler.hpp.


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