PythonQtWrapper_QReadWriteLock.h
31 lines
| 1.1 KiB
| text/x-c
|
CLexer
florianlink
|
r13 | #ifndef PYTHONQTWRAPPER_QREADWRITELOCK_H | ||
#define PYTHONQTWRAPPER_QREADWRITELOCK_H | ||||
#include <qreadwritelock.h> | ||||
#include <QObject> | ||||
florianlink
|
r24 | #include <PythonQt.h> | ||
florianlink
|
r13 | #include <QVariant> | ||
#include <qreadwritelock.h> | ||||
class PythonQtWrapper_QReadWriteLock : public QObject | ||||
{ Q_OBJECT | ||||
public: | ||||
Q_ENUMS(RecursionMode ) | ||||
enum RecursionMode{ | ||||
NonRecursive = QReadWriteLock::NonRecursive, Recursive = QReadWriteLock::Recursive}; | ||||
public slots: | ||||
QReadWriteLock* new_QReadWriteLock(); | ||||
QReadWriteLock* new_QReadWriteLock(QReadWriteLock::RecursionMode recursionMode); | ||||
void delete_QReadWriteLock(QReadWriteLock* obj) { delete obj; } | ||||
florianlink
|
r28 | bool tryLockForWrite(QReadWriteLock* theWrappedObject); | ||
florianlink
|
r13 | void lockForWrite(QReadWriteLock* theWrappedObject); | ||
florianlink
|
r28 | void lockForRead(QReadWriteLock* theWrappedObject); | ||
bool tryLockForRead(QReadWriteLock* theWrappedObject, int timeout); | ||||
florianlink
|
r13 | bool tryLockForRead(QReadWriteLock* theWrappedObject); | ||
florianlink
|
r28 | bool tryLockForWrite(QReadWriteLock* theWrappedObject, int timeout); | ||
florianlink
|
r24 | void unlock(QReadWriteLock* theWrappedObject); | ||
florianlink
|
r13 | }; | ||
#endif // PYTHONQTWRAPPER_QREADWRITELOCK_H | ||||