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 TELEPHONY_NAPI_HRIL_ERROR_CODE_H 17 #define TELEPHONY_NAPI_HRIL_ERROR_CODE_H 18 19 namespace OHOS { 20 namespace Telephony { 21 /** 22 * @brief Indicates the error code of RIL. 23 */ 24 enum RilErrorCode { 25 /** 26 * Indicates the point is null. 27 */ 28 HRIL_ERR_NULL_POINT = -1, 29 30 /** 31 * Indicates there is no error. 32 */ 33 HRIL_ERR_SUCCESS = 0, 34 35 /** 36 * Indicates a generic failure. 37 */ 38 HRIL_ERR_GENERIC_FAILURE = 1, 39 40 /** 41 * Indicates the parameter is invalid. 42 */ 43 HRIL_ERR_INVALID_PARAMETER = 2, 44 45 /** 46 * Indicates the memory is full. 47 */ 48 HRIL_ERR_MEMORY_FULL = 3, 49 50 /** 51 * Indicates send command failed. 52 */ 53 HRIL_ERR_CMD_SEND_FAILURE = 4, 54 55 /** 56 * Indicates NO CARRIER response returned. 57 */ 58 HRIL_ERR_CMD_NO_CARRIER = 5, 59 60 /** 61 * Indicates the response is invalid. 62 */ 63 HRIL_ERR_INVALID_RESPONSE = 6, 64 65 /** 66 * Indicates the new status of radio to set is same with previous. 67 */ 68 HRIL_ERR_REPEAT_STATUS = 7, 69 }; 70 } // namespace Telephony 71 } // namespace OHOS 72 #endif // TELEPHONY_NAPI_HRIL_ERROR_CODE_H