File indexing completed on 2024-11-24 04:44:34

0001 /*  This file is part of the KDE project
0002     SPDX-FileCopyrightText: 2010 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.net>
0003     SPDX-FileContributor: Kevin Krammer <krake@kdab.com>
0004 
0005     SPDX-License-Identifier: LGPL-2.0-or-later
0006 */
0007 
0008 #pragma once
0009 
0010 #include "job.h"
0011 
0012 #include <memory>
0013 
0014 namespace Akonadi
0015 {
0016 class Collection;
0017 
0018 namespace FileStore
0019 {
0020 class AbstractJobSession;
0021 class CollectionModifyJobPrivate;
0022 
0023 /**
0024  */
0025 class AKONADI_FILESTORE_EXPORT CollectionModifyJob : public Job
0026 {
0027     friend class AbstractJobSession;
0028 
0029     Q_OBJECT
0030 
0031 public:
0032     explicit CollectionModifyJob(const Collection &collection, AbstractJobSession *session = nullptr);
0033 
0034     ~CollectionModifyJob() override;
0035 
0036     [[nodiscard]] Collection collection() const;
0037 
0038     bool accept(Visitor *visitor) override;
0039 
0040 private:
0041     void handleCollectionModified(const Collection &collection);
0042 
0043 private:
0044     std::unique_ptr<CollectionModifyJobPrivate> const d;
0045 };
0046 }
0047 }