OpenAB  1.0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
PIMCalendarItemIndex.hpp
Go to the documentation of this file.
1 /*
2  * This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this
4  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
5  */
10 #ifndef PIMCALENDARITEMINDEX_HPP_
11 #define PIMCALENDARITEMINDEX_HPP_
12 
13 #include "PIMItem/PIMItemIndex.hpp"
17 namespace OpenAB {
18 
26 {
27  public:
32 
36  virtual ~PIMCalendarItemIndex();
37 
38  std::string toString() const;
39  std::string toStringFull() const;
40 
48  static bool addCheck(const std::string& fieldName,
50 
56  static bool removeCheck(const std::string& fieldName);
57 
61  static void clearAllChecks();
62 
67  static std::vector<PIMItemCheck> getAllChecks();
68 
69 
78  bool operator==(const PIMItemIndex& other) const;
79 
88  bool operator!=(const PIMItemIndex& other) const;
89 
98  bool operator<(const PIMItemIndex& other) const;
99 
100 
101  bool compare(const PIMItemIndex& other) const;
102  private:
107 
111  PIMCalendarItemIndex& operator=(PIMCalendarItemIndex const &other);
112 
113  protected:
114  static std::vector<PIMItemCheck> fields_desc;
115 
116  virtual bool equal(const PIMItemIndex& other) const;
117  virtual bool notEqual(const PIMItemIndex& other) const;
118  virtual bool lessThan(const PIMItemIndex& other) const;
119  virtual bool compareWith(const PIMItemIndex& other) const;
120 };
121 
122 
124 {
125  public:
130 
134  virtual ~PIMCalendarEventItemIndex();
135 };
136 
138 {
139  public:
144 
148  virtual ~PIMCalendarTaskItemIndex();
149 };
150 
151 } // namespace OpenAB
152 
153 #endif // PIMCALENDARITEMINDEX_HPP_
std::string toString() const
Returns string version of PIMItemIndex. It contains only PIMItemCheck::eKey fields.
Definition: PIMCalendarItemIndex.cpp:66
eFieldRole
Definition: PIMItemIndex.hpp:60
virtual bool equal(const PIMItemIndex &other) const
Definition: PIMCalendarItemIndex.cpp:150
virtual ~PIMCalendarItemIndex()
Destructor, virtual by default.
Definition: PIMCalendarItemIndex.cpp:22
static std::vector< PIMItemCheck > fields_desc
Definition: PIMCalendarItemIndex.hpp:114
bool operator==(const PIMItemIndex &other) const
Compare operator. Checks if two PIMItemIndex matches (may not be exactly the same) ...
Definition: PIMCalendarItemIndex.cpp:37
Definition: PIMCalendarItemIndex.hpp:137
Documentation for class PIMCalendarItemIndex. It implements PIMItemIndex for OpenAB::eEvent or OpenAB...
Definition: PIMCalendarItemIndex.hpp:25
std::string toStringFull() const
Returns string version of PIMItemIndex. It contains both PIMItemCheck::eKey and PIMItemCheck::eConfli...
Definition: PIMCalendarItemIndex.cpp:81
Definition: PIMCalendarItemIndex.hpp:123
static bool addCheck(const std::string &fieldName, PIMItemCheck::eFieldRole role)
Defines new PIMItemCheck for PIMCalendarItemIndex objects.
Definition: PIMCalendarItemIndex.cpp:105
PIMCalendarEventItemIndex()
Constructor.
Definition: PIMCalendarItemIndex.cpp:170
static bool removeCheck(const std::string &fieldName)
Removes check for PIMCalendarItemIndex objects.
Definition: PIMCalendarItemIndex.cpp:122
PIMCalendarItemIndex(PIMItemType t)
Constructor.
Definition: PIMCalendarItemIndex.cpp:17
static void clearAllChecks()
Removes all defined PIMItemCheck for PIMCalendarItemIndex.
Definition: PIMCalendarItemIndex.cpp:95
virtual bool notEqual(const PIMItemIndex &other) const
Definition: PIMCalendarItemIndex.cpp:157
bool compare(const PIMItemIndex &other) const
Compares two PIMItemIndex object, checks if two PIMItemIndex are exactly the same. In opposite to compare operator it checks PIMItemCheck::eConflict fields.
Definition: PIMCalendarItemIndex.cpp:27
PIMCalendarTaskItemIndex()
Constructor.
Definition: PIMCalendarItemIndex.cpp:181
PIMItemType
Definition: PIMItemIndex.hpp:24
bool operator!=(const PIMItemIndex &other) const
Compare operator. Checks if two PIMItemIndex not matches (are totally different)
Definition: PIMCalendarItemIndex.cpp:46
virtual ~PIMCalendarEventItemIndex()
Destructor, virtual by default.
Definition: PIMCalendarItemIndex.cpp:176
virtual bool lessThan(const PIMItemIndex &other) const
Definition: PIMCalendarItemIndex.cpp:165
virtual bool compareWith(const PIMItemIndex &other) const
Definition: PIMCalendarItemIndex.cpp:137
bool operator<(const PIMItemIndex &other) const
Compare operator.
Definition: PIMCalendarItemIndex.cpp:55
virtual ~PIMCalendarTaskItemIndex()
Destructor, virtual by default.
Definition: PIMCalendarItemIndex.cpp:187
static std::vector< PIMItemCheck > getAllChecks()
Returns all defined PIMItemCheck for PIMCalendarItemIndex objects.
Definition: PIMCalendarItemIndex.cpp:100
Documentation for class PIMItemIndex. PIMItemIndex is a PIMItem representation used to match and comp...
Definition: PIMItemIndex.hpp:37