diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-06-02 13:35:40 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-06-02 13:35:40 +0200 |
commit | 855a878bcc124f8949586b3656dcc6e545e18dc0 (patch) | |
tree | 6497f1710ba3db8953d204032e5e8c14a239ad33 /examples/imapresource/imapserverproxy.h | |
parent | 64a1b21a7b11d640f0ebd37184aeb14a4d9e12db (diff) | |
download | sink-855a878bcc124f8949586b3656dcc6e545e18dc0.tar.gz sink-855a878bcc124f8949586b3656dcc6e545e18dc0.zip |
Always return jobs, not futures.
Otherwise the calls are not composable.
Diffstat (limited to 'examples/imapresource/imapserverproxy.h')
-rw-r--r-- | examples/imapresource/imapserverproxy.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/examples/imapresource/imapserverproxy.h b/examples/imapresource/imapserverproxy.h index a5a1296..cf315df 100644 --- a/examples/imapresource/imapserverproxy.h +++ b/examples/imapresource/imapserverproxy.h | |||
@@ -69,6 +69,7 @@ public: | |||
69 | KAsync::Job<void> append(const QString &mailbox, const QByteArray &content, const QList<QByteArray> &flags = QList<QByteArray>(), const QDateTime &internalDate = QDateTime()); | 69 | KAsync::Job<void> append(const QString &mailbox, const QByteArray &content, const QList<QByteArray> &flags = QList<QByteArray>(), const QDateTime &internalDate = QDateTime()); |
70 | KAsync::Job<void> store(const KIMAP::ImapSet &set, const QList<QByteArray> &flags); | 70 | KAsync::Job<void> store(const KIMAP::ImapSet &set, const QList<QByteArray> &flags); |
71 | KAsync::Job<void> create(const QString &mailbox); | 71 | KAsync::Job<void> create(const QString &mailbox); |
72 | KAsync::Job<void> rename(const QString &mailbox, const QString &newMailbox); | ||
72 | KAsync::Job<void> remove(const QString &mailbox); | 73 | KAsync::Job<void> remove(const QString &mailbox); |
73 | KAsync::Job<void> expunge(); | 74 | KAsync::Job<void> expunge(); |
74 | 75 | ||
@@ -87,8 +88,8 @@ public: | |||
87 | KAsync::Job<QList<qint64>> fetchHeaders(const QString &mailbox); | 88 | KAsync::Job<QList<qint64>> fetchHeaders(const QString &mailbox); |
88 | KAsync::Job<void> remove(const QString &mailbox, const QByteArray &imapSet); | 89 | KAsync::Job<void> remove(const QString &mailbox, const QByteArray &imapSet); |
89 | 90 | ||
90 | KAsync::Future<void> fetchFolders(std::function<void(const QVector<Folder> &)> callback); | 91 | KAsync::Job<void> fetchFolders(std::function<void(const QVector<Folder> &)> callback); |
91 | KAsync::Future<void> fetchMessages(const Folder &folder, std::function<void(const QVector<Message> &)> callback); | 92 | KAsync::Job<void> fetchMessages(const Folder &folder, std::function<void(const QVector<Message> &)> callback); |
92 | }; | 93 | }; |
93 | 94 | ||
94 | } | 95 | } |