• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2023-2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef COMMON_NATIVE_INCLUDE_EDM_CONSTANTS_H
17 #define COMMON_NATIVE_INCLUDE_EDM_CONSTANTS_H
18 
19 #include <iostream>
20 
21 namespace OHOS {
22 namespace EDM {
23 namespace EdmConstants {
24     constexpr int32_t DECIMAL = 10;
25     constexpr int32_t APPID_MAX_SIZE = 200;
26     constexpr int32_t DEFAULT_USER_ID = 100;
27     constexpr int32_t USB_ERRCODE_INTERFACE_NO_INIT = 88080389;
28     constexpr int32_t ALLOWED_USB_DEVICES_MAX_SIZE = 1000;
29     constexpr int32_t STORAGE_USB_POLICY_READ_WRITE = 0;
30     constexpr int32_t STORAGE_USB_POLICY_READ_ONLY = 1;
31     constexpr int32_t STORAGE_USB_POLICY_DISABLED = 2;
32     constexpr int32_t AUTO_START_APPS_MAX_SIZE = 10;
33     constexpr int32_t SET_POLICIES_TYPE = 1;
34     constexpr int32_t SET_POLICY_TYPE = 2;
35     constexpr int32_t BLUETOOTH_WHITELIST_MAX_SIZE = 1000;
36 
37     const char* const PERMISSION_TAG_VERSION_11 = "version_11";
38     const char* const PERMISSION_TAG_VERSION_12 = "version_12";
39     const char* const PERMISSION_TAG_SYSTEM_API = "system";
40 
41     namespace DeviceInfo {
42         const char* const DEVICE_NAME = "deviceName";
43         const char* const DEVICE_SERIAL = "deviceSerial";
44         const char* const SIM_INFO = "simInfo";
45         const char* const SIM_SLOT_ID = "slotId";
46         const char* const SIM_MEID = "MEID";
47         const char* const SIM_IMSI = "IMSI";
48         const char* const SIM_ICCID = "ICCID";
49         const char* const SIM_IMEI = "IMEI";
50         constexpr int32_t SIM_SLOT_ID_0 = 0;
51         constexpr int32_t SIM_SLOT_ID_1 = 1;
52     } // namespace DeviceInfo
53 
54     namespace Restrictions {
55         const char* const LABEL_DISALLOWED_POLICY_BLUETOOTH = "bluetooth";
56         const char* const LABEL_DISALLOWED_POLICY_MODIFY_DATETIME = "modifyDateTime";
57         const char* const LABEL_DISALLOWED_POLICY_PRINTER = "printer";
58         const char* const LABEL_DISALLOWED_POLICY_HDC = "hdc";
59         const char* const LABEL_DISALLOWED_POLICY_MIC = "microphone";
60         const char* const LABEL_DISALLOWED_POLICY_FINGER_PRINT = "fingerprint";
61         const char* const LABEL_DISALLOWED_POLICY_SCREENSHOT = "screenshot";
62         const char* const LABEL_DISALLOWED_POLICY_SCREEN_RECORD = "screenRecord";
63         const char* const LABEL_DISALLOWED_POLICY_USB = "usb";
64         const char* const LABEL_DISALLOWED_POLICY_WIFI = "wifi";
65         const char* const LABEL_DISALLOWED_POLICY_DISK_RECOVERY_KEY = "diskRecoveryKey";
66         const char* const LABEL_DISALLOWED_POLICY_NEAR_LINK = "nearLink";
67     } // namespace Restrictions
68 
69     namespace SecurityManager {
70         const char* const PATCH = "patch";
71         const char* const ENCRYPTION = "encryption";
72         const char* const ROOT = "root";
73     } // namespace SecurityManager
74 
75     namespace DeviceSettings {
76         const char* const SCREEN_OFF = "screenOff";
77         const char* const POWER_POLICY = "powerPolicy";
78         const char* const DATE_TIME = "dateTime";
79     } // namespace DeviceSettings
80 
81     namespace DeviceControl {
82         const char* const RESET_FACTORY = "resetFactory";
83         const char* const REBOOT = "reboot";
84         const char* const SHUT_DOWN = "shutDown";
85         const char* const LOCK_SCREEN = "lockScreen";
86     } // namespace DeviceControl
87 } // namespace EdmConstants
88 } // namespace EDM
89 } // namespace OHOS
90 
91 #endif // COMMON_NATIVE_INCLUDE_EDM_CONSTANTS_H
92