File indexing completed on 2024-12-22 05:05:24

0001 /*
0002    SPDX-FileCopyrightText: 2020-2024 Laurent Montel <montel@kde.org>
0003 
0004    SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #pragma once
0008 
0009 #include "exportimportutil.h"
0010 
0011 #include "mail/exportmailjobinterface.h"
0012 
0013 class ExportMailJobInterfaceTestImpl : public ExportMailJobInterface, public ExportImportUtil
0014 {
0015     Q_OBJECT
0016 public:
0017     explicit ExportMailJobInterfaceTestImpl(QObject *parent, Utils::StoredTypes typeSelected, ArchiveStorage *archiveStorage, int numberOfStep);
0018     ~ExportMailJobInterfaceTestImpl() override;
0019 
0020 protected:
0021     void convertCollectionToRealPath(KConfigGroup &group, const QString &currentKey) override;
0022     void convertCollectionListToRealPath(KConfigGroup &group, const QString &currentKey) override;
0023 
0024     void convertCollectionIdsToRealPath(KConfigGroup &group, const QString &currentKey, const QString &prefixCollection) override;
0025 
0026     [[nodiscard]] Akonadi::Collection::Id convertFolderPathToCollectionId(const QString &path) override;
0027 
0028     [[nodiscard]] QList<MailCommon::MailFilter *> filters() override;
0029 
0030     [[nodiscard]] QString convertToFullCollectionPath(const qlonglong collectionValue) override;
0031     void exportResourceToArchive(const QString &archivePath, const QString &url, const QString &identifier) override;
0032     [[nodiscard]] QList<Utils::AkonadiInstanceInfo> listOfResource() override;
0033     [[nodiscard]] QString storeResources(KZip *archive, const QString &identifier, const QString &path) override;
0034     [[nodiscard]] QString resourcePath(const QString &identifier) const override;
0035     void backupMailResourceFile(const QString &agentIdentifier, const QString &defaultPath) override;
0036     [[nodiscard]] QString adaptNewResourceUrl(bool overwriteResources, const KSharedConfig::Ptr &resourceConfig, const QString &storePath) override;
0037     [[nodiscard]] QString createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree) override;
0038     [[nodiscard]] QList<uint> listIdentityUoid() const override;
0039     void exportFilters() override;
0040     void exportFolderAttributes() override;
0041 };