QEverCloud  6.1.0
Unofficial Evernote Cloud API for Qt
Public Member Functions | Public Attributes | List of all members
qevercloud::NoteRestrictions Struct Reference

#include <Types.h>

Inheritance diagram for qevercloud::NoteRestrictions:
qevercloud::Printable

Public Member Functions

virtual void print (QTextStream &strm) const override
 
bool operator== (const NoteRestrictions &other) const
 
bool operator!= (const NoteRestrictions &other) const
 
- Public Member Functions inherited from qevercloud::Printable
 Printable ()=default
 
virtual ~Printable ()=default
 
virtual QString toString () const
 

Public Attributes

EverCloudLocalData localData
 
Optional< bool > noUpdateTitle
 
Optional< bool > noUpdateContent
 
Optional< bool > noEmail
 
Optional< bool > noShare
 
Optional< bool > noSharePublicly
 

Detailed Description

This structure captures information about the operations that cannot be performed on a given note that has been shared with a recipient via a SharedNote. The following operations are never allowed based on SharedNotes, and as such are left out of the NoteRestrictions structure for brevity:

When a client has permission to update a note's title or content, it may also update the Note.updated timestamp.

This structure reflects only the privileges / restrictions conveyed by the SharedNote. It does not incorporate privileges conveyed by a potential SharedNotebook to the same recipient. As such, the actual permissions that the recipient has on the note may differ from the permissions expressed in this structure.

For example, consider a user with read-only access to a shared notebook, and a read-write share of a specific note in the notebook. The note restrictions would contain noUpdateTitle = false, while the notebook restrictions would contain noUpdateNotes = true. In this case, the user is allowed to update the note title based on the note restrictions.

Alternatively, consider a user with read-write access to a shared notebook, and a read-only share of a specific note in that notebook. The note restrictions would contain noUpdateTitle = true, while the notebook restrictions would contain noUpdateNotes = false. In this case, the user would have full edit permissions on the note based on the notebook restrictions.

Member Function Documentation

◆ operator!=()

bool qevercloud::NoteRestrictions::operator!= ( const NoteRestrictions other) const
inline

◆ operator==()

bool qevercloud::NoteRestrictions::operator== ( const NoteRestrictions other) const
inline

◆ print()

virtual void qevercloud::NoteRestrictions::print ( QTextStream &  strm) const
overridevirtual

Implements qevercloud::Printable.

Member Data Documentation

◆ localData

EverCloudLocalData qevercloud::NoteRestrictions::localData

See the declaration of EverCloudLocalData for details

◆ noEmail

Optional< bool > qevercloud::NoteRestrictions::noEmail

The client may not email the note (NoteStore.emailNote).

◆ noShare

Optional< bool > qevercloud::NoteRestrictions::noShare

The client may not share the note with specific recipients (NoteStore.createOrUpdateSharedNotes).

◆ noSharePublicly

Optional< bool > qevercloud::NoteRestrictions::noSharePublicly

The client may not make the note public (NoteStore.shareNote).

◆ noUpdateContent

Optional< bool > qevercloud::NoteRestrictions::noUpdateContent

NOT DOCUMENTED

◆ noUpdateTitle

Optional< bool > qevercloud::NoteRestrictions::noUpdateTitle

The client may not update the note's title (Note.title).