Messagelib

attachmentloadjob.cpp
1 /*
2  SPDX-FileCopyrightText: 2009 Constantin Berzan <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #include "attachmentloadjob.h"
8 
9 #include <QTimer>
10 
11 using namespace MessageCore;
12 
13 class MessageCore::AttachmentLoadJob::AttachmentLoadJobPrivate
14 {
15 public:
16  AttachmentPart::Ptr mPart;
17 };
18 
20  : KJob(parent)
21  , d(new AttachmentLoadJobPrivate)
22 {
23 }
24 
26 
28 {
29  QTimer::singleShot(0, this, &AttachmentLoadJob::doStart);
30 }
31 
33 {
34  return d->mPart;
35 }
36 
38 {
39  d->mPart = part;
40 }
AttachmentPart::Ptr attachmentPart() const
Returns the loaded attachment.
void setAttachmentPart(const AttachmentPart::Ptr &part)
Subclasses use this method to set the loaded part.
void start() override
Starts the attachment load job.
~AttachmentLoadJob() override
Destroys the attachment load job.
AttachmentLoadJob(QObject *parent=nullptr)
Creates a new attachment load job.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Fri Mar 24 2023 04:08:30 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.