digiKam
vkontakte_apppermissions.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2011-02-19
7  * Description : a tool to export images to VKontakte web service
8  *
9  * Copyright (C) 2011-2015 by Alexander Potashev <aspotashev at gmail dot com>
10  * Copyright (C) 2011-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_VKONTAKTE_APPPERMISSIONS_H
25 #define DIGIKAM_VKONTAKTE_APPPERMISSIONS_H
26 
27 namespace Vkontakte
28 {
29 
30 namespace AppPermissions
31 {
32 
33 enum Value
34 {
35  NoPermissions = 0,
36 
37  // User allowed to send notifications to him/her
38  Notify = 1,
39  // Access to friends
40  Friends = 2,
41  // Access to photos
42  Photos = 4,
43  // Access to audios
44  Audio = 8,
45  // Access to videos
46  Video = 16,
47  // Access to offers (obsolete methods)
48  Offers = 32,
49  // Access to questions (obsolete methods).
50  Questions = 64,
51  // Access to wiki pages
52  Pages = 128,
53  // Addition of link to the application in the left menu
54  AppLink = 256,
55  // Access to user status
56  Status = 1024,
57  // Access to user notes
58  Notes = 2048,
59  // Access to advanced methods for messaging
60  Messages = 4096,
61  // Access to standard and advanced methods for the wall
62  Wall = 8192,
63  // Access to advanced methods for Ads API
64  Ads = 32768,
65  // Access to API at any time from a third party server
66  Offline = 65536,
67  // Access to documents
68  Docs = 131072,
69  // Access to user groups
70  Groups = 262144,
71  // Access to notifications about answers to the user
72  Notifications = 524288,
73  // Access to statistics of user's own groups and applications
74  Stats = 1048576,
75  // User e-mail access. Available only for sites.
76  Email = 4194304
77 }; // enum Value
78 
79 inline AppPermissions::Value operator|(AppPermissions::Value a, AppPermissions::Value b)
80 {
81  return static_cast<AppPermissions::Value>(static_cast<int>(a) | static_cast<int>(b));
82 }
83 
84 inline AppPermissions::Value& operator|=(AppPermissions::Value& a, AppPermissions::Value b)
85 {
86  return (a = a | b);
87 }
88 
89 } // namespace AppPermissions
90 
91 } // namespace Vkontakte
92 
93 #endif // DIGIKAM_VKONTAKTE_APPPERMISSIONS_H
Status
Definition: coredbconstants.h:85