19#ifndef LIB_QUENTIER_TYPES_NOTEBOOK_H
20#define LIB_QUENTIER_TYPES_NOTEBOOK_H
22#include "IFavoritableDataElement.h"
24#include <qt5qevercloud/QEverCloud.h>
26#include <QSharedDataPointer>
30QT_FORWARD_DECLARE_CLASS(SharedNotebook)
31QT_FORWARD_DECLARE_CLASS(User)
32QT_FORWARD_DECLARE_CLASS(NotebookData)
49 explicit Notebook(
const qevercloud::Notebook & other);
50 explicit Notebook(qevercloud::Notebook && other);
51 Notebook & operator=(
const qevercloud::Notebook & other);
52 Notebook & operator=(qevercloud::Notebook && other);
56 bool operator==(
const Notebook & other)
const;
57 bool operator!=(
const Notebook & other)
const;
59 const qevercloud::Notebook & qevercloudNotebook()
const;
60 qevercloud::Notebook & qevercloudNotebook();
62 virtual void clear()
override;
64 static bool validateName(
65 const QString & name,
ErrorString * pErrorDescription =
nullptr);
67 virtual bool hasGuid()
const override;
68 virtual const QString & guid()
const override;
69 virtual void setGuid(
const QString & guid)
override;
71 virtual bool hasUpdateSequenceNumber()
const override;
72 virtual qint32 updateSequenceNumber()
const override;
73 virtual void setUpdateSequenceNumber(
const qint32 usn)
override;
75 virtual bool checkParameters(
ErrorString & errorDescription)
const override;
78 const QString & name()
const;
79 void setName(
const QString & name);
81 bool isDefaultNotebook()
const;
82 void setDefaultNotebook(
const bool defaultNotebook);
84 bool hasLinkedNotebookGuid()
const;
85 const QString & linkedNotebookGuid()
const;
86 void setLinkedNotebookGuid(
const QString & linkedNotebookGuid);
88 bool hasCreationTimestamp()
const;
89 qint64 creationTimestamp()
const;
90 void setCreationTimestamp(
const qint64 timestamp);
92 bool hasModificationTimestamp()
const;
93 qint64 modificationTimestamp()
const;
94 void setModificationTimestamp(
const qint64 timestamp);
96 bool hasPublishingUri()
const;
97 const QString & publishingUri()
const;
98 void setPublishingUri(
const QString & uri);
100 bool hasPublishingOrder()
const;
101 qint8 publishingOrder()
const;
102 void setPublishingOrder(
const qint8 order);
104 bool hasPublishingAscending()
const;
105 bool isPublishingAscending()
const;
106 void setPublishingAscending(
const bool ascending);
108 bool hasPublishingPublicDescription()
const;
109 const QString & publishingPublicDescription()
const;
110 void setPublishingPublicDescription(
111 const QString & publishingPublicDescription);
113 bool hasPublished()
const;
114 bool isPublished()
const;
115 void setPublished(
const bool published);
117 bool hasStack()
const;
118 const QString & stack()
const;
119 void setStack(
const QString & stack);
121 bool hasSharedNotebooks();
122 QList<SharedNotebook> sharedNotebooks()
const;
123 void setSharedNotebooks(QList<qevercloud::SharedNotebook> sharedNotebooks);
124 void setSharedNotebooks(QList<SharedNotebook> && notebooks);
128 bool hasBusinessNotebookDescription()
const;
129 const QString & businessNotebookDescription()
const;
131 void setBusinessNotebookDescription(
132 const QString & businessNotebookDescription);
134 bool hasBusinessNotebookPrivilegeLevel()
const;
135 qint8 businessNotebookPrivilegeLevel()
const;
136 void setBusinessNotebookPrivilegeLevel(
const qint8 privilegeLevel);
138 bool hasBusinessNotebookRecommended()
const;
139 bool isBusinessNotebookRecommended()
const;
140 void setBusinessNotebookRecommended(
const bool recommended);
142 bool hasContact()
const;
143 const User contact()
const;
144 void setContact(
const User & contact);
146 bool isLastUsed()
const;
147 void setLastUsed(
const bool lastUsed);
149 bool canReadNotes()
const;
150 void setCanReadNotes(
const bool canReadNotes);
152 bool canCreateNotes()
const;
153 void setCanCreateNotes(
const bool canCreateNotes);
155 bool canUpdateNotes()
const;
156 void setCanUpdateNotes(
const bool canUpdateNotes);
158 bool canExpungeNotes()
const;
159 void setCanExpungeNotes(
const bool canExpungeNotes);
161 bool canShareNotes()
const;
162 void setCanShareNotes(
const bool canShareNotes);
164 bool canEmailNotes()
const;
165 void setCanEmailNotes(
const bool canEmailNotes);
167 bool canSendMessageToRecipients()
const;
168 void setCanSendMessageToRecipients(
const bool canSendMessageToRecipients);
170 bool canUpdateNotebook()
const;
171 void setCanUpdateNotebook(
const bool canUpdateNotebook);
173 bool canExpungeNotebook()
const;
174 void setCanExpungeNotebook(
const bool canExpungeNotebook);
176 bool canSetDefaultNotebook()
const;
177 void setCanSetDefaultNotebook(
const bool canSetDefaultNotebook);
179 bool canSetNotebookStack()
const;
180 void setCanSetNotebookStack(
const bool canSetNotebookStack);
182 bool canPublishToPublic()
const;
183 void setCanPublishToPublic(
const bool canPublishToPublic);
185 bool canPublishToBusinessLibrary()
const;
186 void setCanPublishToBusinessLibrary(
const bool canPublishToBusinessLibrary);
188 bool canCreateTags()
const;
189 void setCanCreateTags(
const bool canCreateTags);
191 bool canUpdateTags()
const;
192 void setCanUpdateTags(
const bool canUpdateTags);
194 bool canExpungeTags()
const;
195 void setCanExpungeTags(
const bool canExpungeTags);
197 bool canSetParentTag()
const;
198 void setCanSetParentTag(
const bool canSetParentTag);
200 bool canCreateSharedNotebooks()
const;
201 void setCanCreateSharedNotebooks(
const bool canCreateSharedNotebooks);
203 bool canShareNotesWithBusiness()
const;
204 void setCanShareNotesWithBusiness(
const bool canShareNotesWithBusiness);
206 bool canRenameNotebook()
const;
207 void setCanRenameNotebook(
const bool canRenameNotebook);
209 bool hasUpdateWhichSharedNotebookRestrictions()
const;
210 qint8 updateWhichSharedNotebookRestrictions()
const;
211 void setUpdateWhichSharedNotebookRestrictions(
const qint8 which);
213 bool hasExpungeWhichSharedNotebookRestrictions()
const;
214 qint8 expungeWhichSharedNotebookRestrictions()
const;
215 void setExpungeWhichSharedNotebookRestrictions(
const qint8 which);
217 bool hasRestrictions()
const;
218 const qevercloud::NotebookRestrictions & restrictions()
const;
220 void setNotebookRestrictions(
221 qevercloud::NotebookRestrictions && restrictions);
223 bool hasRecipientReminderNotifyEmail()
const;
224 bool recipientReminderNotifyEmail()
const;
225 void setRecipientReminderNotifyEmail(
const bool notifyEmail);
227 bool hasRecipientReminderNotifyInApp()
const;
228 bool recipientReminderNotifyInApp()
const;
229 void setRecipientReminderNotifyInApp(
const bool notifyInApp);
231 bool hasRecipientInMyList()
const;
232 bool recipientInMyList()
const;
233 void setRecipientInMyList(
const bool inMyList);
235 bool hasRecipientStack()
const;
236 const QString & recipientStack()
const;
237 void setRecipientStack(
const QString & recipientString);
239 bool hasRecipientSettings()
const;
240 const qevercloud::NotebookRecipientSettings & recipientSettings()
const;
241 void setNotebookRecipientSettings(
242 qevercloud::NotebookRecipientSettings && settings);
244 virtual QTextStream & print(QTextStream & strm)
const override;
247 QSharedDataPointer<NotebookData> d;
The ErrorString class encapsulates two (or more) strings which are meant to contain translatable (bas...
Definition ErrorString.h:44
Definition IFavoritableDataElement.h:33
Definition SharedNotebook.h:33