1 /*
2  * Copyright (c) 2021 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 OHOS_DEVICE_PROFILE_ERRORS_H
17 #define OHOS_DEVICE_PROFILE_ERRORS_H
18 
19 #include "errors.h"
20 
21 namespace OHOS {
22 namespace DeviceProfile {
23 enum {
24     DEVICE_PROFILE_MODULE_DDP = 0,
25 };
26 
27 constexpr ErrCode DEVICE_PROFILE_ERR_OFFSET = ErrCodeOffset(SUBSYS_DEVICEPROFILE, DEVICE_PROFILE_MODULE_DDP);
28 
29 enum {
30     // DEVICE_PROFILE_ERR_OFFSET(98566143)
31     ERR_DP_INVALID_PARAMS = 98566144,
32     ERR_DP_INTERFACE_CHECK_FAILED = 98566145,
33     ERR_DP_GET_LOCAL_UDID_FAILED = 98566146,
34     ERR_DP_GET_SERVICE_FAILED = 98566147,
35     ERR_DP_INIT_DB_FAILED = 98566148,
36     ERR_DP_NOT_SUBSCRIBED = 98566149,
37     ERR_DP_UNSUBSCRIBE_FAILED = 98566150,
38     ERR_DP_SUBSCRIBE_FAILED = 98566151,
39     ERR_DP_SUBSCRIBE_LIMIT_EXCEEDED = 98566152,
40     ERR_DP_POST_TASK_FAILED = 98566153,
41     ERR_DP_DEVICE_SYNC_BUSY = 98566154,
42     ERR_DP_PERMISSION_DENIED = 98566155,
43     ERR_DP_UNTRUSTED_GROUP = 98566156,
44     ERR_DP_NOT_INIT_DB = 98566157,
45     ERR_DP_GET_NETWORKID_FAILED = 98566158,
46     ERR_DP_FILE_FAILED_ERR = 98566159,
47     ERR_DP_LOAD_SERVICE_ERR = 98566160,
48     ERR_DP_GET_DATA_FAILED = 98566161,
49     ERR_DP_DELETE_DATA_FAILED = 98566162,
50     ERR_DP_ADD_DATA_FAILED = 98566163,
51     ERR_DP_SYNC_DATA_FAILED = 98566164,
52 };
53 } // namespace DeviceProfile
54 } // namespace OHOS
55 #endif // OHOS_DEVICE_PROFILE_ERRORS_H
56