|
QEverCloud
3.0.0
Unofficial Evernote Cloud API for Qt
|
Returned by asynchonous versions of functions. More...
#include <AsyncResult.h>
Public Types | |
| typedef QVariant(* | ReadFunctionType )(QByteArray replyData) |
Signals | |
| void | finished (QVariant result, QSharedPointer< EverCloudExceptionData > error) |
| Emitted upon asyncronous call completition. More... | |
Public Member Functions | |
| AsyncResult (QString url, QByteArray postData, ReadFunctionType readFunction=AsyncResult::asIs, bool autoDelete=true, QObject *parent=Q_NULLPTR) | |
| AsyncResult (QNetworkRequest request, QByteArray postData, ReadFunctionType readFunction=AsyncResult::asIs, bool autoDelete=true, QObject *parent=Q_NULLPTR) | |
| ~AsyncResult () | |
| bool | waitForFinished (int timeout=-1) |
| Wait for asyncronous operation to complete. More... | |
Returned by asynchonous versions of functions.
Wait for AsyncResult::finished signal.
Intended usage is something like this:
| typedef QVariant(* qevercloud::AsyncResult::ReadFunctionType)(QByteArray replyData) |
| qevercloud::AsyncResult::AsyncResult | ( | QString | url, |
| QByteArray | postData, | ||
| ReadFunctionType | readFunction = AsyncResult::asIs, |
||
| bool | autoDelete = true, |
||
| QObject * | parent = Q_NULLPTR |
||
| ) |
| qevercloud::AsyncResult::AsyncResult | ( | QNetworkRequest | request, |
| QByteArray | postData, | ||
| ReadFunctionType | readFunction = AsyncResult::asIs, |
||
| bool | autoDelete = true, |
||
| QObject * | parent = Q_NULLPTR |
||
| ) |
| qevercloud::AsyncResult::~AsyncResult | ( | ) |
|
signal |
Emitted upon asyncronous call completition.
| result | |
| error | error.isNull() != true in case of an error. See EverCloudExceptionData for more details. |
AsyncResult deletes itself after emitting this signal. You don't have to manage it's lifetime explicitly.
| bool qevercloud::AsyncResult::waitForFinished | ( | int | timeout = -1 | ) |
Wait for asyncronous operation to complete.
| timeout | Maximum time to wait in milliseconds. Forever if < 0. |
1.8.8