Messagelib

singlepartjob.h
1/*
2 SPDX-FileCopyrightText: 2009 Constantin Berzan <exit3219@gmail.com>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8
9#include "contentjobbase.h"
10#include "messagecomposer_export.h"
11
12namespace KMime
13{
14namespace Headers
15{
18class ContentID;
20class ContentType;
21}
22}
23
24namespace MessageComposer
25{
26class SinglepartJobPrivate;
27
28/**
29 * @brief The SinglepartJob class
30 */
31class MESSAGECOMPOSER_EXPORT SinglepartJob : public ContentJobBase
32{
34
35public:
36 explicit SinglepartJob(QObject *parent = nullptr);
37 ~SinglepartJob() override;
38
39 [[nodiscard]] QByteArray data() const;
40 void setData(const QByteArray &data);
41 /** Indicated the data set with setData() is already encoded with the selected
42 * content transfer encoding.
43 * @default @c false
44 */
45 void setDataIsEncoded(bool encoded);
46
47 /// created on first call. delete them if you don't use the content
49 [[nodiscard]] KMime::Headers::ContentDisposition *contentDisposition();
50 [[nodiscard]] KMime::Headers::ContentID *contentID();
51 [[nodiscard]] KMime::Headers::ContentTransferEncoding *contentTransferEncoding();
52 [[nodiscard]] KMime::Headers::ContentType *contentType();
53
54protected Q_SLOTS:
55 void process() override;
56
57private:
58 Q_DECLARE_PRIVATE(SinglepartJob)
59};
60}
KMime::Headers::ContentDescription * contentDescription()
created on first call. delete them if you don't use the content
void setDataIsEncoded(bool encoded)
Indicated the data set with setData() is already encoded with the selected content transfer encoding.
Simple interface that both EncryptJob and SignEncryptJob implement so the composer can extract some e...
Q_OBJECTQ_OBJECT
Q_SLOTSQ_SLOTS
QObject * parent() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 31 2025 12:05:40 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.