KSMTP

sendjob.h
1/*
2 SPDX-FileCopyrightText: 2010 BetterInbox <contact@betterinbox.com>
3 SPDX-FileContributor: Christophe Laveault <christophe@betterinbox.com>
4 SPDX-FileContributor: Gregory Schlomoff <gregory.schlomoff@gmail.com>
5
6 SPDX-License-Identifier: LGPL-2.1-or-later
7*/
8
9#pragma once
10
11#include "ksmtp_export.h"
12
13#include "job.h"
14
15namespace KSmtp
16{
17class SendJobPrivate;
18/**
19 * @brief The SendJob class
20 */
21class KSMTP_EXPORT SendJob : public Job
22{
23 Q_OBJECT
24 Q_DECLARE_PRIVATE(SendJob)
25
26public:
27 explicit SendJob(Session *session);
28
29 /**
30 * Set the sender email address
31 */
32 void setFrom(const QString &from);
33
34 /**
35 * Add recipients.
36 *
37 */
38 void setTo(const QStringList &to);
39
40 /**
41 * Add recipients.
42 */
43 void setCc(const QStringList &cc);
44
45 /**
46 * Add recipients.
47 */
48 void setBcc(const QStringList &bcc);
49
50 /**
51 * Set the actual message data.
52 */
53 void setData(const QByteArray &data);
54
55 /**
56 * Returns size of the encoded message data.
57 */
58 [[nodiscard]] int size() const;
59
60 /**
61 * Set Delivery Status Notification.
62 */
63 void setDeliveryStatusNotification(bool b);
64
65protected:
66 void doStart() override;
67 void handleResponse(const ServerResponse &r) override;
68};
69}
The Job class.
Definition job.h:25
The SendJob class.
Definition sendjob.h:22
The Session class.
Definition session.h:24
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:16:10 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.