5#ifndef QXMPPTHUMBNAIL_H
6#define QXMPPTHUMBNAIL_H
8#include "QXmppGlobal.h"
12#include <QSharedDataPointer>
16class QXmlStreamWriter;
17class QXmppThumbnailPrivate;
30 const QString &
uri() const;
31 void setUri(const QString &newUri);
36 std::optional<uint32_t>
width() const;
37 void setWidth(std::optional<uint32_t>);
39 std::optional<uint32_t>
height() const;
43 bool parse(const QDomElement &);
44 void toXml(QXmlStreamWriter *writer) const;
48 QSharedDataPointer<QXmppThumbnailPrivate> d;
void setMediaType(const QMimeType &)
Sets the MIME type of the thumbnail data.
Definition QXmppThumbnail.cpp:71
const QMimeType & mediaType() const
Returns the MIME type of the thumbnail data.
Definition QXmppThumbnail.cpp:65
QXmppThumbnail(const QXmppThumbnail &)
Default copy-constructor.
std::optional< uint32_t > width() const
Returns the width of the thumbnail image.
Definition QXmppThumbnail.cpp:77
const QString & uri() const
Returns the URI with the location for the data (usually a XEP-0231: Bits of Binary content ID)
Definition QXmppThumbnail.cpp:53
QXmppThumbnail(QXmppThumbnail &&) noexcept
Default move-constructor.
void setHeight(std::optional< uint32_t >)
Sets the height of the thumbnail image.
Definition QXmppThumbnail.cpp:95
void setWidth(std::optional< uint32_t >)
Sets the width of the thumbnail image.
Definition QXmppThumbnail.cpp:83
std::optional< uint32_t > height() const
Returns the height of the thumbnail image.
Definition QXmppThumbnail.cpp:89
QXmppThumbnail()
Default constructor.
Definition QXmppThumbnail.cpp:38
void setUri(const QString &newUri)
Sets the URI with the location for the data (usually a XEP-0231: Bits of Binary content ID)
Definition QXmppThumbnail.cpp:59