kget
JobQueue Class Reference
#include <jobqueue.h>

Detailed Description
Definition at line 32 of file jobqueue.h.
Public Types | |
| enum | Status { Running, Stopped } |
| typedef QList< Job * >::iterator | iterator |
Public Member Functions | |
| JobQueue (Scheduler *scheduler) | |
| virtual | ~JobQueue () |
| virtual void | setStatus (Status queueStatus) |
| Status | status () const |
| iterator | begin () |
| iterator | end () |
| Job * | last () |
| int | size () const |
| int | indexOf (Job *job) const |
| Job * | operator[] (int i) const |
| const QList< Job * > | runningJobs () |
| void | setMaxSimultaneousJobs (int n) |
| int | maxSimultaneousJobs () const |
Protected Member Functions | |
| void | append (Job *job) |
| void | prepend (Job *job) |
| void | insert (Job *job, Job *after) |
| void | remove (Job *job) |
| void | move (Job *job, Job *after) |
| Scheduler * | scheduler () |
Member Typedef Documentation
| typedef QList<Job *>::iterator JobQueue::iterator |
Definition at line 36 of file jobqueue.h.
Member Enumeration Documentation
| enum JobQueue::Status |
Constructor & Destructor Documentation
| JobQueue::JobQueue | ( | Scheduler * | scheduler | ) |
Definition at line 19 of file jobqueue.cpp.
| JobQueue::~JobQueue | ( | ) | [virtual] |
Definition at line 27 of file jobqueue.cpp.
Member Function Documentation
| void JobQueue::setStatus | ( | Status | queueStatus | ) | [virtual] |
Sets the JobQueue status.
- Parameters:
-
queueStatus the new JobQueue status
Reimplemented in TransferGroup.
Definition at line 52 of file jobqueue.cpp.
| Status JobQueue::status | ( | ) | const [inline] |
| iterator JobQueue::begin | ( | ) | [inline] |
| iterator JobQueue::end | ( | ) | [inline] |
| Job* JobQueue::last | ( | ) | [inline] |
| int JobQueue::size | ( | ) | const [inline] |
| int JobQueue::indexOf | ( | Job * | job | ) | const [inline] |
- Parameters:
-
job The job for which we want to find the index
- Returns:
- the job index for the given job. If the given job can't be found, it returns -1
Definition at line 79 of file jobqueue.h.
| Job * JobQueue::operator[] | ( | int | i | ) | const |
- Returns:
- the Job in the queue at the given index i
Reimplemented in TransferGroup.
Definition at line 32 of file jobqueue.cpp.
| void JobQueue::setMaxSimultaneousJobs | ( | int | n | ) |
Sets the maximum number of jobs belonging to this queue that should executed simultaneously by the scheduler.
- Parameters:
-
n The maximum number of jobs
| int JobQueue::maxSimultaneousJobs | ( | ) | const |
- Returns:
- the maximum number of jobs the scheduler should ever execute simultaneously (in this queue).
Definition at line 79 of file jobqueue.cpp.
| void JobQueue::append | ( | Job * | job | ) | [protected] |
appends a job to the current queue
- Parameters:
-
job The job to append to the current queue
Definition at line 87 of file jobqueue.cpp.
| void JobQueue::prepend | ( | Job * | job | ) | [protected] |
prepends a job to the current queue
- Parameters:
-
job The job to prepend to the current queue
Definition at line 94 of file jobqueue.cpp.
inserts a job to the current queue after the given job
- Parameters:
-
job The job to add in the current queue after The job after which to add the job
Definition at line 101 of file jobqueue.cpp.
| void JobQueue::remove | ( | Job * | job | ) | [protected] |
removes a job from the current queue
- Parameters:
-
job The job to remove from the current queue
Definition at line 110 of file jobqueue.cpp.
Moves a job in the queue.
Both the given jobs must belong to this queue
- Parameters:
-
job The job to move position The job after which we have to move the given job
Definition at line 117 of file jobqueue.cpp.
| Scheduler* JobQueue::scheduler | ( | ) | [inline, protected] |
Definition at line 143 of file jobqueue.h.
The documentation for this class was generated from the following files:
KDE 4.0 API Reference