QXmpp: QXmppDiscoveryIq Class Reference

QXmpp Version: 1.14.4

Loading...
Searching...
No Matches
QXmppDiscoveryIq Class Reference
Stanzas
Inheritance diagram for QXmppDiscoveryIq:

## Public Types
enum | QueryType { InfoQuery , ItemsQuery }
Public Types inherited from QXmppIq
enum | Type { Error = 0 , Get , Set , Result }
| This enum describes the type of IQ. More...

## Public Member Functions
QStringList | features () const
void | setFeatures (const QStringList &features)
QList< QXmppDiscoIdentity > | identities () const
void | setIdentities (const QList< QXmppDiscoIdentity > &identities)
QList< QXmppDiscoItem > | items () const
void | setItems (const QList< QXmppDiscoItem > &items)
QXmppDataForm | form () const
void | setForm (const QXmppDataForm &form)
const QList< QXmppDataForm > & | dataForms () const
void | setDataForms (const QList< QXmppDataForm > &dataForms)
std::optional< QXmppDataForm > | dataForm (QStringView formType) const
template<QXmpp::Private::DataFormConvertible FormT>
std::optional< FormT > | dataForm () const
QString | queryNode () const
void | setQueryNode (const QString &node)
enum QueryType | queryType () const
void | setQueryType (enum QueryType type)
QByteArray | verificationString () const
Public Member Functions inherited from QXmppIq
| QXmppIq (QXmppIq::Type type=QXmppIq::Get)
| QXmppIq (const QXmppIq &other)
| Constructs a copy of other.
| QXmppIq (QXmppIq &&)
| Default move-constructor.
QXmppIq & | operator= (const QXmppIq &other)
| Assigns other to this IQ.
QXmppIq & | operator= (QXmppIq &&)
| Move-assignment operator.
QXmppIq::Type | type () const
void | setType (QXmppIq::Type)
bool | isXmppStanza () const override
Public Member Functions inherited from QXmppStanza
| QXmppStanza (const QString &from=QString(), const QString &to=QString())
| QXmppStanza (const QXmppStanza &other)
| Constructs a copy of other.
| QXmppStanza (QXmppStanza &&)
| Move constructor.
| ~QXmppStanza () override
| Destroys a QXmppStanza.
QXmppStanza & | operator= (const QXmppStanza &other)
| Assigns other to this stanza.
QXmppStanza & | operator= (QXmppStanza &&)
| Move-assignment operator.
QString | to () const
void | setTo (const QString &)
QString | from () const
void | setFrom (const QString &)
QString | id () const
void | setId (const QString &)
QString | lang () const
void | setLang (const QString &)
QXmppStanza::Error | error () const
std::optional< Error > | errorOptional () const
void | setError (const QXmppStanza::Error &error)
void | setError (const std::optional< Error > &error)
QXmppElementList | extensions () const
void | setExtensions (const QXmppElementList &elements)
QList< QXmppExtendedAddress > | extendedAddresses () const
void | setExtendedAddresses (const QList< QXmppExtendedAddress > &extendedAddresses)
std::optional< QXmppE2eeMetadata > | e2eeMetadata () const
void | setE2eeMetadata (const std::optional< QXmppE2eeMetadata > &e2eeMetadata)
Public Member Functions inherited from QXmppNonza
virtual void | parse (const QDomElement &)=0
virtual void | toXml (QXmlStreamWriter *writer) const =0

## Detailed Description

QXmppDiscoveryIq represents a discovery IQ request or result containing a list of features and other information about an entity as defined by XEP-0030: Service Discovery.

Deprecated

## Member Enumeration Documentation

## ◆ QueryType

enum QXmppDiscoveryIq::QueryType

Specifies the type of a service discovery query. An InfoQuery queries identities and features, an ItemsQuery queries subservices in the form of items.

## Member Function Documentation

## ◆ dataForm() [1/2]

template<QXmpp::Private::DataFormConvertible FormT>

std::optional< FormT > QXmppDiscoveryIq::dataForm | ( |  | ) | const
| inline

Looks for a form with the form type of FormT and parses it if found.

Since
  QXmpp 1.12

## ◆ dataForm() [2/2]

std::optional< QXmppDataForm > QXmppDiscoveryIq::dataForm | ( | QStringView | formType | ) | const

Looks for a data form with the given form type and returns it if found.

Data dataForms in service discovery info are defined in XEP-0128: Service Discovery Extensions.

Since
  QXmpp 1.12

## ◆ dataForms()

const QList< QXmppDataForm > & QXmppDiscoveryIq::dataForms | ( |  | ) | const

Returns included data forms as defined by XEP-0128: Service Discovery Extensions.

Since
  QXmpp 1.12

## ◆ features()

QStringList QXmppDiscoveryIq::features | ( |  | ) | const

Returns the features of the service.

## ◆ form()

QXmppDataForm QXmppDiscoveryIq::form | ( |  | ) | const

Returns the first of the included data dataForms as defined by XEP-0128: Service Discovery Extensions.

Returns empty form if no form is included.

Deprecated
  Use dataForms() or findForm() instead.

## ◆ identities()

QList< QXmppDiscoIdentity > QXmppDiscoveryIq::identities | ( |  | ) | const

Returns the list of identities for this service.

## ◆ items()

QList< QXmppDiscoItem > QXmppDiscoveryIq::items | ( |  | ) | const

Returns the list of service discovery items.

## ◆ queryNode()

QString QXmppDiscoveryIq::queryNode | ( |  | ) | const

Returns the special node to query.

## ◆ queryType()

QXmppDiscoveryIq::QueryType QXmppDiscoveryIq::queryType | ( |  | ) | const

Returns the query type (info query or items query).

## ◆ setDataForms()

void QXmppDiscoveryIq::setDataForms | ( | const QList< QXmppDataForm > & | dataForms | ) |

Sets included data forms as defined by XEP-0128: Service Discovery Extensions.

Each form must have a FORM_TYPE field and each form type MUST occur only once.

Since
  QXmpp 1.12

## ◆ setFeatures()

void QXmppDiscoveryIq::setFeatures | ( | const QStringList & | features | ) |

Sets the features of the service.

## ◆ setForm()

void QXmppDiscoveryIq::setForm | ( | const QXmppDataForm & | form | ) |

Sets included data dataForms as defined by XEP-0128: Service Discovery Extensions.

Deprecated
  Use setForms() instead.

## ◆ setIdentities()

void QXmppDiscoveryIq::setIdentities | ( | const QList< QXmppDiscoIdentity > & | identities | ) |

Sets the list of identities for this service.

## ◆ setItems()

void QXmppDiscoveryIq::setItems | ( | const QList< QXmppDiscoItem > & | items | ) |

Sets the list of service discovery items.

## ◆ setQueryNode()

void QXmppDiscoveryIq::setQueryNode | ( | const QString & | node | ) |

Sets the special node to query.

## ◆ setQueryType()

void QXmppDiscoveryIq::setQueryType | ( | enum QueryType | type | ) |

Sets the query type (info query or items query).

## ◆ verificationString()

QByteArray QXmppDiscoveryIq::verificationString | ( |  | ) | const

Calculate the verification string for XEP-0115: Entity Capabilities.

The documentation for this class was generated from the following files:

- QXmppDiscoveryIq.h
- base/compat/removed_api.cpp