diff --git a/src/common/davcollectionsfetchjob.h b/src/common/davcollectionsfetchjob.h index ff2b894..5f939a3 100644 --- a/src/common/davcollectionsfetchjob.h +++ b/src/common/davcollectionsfetchjob.h @@ -1,74 +1,74 @@ /* SPDX-FileCopyrightText: 2010 Tobias Koenig SPDX-License-Identifier: LGPL-2.0-or-later */ #ifndef KDAV_DAVCOLLECTIONSFETCHJOB_H #define KDAV_DAVCOLLECTIONSFETCHJOB_H #include "kdav_export.h" #include "davcollection.h" #include "davjobbase.h" #include "davurl.h" #include namespace KDAV { class DavCollectionsFetchJobPrivate; /** * @short A job that fetches all DAV collection. * * This job is used to fetch all DAV collection that are available * under a certain DAV url. */ class KDAV_EXPORT DavCollectionsFetchJob : public DavJobBase { Q_OBJECT public: /** * Creates a new dav collections fetch job. * * @param url The DAV url of the DAV collection whose sub collections shall be fetched. * @param parent The parent object. */ explicit DavCollectionsFetchJob(const DavUrl &url, QObject *parent = nullptr); /** * Starts the job. */ void start() override; /** * Returns the list of fetched DAV collections. */ Q_REQUIRED_RESULT DavCollection::List collections() const; /** * Return the DavUrl used by this job */ Q_REQUIRED_RESULT DavUrl davUrl() const; Q_SIGNALS: /** * This signal is emitted every time a new collection has been discovered. * * @param collectionUrl The URL of the discovered collection * @param configuredUrl The URL given to the job */ - void collectionDiscovered(int protocol, const QString &collectionUrl, const QString &configuredUrl); + void collectionDiscovered(KDAV::Protocol protocol, const QString &collectionUrl, const QString &configuredUrl); private: void principalFetchFinished(KJob *); void collectionsFetchFinished(KJob *); void doCollectionsFetch(const QUrl &url); void subjobFinished(); Q_DECLARE_PRIVATE(DavCollectionsFetchJob) }; } #endif diff --git a/src/common/davcollectionsmultifetchjob.h b/src/common/davcollectionsmultifetchjob.h index ccbc7d7..a704540 100644 --- a/src/common/davcollectionsmultifetchjob.h +++ b/src/common/davcollectionsmultifetchjob.h @@ -1,71 +1,71 @@ /* SPDX-FileCopyrightText: 2010 Tobias Koenig SPDX-License-Identifier: LGPL-2.0-or-later */ #ifndef KDAV_DAVCOLLECTIONSMULTIFETCHJOB_H #define KDAV_DAVCOLLECTIONSMULTIFETCHJOB_H #include "kdav_export.h" #include "davcollection.h" #include "davurl.h" #include #include namespace KDAV { class DavCollectionsMultiFetchJobPrivate; /** * @short A job that fetches all DAV collection. * * This job is used to fetch all DAV collection that are available * under a certain list of DAV urls. * * @note This class just combines multiple calls of DavCollectionsFetchJob * into one job. */ class KDAV_EXPORT DavCollectionsMultiFetchJob : public KJob { Q_OBJECT public: /** * Creates a new dav collections multi fetch job. * * @param urls The list of DAV urls whose sub collections shall be fetched. * @param parent The parent object. */ explicit DavCollectionsMultiFetchJob(const DavUrl::List &urls, QObject *parent = nullptr); ~DavCollectionsMultiFetchJob(); /** * Starts the job. */ void start() override; /** * Returns the list of fetched DAV collections. */ Q_REQUIRED_RESULT DavCollection::List collections() const; Q_SIGNALS: /** * This signal is emitted every time a new collection has been discovered. * * @param collectionUrl The URL of the discovered collection * @param configuredUrl The URL given to the job */ - void collectionDiscovered(int protocol, const QString &collectionUrl, const QString &configuredUrl); + void collectionDiscovered(KDAV::Protocol protocol, const QString &collectionUrl, const QString &configuredUrl); private: void davJobFinished(KJob *); const std::unique_ptr d; }; } #endif