File indexing completed on 2025-01-19 03:59:32
0001 /* ============================================================ 0002 * 0003 * This file is a part of digiKam project 0004 * https://www.digikam.org 0005 * 0006 * Date : 2013-08-09 0007 * Description : Thread actions task for metadata synchronizer. 0008 * 0009 * SPDX-FileCopyrightText: 2013-2024 by Gilles Caulier <caulier dot gilles at gmail dot com> 0010 * 0011 * SPDX-License-Identifier: GPL-2.0-or-later 0012 * 0013 * ============================================================ */ 0014 0015 #ifndef DIGIKAM_METADATA_SYNC_TASK_H 0016 #define DIGIKAM_METADATA_SYNC_TASK_H 0017 0018 // Qt includes 0019 0020 #include <QThread> 0021 0022 // Local includes 0023 0024 #include "actionthreadbase.h" 0025 #include "iteminfo.h" 0026 #include "metadatasynchronizer.h" 0027 0028 namespace Digikam 0029 { 0030 0031 class MaintenanceData; 0032 0033 class MetadataSyncTask : public ActionJob 0034 { 0035 Q_OBJECT 0036 0037 public: 0038 0039 explicit MetadataSyncTask(); 0040 ~MetadataSyncTask() override; 0041 0042 void setTagsOnly(bool value); 0043 void setDirection(MetadataSynchronizer::SyncDirection dir); 0044 void setMaintenanceData(MaintenanceData* const data = nullptr); 0045 0046 Q_SIGNALS: 0047 0048 void signalFinished(const QImage&); 0049 0050 protected: 0051 0052 void run() override; 0053 0054 private: 0055 0056 // Disable 0057 MetadataSyncTask(QObject*) = delete; 0058 0059 private: 0060 0061 class Private; 0062 Private* const d; 0063 }; 0064 0065 } // namespace Digikam 0066 0067 #endif // DIGIKAM_METADATA_SYNC_TASK_H