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

kaddressbook

  • sources
  • kde-4.14
  • kdepim
  • kaddressbook
  • merge
  • job
mergecontacts.h
Go to the documentation of this file.
1 /*
2  Copyright (c) 2014-2015 Montel Laurent <montel@kde.org>
3 
4  This program is free software; you can redistribute it and/or modify it
5  under the terms of the GNU General Public License, version 2, as
6  published by the Free Software Foundation.
7 
8  This program is distributed in the hope that it will be useful, but
9  WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11  General Public License for more details.
12 
13  You should have received a copy of the GNU General Public License along
14  with this program; if not, write to the Free Software Foundation, Inc.,
15  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16 */
17 
18 #ifndef MERGECONTACTS_H
19 #define MERGECONTACTS_H
20 
21 #include <Akonadi/Item>
22 #include <KABC/Addressee>
23 
24 
25 namespace KABMergeContacts {
26 class MergeContacts
27 {
28 public:
29  MergeContacts(const Akonadi::Item::List &items = Akonadi::Item::List());
30  ~MergeContacts();
31 
32  enum ConflictInformation {
33  None = 0,
34  Birthday = 1,
35  Geo = 2,
36  Photo = 4,
37  Logo = 8,
38  Anniversary = 16,
39  Name = 32,
40  NickName = 64,
41  Blog = 128,
42  HomePage = 256,
43  Organization = 512,
44  Profession = 1024,
45  Title = 2056,
46  Departement = 4096,
47  Office = 8192,
48  ManagerName = 16384,
49  Assistant = 32768,
50  FreeBusy = 65536,
51  FamilyName = 131072,
52  PartnerName = 262144,
53  Keys = 524288
54  };
55  Q_ENUMS(ConflictInformation)
56  Q_DECLARE_FLAGS(ConflictInformations, ConflictInformation)
57 
58  KABC::Addressee mergedContact(bool excludeConflictPart = false);
59 
60  MergeContacts::ConflictInformations requiresManualSelectionOfInformation();
61 
62  void setItems(const Akonadi::Item::List &items);
63 private:
64  void mergeCustomValue(const KABC::Addressee &fromContact, const QString &variable, KABC::Addressee &newContact);
65  void checkCustomValue(const KABC::Addressee &address, const QString &variable, KABC::Addressee &newContact, MergeContacts::ConflictInformations &result, MergeContacts::ConflictInformation conflict);
66  void mergeToContact(KABC::Addressee &newAddress, const KABC::Addressee &fromContact, bool excludeConflictPart);
67  Akonadi::Item::List mListItem;
68 };
69 }
70 
71 #endif // MERGECONTACTS_H
KABMergeContacts::MergeContacts::FreeBusy
Definition: mergecontacts.h:50
KABMergeContacts::MergeContacts::setItems
void setItems(const Akonadi::Item::List &items)
Definition: mergecontacts.cpp:32
KABMergeContacts::MergeContacts::Departement
Definition: mergecontacts.h:46
KABMergeContacts::MergeContacts::Profession
Definition: mergecontacts.h:44
KABMergeContacts::MergeContacts::Blog
Definition: mergecontacts.h:41
KABMergeContacts::MergeContacts::None
Definition: mergecontacts.h:33
KABMergeContacts::MergeContacts
Definition: mergecontacts.h:26
KABMergeContacts::MergeContacts::Anniversary
Definition: mergecontacts.h:38
KABMergeContacts::MergeContacts::Organization
Definition: mergecontacts.h:43
KABMergeContacts::MergeContacts::Photo
Definition: mergecontacts.h:36
KABMergeContacts::MergeContacts::Keys
Definition: mergecontacts.h:53
KABMergeContacts::MergeContacts::mergedContact
KABC::Addressee mergedContact(bool excludeConflictPart=false)
Definition: mergecontacts.cpp:37
KABMergeContacts::MergeContacts::ManagerName
Definition: mergecontacts.h:48
KABMergeContacts::MergeContacts::HomePage
Definition: mergecontacts.h:42
KABMergeContacts::MergeContacts::Logo
Definition: mergecontacts.h:37
KABMergeContacts::MergeContacts::FamilyName
Definition: mergecontacts.h:51
QString
KABMergeContacts::MergeContacts::Office
Definition: mergecontacts.h:47
KABMergeContacts::MergeContacts::Name
Definition: mergecontacts.h:39
KABMergeContacts::MergeContacts::NickName
Definition: mergecontacts.h:40
KABMergeContacts::MergeContacts::MergeContacts
MergeContacts(const Akonadi::Item::List &items=Akonadi::Item::List())
Definition: mergecontacts.cpp:22
KABMergeContacts::MergeContacts::ConflictInformation
ConflictInformation
Definition: mergecontacts.h:32
KABMergeContacts::MergeContacts::Title
Definition: mergecontacts.h:45
KABMergeContacts::MergeContacts::PartnerName
Definition: mergecontacts.h:52
KABMergeContacts::MergeContacts::requiresManualSelectionOfInformation
MergeContacts::ConflictInformations requiresManualSelectionOfInformation()
Definition: mergecontacts.cpp:186
KABMergeContacts::MergeContacts::~MergeContacts
~MergeContacts()
Definition: mergecontacts.cpp:27
KABMergeContacts::MergeContacts::Assistant
Definition: mergecontacts.h:49
KABMergeContacts::MergeContacts::Geo
Definition: mergecontacts.h:35
KABMergeContacts::MergeContacts::Birthday
Definition: mergecontacts.h:34
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:32:34 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kaddressbook

Skip menu "kaddressbook"
  • 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
  • pimprint

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