Merge pull request #3380 from owncloud/doxygenify

Structure developer documentation
This commit is contained in:
Daniel Molkentin 2015-06-29 18:57:23 +02:00
commit c4bc1da171
98 changed files with 534 additions and 96 deletions

View file

@ -194,7 +194,7 @@ add_subdirectory(src)
if(NOT BUILD_LIBRARIES_ONLY) if(NOT BUILD_LIBRARIES_ONLY)
add_subdirectory(shell_integration) add_subdirectory(shell_integration)
add_subdirectory(doc) add_subdirectory(doc)
add_subdirectory(dev-doc) add_subdirectory(doc/dev)
add_subdirectory(admin) add_subdirectory(admin)
endif(NOT BUILD_LIBRARIES_ONLY) endif(NOT BUILD_LIBRARIES_ONLY)

View file

@ -2,7 +2,7 @@
find_package(Doxygen) find_package(Doxygen)
if(DOXYGEN_FOUND) if(DOXYGEN_FOUND)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY)
add_custom_target(dev-doc add_custom_target(doc-dev
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating API documentation with Doxygen" VERBATIM COMMENT "Generating API documentation with Doxygen" VERBATIM

View file

@ -398,7 +398,7 @@ LOOKUP_CACHE_SIZE = 0
# normally produced when WARNINGS is set to YES. # normally produced when WARNINGS is set to YES.
# The default value is: NO. # The default value is: NO.
EXTRACT_ALL = YES EXTRACT_ALL = NO
# If the EXTRACT_PRIVATE tag is set to YES all private members of a class will # If the EXTRACT_PRIVATE tag is set to YES all private members of a class will
# be included in the documentation. # be included in the documentation.
@ -457,7 +457,7 @@ HIDE_UNDOC_MEMBERS = NO
# no effect if EXTRACT_ALL is enabled. # no effect if EXTRACT_ALL is enabled.
# The default value is: NO. # The default value is: NO.
HIDE_UNDOC_CLASSES = NO HIDE_UNDOC_CLASSES = YES
# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend # If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend
# (class|struct|union) declarations. If set to NO these declarations will be # (class|struct|union) declarations. If set to NO these declarations will be
@ -553,7 +553,7 @@ SORT_MEMBERS_CTORS_1ST = NO
# appear in their defined order. # appear in their defined order.
# The default value is: NO. # The default value is: NO.
SORT_GROUP_NAMES = NO SORT_GROUP_NAMES = YES
# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by # If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by
# fully-qualified names, including namespaces. If set to NO, the class list will # fully-qualified names, including namespaces. If set to NO, the class list will
@ -1899,7 +1899,7 @@ ENABLE_PREPROCESSING = YES
# The default value is: NO. # The default value is: NO.
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
MACRO_EXPANSION = NO MACRO_EXPANSION = YES
# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES then # If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES then
# the macro expansion is limited to the macros specified with the PREDEFINED and # the macro expansion is limited to the macros specified with the PREDEFINED and
@ -1907,7 +1907,7 @@ MACRO_EXPANSION = NO
# The default value is: NO. # The default value is: NO.
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
EXPAND_ONLY_PREDEF = NO EXPAND_ONLY_PREDEF = YES
# If the SEARCH_INCLUDES tag is set to YES the includes files in the # If the SEARCH_INCLUDES tag is set to YES the includes files in the
# INCLUDE_PATH will be searched if a #include is found. # INCLUDE_PATH will be searched if a #include is found.
@ -1939,7 +1939,7 @@ INCLUDE_FILE_PATTERNS =
# recursively expanded use the := operator instead of the = operator. # recursively expanded use the := operator instead of the = operator.
# This tag requires that the tag ENABLE_PREPROCESSING is set to YES. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES.
PREDEFINED = PREDEFINED = OWNCLOUDSYNC_EXPORT
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this
# tag can be used to specify a list of macro names that should be expanded. The # tag can be used to specify a list of macro names that should be expanded. The

View file

@ -18,7 +18,10 @@
#include <QObject> #include <QObject>
/**
* @brief Helper class for command line client
* @ingroup cmd
*/
class Cmd : public QObject { class Cmd : public QObject {
Q_OBJECT Q_OBJECT
public: public:

4
src/cmd/cmd.md Normal file
View file

@ -0,0 +1,4 @@
\defgroup cmd The command line client
The command line client
=======================

View file

@ -20,6 +20,10 @@
namespace OCC { namespace OCC {
/**
* @brief Parser for netrc files
* @ingroup cmd
*/
class NetrcParser class NetrcParser
{ {
public: public:

View file

@ -15,6 +15,8 @@
#include "account.h" #include "account.h"
#include "simplesslerrorhandler.h" #include "simplesslerrorhandler.h"
namespace OCC {
bool SimpleSslErrorHandler::handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, OCC::AccountPtr account) bool SimpleSslErrorHandler::handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, OCC::AccountPtr account)
{ {
(void) account; (void) account;
@ -30,3 +32,5 @@ bool SimpleSslErrorHandler::handleErrors(QList<QSslError> errors, const QSslConf
} }
return true; return true;
} }
}

View file

@ -18,9 +18,17 @@
class QSslError; class QSslError;
class QSslCertificate; class QSslCertificate;
namespace OCC {
/**
* @brief The SimpleSslErrorHandler class
* @ingroup cmd
*/
class SimpleSslErrorHandler : public OCC::AbstractSslErrorHandler { class SimpleSslErrorHandler : public OCC::AbstractSslErrorHandler {
public: public:
bool handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, OCC::AccountPtr) Q_DECL_OVERRIDE; bool handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, OCC::AccountPtr) Q_DECL_OVERRIDE;
}; };
}
#endif // SIMPLESSLERRORHANDLER_H #endif // SIMPLESSLERRORHANDLER_H

View file

@ -20,6 +20,10 @@ namespace OCC {
typedef QSharedPointer<AccountState> AccountStatePtr; typedef QSharedPointer<AccountState> AccountStatePtr;
/**
@brief The AccountManager class
@ingroup gui
*/
class AccountManager : public QObject { class AccountManager : public QObject {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -18,6 +18,10 @@
namespace OCC { namespace OCC {
/**
* @brief The AccountSettings class
* @ingroup gui
*/
class AccountMigrator { class AccountMigrator {
public: public:

View file

@ -41,6 +41,10 @@ class Account;
class AccountState; class AccountState;
class FolderStatusModel; class FolderStatusModel;
/**
* @brief The AccountSettings class
* @ingroup gui
*/
class AccountSettings : public QWidget class AccountSettings : public QWidget
{ {
Q_OBJECT Q_OBJECT

View file

@ -31,6 +31,7 @@ class AbstractCredentials;
/** /**
* @brief Extra info about an ownCloud server account. * @brief Extra info about an ownCloud server account.
* @ingroup gui
*/ */
class AccountState : public QObject { class AccountState : public QObject {
Q_OBJECT Q_OBJECT
@ -88,8 +89,6 @@ public:
/** Returns a new settings object for this account, already in the right groups. */ /** Returns a new settings object for this account, already in the right groups. */
std::unique_ptr<QSettings> settings(); std::unique_ptr<QSettings> settings();
private: private:
void setState(State state); void setState(State state);

View file

@ -24,6 +24,10 @@ namespace Ui {
class AddCertificateDialog; class AddCertificateDialog;
} }
/**
* @brief The AddCertificateDialog class
* @ingroup gui
*/
class AddCertificateDialog : public QDialog class AddCertificateDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -43,6 +43,10 @@ class Theme;
class Folder; class Folder;
class SslErrorDialog; class SslErrorDialog;
/**
* @brief The Application class
* @ingroup gui
*/
class Application : public SharedTools::QtSingleApplication class Application : public SharedTools::QtSingleApplication
{ {
Q_OBJECT Q_OBJECT

View file

@ -20,7 +20,10 @@ class QLineEdit;
namespace OCC { namespace OCC {
/** @brief Authenticate a user for a specific credential given his credentials */ /**
* @brief Authenticate a user for a specific credential given his credentials
* @ingroup gui
*/
class AuthenticationDialog : public QDialog { class AuthenticationDialog : public QDialog {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -14,7 +14,10 @@
namespace OCC { namespace OCC {
namespace Mac { namespace Mac {
/** CocoaInitializer provides an AutoRelease Pool via RIIA for use in main() */ /**
* @brief CocoaInitializer provides an AutoRelease Pool via RIIA for use in main()
* @ingroup gui
*/
class CocoaInitializer { class CocoaInitializer {
public: public:
CocoaInitializer(); CocoaInitializer();

View file

@ -22,6 +22,11 @@ namespace OCC
{ {
class AbstractCredentials; class AbstractCredentials;
/**
* @brief The HttpCredentialsGui namespace
* @ingroup gui
*/
namespace CredentialsFactory namespace CredentialsFactory
{ {

View file

@ -19,6 +19,10 @@
namespace OCC namespace OCC
{ {
/**
* @brief The HttpCredentialsGui class
* @ingroup gui
*/
class HttpCredentialsGui : public HttpCredentials { class HttpCredentialsGui : public HttpCredentials {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -26,6 +26,10 @@ namespace OCC
class Account; class Account;
class ShibbolethCredentials; class ShibbolethCredentials;
/**
* @brief The ShibbolethRefresher class
* @ingroup gui
*/
class ShibbolethRefresher : public QObject class ShibbolethRefresher : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -20,8 +20,9 @@ namespace OCC
{ {
/** /**
* @brief Fetch the user name of the shibboleth connection * @brief Fetch the user name of the shibboleth connection
*/ * @ingroup gui
*/
class ShibbolethUserJob : public JsonApiJob { class ShibbolethUserJob : public JsonApiJob {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -28,6 +28,10 @@ namespace OCC
class ShibbolethCookieJar; class ShibbolethCookieJar;
/**
* @brief The ShibbolethWebView class
* @ingroup gui
*/
class ShibbolethWebView : public QWebView class ShibbolethWebView : public QWebView
{ {
Q_OBJECT Q_OBJECT

View file

@ -33,6 +33,10 @@ namespace OCC
class ShibbolethWebView; class ShibbolethWebView;
/**
* @brief The ShibbolethCredentials class
* @ingroup gui
*/
class ShibbolethCredentials : public AbstractCredentials class ShibbolethCredentials : public AbstractCredentials
{ {
Q_OBJECT Q_OBJECT

View file

@ -44,6 +44,10 @@ namespace OCC {
class SyncEngine; class SyncEngine;
class AccountState; class AccountState;
/**
* @brief The FolderDefinition class
* @ingroup gui
*/
class FolderDefinition class FolderDefinition
{ {
public: public:
@ -68,6 +72,10 @@ public:
FolderDefinition* folder); FolderDefinition* folder);
}; };
/**
* @brief The Folder class
* @ingroup gui
*/
class Folder : public QObject class Folder : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -33,6 +33,10 @@ class Application;
class SyncResult; class SyncResult;
class SocketApi; class SocketApi;
/**
* @brief The FolderMan class
* @ingroup gui
*/
class FolderMan : public QObject class FolderMan : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -18,7 +18,10 @@
namespace OCC { namespace OCC {
/**
* @brief The FolderStatusDelegate class
* @ingroup gui
*/
class FolderStatusDelegate : public QStyledItemDelegate class FolderStatusDelegate : public QStyledItemDelegate
{ {
Q_OBJECT Q_OBJECT

View file

@ -26,6 +26,10 @@ namespace OCC {
class Folder; class Folder;
class ProgressInfo; class ProgressInfo;
/**
* @brief The FolderStatusModel class
* @ingroup gui
*/
class FolderStatusModel : public QAbstractItemModel class FolderStatusModel : public QAbstractItemModel
{ {
Q_OBJECT Q_OBJECT

View file

@ -31,7 +31,9 @@ namespace OCC {
class FolderWatcherPrivate; class FolderWatcherPrivate;
/* /**
* @brief Montiors a directory recursively for changes
*
* Folder Watcher monitors a directory and its sub directories * Folder Watcher monitors a directory and its sub directories
* for changes in the local file system. Changes are signalled * for changes in the local file system. Changes are signalled
* through the pathChanged() signal. * through the pathChanged() signal.
@ -40,6 +42,8 @@ class FolderWatcherPrivate;
* does not automatically adds them to the list of monitored * does not automatically adds them to the list of monitored
* dirs. That is the responsibility of the user of this class to * dirs. That is the responsibility of the user of this class to
* call addPath() with the new dir. * call addPath() with the new dir.
*
* @ingroup gui
*/ */
class FolderWatcher : public QObject class FolderWatcher : public QObject

View file

@ -24,6 +24,11 @@
namespace OCC namespace OCC
{ {
/**
* @brief Linux (inotify) API implementation of FolderWatcher
* @ingroup gui
*/
class FolderWatcherPrivate : public QObject class FolderWatcherPrivate : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -23,6 +23,10 @@
namespace OCC namespace OCC
{ {
/**
* @brief Mac OS X API implementation of FolderWatcher
* @ingroup gui
*/
class FolderWatcherPrivate class FolderWatcherPrivate
{ {
public: public:

View file

@ -22,6 +22,10 @@ namespace OCC {
class FolderWatcher; class FolderWatcher;
/**
* @brief Qt API implementation of FolderWatcher
* @ingroup gui
*/
class FolderWatcherPrivate : public QObject { class FolderWatcherPrivate : public QObject {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -21,8 +21,10 @@ namespace OCC {
class FolderWatcher; class FolderWatcher;
// watcher thread /**
* @brief The WatcherThread class
* @ingroup gui
*/
class WatcherThread : public QThread { class WatcherThread : public QThread {
Q_OBJECT Q_OBJECT
public: public:
@ -44,6 +46,10 @@ private:
HANDLE _handle; HANDLE _handle;
}; };
/**
* @brief Windows implementation of FolderWatcher
* @ingroup gui
*/
class FolderWatcherPrivate : public QObject { class FolderWatcherPrivate : public QObject {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -31,6 +31,10 @@ class SelectiveSyncTreeView;
class ownCloudInfo; class ownCloudInfo;
/**
* @brief The FormatWarningsWizardPage class
* @ingroup gui
*/
class FormatWarningsWizardPage : public QWizardPage { class FormatWarningsWizardPage : public QWizardPage {
Q_OBJECT Q_OBJECT
protected: protected:
@ -38,7 +42,8 @@ protected:
}; };
/** /**
* page to ask for the local source folder * @brief Page to ask for the local source folder
* @ingroup gui
*/ */
class FolderWizardLocalPath : public FormatWarningsWizardPage class FolderWizardLocalPath : public FormatWarningsWizardPage
{ {
@ -62,7 +67,8 @@ private:
/** /**
* page to ask for the target folder * @brief page to ask for the target folder
* @ingroup gui
*/ */
class FolderWizardRemotePath : public FormatWarningsWizardPage class FolderWizardRemotePath : public FormatWarningsWizardPage
@ -100,7 +106,10 @@ private:
QTimer _lscolTimer; QTimer _lscolTimer;
}; };
/**
* @brief The FolderWizardSelectiveSync class
* @ingroup gui
*/
class FolderWizardSelectiveSync : public QWizardPage class FolderWizardSelectiveSync : public QWizardPage
{ {
Q_OBJECT Q_OBJECT
@ -118,9 +127,9 @@ private:
}; };
/** /**
* * @brief The FolderWizard class
* @ingroup gui
*/ */
class FolderWizard : public QWizard class FolderWizard : public QWizard
{ {

View file

@ -24,6 +24,10 @@ namespace Ui {
class GeneralSettings; class GeneralSettings;
} }
/**
* @brief The GeneralSettings class
* @ingroup gui
*/
class GeneralSettings : public QWidget class GeneralSettings : public QWidget
{ {
Q_OBJECT Q_OBJECT

5
src/gui/gui.md Normal file
View file

@ -0,0 +1,5 @@
The GUI Client
==============
\defgroup gui The GUI client

View file

@ -24,6 +24,10 @@ namespace Ui {
class IgnoreListEditor; class IgnoreListEditor;
} }
/**
* @brief The IgnoreListEditor class
* @ingroup gui
*/
class IgnoreListEditor : public QDialog class IgnoreListEditor : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -28,6 +28,10 @@
namespace OCC { namespace OCC {
/**
* @brief The LogWidget class
* @ingroup gui
*/
class LogWidget : public QPlainTextEdit class LogWidget : public QPlainTextEdit
{ {
Q_OBJECT Q_OBJECT
@ -38,6 +42,10 @@ signals:
}; };
/**
* @brief The LogBrowser class
* @ingroup gui
*/
class LogBrowser : public QDialog class LogBrowser : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -23,6 +23,10 @@ namespace Ui {
class NetworkSettings; class NetworkSettings;
} }
/**
* @brief The NetworkSettings class
* @ingroup gui
*/
class NetworkSettings : public QWidget class NetworkSettings : public QWidget
{ {
Q_OBJECT Q_OBJECT

View file

@ -15,6 +15,9 @@
#include <QString> #include <QString>
namespace OCC { namespace OCC {
/** Open the file manager with the specified file pre-selected */ /**
* @brief Open the file manager with the specified file pre-selected
* @ingroup gui
*/
void showInFileManager(const QString &localPath); void showInFileManager(const QString &localPath);
} }

View file

@ -33,6 +33,10 @@ class SettingsDialogMac;
class Application; class Application;
class LogBrowser; class LogBrowser;
/**
* @brief The ownCloudGui class
* @ingroup gui
*/
class ownCloudGui : public QObject class ownCloudGui : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -33,6 +33,10 @@ class AccountState;
class OwncloudWizard; class OwncloudWizard;
/**
* @brief The DetermineAuthTypeJob class
* @ingroup gui
*/
class DetermineAuthTypeJob : public AbstractNetworkJob { class DetermineAuthTypeJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
@ -46,7 +50,10 @@ private:
int _redirects; int _redirects;
}; };
/**
* @brief The OwncloudSetupWizard class
* @ingroup gui
*/
class OwncloudSetupWizard : public QObject class OwncloudSetupWizard : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -32,6 +32,10 @@ namespace Ui {
} }
class Application; class Application;
/**
* @brief The ProtocolWidget class
* @ingroup gui
*/
class ProtocolWidget : public QWidget class ProtocolWidget : public QWidget
{ {
Q_OBJECT Q_OBJECT

View file

@ -25,7 +25,8 @@ class AccountState;
class PropfindJob; class PropfindJob;
/** /**
* This class handle the getting the quota to display in the UI * @brief handles getting the quota to display in the UI
*
* It is typically owned by the AccountSetting page. * It is typically owned by the AccountSetting page.
* *
* The quota is requested if those 3 conditions are met: * The quota is requested if those 3 conditions are met:
@ -38,6 +39,8 @@ class PropfindJob;
* quota is not updated fast enough when changed on the server. * quota is not updated fast enough when changed on the server.
* *
* If the quota job is not finished within 30 seconds, it is cancelled and another one is started * If the quota job is not finished within 30 seconds, it is cancelled and another one is started
*
* @ingroup gui
*/ */
class QuotaInfo : public QObject { class QuotaInfo : public QObject {
Q_OBJECT Q_OBJECT

View file

@ -25,6 +25,10 @@ namespace OCC {
class Folder; class Folder;
/**
* @brief The SelectiveSyncTreeView class
* @ingroup gui
*/
class SelectiveSyncTreeView : public QTreeWidget { class SelectiveSyncTreeView : public QTreeWidget {
Q_OBJECT Q_OBJECT
public: public:
@ -57,6 +61,10 @@ private:
QLabel *_loading; QLabel *_loading;
}; };
/**
* @brief The SelectiveSyncDialog class
* @ingroup gui
*/
class SelectiveSyncDialog : public QDialog { class SelectiveSyncDialog : public QDialog {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -34,6 +34,10 @@ class Application;
class FolderMan; class FolderMan;
class ownCloudGui; class ownCloudGui;
/**
* @brief The SettingsDialog class
* @ingroup gui
*/
class SettingsDialog : public QDialog class SettingsDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -31,6 +31,10 @@ class ownCloudGui;
class Folder; class Folder;
class AccountState; class AccountState;
/**
* @brief The SettingsDialogMac class
* @ingroup gui
*/
class SettingsDialogMac : public MacPreferencesWindow class SettingsDialogMac : public MacPreferencesWindow
{ {
Q_OBJECT Q_OBJECT

View file

@ -23,6 +23,10 @@
namespace OCC { namespace OCC {
/**
* @brief The OcsShareJob class
* @ingroup gui
*/
class OcsShareJob : public AbstractNetworkJob { class OcsShareJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
@ -53,6 +57,10 @@ class AbstractCredentials;
class QuotaInfo; class QuotaInfo;
class SyncResult; class SyncResult;
/**
* @brief The ShareDialog class
* @ingroup gui
*/
class ShareDialog : public QDialog class ShareDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -40,6 +40,10 @@ namespace OCC {
class SyncFileStatus; class SyncFileStatus;
class Folder; class Folder;
/**
* @brief The SocketApi class
* @ingroup gui
*/
class SocketApi : public QObject class SocketApi : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -26,6 +26,10 @@ namespace OCC {
class AccountState; class AccountState;
/**
* @brief The SslButton class
* @ingroup gui
*/
class SslButton : public QToolButton class SslButton : public QToolButton
{ {
Q_OBJECT Q_OBJECT

View file

@ -31,11 +31,19 @@ namespace Ui {
class SslErrorDialog; class SslErrorDialog;
} }
/**
* @brief The SslDialogErrorHandler class
* @ingroup gui
*/
class SslDialogErrorHandler : public AbstractSslErrorHandler { class SslDialogErrorHandler : public AbstractSslErrorHandler {
public: public:
bool handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, AccountPtr) Q_DECL_OVERRIDE; bool handleErrors(QList<QSslError> errors, const QSslConfiguration &conf, QList<QSslCertificate> *certs, AccountPtr) Q_DECL_OVERRIDE;
}; };
/**
* @brief The SslErrorDialog class
* @ingroup gui
*/
class SslErrorDialog : public QDialog class SslErrorDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT

View file

@ -24,6 +24,10 @@
namespace OCC { namespace OCC {
class SyncFileItem; class SyncFileItem;
/**
* @brief The SyncRunFileLog class
* @ingroup gui
*/
class SyncRunFileLog class SyncRunFileLog
{ {
public: public:

View file

@ -26,6 +26,10 @@ bool canOsXSendUserNotification();
void sendOsXUserNotification(const QString &title, const QString &message); void sendOsXUserNotification(const QString &title, const QString &message);
#endif #endif
/**
* @brief The Systray class
* @ingroup gui
*/
class Systray : public QSystemTrayIcon class Systray : public QSystemTrayIcon
{ {
Q_OBJECT Q_OBJECT

View file

@ -28,7 +28,10 @@ class QTimer;
namespace OCC { namespace OCC {
/** @short Class that uses an ownCloud propritary XML format to fetch update information */ /**
* @brief Class that uses an ownCloud propritary XML format to fetch update information
* @ingroup gui
*/
class OCUpdater : public QObject, public Updater class OCUpdater : public QObject, public Updater
{ {
Q_OBJECT Q_OBJECT
@ -72,7 +75,10 @@ private:
UpdateInfo _updateInfo; UpdateInfo _updateInfo;
}; };
/** Windows Updater Using NSIS */ /**
* @brief Windows Updater Using NSIS
* @ingroup gui
*/
class NSISUpdater : public OCUpdater { class NSISUpdater : public OCUpdater {
Q_OBJECT Q_OBJECT
public: public:
@ -93,8 +99,13 @@ private:
}; };
/** Passive updater: Only implements notification for use in settings. /**
Does not do popups */ * @brief Updater that only implements notification for use in settings
*
* The implementation does how show popups
*
* @ingroup gui
*/
class PassiveUpdateNotifier : public OCUpdater { class PassiveUpdateNotifier : public OCUpdater {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -21,6 +21,10 @@ namespace OCC
class AbstractCredentials; class AbstractCredentials;
/**
* @brief The AbstractCredentialsWizardPage class
* @ingroup gui
*/
class AbstractCredentialsWizardPage : public QWizardPage class AbstractCredentialsWizardPage : public QWizardPage
{ {
public: public:

View file

@ -25,6 +25,10 @@ class QProgressIndicator;
namespace OCC { namespace OCC {
/**
* @brief The OwncloudAdvancedSetupPage class
* @ingroup gui
*/
class OwncloudAdvancedSetupPage: public QWizardPage class OwncloudAdvancedSetupPage: public QWizardPage
{ {
Q_OBJECT Q_OBJECT

View file

@ -16,6 +16,8 @@
#include "utility.h" #include "utility.h"
#include <QUrl> #include <QUrl>
namespace OCC {
OwncloudConnectionMethodDialog::OwncloudConnectionMethodDialog(QWidget *parent) : OwncloudConnectionMethodDialog::OwncloudConnectionMethodDialog(QWidget *parent) :
QDialog(parent), QDialog(parent),
ui(new Ui::OwncloudConnectionMethodDialog) ui(new Ui::OwncloudConnectionMethodDialog)
@ -60,3 +62,5 @@ OwncloudConnectionMethodDialog::~OwncloudConnectionMethodDialog()
{ {
delete ui; delete ui;
} }
}

View file

@ -19,10 +19,16 @@
#include "ui_owncloudconnectionmethoddialog.h" #include "ui_owncloudconnectionmethoddialog.h"
namespace OCC {
namespace Ui { namespace Ui {
class OwncloudConnectionMethodDialog; class OwncloudConnectionMethodDialog;
} }
/**
* @brief The OwncloudConnectionMethodDialog class
* @ingroup gui
*/
class OwncloudConnectionMethodDialog : public QDialog class OwncloudConnectionMethodDialog : public QDialog
{ {
Q_OBJECT Q_OBJECT
@ -48,4 +54,6 @@ private:
Ui::OwncloudConnectionMethodDialog *ui; Ui::OwncloudConnectionMethodDialog *ui;
}; };
}
#endif // OWNCLOUDCONNECTIONMETHODDIALOG_H #endif // OWNCLOUDCONNECTIONMETHODDIALOG_H

View file

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0"> <ui version="4.0">
<class>OwncloudConnectionMethodDialog</class> <class>OCC::OwncloudConnectionMethodDialog</class>
<widget class="QDialog" name="OwncloudConnectionMethodDialog"> <widget class="QDialog" name="OCC::OwncloudConnectionMethodDialog">
<property name="geometry"> <property name="geometry">
<rect> <rect>
<x>0</x> <x>0</x>

View file

@ -25,6 +25,9 @@ class QProgressIndicator;
namespace OCC { namespace OCC {
/**
* @brief The OwncloudHttpCredsPage class
*/
class OwncloudHttpCredsPage : public AbstractCredentialsWizardPage class OwncloudHttpCredsPage : public AbstractCredentialsWizardPage
{ {
Q_OBJECT Q_OBJECT

View file

@ -32,6 +32,10 @@ class QProgressIndicator;
namespace OCC { namespace OCC {
/**
* @brief The OwncloudSetupPage class
* @ingroup gui
*/
class OwncloudSetupPage: public QWizardPage class OwncloudSetupPage: public QWizardPage
{ {
Q_OBJECT Q_OBJECT

View file

@ -27,6 +27,10 @@ namespace OCC {
class ShibbolethWebView; class ShibbolethWebView;
/**
* @brief The OwncloudShibbolethCredsPage class
* @ingroup gui
*/
class OwncloudShibbolethCredsPage : public AbstractCredentialsWizardPage class OwncloudShibbolethCredsPage : public AbstractCredentialsWizardPage
{ {
Q_OBJECT Q_OBJECT

View file

@ -31,7 +31,11 @@ class OwncloudWizardResultPage;
class AbstractCredentials; class AbstractCredentials;
class AbstractCredentialsWizardPage; class AbstractCredentialsWizardPage;
class OwncloudWizard: public QWizard /**
* @brief The OwncloudWizard class
* @ingroup gui
*/
class OwncloudWizard : public QWizard
{ {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -22,6 +22,10 @@
namespace OCC { namespace OCC {
/**
* @brief The OwncloudWizardResultPage class
* @ingroup gui
*/
class OwncloudWizardResultPage : public QWizardPage class OwncloudWizardResultPage : public QWizardPage
{ {
Q_OBJECT Q_OBJECT

View file

@ -33,6 +33,7 @@ class AbstractSslErrorHandler;
/** /**
* @brief The AbstractNetworkJob class * @brief The AbstractNetworkJob class
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT AbstractNetworkJob : public QObject { class OWNCLOUDSYNC_EXPORT AbstractNetworkJob : public QObject {
Q_OBJECT Q_OBJECT

View file

@ -23,6 +23,10 @@ class QUrl;
namespace OCC namespace OCC
{ {
/**
* @brief The AccessManager class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT AccessManager : public QNetworkAccessManager class OWNCLOUDSYNC_EXPORT AccessManager : public QNetworkAccessManager
{ {
Q_OBJECT Q_OBJECT

View file

@ -32,6 +32,7 @@
namespace OCC { namespace OCC {
Account::Account(QObject *parent) Account::Account(QObject *parent)
: QObject(parent) : QObject(parent)
, _am(0) , _am(0)

View file

@ -41,15 +41,20 @@ class QuotaInfo;
class AccessManager; class AccessManager;
/* Reimplement this to handle SSL errors */ /**
* @brief Reimplement this to handle SSL errors from libsync
* @ingroup libsync
*/
class AbstractSslErrorHandler { class AbstractSslErrorHandler {
public: public:
virtual ~AbstractSslErrorHandler() {} virtual ~AbstractSslErrorHandler() {}
virtual bool handleErrors(QList<QSslError>, const QSslConfiguration &conf, QList<QSslCertificate>*, AccountPtr) = 0; virtual bool handleErrors(QList<QSslError>, const QSslConfiguration &conf, QList<QSslCertificate>*, AccountPtr) = 0;
}; };
/** /**
* @brief This class represents an account on an ownCloud Server * @brief The Account class represents an account on an ownCloud Server
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT Account : public QObject { class OWNCLOUDSYNC_EXPORT Account : public QObject {
Q_OBJECT Q_OBJECT
@ -70,7 +75,7 @@ public:
QString id() const; QString id() const;
/** /**
* @brief Checks the Account instance is different from \param other * @brief Checks the Account instance is different from @param other
* *
* @returns true, if credentials or url have changed, false otherwise * @returns true, if credentials or url have changed, false otherwise
*/ */

View file

@ -26,6 +26,10 @@ class UploadDevice;
class GETFileJob; class GETFileJob;
class OwncloudPropagator; class OwncloudPropagator;
/**
* @brief The BandwidthManager class
* @ingroup libsync
*/
class BandwidthManager : public QObject { class BandwidthManager : public QObject {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -26,6 +26,10 @@ namespace OCC {
class ConfigFile; class ConfigFile;
/**
* @brief The ClientProxy class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT ClientProxy : public QObject class OWNCLOUDSYNC_EXPORT ClientProxy : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -27,6 +27,10 @@ namespace OCC {
class AbstractCredentials; class AbstractCredentials;
/**
* @brief The ConfigFile class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT ConfigFile class OWNCLOUDSYNC_EXPORT ConfigFile
{ {
public: public:

View file

@ -34,7 +34,7 @@ namespace OCC {
* *
* Here follows the state machine * Here follows the state machine
\code{.unparsed}
*---> checkServerAndAuth (check status.php) *---> checkServerAndAuth (check status.php)
Will asynchronously check for system proxy (if using system proxy) Will asynchronously check for system proxy (if using system proxy)
And then invoke slotCheckServerAndAuth And then invoke slotCheckServerAndAuth
@ -62,6 +62,7 @@ namespace OCC {
JsonApiJob JsonApiJob
| |
+-> slotCapabilitiesRecieved --> X +-> slotCapabilitiesRecieved --> X
\endcode
*/ */
class OWNCLOUDSYNC_EXPORT ConnectionValidator : public QObject class OWNCLOUDSYNC_EXPORT ConnectionValidator : public QObject
{ {

View file

@ -20,6 +20,10 @@
namespace OCC { namespace OCC {
/**
* @brief The CookieJar class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT CookieJar : public QNetworkCookieJar class OWNCLOUDSYNC_EXPORT CookieJar : public QNetworkCookieJar
{ {
Q_OBJECT Q_OBJECT

View file

@ -34,6 +34,10 @@ class Account;
* if the files are new, or changed. * if the files are new, or changed.
*/ */
/**
* @brief The FileStatPointer class
* @ingroup libsync
*/
class FileStatPointer { class FileStatPointer {
public: public:
FileStatPointer(csync_vio_file_stat_t *stat) FileStatPointer(csync_vio_file_stat_t *stat)
@ -66,7 +70,13 @@ struct DiscoveryDirectoryResult {
DiscoveryDirectoryResult() : code(EIO), listIndex(0) { } DiscoveryDirectoryResult() : code(EIO), listIndex(0) { }
}; };
// Run in the main thread, reporting to the DiscoveryJobMainThread object /**
* @brief The DiscoverySingleDirectoryJob class
*
* Run in the main thread, reporting to the DiscoveryJobMainThread object
*
* @ingroup libsync
*/
class DiscoverySingleDirectoryJob : public QObject { class DiscoverySingleDirectoryJob : public QObject {
Q_OBJECT Q_OBJECT
public: public:
@ -129,9 +139,13 @@ public:
void setupHooks(DiscoveryJob* discoveryJob, const QString &pathPrefix); void setupHooks(DiscoveryJob* discoveryJob, const QString &pathPrefix);
}; };
/**
// Lives in the other thread * @brief The DiscoveryJob class
// Deletes itself in start() *
* Lives in the other thread, deletes itself in !start()
*
* @ingroup libsync
*/
class DiscoveryJob : public QObject { class DiscoveryJob : public QObject {
Q_OBJECT Q_OBJECT
friend class DiscoveryMainThread; friend class DiscoveryMainThread;

View file

@ -27,19 +27,28 @@ class QFileInfo;
namespace OCC { namespace OCC {
/** /**
* This file contains file system helper. * \addtogroup libsync
* @{
*/ */
/**
* @brief This file contains file system helper
*/
namespace FileSystem { namespace FileSystem {
/** compare two files with given filename and return true if they have the same content */ /**
* @brief compare two files with given filename and return true if they have the same content
*/
bool fileEquals(const QString &fn1, const QString &fn2); bool fileEquals(const QString &fn1, const QString &fn2);
/** Mark the file as hidden (only has effects on windows) */ /**
* @brief Mark the file as hidden (only has effects on windows)
*/
void OWNCLOUDSYNC_EXPORT setFileHidden(const QString& filename, bool hidden); void OWNCLOUDSYNC_EXPORT setFileHidden(const QString& filename, bool hidden);
/** Get the mtime for a filepath. /**
* @brief Get the mtime for a filepath
* *
* Use this over QFileInfo::lastModified() to avoid timezone related bugs. See * Use this over QFileInfo::lastModified() to avoid timezone related bugs. See
* owncloud/core#9781 for details. * owncloud/core#9781 for details.
@ -48,14 +57,16 @@ time_t OWNCLOUDSYNC_EXPORT getModTime(const QString& filename);
bool setModTime(const QString &filename, time_t modTime); bool setModTime(const QString &filename, time_t modTime);
/** Get the size for a file. /**
* @brief Get the size for a file
* *
* Use this over QFileInfo::size() to avoid bugs with lnk files on Windows. * Use this over QFileInfo::size() to avoid bugs with lnk files on Windows.
* See https://bugreports.qt.io/browse/QTBUG-24831. * See https://bugreports.qt.io/browse/QTBUG-24831.
*/ */
qint64 OWNCLOUDSYNC_EXPORT getSize(const QString& filename); qint64 OWNCLOUDSYNC_EXPORT getSize(const QString& filename);
/** Checks whether a file exists. /**
* @brief Checks whether a file exists.
* *
* Use this over QFileInfo::exists() and QFile::exists() to avoid bugs with lnk * Use this over QFileInfo::exists() and QFile::exists() to avoid bugs with lnk
* files, see above. * files, see above.
@ -63,7 +74,7 @@ qint64 OWNCLOUDSYNC_EXPORT getSize(const QString& filename);
bool OWNCLOUDSYNC_EXPORT fileExists(const QString& filename); bool OWNCLOUDSYNC_EXPORT fileExists(const QString& filename);
/** /**
* Rename the file \a originFileName to \a destinationFileName. * @brief Rename the file \a originFileName to \a destinationFileName.
* *
* It behaves as QFile::rename() but handles .lnk files correctly on Windows. * It behaves as QFile::rename() but handles .lnk files correctly on Windows.
*/ */
@ -72,25 +83,31 @@ bool OWNCLOUDSYNC_EXPORT rename(const QString& originFileName,
QString* errorString = NULL); QString* errorString = NULL);
/** /**
* Returns true if the file's mtime or size are not what is expected. * @brief Check if \a fileName chas changed given previous size and mtime
*
* Nonexisting files are covered through mtime: they have an mtime of -1. * Nonexisting files are covered through mtime: they have an mtime of -1.
*
* @return true if the file's mtime or size are not what is expected.
*/ */
bool fileChanged(const QString& fileName, bool fileChanged(const QString& fileName,
qint64 previousSize, qint64 previousSize,
time_t previousMtime); time_t previousMtime);
/** /**
* Like !fileChanged() but with verbose logging if the file *did* change. * @brief Like !fileChanged() but with verbose logging if the file *did* change.
*/ */
bool verifyFileUnchanged(const QString& fileName, bool verifyFileUnchanged(const QString& fileName,
qint64 previousSize, qint64 previousSize,
time_t previousMtime); time_t previousMtime);
/** /**
* @brief renames a file, overriding the target if it exists
*
* Rename the file \a originFileName to \a destinationFileName, and * Rename the file \a originFileName to \a destinationFileName, and
* overwrite the destination if it already exists - as long as the * overwrite the destination if it already exists - as long as the
* destination file has the expected \a destinationSize and * destination file has the expected \a destinationSize and
* \a destinationMtime. * \a destinationMtime.
*
* If the destination file does not exist, the given size and mtime are * If the destination file does not exist, the given size and mtime are
* ignored. * ignored.
*/ */
@ -130,4 +147,8 @@ QByteArray OWNCLOUDSYNC_EXPORT calcSha1( const QString& fileName );
QByteArray OWNCLOUDSYNC_EXPORT calcAdler32( const QString& fileName ); QByteArray OWNCLOUDSYNC_EXPORT calcAdler32( const QString& fileName );
#endif #endif
}} }
/** @} */
}

5
src/libsync/libsync.md Normal file
View file

@ -0,0 +1,5 @@
\defgroup libsync The sync library
The sync library
================

View file

@ -37,6 +37,10 @@ struct Log{
QString message; QString message;
}; };
/**
* @brief The Logger class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT Logger : public QObject class OWNCLOUDSYNC_EXPORT Logger : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -24,6 +24,7 @@ namespace OCC {
/** /**
* @brief The EntityExistsJob class * @brief The EntityExistsJob class
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT EntityExistsJob : public AbstractNetworkJob { class OWNCLOUDSYNC_EXPORT EntityExistsJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -40,6 +41,7 @@ private slots:
/** /**
* @brief The LsColJob class * @brief The LsColJob class
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT LsColXMLParser : public QObject { class OWNCLOUDSYNC_EXPORT LsColXMLParser : public QObject {
Q_OBJECT Q_OBJECT
@ -94,6 +96,8 @@ private:
* *
* Note that this job is only for querying one item. * Note that this job is only for querying one item.
* There is also the LsColJob which can be used to list collections * There is also the LsColJob which can be used to list collections
*
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT PropfindJob : public AbstractNetworkJob { class OWNCLOUDSYNC_EXPORT PropfindJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -125,6 +129,7 @@ private:
/** /**
* @brief The MkColJob class * @brief The MkColJob class
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT MkColJob : public AbstractNetworkJob { class OWNCLOUDSYNC_EXPORT MkColJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -141,6 +146,7 @@ private slots:
/** /**
* @brief The CheckServerJob class * @brief The CheckServerJob class
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT CheckServerJob : public AbstractNetworkJob { class OWNCLOUDSYNC_EXPORT CheckServerJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -188,11 +194,14 @@ private slots:
* Note! you need to be in the connected state before calling this because of a server bug: * Note! you need to be in the connected state before calling this because of a server bug:
* https://github.com/owncloud/core/issues/12930 * https://github.com/owncloud/core/issues/12930
* *
* To be used like this * To be used like this:
* \code
* _job = new JsonApiJob(account, QLatin1String("ocs/v1.php/foo/bar"), this); * _job = new JsonApiJob(account, QLatin1String("ocs/v1.php/foo/bar"), this);
* connect(job, SIGNAL(jsonRecieved(QVariantMap)), ...) * connect(job, SIGNAL(jsonRecieved(QVariantMap)), ...)
* The recieved QVariantMap is empty in case of error or otherwise is a map as parsed by QtJson * The recieved QVariantMap is empty in case of error or otherwise is a map as parsed by QtJson
* \encode
* *
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT JsonApiJob : public AbstractNetworkJob { class OWNCLOUDSYNC_EXPORT JsonApiJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT

View file

@ -41,15 +41,13 @@ class SyncJournalDb;
class OwncloudPropagator; class OwncloudPropagator;
/** /**
* @class PropagatorJob
* @brief the base class of propagator jobs * @brief the base class of propagator jobs
* *
* This can either be a job, or a container for jobs. * This can either be a job, or a container for jobs.
* If it is a composite jobs, it then inherits from PropagateDirectory * If it is a composite jobs, it then inherits from PropagateDirectory
* *
* * @ingroup libsync
*/ */
class PropagatorJob : public QObject { class PropagatorJob : public QObject {
Q_OBJECT Q_OBJECT
protected: protected:
@ -158,8 +156,9 @@ public slots:
}; };
/* /**
* Propagate a directory, and all its sub entries. * @brief Propagate a directory, and all its sub entries.
* @ingroup libsync
*/ */
class PropagateDirectory : public PropagatorJob { class PropagateDirectory : public PropagatorJob {
Q_OBJECT Q_OBJECT
@ -220,7 +219,10 @@ private slots:
}; };
// Dummy job that just mark it as completed and ignored. /**
* @brief Dummy job that just mark it as completed and ignored
* @ingroup libsync
*/
class PropagateIgnoreJob : public PropagateItemJob { class PropagateIgnoreJob : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:
@ -349,7 +351,11 @@ private:
mutable QMutex _touchedFilesMutex; mutable QMutex _touchedFilesMutex;
}; };
// Job that wait for all the poll jobs to be completed
/**
* @brief Job that wait for all the poll jobs to be completed
* @ingroup libsync
*/
class CleanupPollsJob : public QObject { class CleanupPollsJob : public QObject {
Q_OBJECT Q_OBJECT
QVector< SyncJournalDb::PollInfo > _pollInfos; QVector< SyncJournalDb::PollInfo > _pollInfos;

View file

@ -19,6 +19,10 @@
namespace OCC { namespace OCC {
/**
* @brief The ownCloudTheme class
* @ingroup libsync
*/
class ownCloudTheme : public Theme class ownCloudTheme : public Theme
{ {
Q_OBJECT Q_OBJECT

View file

@ -23,6 +23,10 @@
namespace OCC { namespace OCC {
/**
* @brief The SqlDatabase class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SqlDatabase class OWNCLOUDSYNC_EXPORT SqlDatabase
{ {
Q_DISABLE_COPY(SqlDatabase) Q_DISABLE_COPY(SqlDatabase)
@ -48,6 +52,10 @@ private:
}; };
/**
* @brief The SqlQuery class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SqlQuery class OWNCLOUDSYNC_EXPORT SqlQuery
{ {
Q_DISABLE_COPY(SqlQuery) Q_DISABLE_COPY(SqlQuery)

View file

@ -27,6 +27,10 @@
namespace OCC { namespace OCC {
/**
* @brief The ProgressInfo class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT ProgressInfo : public QObject class OWNCLOUDSYNC_EXPORT ProgressInfo : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -21,6 +21,10 @@
namespace OCC { namespace OCC {
/**
* @brief The GETFileJob class
* @ingroup libsync
*/
class GETFileJob : public AbstractNetworkJob { class GETFileJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
QFile* _device; QFile* _device;
@ -98,7 +102,10 @@ private slots:
void slotMetaDataChanged(); void slotMetaDataChanged();
}; };
/**
* @brief The PropagateDownloadFileQNAM class
* @ingroup libsync
*/
class PropagateDownloadFileQNAM : public PropagateItemJob { class PropagateDownloadFileQNAM : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -18,6 +18,10 @@
namespace OCC { namespace OCC {
/**
* @brief The DeleteJob class
* @ingroup libsync
*/
class DeleteJob : public AbstractNetworkJob { class DeleteJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
public: public:
@ -33,6 +37,10 @@ signals:
void finishedSignal(); void finishedSignal();
}; };
/**
* @brief The PropagateRemoteDelete class
* @ingroup libsync
*/
class PropagateRemoteDelete : public PropagateItemJob { class PropagateRemoteDelete : public PropagateItemJob {
Q_OBJECT Q_OBJECT
QPointer<DeleteJob> _job; QPointer<DeleteJob> _job;
@ -46,4 +54,4 @@ private slots:
}; };
} }

View file

@ -18,6 +18,10 @@
namespace OCC { namespace OCC {
/**
* @brief The PropagateRemoteMkdir class
* @ingroup libsync
*/
class PropagateRemoteMkdir : public PropagateItemJob { class PropagateRemoteMkdir : public PropagateItemJob {
Q_OBJECT Q_OBJECT
QPointer<AbstractNetworkJob> _job; QPointer<AbstractNetworkJob> _job;
@ -34,4 +38,4 @@ private slots:
void success(); void success();
}; };
} }

View file

@ -18,6 +18,10 @@
namespace OCC { namespace OCC {
/**
* @brief The MoveJob class
* @ingroup libsync
*/
class MoveJob : public AbstractNetworkJob { class MoveJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
const QString _destination; const QString _destination;
@ -34,7 +38,10 @@ signals:
void finishedSignal(); void finishedSignal();
}; };
/**
* @brief The PropagateRemoteMove class
* @ingroup libsync
*/
class PropagateRemoteMove : public PropagateItemJob { class PropagateRemoteMove : public PropagateItemJob {
Q_OBJECT Q_OBJECT
QPointer<MoveJob> _job; QPointer<MoveJob> _job;

View file

@ -24,6 +24,10 @@
namespace OCC { namespace OCC {
class BandwidthManager; class BandwidthManager;
/**
* @brief The UploadDevice class
* @ingroup libsync
*/
class UploadDevice : public QIODevice { class UploadDevice : public QIODevice {
Q_OBJECT Q_OBJECT
public: public:
@ -74,6 +78,10 @@ protected slots:
void slotJobUploadProgress(qint64 sent, qint64 t); void slotJobUploadProgress(qint64 sent, qint64 t);
}; };
/**
* @brief The PUTFileJob class
* @ingroup libsync
*/
class PUTFileJob : public AbstractNetworkJob { class PUTFileJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -116,10 +124,11 @@ private slots:
}; };
/** /**
* This job implements the assynchronous PUT * @brief This job implements the assynchronous PUT
*
* If the server replies to a PUT with a OC-Finish-Poll url, we will query this url until the server * If the server replies to a PUT with a OC-Finish-Poll url, we will query this url until the server
* replies with an etag * replies with an etag. https://github.com/owncloud/core/issues/12097
* https://github.com/owncloud/core/issues/12097 * @ingroup libsync
*/ */
class PollJob : public AbstractNetworkJob { class PollJob : public AbstractNetworkJob {
Q_OBJECT Q_OBJECT
@ -145,7 +154,10 @@ signals:
void finishedSignal(); void finishedSignal();
}; };
/**
* @brief The PropagateUploadFileQNAM class
* @ingroup libsync
*/
class PropagateUploadFileQNAM : public PropagateItemJob { class PropagateUploadFileQNAM : public PropagateItemJob {
Q_OBJECT Q_OBJECT

View file

@ -38,8 +38,10 @@ struct ScopedPointerHelpers {
}; };
/*
* Abstract class for neon job. Lives in the neon thread /**
* @brief Abstract class for neon job. Lives in the neon thread
* @ingroup libsync
*/ */
class PropagateNeonJob : public PropagateItemJob { class PropagateNeonJob : public PropagateItemJob {
Q_OBJECT Q_OBJECT
@ -76,6 +78,10 @@ public:
JobParallelism parallelism() Q_DECL_OVERRIDE { return WaitForFinished; } JobParallelism parallelism() Q_DECL_OVERRIDE { return WaitForFinished; }
}; };
/**
* @brief The UpdateMTimeAndETagJob class
* @ingroup libsync
*/
class UpdateMTimeAndETagJob : public PropagateNeonJob { class UpdateMTimeAndETagJob : public PropagateNeonJob {
Q_OBJECT Q_OBJECT
public: public:
@ -83,6 +89,10 @@ public:
void start() Q_DECL_OVERRIDE; void start() Q_DECL_OVERRIDE;
}; };
/**
* @brief The PropagateUploadFileLegacy class
* @ingroup libsync
*/
class PropagateUploadFileLegacy: public PropagateNeonJob { class PropagateUploadFileLegacy: public PropagateNeonJob {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -35,7 +35,8 @@ static const char checkSumAdlerC[] = "Adler32";
static const char checkSumAdlerUpperC[] = "ADLER32"; static const char checkSumAdlerUpperC[] = "ADLER32";
/** /**
* Declaration of the other propagation jobs * @brief Declaration of the other propagation jobs
* @ingroup libsync
*/ */
class PropagateLocalRemove : public PropagateItemJob { class PropagateLocalRemove : public PropagateItemJob {
Q_OBJECT Q_OBJECT
@ -43,6 +44,11 @@ public:
PropagateLocalRemove (OwncloudPropagator* propagator,const SyncFileItemPtr& item) : PropagateItemJob(propagator, item) {} PropagateLocalRemove (OwncloudPropagator* propagator,const SyncFileItemPtr& item) : PropagateItemJob(propagator, item) {}
void start() Q_DECL_OVERRIDE; void start() Q_DECL_OVERRIDE;
}; };
/**
* @brief The PropagateLocalMkdir class
* @ingroup libsync
*/
class PropagateLocalMkdir : public PropagateItemJob { class PropagateLocalMkdir : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:
@ -50,6 +56,11 @@ public:
void start() Q_DECL_OVERRIDE; void start() Q_DECL_OVERRIDE;
}; };
/**
* @brief The PropagateLocalRename class
* @ingroup libsync
*/
class PropagateLocalRename : public PropagateItemJob { class PropagateLocalRename : public PropagateItemJob {
Q_OBJECT Q_OBJECT
public: public:

View file

@ -46,6 +46,10 @@ class SyncJournalFileRecord;
class SyncJournalDb; class SyncJournalDb;
class OwncloudPropagator; class OwncloudPropagator;
/**
* @brief The SyncEngine class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SyncEngine : public QObject class OWNCLOUDSYNC_EXPORT SyncEngine : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -29,8 +29,13 @@
#define BITFIELD(size) :size #define BITFIELD(size) :size
#endif #endif
namespace OCC { namespace OCC {
/**
* @brief The SyncFileItem class
* @ingroup libsync
*/
class SyncFileItem { class SyncFileItem {
public: public:
enum Direction { enum Direction {

View file

@ -20,6 +20,10 @@
namespace OCC { namespace OCC {
/**
* @brief The SyncFileStatus class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SyncFileStatus class OWNCLOUDSYNC_EXPORT SyncFileStatus
{ {
public: public:

View file

@ -27,9 +27,10 @@ class SyncJournalFileRecord;
class SyncJournalErrorBlacklistRecord; class SyncJournalErrorBlacklistRecord;
/** /**
* Class that handle the sync database * @brief Class that handle the sync database
* *
* This class is thread safe. All public function are locking the mutex. * This class is thread safe. All public function are locking the mutex.
* @ingroup libsync
*/ */
class OWNCLOUDSYNC_EXPORT SyncJournalDb : public QObject class OWNCLOUDSYNC_EXPORT SyncJournalDb : public QObject
{ {

View file

@ -23,6 +23,10 @@ namespace OCC {
class SyncFileItem; class SyncFileItem;
/**
* @brief The SyncJournalFileRecord class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SyncJournalFileRecord class OWNCLOUDSYNC_EXPORT SyncJournalFileRecord
{ {
public: public:

View file

@ -25,6 +25,10 @@
namespace OCC namespace OCC
{ {
/**
* @brief The SyncResult class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT SyncResult class OWNCLOUDSYNC_EXPORT SyncResult
{ {
public: public:

View file

@ -29,6 +29,10 @@ namespace OCC {
class SyncResult; class SyncResult;
/**
* @brief The Theme class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT Theme : public QObject class OWNCLOUDSYNC_EXPORT Theme : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -22,6 +22,10 @@
namespace OCC { namespace OCC {
/**
* @brief The TransmissionChecksumValidator class
* @ingroup libsync
*/
class OWNCLOUDSYNC_EXPORT TransmissionChecksumValidator : public QObject class OWNCLOUDSYNC_EXPORT TransmissionChecksumValidator : public QObject
{ {
Q_OBJECT Q_OBJECT

View file

@ -24,6 +24,9 @@
namespace OCC { namespace OCC {
/** \addtogroup libsync
* @{
*/
namespace Utility namespace Utility
{ {
OWNCLOUDSYNC_EXPORT void sleep(int sec); OWNCLOUDSYNC_EXPORT void sleep(int sec);
@ -111,7 +114,9 @@ namespace Utility
QDateTime timeOfLap( const QString& lapName ) const; QDateTime timeOfLap( const QString& lapName ) const;
quint64 durationOfLap( const QString& lapName ) const; quint64 durationOfLap( const QString& lapName ) const;
}; };
} }
/** @} */ // \addtogroup
} }
#endif // UTILITY_H #endif // UTILITY_H

View file

@ -1,24 +0,0 @@
#include <execinfo.h>
#include <stdlib.h>
static QString qBacktrace( int levels = -1 )
{
QString s;
void* trace[256];
int n = backtrace(trace, 256);
char** strings = backtrace_symbols (trace, n);
if ( levels != -1 )
n = qMin( n, levels );
s = QString::fromLatin1("[\n");
for (int i = 0; i < n; ++i)
s += QString::number(i) +
QString::fromLatin1(": ") +
QString::fromLatin1(strings[i]) + QString::fromLatin1("\n");
s += QString::fromLatin1("]\n");
free (strings);
return s;
}