File indexing completed on 2024-04-28 03:53:55
0001 /* 0002 SPDX-FileCopyrightText: 2010 Tobias Koenig <tokoe@kde.org> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #ifndef KDAV_DAVITEMFETCHJOB_H 0008 #define KDAV_DAVITEMFETCHJOB_H 0009 0010 #include "kdav_export.h" 0011 0012 #include "davitem.h" 0013 #include "davjobbase.h" 0014 #include "davurl.h" 0015 0016 namespace KDAV 0017 { 0018 class DavItemFetchJobPrivate; 0019 0020 /** 0021 * @class DavItemFetchJob davitemfetchjob.h <KDAV/DavItemFetchJob> 0022 * 0023 * @short A job that fetches a DAV item from the DAV server. 0024 */ 0025 class KDAV_EXPORT DavItemFetchJob : public DavJobBase 0026 { 0027 Q_OBJECT 0028 0029 public: 0030 /** 0031 * Creates a new DAV item fetch job. 0032 * 0033 * @param item The item that shall be fetched. 0034 * @param parent The parent object. 0035 */ 0036 explicit DavItemFetchJob(const DavItem &item, QObject *parent = nullptr); 0037 0038 /** 0039 * Starts the job. 0040 */ 0041 void start() override; 0042 0043 /** 0044 * Returns the fetched item including current ETag information. 0045 */ 0046 Q_REQUIRED_RESULT DavItem item() const; 0047 0048 private: 0049 Q_DECLARE_PRIVATE(DavItemFetchJob) 0050 }; 0051 } 0052 0053 #endif