• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

messagelist

  • sources
  • kde-4.12
  • kdepim
  • messagelist
  • core
storagemodelbase.h
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  * Copyright 2008 Szymon Tomasz Stefanek <pragma@kvirc.net>
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18  *
19  *******************************************************************************/
20 
21 #ifndef __MESSAGELIST_CORE_STORAGEMODELBASE_H__
22 #define __MESSAGELIST_CORE_STORAGEMODELBASE_H__
23 
24 #include <QAbstractItemModel>
25 
26 #include <messagelist/messagelist_export.h>
27 
28 namespace Akonadi
29 {
30  class MessageStatus;
31 }
32 
33 namespace MessageList
34 {
35 
36 namespace Core
37 {
38 
39 class MessageItem;
40 
45 class MESSAGELIST_EXPORT StorageModel : public QAbstractItemModel
46 {
47  Q_OBJECT
48 
49 public:
50  explicit StorageModel( QObject * parent = 0 );
51  ~StorageModel();
52 
57  virtual QString id() const = 0;
58 
63  unsigned long preSelectedMessage() const;
64 
69  void savePreSelectedMessage( unsigned long uniqueIdOfMessage );
70 
74  virtual bool containsOutboundMessages() const = 0;
75 
82  virtual int initialUnreadRowCountGuess() const;
83 
93  virtual bool initializeMessageItem( MessageItem * it, int row, bool bUseReceiver ) const = 0;
94 
95  enum ThreadingDataSubset
96  {
97  PerfectThreadingOnly,
98  PerfectThreadingPlusReferences,
99  PerfectThreadingReferencesAndSubject
100  };
101 
107  virtual void fillMessageItemThreadingData( MessageItem * mi, int row, ThreadingDataSubset subset ) const = 0;
108 
114  virtual void updateMessageItemData( MessageItem * mi, int row ) const = 0;
115 
121  virtual void setMessageItemStatus( MessageItem * mi, int row, const Akonadi::MessageStatus &status ) = 0;
122 
126  virtual void prepareForScan() = 0;
127 
132  virtual QMimeData* mimeData( const QList< MessageItem* >& ) const = 0;
133  using QAbstractItemModel::mimeData;
134 };
135 
136 } // namespace Core
137 
138 } // namespace MessageList
139 
140 #endif
messagelist_export.h
MessageList::Core::MessageItem
Definition: messageitem.h:50
QObject
MessageList::Core::StorageModel::ThreadingDataSubset
ThreadingDataSubset
Definition: storagemodelbase.h:95
MessageList::Core::StorageModel::PerfectThreadingPlusReferences
messageIdMD5, inReplyToMD5, referencesIdMD5
Definition: storagemodelbase.h:98
QAbstractItemModel
MESSAGELIST_EXPORT
#define MESSAGELIST_EXPORT
Definition: messagelist_export.h:34
MessageList::Core::StorageModel
The QAbstractItemModel based interface that you need to provide for your storage to work with Message...
Definition: storagemodelbase.h:45
MessageList::Core::StorageModel::PerfectThreadingOnly
Only the data for messageIdMD5 and inReplyToMD5 is needed.
Definition: storagemodelbase.h:97
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:32 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

messagelist

Skip menu "messagelist"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal