libtdepim

weaverextensions.h
1 /* -*- C++ -*-
2 
3  This file declares the Weaver Extensions basics.
4 
5  $ Author: Mirko Boehm $
6  $ Copyright: (C) 2004, Mirko Boehm $
7  $ Contact: mirko@kde.org
8  http://www.kde.org
9  http://www.hackerbuero.org $
10  $ License: LGPL with the following explicit clarification:
11  This code may be linked against any version of the TQt toolkit
12  from Troll Tech, Norway. $
13 
14 */
15 
16 #ifndef WEAVEREXTENSIONS_H
17 #define WEAVEREXTENSIONS_H
18 
19 #include <tqobject.h>
20 
21 namespace KPIM {
22 namespace ThreadWeaver {
23 
24  class Weaver;
25  class Thread;
26 
33  class WeaverExtension : public TQObject
34  {
35  Q_OBJECT
36 
37  public:
38  WeaverExtension ( TQObject *parent = 0, const char *name = 0);
42  void attach (Weaver *);
43  virtual ~WeaverExtension() = 0;
44  public slots:
45  // these methods are implemented, but do nothing in the default configuration
46  // a thread is created:
47  virtual void threadCreated (Thread *);
48  // a thread is destroyed:
49  virtual void threadDestroyed (Thread *);
50  // the thread is processing a job
51  virtual void threadBusy (Thread *);
52  // the thread is suspended and will be waked when jobs become
53  // available
54  virtual void threadSuspended (Thread *);
55  };
56 
57 } // namespace ThreadWeaver
58 }
59 
60 #endif // WEAVEREXTENSIONS_H
A weaver is the manager of worker threads (Thread objects) to which it assigns jobs from it&#39;s queue...
Definition: weaver.h:297
void attach(Weaver *)
Attach() is a convenience method that will connect all our slots to signals emitted by the weaver...
A WeaverExtension can be attached to an existing Weaver object and will then receive signals on actio...
TDEPIM classes for drag and drop of mails.
The class Thread is used to represent the worker threads in the weaver&#39;s inventory.
Definition: weaver.h:250