File indexing completed on 2024-09-22 04:49:59

0001 /*
0002  * SPDX-FileCopyrightText: 1996-1998 Stefan Taferner <taferner@kde.org>
0003  *
0004  * SPDX-License-Identifier: GPL-2.0-or-later
0005  *
0006  */
0007 
0008 #pragma once
0009 
0010 #include "filteractionwithfolder.h"
0011 
0012 class KJob;
0013 
0014 namespace MailCommon
0015 {
0016 //=============================================================================
0017 // FilterActionCopy - copy into folder
0018 // Copy message into another mail folder
0019 //=============================================================================
0020 class FilterActionCopy : public FilterActionWithFolder
0021 {
0022     Q_OBJECT
0023 public:
0024     explicit FilterActionCopy(QObject *parent = nullptr);
0025     [[nodiscard]] ReturnCode process(ItemContext &context, bool applyOnOutbound) const override;
0026     [[nodiscard]] SearchRule::RequiredPart requiredPart() const override;
0027     static FilterAction *newAction();
0028     [[nodiscard]] QString sieveCode() const override;
0029     [[nodiscard]] QStringList sieveRequires() const override;
0030     [[nodiscard]] QString informationAboutNotValidAction() const override;
0031 
0032 protected Q_SLOTS:
0033     void jobFinished(KJob *job);
0034 };
0035 }