19 #ifndef LIB_QUENTIER_TYPES_I_NOTE_STORE_DATA_ELEMENT_H 20 #define LIB_QUENTIER_TYPES_I_NOTE_STORE_DATA_ELEMENT_H 22 #include "ILocalStorageDataElement.h" 24 #include <quentier/types/ErrorString.h> 25 #include <quentier/utility/Printable.h> 37 virtual void clear() = 0;
39 virtual bool hasGuid()
const = 0;
40 virtual const QString & guid()
const = 0;
41 virtual void setGuid(
const QString & guid) = 0;
43 virtual bool hasUpdateSequenceNumber()
const = 0;
44 virtual qint32 updateSequenceNumber()
const = 0;
45 virtual void setUpdateSequenceNumber(
const qint32 usn) = 0;
47 virtual bool checkParameters(
ErrorString & errorDescription)
const = 0;
49 virtual bool isDirty()
const = 0;
50 virtual void setDirty(
const bool dirty) = 0;
52 virtual bool isLocal()
const = 0;
53 virtual void setLocal(
const bool local) = 0;
58 #define DECLARE_IS_DIRTY \ 59 virtual bool isDirty() const override; \ 62 #define DECLARE_SET_DIRTY \ 63 virtual void setDirty(const bool isDirty) override; \ 66 #define QN_DECLARE_DIRTY \ 71 #define DEFINE_IS_DIRTY(type) \ 72 bool type::isDirty() const \ 74 return d->m_isDirty; \ 78 #define DEFINE_SET_DIRTY(type) \ 79 void type::setDirty(const bool dirty) \ 81 d->m_isDirty = dirty; \ 85 #define QN_DEFINE_DIRTY(type) \ 86 DEFINE_IS_DIRTY(type) \ 87 DEFINE_SET_DIRTY(type) \ 90 #define DECLARE_IS_LOCAL \ 91 virtual bool isLocal() const override; \ 94 #define DECLARE_SET_LOCAL \ 95 virtual void setLocal(const bool isLocal) override; \ 98 #define QN_DECLARE_LOCAL \ 103 #define DEFINE_IS_LOCAL(type) \ 104 bool type::isLocal() const \ 106 return d->m_isLocal; \ 110 #define DEFINE_SET_LOCAL(type) \ 111 void type::setLocal(const bool local) \ 113 d->m_isLocal = local; \ 117 #define QN_DEFINE_LOCAL(type) \ 118 DEFINE_IS_LOCAL(type) \ 119 DEFINE_SET_LOCAL(type) \ 124 #endif // LIB_QUENTIER_TYPES_I_NOTE_STORE_DATA_ELEMENT_H Definition: INoteStoreDataElement.h:32
The ErrorString class encapsulates two (or more) strings which are meant to contain translatable (bas...
Definition: ErrorString.h:43
Definition: DecryptedTextManager.h:26
The Printable class is the interface for Quentier's internal classes which should be able to write th...
Definition: Printable.h:37
Definition: ILocalStorageDataElement.h:30