QXmppCall Class

The QXmppCall class represents a voice or video call using XEP-0166: Jingle. More...

Header: #include <QXmppCall.h>
Inherits: QXmppLoggable

Public Types

enum Direction { IncomingDirection, OutgoingDirection }
enum State { ConnectingState, ActiveState, DisconnectingState, FinishedState }

Properties

Public Functions

void accept()
void addVideo()
(since QXmpp 1.3) QXmppCallStream *audioStream() const
void decline()
QXmppCall::Direction direction() const
(since QXmpp 1.14) std::optional<QXmppError> error() const
void hangUp()
(since QXmpp 1.11) bool isEncrypted() const
QString jid() const
(since QXmpp 1.3) GstElement *pipeline() const
QString sid() const
QXmppCall::State state() const
(since QXmpp 1.3) QXmppCallStream *videoStream() const
(since QXmpp 1.14) bool videoSupported() const

Signals

void connected()
void finished()
void ringing()
void stateChanged(QXmppCall::State state)
void streamCreated(QXmppCallStream *stream)

Detailed Description

Note: THIS API IS NOT FINALIZED YET

See also QXmppCallManager.

Member Type Documentation

enum QXmppCall::Direction

This enum is used to describe the direction of a call.

ConstantValueDescription
QXmppCall::IncomingDirection0The call is incoming.
QXmppCall::OutgoingDirection1The call is outgoing.

enum QXmppCall::State

This enum is used to describe the state of a call.

ConstantValueDescription
QXmppCall::ConnectingState0The call is being connected.
QXmppCall::ActiveState1The call is active.
QXmppCall::DisconnectingState2The call is being disconnected.
QXmppCall::FinishedState3The call is finished.

Property Documentation

[read-only] direction : const Direction

The call's direction

Access functions:

QXmppCall::Direction direction() const

[read-only] jid : const QString

The remote party's JID

Access functions:

QString jid() const

[read-only] state : State

The call's state

Access functions:

QXmppCall::State state() const

Notifier signal:

void stateChanged(QXmppCall::State state)

Member Function Documentation

void QXmppCall::accept()

Call this method if you wish to accept an incoming call.

See also decline().

void QXmppCall::addVideo()

Starts sending video to the remote party.

[since QXmpp 1.3] QXmppCallStream *QXmppCall::audioStream() const

Returns the RTP stream for the audio data.

This function was introduced in QXmpp 1.3.

[signal] void QXmppCall::connected()

This signal is emitted when a call is connected.

void QXmppCall::decline()

Rejects the call.

This will terminate the call with reason *decline*.

See also accept().

QXmppCall::Direction QXmppCall::direction() const

Returns the call's direction.

Note: Getter function for property direction.

[since QXmpp 1.14] std::optional<QXmppError> QXmppCall::error() const

Returns the error of the call if any occurred.

This function was introduced in QXmpp 1.14.

[signal] void QXmppCall::finished()

This signal is emitted when a call is finished.

void QXmppCall::hangUp()

Hangs up the call.

Terminates with the reason *success*.

[since QXmpp 1.11] bool QXmppCall::isEncrypted() const

Returns if the call is encrypted

This function was introduced in QXmpp 1.11.

QString QXmppCall::jid() const

Returns the remote party's JID.

Note: Getter function for property jid.

[since QXmpp 1.3] GstElement *QXmppCall::pipeline() const

Returns the GStreamer pipeline.

This function was introduced in QXmpp 1.3.

[signal] void QXmppCall::ringing()

This signal is emitted when the remote party is ringing.

QString QXmppCall::sid() const

Returns the call's session identifier.

QXmppCall::State QXmppCall::state() const

Returns the call's state.

Note: Getter function for property state.

See also stateChanged().

[signal] void QXmppCall::stateChanged(QXmppCall::State state)

This signal is emitted when the call state changes.

Note: Notifier signal for property state.

[signal] void QXmppCall::streamCreated(QXmppCallStream *stream)

This signal is emitted when a stream is created.

[since QXmpp 1.3] QXmppCallStream *QXmppCall::videoStream() const

Returns the RTP stream for the video data.

This function was introduced in QXmpp 1.3.

[since QXmpp 1.14] bool QXmppCall::videoSupported() const

Returns whether the remote also supports video calls.

This function was introduced in QXmpp 1.14.