-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathEnums.cs
243 lines (199 loc) · 4.89 KB
/
Enums.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
using System;
namespace net.vieapps.Components.Security
{
/// <summary>
/// Available actions
/// </summary>
[Serializable]
public enum Action
{
/// <summary>
/// Unknown (or Other) action
/// </summary>
Unknown,
/// <summary>
/// Creates (Contributes) an object
/// </summary>
Create,
/// <summary>
/// Views (Reads) an object
/// </summary>
View,
/// <summary>
/// Downloads a resource (like attachment file, image, ..)
/// </summary>
Download,
/// <summary>
/// Updates an existing object
/// </summary>
Update,
/// <summary>
/// Deletes an existing object (means move the object into recycle-bin)
/// </summary>
Delete,
/// <summary>
/// Deletes an existing object permanently
/// </summary>
PermanentDelete,
/// <summary>
/// Rollbacks an existing object from a previous version
/// </summary>
Rollback,
/// <summary>
/// Restores an object (means put back the object from the recycle-bin)
/// </summary>
Restore,
/// <summary>
/// Approves an object (means change the approval/moderation status of an object)
/// </summary>
Approve,
/// <summary>
/// Archives an object (means backup or move an object into archiving repository)
/// </summary>
Archive,
/// <summary>
/// Synchronizes an object (means update/create new/delete an object by related information from other data-source)
/// </summary>
Synchronize,
/// <summary>
/// Votes up/down an object
/// </summary>
Vote,
/// <summary>
/// Comments on an object
/// </summary>
Comment,
/// <summary>
/// Checks an object out
/// </summary>
CheckOut,
/// <summary>
/// Checks an object in
/// </summary>
CheckIn,
/// <summary>
/// Registers an object
/// </summary>
Register,
/// <summary>
/// Activates an object
/// </summary>
Activate,
/// <summary>
/// Locks an object
/// </summary>
Lock,
/// <summary>
/// Unlocks an object
/// </summary>
Unlock,
/// <summary>
/// Books an object
/// </summary>
Book,
/// <summary>
/// Gives an object
/// </summary>
Give,
/// <summary>
/// Sends an object
/// </summary>
Send,
/// <summary>
/// Returns an object
/// </summary>
Return,
/// <summary>
/// All actions
/// </summary>
Full
}
// --------------------------------------------------------------------------------------------
/// <summary>
/// Available system roles
/// </summary>
[Serializable]
public enum SystemRole
{
/// <summary>
/// All kinds of users (include anonymous/visitor)
/// </summary>
All,
/// <summary>
/// All kinds of users that are marked as already authorized (means already signed/logged in)
/// </summary>
Authenticated,
/// <summary>
/// Signed/Logged in accounts that mark as system administrator
/// </summary>
SystemAdministrator
}
// --------------------------------------------------------------------------------------------
/// <summary>
/// Available privilege roles
/// </summary>
[Serializable]
public enum PrivilegeRole
{
/// <summary>
/// Presents the working role that have no privilege on any resource
/// </summary>
None,
/// <summary>
/// Presents the working role that able to download files/attachments of the published resources
/// </summary>
Downloader,
/// <summary>
/// Presents the working role that able to view the details (means read-only on published resources)
/// </summary>
Viewer,
/// <summary>
/// Presents the working role that able to contribute (means create new and view the published/their own resources)
/// </summary>
Contributor,
/// <summary>
/// Presents the working role that able to edit (means create new and re-update the published resources)
/// </summary>
Editor,
/// <summary>
/// Presents the working role that able to moderate (means moderate all kinds of resources)
/// </summary>
Moderator,
/// <summary>
/// Presents the working role that able to do anything (means full access)
/// </summary>
Administrator
}
// --------------------------------------------------------------------------------------------
/// <summary>
/// All available approval statuses
/// </summary>
[Serializable]
public enum ApprovalStatus
{
/// <summary>
/// Draft mean the content is in editing by owner.
/// </summary>
Draft,
/// <summary>
/// Pending mean the content is submited for approval review.
/// </summary>
Pending,
/// <summary>
/// Rejected mean the content is rejected by reviewer and need to re-edit.
/// </summary>
Rejected,
/// <summary>
/// Approved mean the content is approved but await for publishing to public.
/// </summary>
Approved,
/// <summary>
/// Published mean the content is published to public.
/// </summary>
Published,
/// <summary>
/// Archieved mean the content is archieved for using with other purpose in the furture.
/// </summary>
Archieved
}
}