Home · Modules · All Classes · All Namespaces
Public Member Functions | List of all members
Tp::Metadata Struct Reference

#include <TelepathyQt/Types>

Inherits QMap< QString, QStringList >.

Public Member Functions

 Metadata ()
 
 Metadata (const QMap< QString, QStringList > &a)
 
 Metadata (std::initializer_list< std::pair< QString, QStringList > > a)
 
Metadataoperator= (const QMap< QString, QStringList > &a)
 

Detailed Description

Mapping type generated from the specification. Convertible with QMap<QString, QStringList>, but needed to have a discrete type in the Qt type system.

A mapping from string key to a list of strings, used in the Metadata property. To emulate a simple string → string hash table one should have exactly one member in the value string list. This property is an a{sas} primarily because this maps easily to XEP-0004 Data Forms, and allows more structured metadata than a{ss} would. (For instance, a list of RDF triples could be expressed as one long array of strings, or as three-element values for a series of dummy key names, rather than as one big string blob.) While it might be convenient for applications to allow keys of arbitrary types, the added convenience would be outweighed by having to define the XMPP representation

Constructor & Destructor Documentation

◆ Metadata() [1/3]

Tp::Metadata::Metadata ( )
inline

◆ Metadata() [2/3]

Tp::Metadata::Metadata ( const QMap< QString, QStringList > &  a)
inline

◆ Metadata() [3/3]

Tp::Metadata::Metadata ( std::initializer_list< std::pair< QString, QStringList > >  a)
inline

Member Function Documentation

◆ operator=()

Metadata& Tp::Metadata::operator= ( const QMap< QString, QStringList > &  a)
inline