Initialize Tizen 2.3
[framework/web/wrt-plugins-common.git] / src_mobile / modules / API / Filesystem / Enums.h
1 /*
2  * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
3  *
4  *    Licensed under the Apache License, Version 2.0 (the "License");
5  *    you may not use this file except in compliance with the License.
6  *    You may obtain a copy of the License at
7  *
8  *        http://www.apache.org/licenses/LICENSE-2.0
9  *
10  *    Unless required by applicable law or agreed to in writing, software
11  *    distributed under the License is distributed on an "AS IS" BASIS,
12  *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  *    See the License for the specific language governing permissions and
14  *    limitations under the License.
15  */
16 #ifndef WRTDEVICEAPIS_FILESYSTEM_ENUMS_H_
17 #define WRTDEVICEAPIS_FILESYSTEM_ENUMS_H_
18
19 #include <string>
20 #include <map>
21
22 namespace WrtDeviceApis {
23 namespace Filesystem {
24 namespace Api {
25 enum LocationType
26 {
27     LT_APPS,
28     LT_DOCUMENTS,
29     LT_DOWNLOADS,
30     LT_GAMES,
31     LT_IMAGES,
32     LT_OTHERS,
33     LT_ROOT,
34     LT_SDCARD,
35     LT_SOUNDS,
36     LT_TEMP,
37     LT_VIDEOS
38 };
39
40 enum NodeType
41 {
42     NT_DIRECTORY,
43     NT_FILE
44 };
45
46 enum AccessMode
47 {
48     AM_READ = 0x0001,
49     AM_WRITE = 0x0002,
50     AM_APPEND = 0x0004
51 };
52
53 /**
54  * Used in @see IManager::access().
55  */
56 enum AccessType
57 {
58     AT_READ = 0x0001,     //!< AT_READ   - checks for read access
59     AT_WRITE = 0x0002,    //!< AT_WRITE  - checks for write access
60     AT_EXEC = 0x0004,     //!< AT_EXEC   - checks for execution access
61     AT_EXISTS = 0x0008    //!< AT_EXISTS - checks for existence
62 };
63
64 enum Permissions
65 {
66     PERM_NONE = 0x0000,
67     PERM_READ = 0x0001,
68     PERM_WRITE = 0x0002
69 };
70
71 enum PlatformMode
72 {
73     PM_USER_READ = 0x0100,
74     PM_USER_WRITE = 0x0080,
75     PM_USER_EXEC = 0x0040,
76     PM_GROUP_READ = 0x0020,
77     PM_GROUP_WRITE = 0x0010,
78     PM_GROUP_EXEC = 0x0008,
79     PM_OTHER_READ = 0x0004,
80     PM_OTHER_WRITE = 0x0002,
81     PM_OTHER_EXEC = 0x0001,
82     PM_NONE = 0x0000
83 };
84
85 enum Options
86 {
87     OPT_NONE = 0x0000,
88     OPT_OVERWRITE = 0x0001,
89     OPT_RECURSIVE = 0x0002
90 };
91
92 enum FindFilter
93 {
94     FF_NAME,
95     FF_CREATED,
96     FF_MODIFIED,
97     FF_SIZE
98 };
99 typedef std::map<FindFilter, std::string> FiltersMap;
100 } // API
101 } // Filesystem
102 } // WrtDeviceApis
103
104 #endif /* WRTDEVICEAPIS_FILESYSTEM_ENUMS_H_ */