File indexing completed on 2025-03-09 04:54:36

0001 /*
0002    SPDX-FileCopyrightText: 2021-2024 Laurent Montel <montel@kde.org>
0003 
0004    SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #pragma once
0008 #include "messageviewer_export.h"
0009 #include <Akonadi/Item>
0010 namespace MessageViewer
0011 {
0012 class MessageViewerCheckBeforeDeletingParametersPrivate;
0013 /** @brief The MessageViewerCheckBeforeDeletingParameters class
0014  * @author Laurent Montel <montel@kde.org>
0015  */
0016 class MESSAGEVIEWER_EXPORT MessageViewerCheckBeforeDeletingParameters
0017 {
0018 public:
0019     MessageViewerCheckBeforeDeletingParameters();
0020     MessageViewerCheckBeforeDeletingParameters(const MessageViewerCheckBeforeDeletingParameters &other);
0021     ~MessageViewerCheckBeforeDeletingParameters();
0022 
0023     enum DeleteType {
0024         Unknown = 0,
0025         MoveToTrash = 1,
0026         Delete = 2,
0027     };
0028 
0029     [[nodiscard]] MessageViewerCheckBeforeDeletingParameters::DeleteType deleteType() const;
0030     void setDeleteType(MessageViewerCheckBeforeDeletingParameters::DeleteType type);
0031 
0032     MessageViewerCheckBeforeDeletingParameters &operator=(const MessageViewerCheckBeforeDeletingParameters &other);
0033     [[nodiscard]] bool operator==(const MessageViewerCheckBeforeDeletingParameters &other) const;
0034 
0035     [[nodiscard]] Akonadi::Item::List items() const;
0036     void setItems(const Akonadi::Item::List &items);
0037 
0038     [[nodiscard]] bool isValid() const;
0039 
0040 private:
0041     MessageViewerCheckBeforeDeletingParametersPrivate *const d;
0042 };
0043 }