This repository has been archived by the owner on May 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 24
/
QtDispatch.dox
35 lines (27 loc) · 1.58 KB
/
QtDispatch.dox
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/**
@defgroup qtdispatch libQtDispatch
QtDispatch is an additional Qt Module building on QtCore and providing a custom Qt adapted interface to use \ref dispatch.
This interface is fully compatible with the generic C++ interface provided by
\ref xdispatch.
As integration into Qt, it is possible to dispatch QRunnables onto groups and queues the same way as when executing them on a QThreadPool. Going along with that we added
QBlockRunnable, a simple QRunnable created by passing an individual block.
For integrating the main queue into your Qt Application there is a QDispatchApplication which can be used as a drop-in replacement to QApplication. It will call xdispatch::exec() internally and ensure that all work dispatched to the main queue is executed on the main/gui thread. That way it is very easy to send gui updates to the main thread. All other functionality is equal to that of QApplication.
@section qt_use Usage
You can use QtDispach (in case you have Qt > 4.6 available on your system) by including the QtDispatch header or one of the individual modules - this will automatically include all other needed headers as well. Below you find a list of the available classes.
- QDispatch
- QDispatchQueue
- QDispatchGroup
- QDispatchSemaphore
- QBlockRunnable
- QIterationBlockRunnable
- QIterationRunnable
- QDispatchCoreApplication
- QDispatchApplication
- QDispatchSource
- QDispatchSourceType
The corresponding headers have the same name and can be included all by once using
@code
#include <QtDispatch/QtDispatch>
@endcode
Please link your program with qtdispatch and xdispatch.
*/