The QXmppIceConnection class represents a set of UDP sockets capable of performing Interactive Connectivity Establishment (RFC 5245).
More...
#include <QXmppStun.h>
|
| enum | GatheringState { NewGatheringState
, BusyGatheringState
, CompleteGatheringState
} |
|
|
void | debug (const QString &message) |
| | Logs a debugging message.
|
|
void | info (const QString &message) |
| | Logs an informational message.
|
|
void | warning (const QString &message) |
| | Logs a warning message.
|
|
void | logReceived (const QString &message) |
| | Logs a received packet.
|
|
void | logSent (const QString &message) |
| | Logs a sent packet.
|
The QXmppIceConnection class represents a set of UDP sockets capable of performing Interactive Connectivity Establishment (RFC 5245).
A typical example is:
static QList< QHostAddress > discoverAddresses()
Definition QXmppStun.cpp:2387
void addRemoteCandidate(const QXmppJingleCandidate &candidate)
Definition QXmppStun.cpp:2594
Q_SLOT void connectToHost()
Definition QXmppStun.cpp:2643
bool bind(const QList< QHostAddress > &addresses)
Definition QXmppStun.cpp:2609
void setIceControlling(bool controlling)
Definition QXmppStun.cpp:2679
QXmppIceConnection(QObject *parent=nullptr)
Definition QXmppStun.cpp:2535
void setRemoteUser(const QString &user)
Definition QXmppStun.cpp:2718
void addComponent(int component)
Definition QXmppStun.cpp:2565
◆ GatheringState
This enum describes the gathering state of the ICE connection.
- Since
- QXmpp 0.9.3
◆ QXmppIceConnection()
| QXmppIceConnection::QXmppIceConnection |
( |
QObject * | parent = nullptr | ) |
|
Constructs a new ICE connection.
- Parameters
-
◆ addComponent()
| void QXmppIceConnection::addComponent |
( |
int | component | ) |
|
Adds a component to this ICE connection, for instance 1 for RTP or 2 for RTCP.
- Parameters
-
◆ addRemoteCandidate()
Adds a candidate for one of the remote components.
- Parameters
-
◆ bind()
| bool QXmppIceConnection::bind |
( |
const QList< QHostAddress > & | addresses | ) |
|
Binds the local sockets to the specified addresses.
- Parameters
-
| addresses | The addresses on which to listen. |
◆ close()
| void QXmppIceConnection::close |
( |
| ) |
|
Closes the ICE connection.
◆ component()
Returns the given component of this ICE connection.
- Parameters
-
◆ connectToHost()
| void QXmppIceConnection::connectToHost |
( |
| ) |
|
Starts ICE connectivity checks.
◆ gatheringState()
Returns the ICE gathering state, that is the discovery of local candidates.
- Since
- QXmpp 0.9.3
◆ gatheringStateChanged()
| Q_SIGNAL void QXmppIceConnection::gatheringStateChanged |
( |
| ) |
|
This signal is emitted when the gathering state of local candidates changes.
- Since
- QXmpp 0.9.3
◆ isConnected()
| bool QXmppIceConnection::isConnected |
( |
| ) |
const |
Returns true if ICE negotiation completed, false otherwise.
◆ localCandidates()
Returns the list of local HOST CANDIDATES candidates by iterating over the available network interfaces.
◆ localPassword()
| QString QXmppIceConnection::localPassword |
( |
| ) |
const |
Returns the local password.
◆ localUser()
| QString QXmppIceConnection::localUser |
( |
| ) |
const |
Returns the local user fragment.
◆ setIceControlling()
| void QXmppIceConnection::setIceControlling |
( |
bool | controlling | ) |
|
Sets whether the local party has the ICE controlling role.
note This must be called only once, immediately after creating the connection.
◆ setRemotePassword()
| void QXmppIceConnection::setRemotePassword |
( |
const QString & | password | ) |
|
Sets the remote password.
- Parameters
-
◆ setRemoteUser()
| void QXmppIceConnection::setRemoteUser |
( |
const QString & | user | ) |
|
Sets the remote user fragment.
- Parameters
-
◆ setStunServer()
| void QXmppIceConnection::setStunServer |
( |
const QHostAddress & | host, |
|
|
quint16 | port = 3478 ) |
◆ setStunServers() [1/2]
| void QXmppIceConnection::setStunServers |
( |
const QList< QPair< QHostAddress, quint16 > > & | servers | ) |
|
◆ setStunServers() [2/2]
| void QXmppIceConnection::setStunServers |
( |
const QList< QXmpp::StunServer > & | servers | ) |
|
Sets multiple STUN servers to use to determine server-reflexive addresses and ports.
- Note
- This may only be called prior to calling bind().
- Parameters
-
| servers | List of the STUN servers. |
- Since
- QXmpp 1.14
◆ setTurnPassword()
| void QXmppIceConnection::setTurnPassword |
( |
const QString & | password | ) |
|
◆ setTurnServer() [1/2]
| void QXmppIceConnection::setTurnServer |
( |
const QHostAddress & | host, |
|
|
quint16 | port = 3478 ) |
◆ setTurnServer() [2/2]
Sets the TURN server to use to relay packets in double-NAT configurations.
- Note
- This may only be called prior to calling bind().
- Since
- QXmpp 1.14
◆ setTurnUser()
| void QXmppIceConnection::setTurnUser |
( |
const QString & | user | ) |
|
◆ gatheringState
The ICE gathering state, that is the discovery of local candidates
- Since
- QXmpp 0.9.3
The documentation for this class was generated from the following files: