QXmpp: QXmppTransferManager_p.h Source File

QXmpp Version: 1.14.4

Loading...
Searching...
No Matches
QXmppTransferManager_p.h
1// SPDX-FileCopyrightText: 2012 Jeremy Lainé <jeremy.laine@m4x.org>
2//
3// SPDX-License-Identifier: LGPL-2.1-or-later
4
5#ifndef QXMPPTRANSFERMANAGER_P_H
6#define QXMPPTRANSFERMANAGER_P_H
7
8#include "QXmppByteStreamIq.h"
9#include "QXmppTransferManager.h"
10
11//
12// W A R N I N G
13// -------------
14//
15// This file is not part of the QXmpp API. It exists for the convenience
16// of the QXmppTransferManager class. This header file may change from
17// version to version without notice, or even be removed.
18//
19// We mean it.
20//
21
22class QTimer;
23class QXmppSocksClient;
24
25class QXmppTransferIncomingJob : public QXmppTransferJob
26{
27 Q_OBJECT
28
29public:
30 QXmppTransferIncomingJob(const QString &jid, QXmppClient *client, QObject *parent);
31 void checkData();
32 void connectToHosts(const QXmppByteStreamIq &iq);
33 bool writeData(const QByteArray &data);
34
35private:
36 Q_SLOT void _q_candidateDisconnected();
37 Q_SLOT void _q_candidateReady();
38 Q_SLOT void _q_disconnected();
39 Q_SLOT void _q_receiveData();
40
41 void connectToNextHost();
42
43 QXmppByteStreamIq::StreamHost m_candidateHost;
44 QXmppSocksClient *m_candidateClient;
45 QTimer *m_candidateTimer;
46 QList<QXmppByteStreamIq::StreamHost> m_streamCandidates;
47 QString m_streamOfferId;
48 QString m_streamOfferFrom;
49};
50
51class QXmppTransferOutgoingJob : public QXmppTransferJob
52{
53 Q_OBJECT
54
55public:
56 QXmppTransferOutgoingJob(const QString &jid, QXmppClient *client, QObject *parent);
57 void connectToProxy();
58 void startSending();
59
60 Q_SLOT void _q_disconnected();
61
62private:
63 Q_SLOT void _q_proxyReady();
64 Q_SLOT void _q_sendData();
65};
66
67#endif
QXmppTransferJob
Definition QXmppTransferManager.h:64
QXmppTransferJob::jid
QString jid
The remote party's JID.
Definition QXmppTransferManager.h:72