Loading...
Searching...
No Matches
QXmppCallManager.h
// SPDX-FileCopyrightText: 2010 Jeremy Lainé <jeremy.laine@m4x.org>
//
// SPDX-License-Identifier: LGPL-2.1-or-later
#ifndef QXMPPCALLMANAGER_H
#define QXMPPCALLMANAGER_H
#include "QXmppCall.h"
#include "QXmppClientExtension.h"
#include "QXmppLogger.h"
#include <QIODevice>
#include <QMetaType>
#include <QObject>
class QHostAddress;
class QXmppCallManagerPrivate;
class QXmppIq;
class QXmppJingleCandidate;
class QXmppJingleIq;
class QXmppJinglePayloadType;
class QXmppPresence;
class QXMPP_EXPORT QXmppCallManager : public QXmppClientExtension
{
Q_OBJECT
public:
QXmppCallManager();
~QXmppCallManager() override;
void setStunServers(const QList<QPair<QHostAddress, quint16>> &servers);
void setStunServer(const QHostAddress &host, quint16 port = 3478);
void setTurnServer(const QHostAddress &host, quint16 port = 3478);
void setTurnUser(const QString &user);
void setTurnPassword(const QString &password);
QStringList discoveryFeatures() const override;
bool handleStanza(const QDomElement &element) override;
Q_SIGNALS:
void callReceived(QXmppCall *call);
void callStarted(QXmppCall *call);
public Q_SLOTS:
QXmppCall *call(const QString &jid);
protected:
void setClient(QXmppClient *client) override;
private Q_SLOTS:
void _q_callDestroyed(QObject *object);
void _q_disconnected();
void _q_iqReceived(const QXmppIq &iq);
void _q_jingleIqReceived(const QXmppJingleIq &iq);
void _q_presenceReceived(const QXmppPresence &presence);
private:
QXmppCallManagerPrivate *d;
friend class QXmppCall;
friend class QXmppCallPrivate;
friend class QXmppCallManagerPrivate;
};
#endif
QXmppCallManager
The QXmppCallManager class provides support for making and receiving voice calls.
Definition QXmppCallManager.h:46
QXmppCallManager::callStarted
void callStarted(QXmppCall *call)
This signal is emitted when a call (incoming or outgoing) is started.
QXmppCallManager::callReceived
void callReceived(QXmppCall *call)
QXmppCall
Definition QXmppCall.h:21
QXmppClientExtension
The QXmppClientExtension class is the base class for QXmppClient extensions.
Definition QXmppClientExtension.h:33
QXmppClientExtension::setClient
virtual void setClient(QXmppClient *client)
Definition QXmppClientExtension.cpp:88
QXmppClientExtension::discoveryFeatures
virtual QStringList discoveryFeatures() const
Definition QXmppClientExtension.cpp:22
QXmppClientExtension::handleStanza
virtual bool handleStanza(const QDomElement &stanza)
You need to implement this method to process incoming XMPP stanzas.
Definition QXmppClientExtension.cpp:51
QXmppClient
The QXmppClient class is the main class for using QXmpp.
Definition QXmppClient.h:84
QXmppIq
The QXmppIq class is the base class for all IQs.
Definition QXmppIq.h:23
QXmppJingleCandidate
The QXmppJingleCandidate class represents a transport candidate as specified by XEP-0176: Jingle ICE-...
Definition QXmppJingleIq.h:245
QXmppJingleIq
The QXmppJingleIq class represents an IQ used for initiating media sessions as specified by XEP-0166:...
Definition QXmppJingleIq.h:317
QXmppJinglePayloadType
The QXmppJinglePayloadType class represents a payload type as specified by XEP-0167: Jingle RTP Sessi...
Definition QXmppJingleIq.h:195
QXmppPresence
The QXmppPresence class represents an XMPP presence stanza.
Definition QXmppPresence.h:21