• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.14.10 API Reference
  • KDE Home
  • Contact Us
 

akonadi

  • akonadi
  • contact
contactstreemodel.h
1/*
2 This file is part of Akonadi Contact.
3
4 Copyright (c) 2009 Stephen Kelly <steveire@gmail.com>
5 Copyright (c) 2009 Tobias Koenig <tokoe@kde.org>
6
7 This library is free software; you can redistribute it and/or modify it
8 under the terms of the GNU Library General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or (at your
10 option) any later version.
11
12 This library is distributed in the hope that it will be useful, but WITHOUT
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
15 License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with this library; see the file COPYING.LIB. If not, write to the
19 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20 02110-1301, USA.
21*/
22
23#ifndef AKONADI_CONTACTSTREEMODEL_H
24#define AKONADI_CONTACTSTREEMODEL_H
25
26#include "akonadi-contact_export.h"
27
28#include <akonadi/entitytreemodel.h>
29
30namespace Akonadi {
31
78class AKONADI_CONTACT_EXPORT ContactsTreeModel : public EntityTreeModel
79{
80 Q_OBJECT
81
82 public:
86 enum Column {
90 FullName,
91
95 FamilyName,
96
100 GivenName,
101
105 Birthday,
106
110 HomeAddress,
111
115 BusinessAddress,
116
120 PhoneNumbers,
121
125 PreferredEmail,
126
130 AllEmails,
131
135 Organization,
136
140 Role,
141
145 Homepage,
146
150 Note
151 };
152
156 typedef QList<Column> Columns;
157
161 enum Roles {
162 DateRole = EntityTreeModel::UserRole + 1,
163 UserRole = DateRole + 42
164 };
165
172 explicit ContactsTreeModel( ChangeRecorder *monitor, QObject *parent = 0 );
173
177 virtual ~ContactsTreeModel();
178
182 void setColumns( const Columns &columns );
183
187 Columns columns() const;
188
189 //@cond PRIVATE
190 virtual QVariant entityData( const Item &item, int column, int role = Qt::DisplayRole ) const;
191 virtual QVariant entityData( const Collection &collection, int column, int role = Qt::DisplayRole ) const;
192 virtual QVariant entityHeaderData( int section, Qt::Orientation orientation, int role, HeaderGroup headerGroup ) const;
193 virtual int entityColumnCount( HeaderGroup headerGroup ) const;
194 //@endcond
195
196 private:
197 //@cond PRIVATE
198 class Private;
199 Private* const d;
200 //@endcond
201};
202
203}
204
205#endif
Akonadi::ChangeRecorder
Records and replays change notification.
Definition changerecorder.h:48
Akonadi::Collection
Represents a collection of PIM items.
Definition collection.h:76
Akonadi::ContactsTreeModel
A model for contacts and contact groups as available in Akonadi.
Definition contactstreemodel.h:79
Akonadi::ContactsTreeModel::Columns
QList< Column > Columns
Describes a list of columns of the contacts tree model.
Definition contactstreemodel.h:156
Akonadi::ContactsTreeModel::Column
Column
Describes the columns that can be shown by the model.
Definition contactstreemodel.h:86
Akonadi::ContactsTreeModel::PreferredEmail
@ PreferredEmail
Shows the preferred email address.
Definition contactstreemodel.h:125
Akonadi::ContactsTreeModel::GivenName
@ GivenName
Shows the given name.
Definition contactstreemodel.h:100
Akonadi::ContactsTreeModel::Homepage
@ Homepage
Shows homepage url.
Definition contactstreemodel.h:145
Akonadi::ContactsTreeModel::HomeAddress
@ HomeAddress
Shows the formatted home address.
Definition contactstreemodel.h:110
Akonadi::ContactsTreeModel::Role
@ Role
Shows the role of a contact.
Definition contactstreemodel.h:140
Akonadi::ContactsTreeModel::BusinessAddress
@ BusinessAddress
Shows the formatted business address.
Definition contactstreemodel.h:115
Akonadi::ContactsTreeModel::Birthday
@ Birthday
Shows the birthday.
Definition contactstreemodel.h:105
Akonadi::ContactsTreeModel::FamilyName
@ FamilyName
Shows the family name.
Definition contactstreemodel.h:95
Akonadi::ContactsTreeModel::AllEmails
@ AllEmails
Shows all email address.
Definition contactstreemodel.h:130
Akonadi::ContactsTreeModel::PhoneNumbers
@ PhoneNumbers
Shows the phone numbers.
Definition contactstreemodel.h:120
Akonadi::ContactsTreeModel::FullName
@ FullName
Shows the formatted name or, if empty, the assembled name.
Definition contactstreemodel.h:90
Akonadi::ContactsTreeModel::Organization
@ Organization
Shows organization name.
Definition contactstreemodel.h:135
Akonadi::ContactsTreeModel::Roles
Roles
Describes the role for contacts and contact groups.
Definition contactstreemodel.h:161
Akonadi::EntityTreeModel
A model for collections and items together.
Definition entitytreemodel.h:319
Akonadi
FreeBusyManager::Singleton.
Definition actionstatemanager_p.h:28
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Wed Jan 24 2024 00:00:00 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

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

kdepimlibs-4.14.10 API Reference

Skip menu "kdepimlibs-4.14.10 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
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