176fd607bSopenharmony_ci/* 276fd607bSopenharmony_ci * Copyright (C) 2022 Huawei Device Co., Ltd. 376fd607bSopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 476fd607bSopenharmony_ci * you may not use this file except in compliance with the License. 576fd607bSopenharmony_ci * You may obtain a copy of the License at 676fd607bSopenharmony_ci * 776fd607bSopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 876fd607bSopenharmony_ci * 976fd607bSopenharmony_ci * Unless required by applicable law or agreed to in writing, software 1076fd607bSopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 1176fd607bSopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1276fd607bSopenharmony_ci * See the License for the specific language governing permissions and 1376fd607bSopenharmony_ci * limitations under the License. 1476fd607bSopenharmony_ci */ 1576fd607bSopenharmony_ci 1676fd607bSopenharmony_ci#ifndef OHOS_MEDIALIBRARY_ERRNO_H 1776fd607bSopenharmony_ci#define OHOS_MEDIALIBRARY_ERRNO_H 1876fd607bSopenharmony_ci 1976fd607bSopenharmony_ci#include <errno.h> 2076fd607bSopenharmony_ci#include <stdint.h> 2176fd607bSopenharmony_ci 2276fd607bSopenharmony_cinamespace OHOS { 2376fd607bSopenharmony_cinamespace Media { 2476fd607bSopenharmony_ci#define MEDIA_LIBRARY_ERR(offset, errCode) (-((offset) + (errCode))) 2576fd607bSopenharmony_ci 2676fd607bSopenharmony_ci// common error code 2776fd607bSopenharmony_ci// linux standard ERROR { 0, 200 } 2876fd607bSopenharmony_ciconstexpr int32_t E_OK = 0; 2976fd607bSopenharmony_ciconstexpr int32_t E_SUCCESS = 0; 3076fd607bSopenharmony_ci#ifdef MEDIALIBRARY_MTP_ENABLE 3176fd607bSopenharmony_ciconstexpr int32_t MTP_SUCCESS = 0; 3276fd607bSopenharmony_ci#endif 3376fd607bSopenharmony_ciconstexpr int32_t E_ERR = -1; 3476fd607bSopenharmony_ciconstexpr int32_t E_PERMISSION_DENIED = -EACCES; 3576fd607bSopenharmony_ciconstexpr int32_t E_NO_SUCH_FILE = -ENOENT; 3676fd607bSopenharmony_ciconstexpr int32_t E_FILE_EXIST = -EEXIST; 3776fd607bSopenharmony_ciconstexpr int32_t E_NO_MEMORY = -ENOMEM; 3876fd607bSopenharmony_ciconstexpr int32_t E_NO_SPACE = -ENOSPC; 3976fd607bSopenharmony_ciconstexpr int32_t E_CHECK_SYSTEMAPP_FAIL = 202; 4076fd607bSopenharmony_ci 4176fd607bSopenharmony_ci// medialibary inner common err { 200, 1999 } 4276fd607bSopenharmony_ciconstexpr int32_t E_COMMON_OFFSET = 200; 4376fd607bSopenharmony_ciconstexpr int32_t E_COMMON_START = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 0); 4476fd607bSopenharmony_ciconstexpr int32_t E_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 0); 4576fd607bSopenharmony_ciconstexpr int32_t E_FILE_OPER_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 1); 4676fd607bSopenharmony_ciconstexpr int32_t E_HAS_FS_ERROR = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 3); 4776fd607bSopenharmony_ciconstexpr int32_t E_CHECK_DIR_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 4); 4876fd607bSopenharmony_ciconstexpr int32_t E_MODIFY_DATA_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 5); 4976fd607bSopenharmony_ciconstexpr int32_t E_INVALID_VALUES = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 6); 5076fd607bSopenharmony_ciconstexpr int32_t E_INVALID_URI = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 7); 5176fd607bSopenharmony_ciconstexpr int32_t E_INVALID_FILEID = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 8); 5276fd607bSopenharmony_ciconstexpr int32_t E_INVALID_PATH = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 9); 5376fd607bSopenharmony_ciconstexpr int32_t E_VIOLATION_PARAMETERS = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 10); 5476fd607bSopenharmony_ciconstexpr int32_t E_RENAME_DIR_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 11); 5576fd607bSopenharmony_ciconstexpr int32_t E_GET_VALUEBUCKET_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 12); 5676fd607bSopenharmony_ciconstexpr int32_t E_GET_ASSET_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 13); 5776fd607bSopenharmony_ciconstexpr int32_t E_GET_HASH_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 14); 5876fd607bSopenharmony_ciconstexpr int32_t E_GET_CLIENTBUNDLE_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 15); 5976fd607bSopenharmony_ciconstexpr int32_t E_EXIST_IN_DB = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 16); 6076fd607bSopenharmony_ciconstexpr int32_t E_INVALID_MODE = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 17); 6176fd607bSopenharmony_ciconstexpr int32_t E_INVALID_BUNDLENAME = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 18); 6276fd607bSopenharmony_ciconstexpr int32_t E_RENAME_FILE_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 19); 6376fd607bSopenharmony_ciconstexpr int32_t E_DB_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 20); 6476fd607bSopenharmony_ciconstexpr int32_t E_DELETE_DENIED = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 21); 6576fd607bSopenharmony_ciconstexpr int32_t E_HAS_DB_ERROR = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 22); 6676fd607bSopenharmony_ciconstexpr int32_t E_INVALID_ARGUMENTS = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 23); 6776fd607bSopenharmony_ciconstexpr int32_t E_SQL_CHECK_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 24); 6876fd607bSopenharmony_ciconstexpr int32_t E_IS_PENDING_ERROR = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 25); 6976fd607bSopenharmony_ciconstexpr int32_t E_NEED_FURTHER_CHECK = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 26); 7076fd607bSopenharmony_ciconstexpr int32_t E_CHECK_NATIVE_SA_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 27); 7176fd607bSopenharmony_ciconstexpr int32_t E_INVALID_TIMESTAMP = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 28); 7276fd607bSopenharmony_ciconstexpr int32_t E_GRANT_URI_PERM_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 29); 7376fd607bSopenharmony_ciconstexpr int32_t E_IS_IN_COMMIT = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 30); 7476fd607bSopenharmony_ciconstexpr int32_t E_IS_IN_REVERT = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 31); 7576fd607bSopenharmony_ciconstexpr int32_t E_GET_PRAMS_FAIL = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 32); 7676fd607bSopenharmony_ciconstexpr int32_t E_INVALID_MOVING_PHOTO = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 33); 7776fd607bSopenharmony_ciconstexpr int32_t E_INVALID_LIVE_PHOTO = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 34); 7876fd607bSopenharmony_ciconstexpr int32_t E_COMMON_END = MEDIA_LIBRARY_ERR(E_COMMON_OFFSET, 1799); 7976fd607bSopenharmony_ci 8076fd607bSopenharmony_ci// medialibary directory and file type control { 2000, 2099 } 8176fd607bSopenharmony_ciconstexpr int32_t E_DIR_CTRL_OFFSET = 2000; 8276fd607bSopenharmony_ciconstexpr int32_t E_CHECK_EXTENSION_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 0); 8376fd607bSopenharmony_ciconstexpr int32_t E_DELETE_DIR_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 1); 8476fd607bSopenharmony_ciconstexpr int32_t E_CHECK_MEDIATYPE_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 2); 8576fd607bSopenharmony_ciconstexpr int32_t E_CHECK_ROOT_DIR_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 3); 8676fd607bSopenharmony_ciconstexpr int32_t E_CHECK_MEDIATYPE_MATCH_EXTENSION_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 4); 8776fd607bSopenharmony_ciconstexpr int32_t E_FILE_NAME_INVALID = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 5); 8876fd607bSopenharmony_ciconstexpr int32_t E_ALBUM_OPER_ERR = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 6); 8976fd607bSopenharmony_ciconstexpr int32_t E_DIR_OPER_ERR = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 7); 9076fd607bSopenharmony_ciconstexpr int32_t E_SAME_PATH = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 8); 9176fd607bSopenharmony_ciconstexpr int32_t E_DIR_CHECK_DIR_FAIL = MEDIA_LIBRARY_ERR(E_DIR_CTRL_OFFSET, 9); 9276fd607bSopenharmony_ci 9376fd607bSopenharmony_ci// medialibary recycle, trash { 2100, 2199 } 9476fd607bSopenharmony_ciconstexpr int32_t E_TRASH_OFFSET = 2100; 9576fd607bSopenharmony_ciconstexpr int32_t E_RECYCLE_FILE_IS_NULL = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 0); 9676fd607bSopenharmony_ciconstexpr int32_t E_IS_RECYCLED = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 1); 9776fd607bSopenharmony_ciconstexpr int32_t E_RECYCLE_DIR_FAIL = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 2); 9876fd607bSopenharmony_ciconstexpr int32_t E_CREATE_TRASHDIR_FAIL = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 3); 9976fd607bSopenharmony_ciconstexpr int32_t E_MAKE_HASHNAME_FAIL = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 4); 10076fd607bSopenharmony_ciconstexpr int32_t E_GET_EXTENSION_FAIL = MEDIA_LIBRARY_ERR(E_TRASH_OFFSET, 5); 10176fd607bSopenharmony_ci 10276fd607bSopenharmony_ci 10376fd607bSopenharmony_ci// medialibary distributed { 2200, 2299 } 10476fd607bSopenharmony_ciconstexpr int32_t E_DISTRIBUTED_OFFSET = 2200; 10576fd607bSopenharmony_ciconstexpr int32_t E_DEVICE_OPER_ERR = MEDIA_LIBRARY_ERR(E_DISTRIBUTED_OFFSET, 0); 10676fd607bSopenharmony_ci 10776fd607bSopenharmony_ci// medialibary thumbanail { 2300, 2399 } 10876fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_OFFSET = 2300; 10976fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_CONNECT_TIMEOUT = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 0); 11076fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_HAS_OPENED_FAIL = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 1); 11176fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_LOCAL_CREATE_FAIL = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 2); 11276fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_REMOTE_CREATE_FAIL = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 3); 11376fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_SERVICE_NULLPTR = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 4); 11476fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_INVALID_SIZE = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 5); 11576fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_UNKNOWN = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 6); 11676fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_ASTC_ALL_EXIST = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 7); 11776fd607bSopenharmony_ciconstexpr int32_t E_THUMBNAIL_LCD_ALL_EXIST = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 8); 11876fd607bSopenharmony_ciconstexpr int32_t E_CLOUD_THUMBNAIL_NOT_DOWNLOAD_FINISH = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 9); 11976fd607bSopenharmony_ciconstexpr int32_t E_CLOUD_NOT_SUITABLE_FOR_TASK = MEDIA_LIBRARY_ERR(E_THUMBNAIL_OFFSET, 10); 12076fd607bSopenharmony_ci 12176fd607bSopenharmony_ci// medialibary scanner { 2400, 2499 } 12276fd607bSopenharmony_ciconstexpr int32_t E_SCANNER_OFFSET = 2400; 12376fd607bSopenharmony_ciconstexpr int32_t E_FILE_HIDDEN = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 0); 12476fd607bSopenharmony_ciconstexpr int32_t E_DIR_HIDDEN = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 1); 12576fd607bSopenharmony_ciconstexpr int32_t E_RDB = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 2); 12676fd607bSopenharmony_ciconstexpr int32_t E_DATA = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 3); 12776fd607bSopenharmony_ciconstexpr int32_t E_SYSCALL = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 4); 12876fd607bSopenharmony_ciconstexpr int32_t E_SCANNED = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 5); 12976fd607bSopenharmony_ciconstexpr int32_t E_AVMETADATA = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 6); 13076fd607bSopenharmony_ciconstexpr int32_t E_IMAGE = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 7); 13176fd607bSopenharmony_ciconstexpr int32_t E_NO_RESULT = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 8); 13276fd607bSopenharmony_ciconstexpr int32_t E_STOP = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 9); 13376fd607bSopenharmony_ciconstexpr int32_t E_IS_PENDING = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 10); 13476fd607bSopenharmony_ciconstexpr int32_t E_MOVING_PHOTO = MEDIA_LIBRARY_ERR(E_SCANNER_OFFSET, 11); 13576fd607bSopenharmony_ci 13676fd607bSopenharmony_ci// media file extension module error code { 3000, 3099 } 13776fd607bSopenharmony_ciconstexpr int32_t E_MEDIA_FILE_OFFSET = 3000; 13876fd607bSopenharmony_ciconstexpr int32_t E_URI_INVALID = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 0); 13976fd607bSopenharmony_ciconstexpr int32_t E_DISTIBUTED_URI_NO_SUPPORT = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 1); 14076fd607bSopenharmony_ciconstexpr int32_t E_URI_IS_NOT_ALBUM = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 2); 14176fd607bSopenharmony_ciconstexpr int32_t E_URI_IS_NOT_FILE = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 3); 14276fd607bSopenharmony_ciconstexpr int32_t E_TWO_URI_ARE_THE_SAME = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 4); 14376fd607bSopenharmony_ciconstexpr int32_t E_OPENFILE_INVALID_FLAG = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 5); 14476fd607bSopenharmony_ciconstexpr int32_t E_INVALID_DISPLAY_NAME = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 6); 14576fd607bSopenharmony_ciconstexpr int32_t E_DENIED_MOVE = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 7); 14676fd607bSopenharmony_ciconstexpr int32_t E_UPDATE_DB_FAIL = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 8); 14776fd607bSopenharmony_ciconstexpr int32_t E_DENIED_RENAME = MEDIA_LIBRARY_ERR(E_MEDIA_FILE_OFFSET, 9); 14876fd607bSopenharmony_ci 14976fd607bSopenharmony_ci#ifdef MEDIALIBRARY_MTP_ENABLE 15076fd607bSopenharmony_ci// common error {14000, 14099} 15176fd607bSopenharmony_ciconstexpr int32_t E_MTP_COMMON_OFFSET = 14000; 15276fd607bSopenharmony_ciconstexpr int32_t MTP_FAIL = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 0); 15376fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_SESSION_ALREADY_OPEN = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 1); 15476fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_CONTEXT_IS_NULL = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 2); 15576fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_PACKET_INCORRECT = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 3); 15676fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_NO_THIS_FILE = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 4); 15776fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INCOMPLETE_TRANSFER = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 5); 15876fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_SESSION_NOT_OPEN = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 6); 15976fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_STORAGE_ID = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 7); 16076fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_OBJECTHANDLE = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 8); 16176fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_DEVICEPROP_NOT_SUPPORTED = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 9); 16276fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_DRIVER_OPEN_FAILED = MEDIA_LIBRARY_ERR(E_MTP_COMMON_OFFSET, 10); 16376fd607bSopenharmony_ci 16476fd607bSopenharmony_ci// medialibrary error { 15000, 15099 } 16576fd607bSopenharmony_ciconstexpr int32_t E_MTP_MEDIALIBRARY_OFFSET = 15000; 16676fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_STORE_NOT_AVAILABLE = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 0); 16776fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_NO_THUMBNAIL_PRESENT = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 1); 16876fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_PARENTOBJECT = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 2); 16976fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_PARAMETER_NOT_SUPPORTED = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 3); 17076fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_OBJECTPROP_VALUE = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 4); 17176fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_OBJECTPROP_FORMAT = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 5); 17276fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_INVALID_OBJECTPROPCODE = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 6); 17376fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_ACCESS_DENIED = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 7); 17476fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_SPECIFICATION_BY_GROUP_UNSUPPORTED = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 8); 17576fd607bSopenharmony_ciconstexpr int32_t MTP_ERROR_SPECIFICATION_BY_DEPTH_UNSUPPORTED = MEDIA_LIBRARY_ERR(E_MTP_MEDIALIBRARY_OFFSET, 9); 17676fd607bSopenharmony_ci#endif 17776fd607bSopenharmony_ci 17876fd607bSopenharmony_ci// media smart album module error code { 4000, 4099 } 17976fd607bSopenharmony_ciconstexpr int32_t E_MEDIA_SMART_OFFSET = 4000; 18076fd607bSopenharmony_ciconstexpr int32_t E_PARENT_SMARTALBUM_IS_NOT_EXISTED = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 0); 18176fd607bSopenharmony_ciconstexpr int32_t E_PARENT_SMARTALBUM_CAN_NOT_DELETE = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 1); 18276fd607bSopenharmony_ciconstexpr int32_t E_DELETE_SMARTALBUM_MAP_FAIL = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 2); 18376fd607bSopenharmony_ciconstexpr int32_t E_SMARTALBUM_IS_NOT_EXISTED = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 3); 18476fd607bSopenharmony_ciconstexpr int32_t E_CHILD_CAN_NOT_ADD_SMARTALBUM = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 4); 18576fd607bSopenharmony_ciconstexpr int32_t E_TRASHALBUM_CAN_NOT_DELETE = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 5); 18676fd607bSopenharmony_ciconstexpr int32_t E_FAVORITEALBUM_CAN_NOT_DELETE = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 6); 18776fd607bSopenharmony_ciconstexpr int32_t E_PARENT_CAN_NOT_ADDASSETS = MEDIA_LIBRARY_ERR(E_MEDIA_SMART_OFFSET, 7); 18876fd607bSopenharmony_ci 18976fd607bSopenharmony_ci 19076fd607bSopenharmony_ci// media on notify module error code { 16000, 16099 } 19176fd607bSopenharmony_ciconstexpr int32_t E_MEDIA_NOTIFY_OFFSET = 16000; 19276fd607bSopenharmony_ciconstexpr int32_t E_ASYNC_WORKER_IS_NULL = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 0); 19376fd607bSopenharmony_ciconstexpr int32_t E_NOTIFY_TASK_DATA_IS_NULL = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 1); 19476fd607bSopenharmony_ciconstexpr int32_t E_SOLVE_URIS_FAILED = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 2); 19576fd607bSopenharmony_ciconstexpr int32_t E_NOTIFY_CHANGE_EXT_FAILED = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 3); 19676fd607bSopenharmony_ciconstexpr int32_t E_PARCEL_GET_SIZE_FAILED = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 4); 19776fd607bSopenharmony_ciconstexpr int32_t E_GET_ALBUM_ID_FAILED = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 5); 19876fd607bSopenharmony_ciconstexpr int32_t E_DO_NOT_NEDD_SEND_NOTIFY = MEDIA_LIBRARY_ERR(E_MEDIA_NOTIFY_OFFSET, 6); 19976fd607bSopenharmony_ci} // namespace Media 20076fd607bSopenharmony_ci} // namespace OHOS 20176fd607bSopenharmony_ci#endif // OHOS_MEDIALIBRARY_ERRNO_H 202