akonadi
agentmanager.h
00001 /* 00002 Copyright (c) 2006-2008 Tobias Koenig <tokoe@kde.org> 00003 00004 This library is free software; you can redistribute it and/or modify it 00005 under the terms of the GNU Library General Public License as published by 00006 the Free Software Foundation; either version 2 of the License, or (at your 00007 option) any later version. 00008 00009 This library is distributed in the hope that it will be useful, but WITHOUT 00010 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00011 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public 00012 License for more details. 00013 00014 You should have received a copy of the GNU Library General Public License 00015 along with this library; see the file COPYING.LIB. If not, write to the 00016 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 00017 02110-1301, USA. 00018 */ 00019 00020 #ifndef AKONADI_AGENTMANAGER_H 00021 #define AKONADI_AGENTMANAGER_H 00022 00023 #include "akonadi_export.h" 00024 00025 #include <akonadi/agenttype.h> 00026 #include <akonadi/agentinstance.h> 00027 00028 #include <QtCore/QObject> 00029 00030 namespace Akonadi { 00031 00032 class AgentManagerPrivate; 00033 class Collection; 00034 00055 class AKONADI_EXPORT AgentManager : public QObject 00056 { 00057 friend class AgentInstance; 00058 friend class AgentInstanceCreateJobPrivate; 00059 friend class AgentManagerPrivate; 00060 00061 Q_OBJECT 00062 00063 public: 00067 static AgentManager *self(); 00068 00072 ~AgentManager(); 00073 00077 AgentType::List types() const; 00078 00083 AgentType type( const QString &identifier ) const; 00084 00088 AgentInstance::List instances() const; 00089 00094 AgentInstance instance( const QString &identifier ) const; 00095 00099 void removeInstance( const AgentInstance &instance ); 00100 00106 void synchronizeCollection( const Collection &collection ); 00107 00116 void synchronizeCollection( const Collection &collection, bool recursive ); 00117 00118 Q_SIGNALS: 00124 void typeAdded( const Akonadi::AgentType &type ); 00125 00131 void typeRemoved( const Akonadi::AgentType &type ); 00132 00138 void instanceAdded( const Akonadi::AgentInstance &instance ); 00139 00145 void instanceRemoved( const Akonadi::AgentInstance &instance ); 00146 00153 void instanceStatusChanged( const Akonadi::AgentInstance &instance ); 00154 00161 void instanceProgressChanged( const Akonadi::AgentInstance &instance ); 00162 00168 void instanceNameChanged( const Akonadi::AgentInstance &instance ); 00169 00176 void instanceError( const Akonadi::AgentInstance &instance, const QString &message ); 00177 00184 void instanceWarning( const Akonadi::AgentInstance &instance, const QString &message ); 00185 00193 void instanceOnline( const Akonadi::AgentInstance &instance, bool online ); 00194 00195 private: 00196 //@cond PRIVATE 00197 AgentManager(); 00198 00199 AgentManagerPrivate* const d; 00200 00201 Q_PRIVATE_SLOT( d, void agentTypeAdded( const QString& ) ) 00202 Q_PRIVATE_SLOT( d, void agentTypeRemoved( const QString& ) ) 00203 Q_PRIVATE_SLOT( d, void agentInstanceAdded( const QString& ) ) 00204 Q_PRIVATE_SLOT( d, void agentInstanceRemoved( const QString& ) ) 00205 Q_PRIVATE_SLOT( d, void agentInstanceStatusChanged( const QString&, int, const QString& ) ) 00206 Q_PRIVATE_SLOT( d, void agentInstanceProgressChanged( const QString&, uint, const QString& ) ) 00207 Q_PRIVATE_SLOT( d, void agentInstanceNameChanged( const QString&, const QString& ) ) 00208 Q_PRIVATE_SLOT( d, void agentInstanceWarning( const QString&, const QString& ) ) 00209 Q_PRIVATE_SLOT( d, void agentInstanceError( const QString&, const QString& ) ) 00210 Q_PRIVATE_SLOT( d, void agentInstanceOnlineChanged( const QString&, bool ) ) 00211 Q_PRIVATE_SLOT( d, void serviceOwnerChanged( const QString&, const QString&, const QString& ) ) 00212 //@endcond 00213 }; 00214 00215 } 00216 00217 #endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu Aug 2 2012 15:25:17 by doxygen 1.7.5 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2012 The KDE developers.
Generated on Thu Aug 2 2012 15:25:17 by doxygen 1.7.5 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.