• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • KDE-PIM Libraries
  • Sitemap
  • Contact Us
 

akonadi

monitor.h

00001 /*
00002     Copyright (c) 2006 - 2007 Volker Krause <vkrause@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_MONITOR_H
00021 #define AKONADI_MONITOR_H
00022 
00023 #include <akonadi/collection.h>
00024 
00025 #include <QtCore/QObject>
00026 
00027 namespace Akonadi {
00028 
00029 class CollectionStatistics;
00030 class Item;
00031 class ItemFetchScope;
00032 class MonitorPrivate;
00033 class Session;
00034 
00049 class AKONADI_EXPORT Monitor : public QObject
00050 {
00051   Q_OBJECT
00052 
00053   public:
00059     explicit Monitor( QObject *parent = 0 );
00060 
00064     virtual ~Monitor();
00065 
00073     void setCollectionMonitored( const Collection &collection, bool monitored = true );
00074 
00080     void setItemMonitored( const Item &item, bool monitored = true );
00081 
00087     void setResourceMonitored( const QByteArray &resource, bool monitored = true );
00088 
00094     void setMimeTypeMonitored( const QString &mimetype, bool monitored = true );
00095 
00099     void setAllMonitored( bool monitored = true );
00100 
00106     void ignoreSession( Session *session );
00107 
00113     void fetchCollection( bool enable );
00114 
00121     void fetchCollectionStatistics( bool enable );
00122 
00133     void setItemFetchScope( const ItemFetchScope &fetchScope );
00134 
00147     ItemFetchScope &itemFetchScope();
00148 
00149   Q_SIGNALS:
00156     void itemChanged( const Akonadi::Item &item, const QSet<QByteArray> &partIdentifiers );
00157 
00165     void itemMoved( const Akonadi::Item &item, const Akonadi::Collection &collectionSource,
00166                                                const Akonadi::Collection &collectionDestination );
00167 
00174     void itemAdded( const Akonadi::Item &item, const Akonadi::Collection &collection );
00175 
00184     void itemRemoved( const Akonadi::Item &item );
00185 
00193     void itemLinked( const Akonadi::Item &item, const Akonadi::Collection &collection );
00194 
00202     void itemUnlinked( const Akonadi::Item &item, const Akonadi::Collection &collection );
00203 
00210     void collectionAdded( const Akonadi::Collection &collection, const Akonadi::Collection &parent );
00211 
00218     void collectionChanged( const Akonadi::Collection &collection );
00219 
00225     void collectionRemoved( const Akonadi::Collection &collection );
00226 
00235     void collectionStatisticsChanged( Akonadi::Collection::Id id,
00236                                       const Akonadi::CollectionStatistics &statistics );
00237 
00238   protected:
00239     //@cond PRIVATE
00240     MonitorPrivate *d_ptr;
00241     explicit Monitor( MonitorPrivate *d, QObject *parent = 0 );
00242     //@endcond
00243 
00244   private:
00245     Q_DECLARE_PRIVATE( Monitor )
00246 
00247     //@cond PRIVATE
00248     Q_PRIVATE_SLOT( d_ptr, void slotStatisticsChangedFinished( KJob* ) )
00249     Q_PRIVATE_SLOT( d_ptr, void slotFlushRecentlyChangedCollections() )
00250     Q_PRIVATE_SLOT( d_ptr, void slotNotify( const Akonadi::NotificationMessage::List& ) )
00251     Q_PRIVATE_SLOT( d_ptr, void slotItemJobFinished( KJob* ) )
00252     Q_PRIVATE_SLOT( d_ptr, void slotCollectionJobFinished( KJob* ) )
00253     //@endcond
00254 };
00255 
00256 }
00257 
00258 #endif

akonadi

Skip menu "akonadi"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

KDE-PIM Libraries

Skip menu "KDE-PIM Libraries"
  • akonadi
  • kabc
  • kblog
  • kcal
  • kimap
  • kioslave
  •   imap4
  •   mbox
  • kldap
  • kmime
  • kpimidentities
  •   richtextbuilders
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Generated for KDE-PIM Libraries by doxygen 1.5.7
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal