• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdelibs-4.14.38 API Reference
  • KDE Home
  • Contact Us
 

ThreadWeaver

  • threadweaver
  • Weaver
Thread.h
Go to the documentation of this file.
1/* -*- C++ -*-
2
3 This file declares the Thread class.
4
5 Thread is not a part of the public interface of the ThreadWeaver library.
6
7 $ Author: Mirko Boehm $
8 $ Copyright: (C) 2004-2013 Mirko Boehm $
9 $ Contact: mirko@kde.org
10 http://www.kde.org
11 http://creative-destruction.me $
12
13 This library is free software; you can redistribute it and/or
14 modify it under the terms of the GNU Library General Public
15 License as published by the Free Software Foundation; either
16 version 2 of the License, or (at your option) any later version.
17
18 This library is distributed in the hope that it will be useful,
19 but WITHOUT ANY WARRANTY; without even the implied warranty of
20 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 Library General Public License for more details.
22
23 You should have received a copy of the GNU Library General Public License
24 along with this library; see the file COPYING.LIB. If not, write to
25 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
26 Boston, MA 02110-1301, USA.
27
28 $Id: Thread.h 32 2005-08-17 08:38:01Z mirko $
29*/
30
31#ifndef THREADWEAVER_THREAD_H
32#define THREADWEAVER_THREAD_H
33
34#include <QtCore/QMutex>
35#include <QtCore/QThread>
36
37#include <threadweaver/threadweaver_export.h>
38
39namespace ThreadWeaver {
40
41 class Job;
42 class WeaverImpl;
43
46 class THREADWEAVER_EXPORT Thread : public QThread
47 {
48 Q_OBJECT
49
50 public:
57 explicit Thread ( WeaverImpl *parent = 0 );
58
60 ~Thread();
61
68 void run();
69
74 void msleep ( unsigned long msec );
75
85 unsigned int id();
86
92 void requestAbort();
93
94 Q_SIGNALS:
96 void started ( ThreadWeaver::Thread* );
98 void jobStarted ( ThreadWeaver::Thread*, ThreadWeaver::Job* );
100 void jobDone ( ThreadWeaver::Job* );
101
102 private:
103 class Private;
104 Private * const d;
105 };
106
107}
108
109#endif
110
111
QThread
ThreadWeaver::Job
A Job is a simple abstraction of an action that is to be executed in a thread context.
Definition: Job.h:66
ThreadWeaver::Thread
The class Thread is used to represent the worker threads in the weaver's inventory.
Definition: Thread.h:47
ThreadWeaver::Thread::started
void started(ThreadWeaver::Thread *)
The thread has been started.
ThreadWeaver::Thread::jobStarted
void jobStarted(ThreadWeaver::Thread *, ThreadWeaver::Job *)
The thread started to process a job.
ThreadWeaver::Thread::jobDone
void jobDone(ThreadWeaver::Job *)
The thread finished to execute a job.
ThreadWeaver::WeaverImpl
A WeaverImpl is the manager of worker threads (Thread objects) to which it assigns jobs from its queu...
Definition: WeaverImpl.h:52
ThreadWeaver
Definition: DebuggingAids.h:51
threadweaver_export.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Feb 20 2023 00:00:00 by doxygen 1.9.6 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

ThreadWeaver

Skip menu "ThreadWeaver"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdelibs-4.14.38 API Reference

Skip menu "kdelibs-4.14.38 API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal