已合并
媒体库SDK差异同步 #35073
媒体库SDK差异同步 #35073
已合并
qinquan创建于 9 天前
2 个文件变更+249-380
Mapi/@ohos.file.photoAccessHelper.d.ts+65-190
@@ -7143,7 +7143,7 @@ declare namespace photoAccessHelper {
7143 * @throws { BusinessError } 201 - Permission denied7143 * @throws { BusinessError } 201 - Permission denied
7144 * @throws { BusinessError } 23800151 The scenario parameter verification fails. Possible causes:7144 * @throws { BusinessError } 23800151 The scenario parameter verification fails. Possible causes:
7145 * <br>1. The type is not fixed at 'photoChange'; 7145 * <br>1. The type is not fixed at 'photoChange';
7146- * <br>2. The same callback is registered repeatedly.7146+ * <br>2. The same callback is unregistered repeatedly.
7147 * @throws { BusinessError } 23800301 - Internal system error. You are advised to retry and check the logs.7147 * @throws { BusinessError } 23800301 - Internal system error. You are advised to retry and check the logs.
7148 * Possible causes: 7148 * Possible causes:
7149 * <br>1. The database is corrupted. 7149 * <br>1. The database is corrupted.
@@ -7377,7 +7377,8 @@ declare namespace photoAccessHelper {
7377 * <br>Once a specific callback is unregistered, it will not be invoked when an album changes.7377 * <br>Once a specific callback is unregistered, it will not be invoked when an album changes.
7378 * @throws { BusinessError } 201 - Permission denied7378 * @throws { BusinessError } 201 - Permission denied
7379 * @throws { BusinessError } 23800151 The scenario parameter verification fails. Possible causes:7379 * @throws { BusinessError } 23800151 The scenario parameter verification fails. Possible causes:
7380- * The same callback is unregistered repeatedly.7380+ * <br>1. The type is not fixed at 'photoAlbumChange';
7381+ * <br>2. The same callback is unregistered repeatedly.
7381 * @throws { BusinessError } 23800301 - Internal system error. You are advised to retry and check the7382 * @throws { BusinessError } 23800301 - Internal system error. You are advised to retry and check the
7382 * logs.7383 * logs.
7383 * <br>Possible causes: 7384 * <br>Possible causes:
@@ -8173,27 +8174,6 @@ declare namespace photoAccessHelper {
8173 */8174 */
8174 getAlbumIdByLpath(lpath: string): Promise<int>;8175 getAlbumIdByLpath(lpath: string): Promise<int>;
8175 8176 
8176- /**
8177- * Convert to PhotoAsset from path of filemanagerr.
8178- *
8179- * @permission ohos.permission.WRITE_IMAGEVIDEO
8180- * @param { string }path - file path of filemanager.
8181- * @returns { Promise<PhotoAsset> } Returns successed asset.
8182- * @throws { BusinessError } 201 - Permission denied
8183- * @throws {BusinessError } 202 - Called by non-system application.
8184- * @throws {BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
8185- * <br>1. Converted an image after filtering into an asset object;
8186- * <br>2.File to be converted is not exist;
8187- * <br>3. Only images in the public directory of filemanager can be converted.
8188- * @throws { BusinessError } 23800301 - Internalsystem error. It is recommended to retry and check the logs.
8189- * <br>Possible causes: 1. Database corrupted; 2.The file system is abnormal; 3. The IPC request timed out.
8190- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
8191- * @systemapi
8192- * @stagemodelonly
8193- * @since 26.0.0 dynamic&static
8194- */
8195- convertToAsset(path: string): Promise<PhotoAsset>;
8196- 
8197 /**8177 /**
8198 * Converts the **ValuesBucket** record to a **PhotoAsset** object.8178 * Converts the **ValuesBucket** record to a **PhotoAsset** object.
8199 *8179 *
@@ -8471,53 +8451,6 @@ declare namespace photoAccessHelper {
8471 disableModification: boolean,8451 disableModification: boolean,
8472 isAsyncRefreshAlbum: boolean): Promise<void>;8452 isAsyncRefreshAlbum: boolean): Promise<void>;
8473 8453 
8474- /**
8475- * move assets of medialibrary sandbox to directory of filemanager.
8476- *
8477- * @permission ohos.permission.WRITE_IMAGEVIDEO
8478- * @param { string[] } assets - Assets URI from medialibrary sandbox.
8479- * @param { string } target - Target directory of filemanager.
8480- * @param { BatchOperationOptions } [option] - Option for performing batch operations on assets.
8481- * <br>Options for bulk operations
8482- * @returns { Promise<string[]> } Return the paths to the asset
8483- * @throws { BusinessError } 201 - Permission denied
8484- * @throws { BusinessError } 202 - Called by non-system application.
8485- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
8486- * <br>1. Moving to the target directory is not supported;
8487- * <br>2. Assets to be Moved does not exist;
8488- * <br>3. Automatic renaming is not supported.
8489- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
8490- * <br>Possible causes: 1. Database corrupted; 2. The file system is abnormal; 3. The IPC request timed out.
8491- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
8492- * @systemapi
8493- * @stagemodelonly
8494- * @since 26.1.0 dynamic&static
8495- */
8496- moveAssetsToDir(assets: string[], target: string, option?: BatchOperationOptions): Promise<string[]>;
8497- 
8498- /**
8499- * move assets of filemanager to Album.
8500- *
8501- * @permission ohos.permission.WRITE_IMAGEVIDEO
8502- * @param { string[] } assets - Assets path from filemanager(e.g., "/Download/test.jpg").
8503- * @param { Album } target - Target Album.
8504- * @param { BatchOperationOptions } [option] - Option for performing batch operations on assets.
8505- * @returns { Promise<string[]> } Returns successed assets URIs.
8506- * @throws { BusinessError } 201 - Permission denied
8507- * @throws { BusinessError } 202 - Called by non-system application.
8508- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
8509- * <br>1. Moving to the target Album is not supported;
8510- * <br>2. Assets to be Moved does not exist;
8511- * <br>3. Automatic renaming is not supported.
8512- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
8513- * <br>Possible causes: 1. Database corrupted; 2. The file system is abnormal; 3. The IPC request timed out.
8514- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
8515- * @systemapi
8516- * @stagemodelonly
8517- * @since 26.1.0 dynamic&static
8518- */
8519- moveAssetsByPath(assets: string[], target: Album, option?: BatchOperationOptions): Promise<string[]>;
8520- 
8521 /**8454 /**
8522 * clone assets to Album.8455 * clone assets to Album.
8523 *8456 *
@@ -8543,56 +8476,6 @@ declare namespace photoAccessHelper {
8543 */8476 */
8544 cloneToAlbum(assets: PhotoAsset[], target: Album,option?: BatchOperationOptions): Promise<PhotoAsset[]>;8477 cloneToAlbum(assets: PhotoAsset[], target: Album,option?: BatchOperationOptions): Promise<PhotoAsset[]>;
8545 8478 
8546- /**
8547- * clone assets of medialibrary sandbox to directory of filemanager.
8548- *
8549- * @permission ohos.permission.WRITE_IMAGEVIDEO
8550- * @param { string[] } assets - Assets uri to be cloned.
8551- * @param { string } target - Target directory of filemanager.
8552- * @param { BatchOperationOptions } [option] - Optionfor performing batch operations on assets.
8553- * @returns { Promise<string[]> } Returns successed assets path.
8554- * @throws { BusinessError } 201 - Permission denied
8555- * @throws { BusinessError } 202 - Called by non-system application.
8556- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
8557- * <br>1. Asset to be cloned has been deleted or hidden;
8558- * <br>2. Asset to be cloned is cloud pictures, which can not be cloned;
8559- * <br>3. The Target Album does not exist.
8560- * <br>4. Insufficient system space.
8561- * <br>5. Automatic renaming is not supported.
8562- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
8563- * <br>Possible causes: 1. Database corrupted; 2. The file system is abnormal; 3. The IPC request timed out.
8564- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
8565- * @systemapi
8566- * @stagemodelonly
8567- * @since 26.0.0 dynamic&static
8568- */
8569- cloneToDir(assets: string[], target: string, option?: BatchOperationOptions): Promise<string[]>;
8570- 
8571- /**
8572- * clone assets of filemanager to Album.
8573- *
8574- * @permission ohos.permission.WRITE_IMAGEVIDEO
8575- * @param { string[] } assets - Assets path to be cloned.
8576- * @param { Album } target - Target Album.
8577- * @param { BatchOperationOptions } [option] - Option for performing batch operations on assets.
8578- * @returns { Promise<string[]> } Returns successed assets URI.
8579- * @throws { BusinessError } 201 - Permission denied
8580- * @throws { BusinessError } 202 - Called by non-system application.
8581- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
8582- * <br>1. Asset to be cloned has been deleted or hidden;
8583- * <br>2. Asset to be cloned is cloud pictures, which can not be cloned;
8584- * <br>3. The Target Album does not exist.
8585- * <br>4. Insufficient system space.
8586- * <br>5. Automatic renaming is not supported.
8587- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
8588- * <br>Possible causes: 1. Database corrupted; 2. The file system is abnormal; 3. The IPC request timed out.
8589- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
8590- * @systemapi
8591- * @stagemodelonly
8592- * @since 26.0.0 dynamic&static
8593- */
8594- cloneAssetsByPath(assets: string[], target: Album, option?: BatchOperationOptions): Promise<string[]>;
8595- 
8596 /**8479 /**
8597 * Whether deep storage space optimization can be performed.8480 * Whether deep storage space optimization can be performed.
8598 *8481 *
@@ -12428,41 +12311,18 @@ declare namespace photoAccessHelper {
12428 setCompositeDisplayMode(compositeDisplayMode: CompositeDisplayMode): Promise<void>;12311 setCompositeDisplayMode(compositeDisplayMode: CompositeDisplayMode): Promise<void>;
12429 12312 
12430 /**12313 /**
12431- * Set hidden state of asset.12314+ * Set 4d livephoto status.
12432 *12315 *
12433- * @param { boolean } hiddenState - Hidden status of the asset.12316+ * @param { LivePhoto4dStatus } status - 4d livephoto status.
12434- * @throws { BusinessError } 202 - Called by non-system application.12317+ * @param { string } [livephoto_4d_latest_pair] - The latest 4d livephoto which is genetated by the livephoto.
12435- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:12318+ * @throws { BusinessError } 202 - Called by non-system application
12436- * 1. The asset is not exist;
12437 * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.12319 * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
12438- * <br>Possible causes: 1. Database corrupted.2. The filesystem is abnormal.3. The IPC request timed out.
12439 * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core12320 * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
12440 * @systemapi12321 * @systemapi
12441 * @stagemodelonly12322 * @stagemodelonly
12442- * @since 26.0.0 dynamic&static12323+ * @since 24 dynamic&static
12443 */12324 */
12444- setHiddenAttribute(hiddenState: boolean): void;12325+ setLivePhoto4dStatus(status: LivePhoto4dStatus, livephoto_4d_latest_pair?: string): void;
12445- 
12446- /**
12447- * Set title by filemanger.
12448- *
12449- * @param { string } name - asset name to set.
12450- * <br> Should not contain extensions.
12451- * The file name contains 1 to 255 characters.
12452- * Invalid English characters, including:
12453- * . \ /: *? "'`< > | {} []
12454- * Name-only is not allowed. Or..
12455- * @throws { BusinessError } 202 - Called by non-system application.
12456- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
12457- * 1. The asset is not exist;
12458- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
12459- * <br>Possible causes:1. Database corrupted.2. The file system is abnormal.3. The IPC request timed out.
12460- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
12461- * @systemapi
12462- * @stagemodelonly
12463- * @since 26.0.0 dynamic&static
12464- */
12465- setTitleByFile(name: string): void;
12466 }12326 }
12467 12327 
12468 /**12328 /**
@@ -13073,47 +12933,6 @@ declare namespace photoAccessHelper {
13073 */12933 */
13074 resetCoverUri(): void;12934 resetCoverUri(): void;
13075 12935 
13076- /**
13077- * set hidden state of album.
13078- *
13079- * @param { boolean } hiddenState - Hidden status of the album.
13080- * @param { boolean } isInherited - Whether all child files or directories under an album inherit this setting.
13081- * @throws { BusinessError } 202 - Called by non-system application.
13082- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
13083- * 1. The ablum is not exist;
13084- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
13085- * <br>Possible causes: 1. Database corrupted. 2. The file system is abnormal. 3. The IPC request timed out.
13086- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
13087- * @systemapi
13088- * @stagemodelonly
13089- * @since 26.0.0 dynamic&static
13090- */
13091- setHiddenAttribute(hiddenState: boolean, isInherited:boolean):void;
13092- 
13093- /**
13094- * set album name by filemanger.
13095- *
13096- * @param { string } name - Album name to set.
13097- * <br>Value range:1-255
13098- * <br>Album name parameter specifications:
13099- * The album name contains 1 to 255 characters.
13100- * Invalid English characters, including:
13101- * \ /: *? "'`< > | {} []
13102- * It is not allowed to name only. or..
13103- * English characters are case insensitive.
13104- * The album name must be unique.
13105- * @throws { BusinessError } 202 - Called by non-system application.
13106- * @throws { BusinessError } 23800151 - The scenario parameter verification fails. Possible causes:
13107- * 1. The album is not exist;
13108- * @throws { BusinessError } 23800301 - Internal system error. It is recommended to retry and check the logs.
13109- * <br>Possible causes: 1. Database corrupted. 2. The file system is abnormal. 3. The IPC request timed out.
13110- * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
13111- * @systemapi
13112- * @stagemodelonly
13113- * @since 26.0.0 dynamic&static
13114- */
13115- setAlbumNameByFile(name: string): void;
13116- 
13117 /**12936 /**
13118 * Operates album attribute.12937 * Operates album attribute.
13119 *12938 *
@@ -16665,6 +16484,62 @@ declare namespace photoAccessHelper {
16665 static getSearchSuggestion( searchSuggestionTypes: Array<SearchSuggestionType>): Promise<Array<SearchSuggestionResult>>;16484 static getSearchSuggestion( searchSuggestionTypes: Array<SearchSuggestionType>): Promise<Array<SearchSuggestionResult>>;
16666 }16485 }
16667 16486 
16487+ /**
16488+ * Enumerates the 4d livephoto status.
16489+ *
16490+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16491+ * @systemapi
16492+ * @stagemodelonly
16493+ * @since 24 dynamic&static
16494+ */
16495+ enum LivePhoto4dStatus {
16496+ /**
16497+ * The livephoto has not been identified.
16498+ *
16499+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16500+ * @systemapi
16501+ * @stagemodelonly
16502+ * @since 24 dynamic&static
16503+ */
16504+ UNIDENTIFIED = 0,
16505+ /**
16506+ * The livephoto does not support 4d livephoto.
16507+ *
16508+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16509+ * @systemapi
16510+ * @stagemodelonly
16511+ * @since 24 dynamic&static
16512+ */
16513+ UNSUPPORTED = 1,
16514+ /**
16515+ * The livephoto supports 4d livephoto.
16516+ *
16517+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16518+ * @systemapi
16519+ * @stagemodelonly
16520+ * @since 24 dynamic&static
16521+ */
16522+ SUPPORTED = 2,
16523+ /**
16524+ * The livephoto has generated 4d livephoto.
16525+ *
16526+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16527+ * @systemapi
16528+ * @stagemodelonly
16529+ * @since 24 dynamic&static
16530+ */
16531+ USED = 3,
16532+ /**
16533+ * The livephoto is 4d livephoto.
16534+ *
16535+ * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core
16536+ * @systemapi
16537+ * @stagemodelonly
16538+ * @since 24 dynamic&static
16539+ */
16540+ LIVEPHOTO_4D = 4
16541+ }
16542+ 
16668 /**16543 /**
16669 * Enumeration of permission level for an application to access asset.16544 * Enumeration of permission level for an application to access asset.
16670 *16545 *
Mapi/@ohos.filemanagement.userFileManager.d.ts+184-190
@@ -24,7 +24,7 @@ import image from './@ohos.multimedia.image';
24import dataSharePredicates from './@ohos.data.dataSharePredicates';24import dataSharePredicates from './@ohos.data.dataSharePredicates';
25 25 
26/**26/**
27- * The **userFileManager** module provides user data management capabilities, including accessing and modifying user 27+ * The **userFileManager** module provides user data management capabilities, including accessing and modifying user
28 * media data.28 * media data.
29 *29 *
30 * @syscap SystemCapability.FileManagement.UserFileManager.Core30 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -35,7 +35,7 @@ import dataSharePredicates from './@ohos.data.dataSharePredicates';
35 */35 */
36declare namespace userFileManager {36declare namespace userFileManager {
37 /**37 /**
38- * Obtains a **UserFileManager** instance. This instance can be used to access and modify user media data (such as 38+ * Obtains a **UserFileManager** instance. This instance can be used to access and modify user media data (such as
39 * audio and video assets, images, and documents).39 * audio and video assets, images, and documents).
40 *40 *
41 * @param { Context } context - Context of the ability instance.41 * @param { Context } context - Context of the ability instance.
@@ -78,7 +78,7 @@ declare namespace userFileManager {
78 * @deprecated since 26.0.078 * @deprecated since 26.0.0
79 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoType.VIDEO79 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoType.VIDEO
80 */80 */
81- VIDEO,81+ VIDEO = 2,
82 /**82 /**
83 * Audio.83 * Audio.
84 *84 *
@@ -88,7 +88,7 @@ declare namespace userFileManager {
88 * @deprecated since 26.0.088 * @deprecated since 26.0.0
89 * @useinstead @ohos.file.picker:picker.AudioViewPicker89 * @useinstead @ohos.file.picker:picker.AudioViewPicker
90 */90 */
91- AUDIO91+ AUDIO = 3
92 }92 }
93 93 
94 /**94 /**
@@ -110,7 +110,7 @@ declare namespace userFileManager {
110 * @deprecated since 26.0.0110 * @deprecated since 26.0.0
111 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoSubType.DEFAULT111 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoSubType.DEFAULT
112 */112 */
113- DEFAULT,113+ DEFAULT = 0,
114 /**114 /**
115 * Screenshots and screen recording files.115 * Screenshots and screen recording files.
116 *116 *
@@ -120,7 +120,7 @@ declare namespace userFileManager {
120 * @deprecated since 26.0.0120 * @deprecated since 26.0.0
121 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoSubType.SCREENSHOT121 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoSubType.SCREENSHOT
122 */122 */
123- SCREENSHOT,123+ SCREENSHOT = 1,
124 /**124 /**
125 * Photos and videos taken by a camera.125 * Photos and videos taken by a camera.
126 *126 *
@@ -130,7 +130,7 @@ declare namespace userFileManager {
130 * @deprecated since 26.0.0130 * @deprecated since 26.0.0
131 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubType.SOURCE_GENERIC131 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubType.SOURCE_GENERIC
132 */132 */
133- CAMERA133+ CAMERA = 2
134 }134 }
135 135 
136 /**136 /**
@@ -162,7 +162,7 @@ declare namespace userFileManager {
162 * @deprecated since 26.0.0162 * @deprecated since 26.0.0
163 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PositionType.CLOUD163 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PositionType.CLOUD
164 */164 */
165- CLOUD,165+ CLOUD = 2,
166 /**166 /**
167 * Stored both on a local device and the cloud.167 * Stored both on a local device and the cloud.
168 *168 *
@@ -172,7 +172,7 @@ declare namespace userFileManager {
172 * @deprecated since 26.0.0172 * @deprecated since 26.0.0
173 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PositionType.LOCAL_AND_CLOUD173 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PositionType.LOCAL_AND_CLOUD
174 */174 */
175- BOTH175+ BOTH = 3
176 }176 }
177 177 
178 /**178 /**
@@ -204,13 +204,7 @@ declare namespace userFileManager {
204 * @deprecated since 26.0.0204 * @deprecated since 26.0.0
205 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.ChangeData205 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.ChangeData
206 */206 */
207- type ChangeEvent =207+ type ChangeEvent = 'deviceChange' | 'albumChange' | 'imageChange' | 'audioChange' | 'videoChange' | 'remoteFileChange';
208- 'deviceChange'
209- | 'albumChange'
210- | 'imageChange'
211- | 'audioChange'
212- | 'videoChange'
213- | 'remoteFileChange';
214 208 
215 /**209 /**
216 * Provides APIs for encapsulating file asset attributes.210 * Provides APIs for encapsulating file asset attributes.
@@ -223,7 +217,7 @@ declare namespace userFileManager {
223 */217 */
224 interface FileAsset {218 interface FileAsset {
225 /**219 /**
226- * Media asset URI, for example, **file://media/Photo/1/IMG_datetime_0001/displayName.jpg**. For details, see 220+ * Media asset URI, for example, **file://media/Photo/1/IMG_datetime_0001/displayName.jpg**. For details, see
227 * [Media File URI](docroot://file-management/user-file-uri-intro.md#media-file-uri).221 * [Media File URI](docroot://file-management/user-file-uri-intro.md#media-file-uri).
228 *222 *
229 * @syscap SystemCapability.FileManagement.UserFileManager.Core223 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -281,7 +275,7 @@ declare namespace userFileManager {
281 */275 */
282 set(member: string, value: string): void;276 set(member: string, value: string): void;
283 /**277 /**
284- * Commits the modification on the file metadata to the database. This API uses an asynchronous callback to return 278+ * Commits the modification on the file metadata to the database. This API uses an asynchronous callback to return
285 * the result.279 * the result.
286 *280 *
287 * @permission ohos.permission.WRITE_IMAGEVIDEO or ohos.permission.WRITE_AUDIO281 * @permission ohos.permission.WRITE_IMAGEVIDEO or ohos.permission.WRITE_AUDIO
@@ -307,10 +301,10 @@ declare namespace userFileManager {
307 commitModify(): Promise<void>;301 commitModify(): Promise<void>;
308 /**302 /**
309 * Opens this file asset. This API uses an asynchronous callback to return the result.303 * Opens this file asset. This API uses an asynchronous callback to return the result.
310- * 304+ *
311 * > **NOTE**305 * > **NOTE**
312 * >306 * >
313- * > The write operations are mutually exclusive. After a write operation is complete, you must call **close** to 307+ * > The write operations are mutually exclusive. After a write operation is complete, you must call **close** to
314 * > close the file.308 * > close the file.
315 *309 *
316 * @permission ohos.permission.READ_IMAGEVIDEO or ohos.permission.READ_AUDIO or ohos.permission.WRITE_IMAGEVIDEO or310 * @permission ohos.permission.READ_IMAGEVIDEO or ohos.permission.READ_AUDIO or ohos.permission.WRITE_IMAGEVIDEO or
@@ -327,10 +321,10 @@ declare namespace userFileManager {
327 open(mode: string, callback: AsyncCallback<number>): void;321 open(mode: string, callback: AsyncCallback<number>): void;
328 /**322 /**
329 * Opens this file asset. This API uses a promise to return the result.323 * Opens this file asset. This API uses a promise to return the result.
330- * 324+ *
331 * > **NOTE**325 * > **NOTE**
332 * >326 * >
333- * > The write operations are mutually exclusive. After a write operation is complete, you must call **close** to 327+ * > The write operations are mutually exclusive. After a write operation is complete, you must call **close** to
334 * > close the file.328 * > close the file.
335 *329 *
336 * @permission ohos.permission.READ_IMAGEVIDEO or ohos.permission.READ_AUDIO or ohos.permission.WRITE_IMAGEVIDEO or330 * @permission ohos.permission.READ_IMAGEVIDEO or ohos.permission.READ_AUDIO or ohos.permission.WRITE_IMAGEVIDEO or
@@ -437,9 +431,9 @@ declare namespace userFileManager {
437 favorite(isFavorite: boolean): Promise<void>;431 favorite(isFavorite: boolean): Promise<void>;
438 /**432 /**
439 * Sets a file to hidden state. This API uses an asynchronous callback to return the result.433 * Sets a file to hidden state. This API uses an asynchronous callback to return the result.
440- * 434+ *
441- * The private files set to hidden state are located in the private album (in hidden state) and are not open to 435+ * The private files set to hidden state are located in the private album (in hidden state) and are not open to
442- * third-party applications. After obtaining private files from the private album, users can set **hiddenState** to 436+ * third-party applications. After obtaining private files from the private album, users can set **hiddenState** to
443 * **false** to remove them from the private album.437 * **false** to remove them from the private album.
444 *438 *
445 * @permission ohos.permission.WRITE_IMAGEVIDEO439 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -457,9 +451,9 @@ declare namespace userFileManager {
457 setHidden(hiddenState: boolean, callback: AsyncCallback<void>): void;451 setHidden(hiddenState: boolean, callback: AsyncCallback<void>): void;
458 /**452 /**
459 * Sets this file asset to the hidden state. This API uses a promise to return the result.453 * Sets this file asset to the hidden state. This API uses a promise to return the result.
460- * 454+ *
461- * The private files set to hidden state are located in the private album (in hidden state) and are not open to 455+ * The private files set to hidden state are located in the private album (in hidden state) and are not open to
462- * third-party applications. After obtaining private files from the private album, users can set **hiddenState** to 456+ * third-party applications. After obtaining private files from the private album, users can set **hiddenState** to
463 * **false** to remove them from the private album.457 * **false** to remove them from the private album.
464 *458 *
465 * @permission ohos.permission.WRITE_IMAGEVIDEO459 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -477,7 +471,7 @@ declare namespace userFileManager {
477 setHidden(hiddenState: boolean): Promise<void>;471 setHidden(hiddenState: boolean): Promise<void>;
478 /**472 /**
479 * Sets user comment information of an image or video. This API uses an asynchronous callback to return the result.473 * Sets user comment information of an image or video. This API uses an asynchronous callback to return the result.
480- * 474+ *
481 * > **NOTE**475 * > **NOTE**
482 * >476 * >
483 * > This API can only be used to set user comment information of an image or video.477 * > This API can only be used to set user comment information of an image or video.
@@ -488,7 +482,7 @@ declare namespace userFileManager {
488 * @throws { BusinessError } 202 - Called by non-system application.482 * @throws { BusinessError } 202 - Called by non-system application.
489 * @throws { BusinessError } 401 - Parameter error. Possible causes:483 * @throws { BusinessError } 401 - Parameter error. Possible causes:
490 * <br>1. Mandatory parameters are left unspecified;484 * <br>1. Mandatory parameters are left unspecified;
491- * <br>2. Incorrect parameter types; 485+ * <br>2. Incorrect parameter types;
492 * <br>3. Parameter verification failed.486 * <br>3. Parameter verification failed.
493 * @syscap SystemCapability.FileManagement.UserFileManager.Core487 * @syscap SystemCapability.FileManagement.UserFileManager.Core
494 * @systemapi488 * @systemapi
@@ -499,7 +493,7 @@ declare namespace userFileManager {
499 setUserComment(userComment: string, callback: AsyncCallback<void>): void;493 setUserComment(userComment: string, callback: AsyncCallback<void>): void;
500 /**494 /**
501 * Sets user comment information of an image or video. This API uses a promise to return the result.495 * Sets user comment information of an image or video. This API uses a promise to return the result.
502- * 496+ *
503 * > **NOTE**497 * > **NOTE**
504 * >498 * >
505 * > This API can only be used to set user comment information of an image or video.499 * > This API can only be used to set user comment information of an image or video.
@@ -508,9 +502,9 @@ declare namespace userFileManager {
508 * @param { string } userComment - User comment information to set, which cannot exceed 140 characters.502 * @param { string } userComment - User comment information to set, which cannot exceed 140 characters.
509 * @returns { Promise<void> } Promise that returns no value.503 * @returns { Promise<void> } Promise that returns no value.
510 * @throws { BusinessError } 202 - Called by non-system application.504 * @throws { BusinessError } 202 - Called by non-system application.
511- * @throws { BusinessError } 401 - Parameter error. Possible causes: 505+ * @throws { BusinessError } 401 - Parameter error. Possible causes:
512 * <br>1. Mandatory parameters are left unspecified;506 * <br>1. Mandatory parameters are left unspecified;
513- * <br>2. Incorrect parameter types; 507+ * <br>2. Incorrect parameter types;
514 * <br>3. Parameter verification failed.508 * <br>3. Parameter verification failed.
515 * @syscap SystemCapability.FileManagement.UserFileManager.Core509 * @syscap SystemCapability.FileManagement.UserFileManager.Core
516 * @systemapi510 * @systemapi
@@ -520,11 +514,11 @@ declare namespace userFileManager {
520 */514 */
521 setUserComment(userComment: string): Promise<void>;515 setUserComment(userComment: string): Promise<void>;
522 /**516 /**
523- * Obtains the EXIF data from a JPG image and returns a JSON string. This API uses an asynchronous callback to 517+ * Obtains the EXIF data from a JPG image and returns a JSON string. This API uses an asynchronous callback to
524 * return the result.518 * return the result.
525- * 519+ *
526 * For details about the EXIF tags, see [image.PropertyKey]{@link @ohos.multimedia.image:image.PropertyKey}.520 * For details about the EXIF tags, see [image.PropertyKey]{@link @ohos.multimedia.image:image.PropertyKey}.
527- * 521+ *
528 * | Key Value | Description |522 * | Key Value | Description |
529 * | --------------------------------------- | ----------------- |523 * | --------------------------------------- | ----------------- |
530 * | BitsPerSample | Number of bits per sample.|524 * | BitsPerSample | Number of bits per sample.|
@@ -562,11 +556,11 @@ declare namespace userFileManager {
562 * | WhiteBalance | White balance.|556 * | WhiteBalance | White balance.|
563 * | FocalLengthIn35mmFilm | Focal length in 35 mm film.|557 * | FocalLengthIn35mmFilm | Focal length in 35 mm film.|
564 * | ExposureBiasValue | Exposure compensation.|558 * | ExposureBiasValue | Exposure compensation.|
565- * 559+ *
566 * > **NOTE**560 * > **NOTE**
567 * >561 * >
568- * > This API returns a JSON string that contains EXIF tags. The complete Exif information consists of all_exif and 562+ * > This API returns a JSON string that contains EXIF tags. The complete Exif information consists of all_exif and
569- * > [ImageVideoKey]{@link userFileManager.ImageVideoKey}.USER_COMMENT. The two fields need to be passed to 563+ * > [ImageVideoKey]{@link userFileManager.ImageVideoKey}.USER_COMMENT. The two fields need to be passed to
570 * > **fetchColumns**.564 * > **fetchColumns**.
571 *565 *
572 * @permission ohos.permission.READ_IMAGEVIDEO566 * @permission ohos.permission.READ_IMAGEVIDEO
@@ -581,9 +575,9 @@ declare namespace userFileManager {
581 getExif(callback: AsyncCallback<string>): void;575 getExif(callback: AsyncCallback<string>): void;
582 /**576 /**
583 * Obtains the EXIF data from a JPG image and returns a JSON string. This API uses a promise to return the result.577 * Obtains the EXIF data from a JPG image and returns a JSON string. This API uses a promise to return the result.
584- * 578+ *
585 * For details about the EXIF tags, see [image.PropertyKey]{@link @ohos.multimedia.image:image.PropertyKey}.579 * For details about the EXIF tags, see [image.PropertyKey]{@link @ohos.multimedia.image:image.PropertyKey}.
586- * 580+ *
587 * | Key Value | Description |581 * | Key Value | Description |
588 * | --------------------------------------- | ----------------- |582 * | --------------------------------------- | ----------------- |
589 * | BitsPerSample | Number of bits per sample.|583 * | BitsPerSample | Number of bits per sample.|
@@ -621,11 +615,11 @@ declare namespace userFileManager {
621 * | WhiteBalance | White balance.|615 * | WhiteBalance | White balance.|
622 * | FocalLengthIn35mmFilm | Focal length in 35 mm film.|616 * | FocalLengthIn35mmFilm | Focal length in 35 mm film.|
623 * | ExposureBiasValue | Exposure compensation.|617 * | ExposureBiasValue | Exposure compensation.|
624- * 618+ *
625 * > **NOTE**619 * > **NOTE**
626 * >620 * >
627- * > This API returns a JSON string that contains EXIF tags. The complete Exif information consists of all_exif and 621+ * > This API returns a JSON string that contains EXIF tags. The complete Exif information consists of all_exif and
628- * > [ImageVideoKey]{@link userFileManager.ImageVideoKey}.USER_COMMENT. The two fields need to be passed to 622+ * > [ImageVideoKey]{@link userFileManager.ImageVideoKey}.USER_COMMENT. The two fields need to be passed to
629 * > **fetchColumns**.623 * > **fetchColumns**.
630 *624 *
631 * @permission ohos.permission.READ_IMAGEVIDEO625 * @permission ohos.permission.READ_IMAGEVIDEO
@@ -659,7 +653,7 @@ declare namespace userFileManager {
659 * @deprecated since 26.0.0653 * @deprecated since 26.0.0
660 * @useinstead @ohos.file.picker:picker.AudioViewPicker654 * @useinstead @ohos.file.picker:picker.AudioViewPicker
661 */655 */
662- URI,656+ URI = 0,
663 /**657 /**
664 * File name displayed.658 * File name displayed.
665 *659 *
@@ -669,9 +663,9 @@ declare namespace userFileManager {
669 * @deprecated since 26.0.0663 * @deprecated since 26.0.0
670 * @useinstead @ohos.file.picker:picker.AudioViewPicker664 * @useinstead @ohos.file.picker:picker.AudioViewPicker
671 */665 */
672- DISPLAY_NAME,666+ DISPLAY_NAME = 1,
673 /**667 /**
674- * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on 668+ * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on
675 * January 1, 1970).669 * January 1, 1970).
676 *670 *
677 * @syscap SystemCapability.FileManagement.UserFileManager.Core671 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -680,9 +674,9 @@ declare namespace userFileManager {
680 * @deprecated since 26.0.0674 * @deprecated since 26.0.0
681 * @useinstead @ohos.file.picker:picker.AudioViewPicker675 * @useinstead @ohos.file.picker:picker.AudioViewPicker
682 */676 */
683- DATE_ADDED,677+ DATE_ADDED = 2,
684 /**678 /**
685- * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed 679+ * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed
686 * since the Epoch time (00:00:00 UTC on January 1, 1970).680 * since the Epoch time (00:00:00 UTC on January 1, 1970).
687 *681 *
688 * @syscap SystemCapability.FileManagement.UserFileManager.Core682 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -691,7 +685,7 @@ declare namespace userFileManager {
691 * @deprecated since 26.0.0685 * @deprecated since 26.0.0
692 * @useinstead @ohos.file.picker:picker.AudioViewPicker686 * @useinstead @ohos.file.picker:picker.AudioViewPicker
693 */687 */
694- DATE_MODIFIED,688+ DATE_MODIFIED = 3,
695 /**689 /**
696 * Title of the file.690 * Title of the file.
697 *691 *
@@ -701,7 +695,7 @@ declare namespace userFileManager {
701 * @deprecated since 26.0.0695 * @deprecated since 26.0.0
702 * @useinstead @ohos.file.picker:picker.AudioViewPicker696 * @useinstead @ohos.file.picker:picker.AudioViewPicker
703 */697 */
704- TITLE,698+ TITLE = 4,
705 /**699 /**
706 * Author of the file.700 * Author of the file.
707 *701 *
@@ -711,7 +705,7 @@ declare namespace userFileManager {
711 * @deprecated since 26.0.0705 * @deprecated since 26.0.0
712 * @useinstead @ohos.file.picker:picker.AudioViewPicker706 * @useinstead @ohos.file.picker:picker.AudioViewPicker
713 */707 */
714- ARTIST,708+ ARTIST = 5,
715 /**709 /**
716 * Audio album.710 * Audio album.
717 *711 *
@@ -721,7 +715,7 @@ declare namespace userFileManager {
721 * @deprecated since 26.0.0715 * @deprecated since 26.0.0
722 * @useinstead @ohos.file.picker:picker.AudioViewPicker716 * @useinstead @ohos.file.picker:picker.AudioViewPicker
723 */717 */
724- AUDIOALBUM,718+ AUDIOALBUM = 6,
725 /**719 /**
726 * Duration, in ms.720 * Duration, in ms.
727 *721 *
@@ -731,7 +725,7 @@ declare namespace userFileManager {
731 * @deprecated since 26.0.0725 * @deprecated since 26.0.0
732 * @useinstead @ohos.file.picker:picker.AudioViewPicker726 * @useinstead @ohos.file.picker:picker.AudioViewPicker
733 */727 */
734- DURATION,728+ DURATION = 7,
735 /**729 /**
736 * Whether the file is added to favorites.730 * Whether the file is added to favorites.
737 *731 *
@@ -741,7 +735,7 @@ declare namespace userFileManager {
741 * @deprecated since 26.0.0735 * @deprecated since 26.0.0
742 * @useinstead @ohos.file.picker:picker.AudioViewPicker736 * @useinstead @ohos.file.picker:picker.AudioViewPicker
743 */737 */
744- FAVORITE738+ FAVORITE = 8
745 }739 }
746 740 
747 /**741 /**
@@ -763,7 +757,7 @@ declare namespace userFileManager {
763 * @deprecated since 26.0.0757 * @deprecated since 26.0.0
764 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.URI758 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.URI
765 */759 */
766- URI,760+ URI = 0,
767 /**761 /**
768 * Type of the file.762 * Type of the file.
769 *763 *
@@ -773,7 +767,7 @@ declare namespace userFileManager {
773 * @deprecated since 26.0.0767 * @deprecated since 26.0.0
774 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.PHOTO_TYPE768 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.PHOTO_TYPE
775 */769 */
776- FILE_TYPE,770+ FILE_TYPE = 1,
777 /**771 /**
778 * File name displayed.772 * File name displayed.
779 *773 *
@@ -783,9 +777,9 @@ declare namespace userFileManager {
783 * @deprecated since 26.0.0777 * @deprecated since 26.0.0
784 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DISPLAY_NAME778 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DISPLAY_NAME
785 */779 */
786- DISPLAY_NAME,780+ DISPLAY_NAME = 2,
787 /**781 /**
788- * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on 782+ * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on
789 * January 1, 1970).783 * January 1, 1970).
790 *784 *
791 * @syscap SystemCapability.FileManagement.UserFileManager.Core785 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -794,9 +788,9 @@ declare namespace userFileManager {
794 * @deprecated since 26.0.0788 * @deprecated since 26.0.0
795 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_ADDED789 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_ADDED
796 */790 */
797- DATE_ADDED,791+ DATE_ADDED = 3,
798 /**792 /**
799- * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed 793+ * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed
800 * since the Epoch time (00:00:00 UTC on January 1, 1970).794 * since the Epoch time (00:00:00 UTC on January 1, 1970).
801 *795 *
802 * @syscap SystemCapability.FileManagement.UserFileManager.Core796 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -805,7 +799,7 @@ declare namespace userFileManager {
805 * @deprecated since 26.0.0799 * @deprecated since 26.0.0
806 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys#DATE_MODIFIED800 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys#DATE_MODIFIED
807 */801 */
808- DATE_MODIFIED,802+ DATE_MODIFIED = 4,
809 /**803 /**
810 * Title of the file.804 * Title of the file.
811 *805 *
@@ -815,7 +809,7 @@ declare namespace userFileManager {
815 * @deprecated since 26.0.0809 * @deprecated since 26.0.0
816 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.TITLE810 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.TITLE
817 */811 */
818- TITLE,812+ TITLE = 5,
819 /**813 /**
820 * Duration, in ms.814 * Duration, in ms.
821 *815 *
@@ -825,7 +819,7 @@ declare namespace userFileManager {
825 * @deprecated since 26.0.0819 * @deprecated since 26.0.0
826 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DURATION820 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DURATION
827 */821 */
828- DURATION,822+ DURATION = 6,
829 /**823 /**
830 * Image width, in pixels.824 * Image width, in pixels.
831 *825 *
@@ -835,7 +829,7 @@ declare namespace userFileManager {
835 * @deprecated since 26.0.0829 * @deprecated since 26.0.0
836 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.WIDTH830 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.WIDTH
837 */831 */
838- WIDTH,832+ WIDTH = 7,
839 /**833 /**
840 * Image height, in pixels.834 * Image height, in pixels.
841 *835 *
@@ -845,9 +839,9 @@ declare namespace userFileManager {
845 * @deprecated since 26.0.0839 * @deprecated since 26.0.0
846 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.HEIGHT840 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.HEIGHT
847 */841 */
848- HEIGHT,842+ HEIGHT = 8,
849 /**843 /**
850- * Date when the file (photo) was taken. The value is the number of seconds elapsed since the Epoch time (00:00:00 844+ * Date when the file (photo) was taken. The value is the number of seconds elapsed since the Epoch time (00:00:00
851 * UTC on January 1, 1970).845 * UTC on January 1, 1970).
852 *846 *
853 * @syscap SystemCapability.FileManagement.UserFileManager.Core847 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -856,7 +850,7 @@ declare namespace userFileManager {
856 * @deprecated since 26.0.0850 * @deprecated since 26.0.0
857 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_TAKEN851 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_TAKEN
858 */852 */
859- DATE_TAKEN,853+ DATE_TAKEN = 9,
860 /**854 /**
861 * Orientation of the image file.855 * Orientation of the image file.
862 *856 *
@@ -866,7 +860,7 @@ declare namespace userFileManager {
866 * @deprecated since 26.0.0860 * @deprecated since 26.0.0
867 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.ORIENTATION861 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.ORIENTATION
868 */862 */
869- ORIENTATION,863+ ORIENTATION = 10,
870 /**864 /**
871 * Whether the file is added to favorites.865 * Whether the file is added to favorites.
872 *866 *
@@ -876,7 +870,7 @@ declare namespace userFileManager {
876 * @deprecated since 26.0.0870 * @deprecated since 26.0.0
877 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.FAVORITE871 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.FAVORITE
878 */872 */
879- FAVORITE,873+ FAVORITE = 11,
880 /**874 /**
881 * File location type.875 * File location type.
882 *876 *
@@ -886,9 +880,9 @@ declare namespace userFileManager {
886 * @deprecated since 26.0.0880 * @deprecated since 26.0.0
887 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.POSITION881 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.POSITION
888 */882 */
889- POSITION,883+ POSITION = 12,
890 /**884 /**
891- * Date when the file was deleted. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on 885+ * Date when the file was deleted. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on
892 * January 1, 1970).886 * January 1, 1970).
893 *887 *
894 * @syscap SystemCapability.FileManagement.UserFileManager.Core888 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -897,7 +891,7 @@ declare namespace userFileManager {
897 * @deprecated since 26.0.0891 * @deprecated since 26.0.0
898 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_TRASHED892 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.DATE_TRASHED
899 */893 */
900- DATE_TRASHED,894+ DATE_TRASHED = 13,
901 /**895 /**
902 * Whether the file is hidden.896 * Whether the file is hidden.
903 *897 *
@@ -907,7 +901,7 @@ declare namespace userFileManager {
907 * @deprecated since 26.0.0901 * @deprecated since 26.0.0
908 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.HIDDEN902 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.HIDDEN
909 */903 */
910- HIDDEN,904+ HIDDEN = 14,
911 /**905 /**
912 * User comment information.906 * User comment information.
913 *907 *
@@ -917,10 +911,10 @@ declare namespace userFileManager {
917 * @deprecated since 26.0.0911 * @deprecated since 26.0.0
918 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.USER_COMMENT912 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.USER_COMMENT
919 */913 */
920- USER_COMMENT,914+ USER_COMMENT = 15,
921 /**915 /**
922 * Key for the Ultra Snapshot feature.916 * Key for the Ultra Snapshot feature.
923- * 917+ *
924 * This parameter is available only for the system camera, and the key value is defined by the system camera.918 * This parameter is available only for the system camera, and the key value is defined by the system camera.
925 *919 *
926 * @syscap SystemCapability.FileManagement.UserFileManager.Core920 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -929,7 +923,7 @@ declare namespace userFileManager {
929 * @deprecated since 26.0.0923 * @deprecated since 26.0.0
930 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.CAMERA_SHOT_KEY924 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.PhotoKeys.CAMERA_SHOT_KEY
931 */925 */
932- CAMERA_SHOT_KEY926+ CAMERA_SHOT_KEY = 16
933 }927 }
934 928 
935 /**929 /**
@@ -951,7 +945,7 @@ declare namespace userFileManager {
951 * @deprecated since 26.0.0945 * @deprecated since 26.0.0
952 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.URI946 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.URI
953 */947 */
954- URI,948+ URI = 0,
955 /**949 /**
956 * Type of the file.950 * Type of the file.
957 *951 *
@@ -961,7 +955,7 @@ declare namespace userFileManager {
961 * @deprecated since 26.0.0955 * @deprecated since 26.0.0
962 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumType956 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumType
963 */957 */
964- FILE_TYPE,958+ FILE_TYPE = 1,
965 /**959 /**
966 * Name of the album.960 * Name of the album.
967 *961 *
@@ -971,9 +965,9 @@ declare namespace userFileManager {
971 * @deprecated since 26.0.0965 * @deprecated since 26.0.0
972 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.ALBUM_NAME966 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.ALBUM_NAME
973 */967 */
974- ALBUM_NAME,968+ ALBUM_NAME = 2,
975 /**969 /**
976- * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on 970+ * Date when the file was added. The value is the number of seconds elapsed since the Epoch time (00:00:00 UTC on
977 * January 1, 1970).971 * January 1, 1970).
978 *972 *
979 * @syscap SystemCapability.FileManagement.UserFileManager.Core973 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -982,9 +976,9 @@ declare namespace userFileManager {
982 * @deprecated since 26.0.0976 * @deprecated since 26.0.0
983 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.DATE_MODIFIED977 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.DATE_MODIFIED
984 */978 */
985- DATE_ADDED,979+ DATE_ADDED = 3,
986 /**980 /**
987- * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed 981+ * Date when the file content (not the file name) was last modified. The value is the number of seconds elapsed
988 * since the Epoch time (00:00:00 UTC on January 1, 1970).982 * since the Epoch time (00:00:00 UTC on January 1, 1970).
989 *983 *
990 * @syscap SystemCapability.FileManagement.UserFileManager.Core984 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -993,7 +987,7 @@ declare namespace userFileManager {
993 * @deprecated since 26.0.0987 * @deprecated since 26.0.0
994 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.DATE_MODIFIED988 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumKeys.DATE_MODIFIED
995 */989 */
996- DATE_MODIFIED990+ DATE_MODIFIED = 4
997 }991 }
998 992 
999 /**993 /**
@@ -1008,11 +1002,11 @@ declare namespace userFileManager {
1008 interface FetchOptions {1002 interface FetchOptions {
1009 /**1003 /**
1010 * Options for fetching files based on the attributes in columns. If this parameter is left empty, files are fetched1004 * Options for fetching files based on the attributes in columns. If this parameter is left empty, files are fetched
1011- * by URI, name, and type (the specific field names vary with the file asset or album object) by default. In 1005+ * by URI, name, and type (the specific field names vary with the file asset or album object) by default. In
1012- * addition, an error will be reported if 1006+ * addition, an error will be reported if
1013 * [get]{@link userFileManager.UserFileManager.getPhotoAssets(options: FetchOptions, callback: AsyncCallback<FetchResult<FileAsset>>)}1007 * [get]{@link userFileManager.UserFileManager.getPhotoAssets(options: FetchOptions, callback: AsyncCallback<FetchResult<FileAsset>>)}
1014 * is called to obtain other attributes of this object. Example:1008 * is called to obtain other attributes of this object. Example:
1015- * 1009+ *
1016 * fetchColumns: ['uri', 'title']1010 * fetchColumns: ['uri', 'title']
1017 *1011 *
1018 * @syscap SystemCapability.FileManagement.UserFileManager.Core1012 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -1078,7 +1072,7 @@ declare namespace userFileManager {
1078 subType?: PhotoSubType;1072 subType?: PhotoSubType;
1079 /**1073 /**
1080 * Key for the Ultra Snapshot feature.1074 * Key for the Ultra Snapshot feature.
1081- * 1075+ *
1082 * This parameter is available only for the system camera, and the key value is defined by the system camera.1076 * This parameter is available only for the system camera, and the key value is defined by the system camera.
1083 *1077 *
1084 * @syscap SystemCapability.FileManagement.UserFileManager.Core1078 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -1124,7 +1118,7 @@ declare namespace userFileManager {
1124 */1118 */
1125 isAfterLast(): boolean;1119 isAfterLast(): boolean;
1126 /**1120 /**
1127- * Releases and invalidates the **FetchFileResult** instance. After this instance is released, the APIs in this 1121+ * Releases and invalidates the **FetchFileResult** instance. After this instance is released, the APIs in this
1128 * instance cannot be invoked.1122 * instance cannot be invoked.
1129 *1123 *
1130 * @syscap SystemCapability.FileManagement.UserFileManager.Core1124 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -1158,8 +1152,8 @@ declare namespace userFileManager {
1158 getFirstObject(): Promise<T>;1152 getFirstObject(): Promise<T>;
1159 /**1153 /**
1160 * Obtains the next file asset in the result set. This API uses an asynchronous callback to return the result.1154 * Obtains the next file asset in the result set. This API uses an asynchronous callback to return the result.
1161- * 1155+ *
1162- * Before using this API, you must use [isAfterLast()]{@link userFileManager.FetchResult.isAfterLast} to check 1156+ * Before using this API, you must use [isAfterLast()]{@link userFileManager.FetchResult.isAfterLast} to check
1163 * whether the current position is the end of the result set.1157 * whether the current position is the end of the result set.
1164 *1158 *
1165 * @param { AsyncCallback<T> } callback - Callback used to return the next file asset.1159 * @param { AsyncCallback<T> } callback - Callback used to return the next file asset.
@@ -1172,8 +1166,8 @@ declare namespace userFileManager {
1172 getNextObject(callback: AsyncCallback<T>): void;1166 getNextObject(callback: AsyncCallback<T>): void;
1173 /**1167 /**
1174 * Obtains the next file asset in the result set. This API uses a promise to return the result.1168 * Obtains the next file asset in the result set. This API uses a promise to return the result.
1175- * 1169+ *
1176- * Before using this API, you must use [isAfterLast()]{@link userFileManager.FetchResult.isAfterLast} to check 1170+ * Before using this API, you must use [isAfterLast()]{@link userFileManager.FetchResult.isAfterLast} to check
1177 * whether the current position is the end of the result set.1171 * whether the current position is the end of the result set.
1178 *1172 *
1179 * @returns { Promise<T> } Promise that returns the next object in the result set.1173 * @returns { Promise<T> } Promise that returns the next object in the result set.
@@ -1329,7 +1323,7 @@ declare namespace userFileManager {
1329 * @deprecated since 26.0.01323 * @deprecated since 26.0.0
1330 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.VIDEO1324 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.VIDEO
1331 */1325 */
1332- VIDEO,1326+ VIDEO = 1026,
1333 /**1327 /**
1334 * Hidden album.1328 * Hidden album.
1335 *1329 *
@@ -1339,7 +1333,7 @@ declare namespace userFileManager {
1339 * @deprecated since 26.0.01333 * @deprecated since 26.0.0
1340 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.HIDDEN1334 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.HIDDEN
1341 */1335 */
1342- HIDDEN,1336+ HIDDEN = 1027,
1343 /**1337 /**
1344 * Trash.1338 * Trash.
1345 *1339 *
@@ -1349,7 +1343,7 @@ declare namespace userFileManager {
1349 * @deprecated since 26.0.01343 * @deprecated since 26.0.0
1350 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.TRASH1344 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.TRASH
1351 */1345 */
1352- TRASH,1346+ TRASH = 1028,
1353 /**1347 /**
1354 * Album for screenshots and screen recording files.1348 * Album for screenshots and screen recording files.
1355 *1349 *
@@ -1359,7 +1353,7 @@ declare namespace userFileManager {
1359 * @deprecated since 26.0.01353 * @deprecated since 26.0.0
1360 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.SCREENSHOT1354 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.SCREENSHOT
1361 */1355 */
1362- SCREENSHOT,1356+ SCREENSHOT = 1029,
1363 /**1357 /**
1364 * Album for photos and videos taken by the camera.1358 * Album for photos and videos taken by the camera.
1365 *1359 *
@@ -1369,7 +1363,7 @@ declare namespace userFileManager {
1369 * @deprecated since 26.0.01363 * @deprecated since 26.0.0
1370 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.CAMERA1364 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.CAMERA
1371 */1365 */
1372- CAMERA,1366+ CAMERA = 1030,
1373 /**1367 /**
1374 * Any album.1368 * Any album.
1375 *1369 *
@@ -1414,10 +1408,10 @@ declare namespace userFileManager {
1414 readonly albumSubType: AlbumSubType;1408 readonly albumSubType: AlbumSubType;
1415 /**1409 /**
1416 * Name of the album.1410 * Name of the album.
1417- * 1411+ *
1418 * > **NOTE**1412 * > **NOTE**
1419 * >1413 * >
1420- * > The user album is writable, but the system album is not writable. 1414+ * > The user album is writable, but the system album is not writable.
1421 *1415 *
1422 * @syscap SystemCapability.FileManagement.UserFileManager.Core1416 * @syscap SystemCapability.FileManagement.UserFileManager.Core
1423 * @systemapi1417 * @systemapi
@@ -1459,7 +1453,7 @@ declare namespace userFileManager {
1459 readonly count: number;1453 readonly count: number;
1460 /**1454 /**
1461 * URI of the cover file of the album.1455 * URI of the cover file of the album.
1462- * 1456+ *
1463 * > **NOTE**1457 * > **NOTE**
1464 * >1458 * >
1465 * > The user album is writable, but the system album is not writable.1459 * > The user album is writable, but the system album is not writable.
@@ -1513,7 +1507,7 @@ declare namespace userFileManager {
1513 */1507 */
1514 interface Album extends AbsAlbum {1508 interface Album extends AbsAlbum {
1515 /**1509 /**
1516- * Commits the modification on the album attributes to the database. This API uses an asynchronous callback to 1510+ * Commits the modification on the album attributes to the database. This API uses an asynchronous callback to
1517 * return the result.1511 * return the result.
1518 *1512 *
1519 * @permission ohos.permission.WRITE_IMAGEVIDEO1513 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1538,7 +1532,7 @@ declare namespace userFileManager {
1538 */1532 */
1539 commitModify(): Promise<void>;1533 commitModify(): Promise<void>;
1540 /**1534 /**
1541- * Adds image and video assets to an album. Before the operation, ensure that the image and video assets to add and 1535+ * Adds image and video assets to an album. Before the operation, ensure that the image and video assets to add and
1542 * the album exist. This API uses an asynchronous callback to return the result.1536 * the album exist. This API uses an asynchronous callback to return the result.
1543 *1537 *
1544 * @permission ohos.permission.WRITE_IMAGEVIDEO1538 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1553,7 +1547,7 @@ declare namespace userFileManager {
1553 */1547 */
1554 addPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;1548 addPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;
1555 /**1549 /**
1556- * Adds image and video assets to an album. Before the operation, ensure that the image and video assets to add and 1550+ * Adds image and video assets to an album. Before the operation, ensure that the image and video assets to add and
1557 * the album exist. This API uses a promise to return the result.1551 * the album exist. This API uses a promise to return the result.
1558 *1552 *
1559 * @permission ohos.permission.WRITE_IMAGEVIDEO1553 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1568,7 +1562,7 @@ declare namespace userFileManager {
1568 */1562 */
1569 addPhotoAssets(assets: Array<FileAsset>): Promise<void>;1563 addPhotoAssets(assets: Array<FileAsset>): Promise<void>;
1570 /**1564 /**
1571- * Removes image and video assets from an album. The album and file resources must exist. This API uses an 1565+ * Removes image and video assets from an album. The album and file resources must exist. This API uses an
1572 * asynchronous callback to return the result.1566 * asynchronous callback to return the result.
1573 *1567 *
1574 * @permission ohos.permission.WRITE_IMAGEVIDEO1568 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1598,7 +1592,7 @@ declare namespace userFileManager {
1598 */1592 */
1599 removePhotoAssets(assets: Array<FileAsset>): Promise<void>;1593 removePhotoAssets(assets: Array<FileAsset>): Promise<void>;
1600 /**1594 /**
1601- * Recovers image or video assets from the recycle bin. Before the operation, ensure that the image or video assets 1595+ * Recovers image or video assets from the recycle bin. Before the operation, ensure that the image or video assets
1602 * exist in the recycle bin. This API uses an asynchronous callback to return the result.1596 * exist in the recycle bin. This API uses an asynchronous callback to return the result.
1603 *1597 *
1604 * @permission ohos.permission.WRITE_IMAGEVIDEO1598 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1613,7 +1607,7 @@ declare namespace userFileManager {
1613 */1607 */
1614 recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;1608 recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;
1615 /**1609 /**
1616- * Recovers image or video assets from the recycle bin. Before the operation, ensure that the image or video assets 1610+ * Recovers image or video assets from the recycle bin. Before the operation, ensure that the image or video assets
1617 * exist in the recycle bin. This API uses a promise to return the result.1611 * exist in the recycle bin. This API uses a promise to return the result.
1618 *1612 *
1619 * @permission ohos.permission.WRITE_IMAGEVIDEO1613 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1628,12 +1622,12 @@ declare namespace userFileManager {
1628 */1622 */
1629 recoverPhotoAssets(assets: Array<FileAsset>): Promise<void>;1623 recoverPhotoAssets(assets: Array<FileAsset>): Promise<void>;
1630 /**1624 /**
1631- * Deletes image or video assets from the recycle bin. Before the operation, ensure that the image or video assets 1625+ * Deletes image or video assets from the recycle bin. Before the operation, ensure that the image or video assets
1632 * exist in the recycle bin. This API uses an asynchronous callback to return the result.1626 * exist in the recycle bin. This API uses an asynchronous callback to return the result.
1633- * 1627+ *
1634 * > **NOTE**1628 * > **NOTE**
1635 * >1629 * >
1636- * > This operation is irreversible. The assets deleted cannot be restored. Exercise caution when performing this 1630+ * > This operation is irreversible. The assets deleted cannot be restored. Exercise caution when performing this
1637 * > operation.1631 * > operation.
1638 *1632 *
1639 * @permission ohos.permission.WRITE_IMAGEVIDEO1633 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1648,12 +1642,12 @@ declare namespace userFileManager {
1648 */1642 */
1649 deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;1643 deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>): void;
1650 /**1644 /**
1651- * Deletes image or video assets from the recycle bin. Before the operation, ensure that the image or video assets 1645+ * Deletes image or video assets from the recycle bin. Before the operation, ensure that the image or video assets
1652 * exist in the recycle bin. This API uses a promise to return the result.1646 * exist in the recycle bin. This API uses a promise to return the result.
1653- * 1647+ *
1654 * > **NOTE**1648 * > **NOTE**
1655 * >1649 * >
1656- * > This operation is irreversible. The assets deleted cannot be restored. Exercise caution when performing this 1650+ * > This operation is irreversible. The assets deleted cannot be restored. Exercise caution when performing this
1657 * > operation.1651 * > operation.
1658 *1652 *
1659 * @permission ohos.permission.WRITE_IMAGEVIDEO1653 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1709,7 +1703,7 @@ declare namespace userFileManager {
1709 */1703 */
1710 getPhotoAssets(options: FetchOptions): Promise<FetchResult<FileAsset>>;1704 getPhotoAssets(options: FetchOptions): Promise<FetchResult<FileAsset>>;
1711 /**1705 /**
1712- * Creates an image or video asset with the specified file name and URI. This API uses an asynchronous callback to 1706+ * Creates an image or video asset with the specified file name and URI. This API uses an asynchronous callback to
1713 * return the result.1707 * return the result.
1714 *1708 *
1715 * @permission ohos.permission.WRITE_IMAGEVIDEO1709 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1726,7 +1720,7 @@ declare namespace userFileManager {
1726 */1720 */
1727 createPhotoAsset(displayName: string, albumUri: string, callback: AsyncCallback<FileAsset>): void;1721 createPhotoAsset(displayName: string, albumUri: string, callback: AsyncCallback<FileAsset>): void;
1728 /**1722 /**
1729- * Creates an image or video asset with the specified file name. This API uses an asynchronous callback to return 1723+ * Creates an image or video asset with the specified file name. This API uses an asynchronous callback to return
1730 * the result.1724 * the result.
1731 *1725 *
1732 * @permission ohos.permission.WRITE_IMAGEVIDEO1726 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1758,7 +1752,7 @@ declare namespace userFileManager {
1758 */1752 */
1759 createPhotoAsset(displayName: string, albumUri?: string): Promise<FileAsset>;1753 createPhotoAsset(displayName: string, albumUri?: string): Promise<FileAsset>;
1760 /**1754 /**
1761- * Creates an image or video asset with the specified file name and options. This API uses a promise to return the 1755+ * Creates an image or video asset with the specified file name and options. This API uses a promise to return the
1762 * result.1756 * result.
1763 *1757 *
1764 * @permission ohos.permission.WRITE_IMAGEVIDEO1758 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1774,7 +1768,7 @@ declare namespace userFileManager {
1774 */1768 */
1775 createPhotoAsset(displayName: string, createOption: PhotoCreateOptions): Promise<FileAsset>;1769 createPhotoAsset(displayName: string, createOption: PhotoCreateOptions): Promise<FileAsset>;
1776 /**1770 /**
1777- * Creates an image or video asset with the specified file name and options. This API uses an asynchronous callback 1771+ * Creates an image or video asset with the specified file name and options. This API uses an asynchronous callback
1778 * to return the result.1772 * to return the result.
1779 *1773 *
1780 * @permission ohos.permission.WRITE_IMAGEVIDEO1774 * @permission ohos.permission.WRITE_IMAGEVIDEO
@@ -1820,12 +1814,12 @@ declare namespace userFileManager {
1820 createAudioAsset(displayName: string): Promise<FileAsset>;1814 createAudioAsset(displayName: string): Promise<FileAsset>;
1821 /**1815 /**
1822 * Obtains image and video albums. This API uses an asynchronous callback to return the result.1816 * Obtains image and video albums. This API uses an asynchronous callback to return the result.
1823- * 1817+ *
1824- * This API cannot be used to obtain hidden albums. Use 1818+ * This API cannot be used to obtain hidden albums. Use
1825 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}1819 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}
1826 * to obtain hidden albums.1820 * to obtain hidden albums.
1827- * 1821+ *
1828- * This API will be deprecated. Use 1822+ * This API will be deprecated. Use
1829 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}1823 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}
1830 * instead.1824 * instead.
1831 *1825 *
@@ -1842,12 +1836,12 @@ declare namespace userFileManager {
1842 getPhotoAlbums(options: AlbumFetchOptions, callback: AsyncCallback<FetchResult<Album>>): void;1836 getPhotoAlbums(options: AlbumFetchOptions, callback: AsyncCallback<FetchResult<Album>>): void;
1843 /**1837 /**
1844 * Obtains albums. This API uses a promise to return the result.1838 * Obtains albums. This API uses a promise to return the result.
1845- * 1839+ *
1846- * This API cannot be used to obtain hidden albums. Use 1840+ * This API cannot be used to obtain hidden albums. Use
1847 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}1841 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}
1848 * to obtain hidden albums.1842 * to obtain hidden albums.
1849- * 1843+ *
1850- * This API will be deprecated. Use 1844+ * This API will be deprecated. Use
1851 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}1845 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}
1852 * instead.1846 * instead.
1853 *1847 *
@@ -1864,14 +1858,14 @@ declare namespace userFileManager {
1864 getPhotoAlbums(options: AlbumFetchOptions): Promise<FetchResult<Album>>;1858 getPhotoAlbums(options: AlbumFetchOptions): Promise<FetchResult<Album>>;
1865 /**1859 /**
1866 * Creates an album. This API uses an asynchronous callback to return the result.1860 * Creates an album. This API uses an asynchronous callback to return the result.
1867- * 1861+ *
1868 * The album name must meet the following requirements:1862 * The album name must meet the following requirements:
1869- * 1863+ *
1870 * - The album name is a string of 1 to 255 characters.1864 * - The album name is a string of 1 to 255 characters.
1871 * - The album name cannot contain any of the following characters:1865 * - The album name cannot contain any of the following characters:
1872- * 1866+ *
1873 * . .. \ / : * ? " ' ` < > | { } [ ]1867 * . .. \ / : * ? " ' ` < > | { } [ ]
1874- * 1868+ *
1875 * - The album name is case-insensitive.1869 * - The album name is case-insensitive.
1876 * - Duplicate album names are not allowed.1870 * - Duplicate album names are not allowed.
1877 *1871 *
@@ -1887,14 +1881,14 @@ declare namespace userFileManager {
1887 createAlbum(name: string, callback: AsyncCallback<Album>): void;1881 createAlbum(name: string, callback: AsyncCallback<Album>): void;
1888 /**1882 /**
1889 * Creates an album. This API uses a promise to return the result.1883 * Creates an album. This API uses a promise to return the result.
1890- * 1884+ *
1891 * The album name must meet the following requirements:1885 * The album name must meet the following requirements:
1892- * 1886+ *
1893 * - The album name is a string of 1 to 255 characters.1887 * - The album name is a string of 1 to 255 characters.
1894 * - The album name cannot contain any of the following characters:1888 * - The album name cannot contain any of the following characters:
1895- * 1889+ *
1896 * . .. \ / : * ? " ' ` < > | { } [ ]1890 * . .. \ / : * ? " ' ` < > | { } [ ]
1897- * 1891+ *
1898 * - The album name is case-insensitive.1892 * - The album name is case-insensitive.
1899 * - Duplicate album names are not allowed.1893 * - Duplicate album names are not allowed.
1900 *1894 *
@@ -1935,13 +1929,13 @@ declare namespace userFileManager {
1935 */1929 */
1936 deleteAlbums(albums: Array<Album>): Promise<void>;1930 deleteAlbums(albums: Array<Album>): Promise<void>;
1937 /**1931 /**
1938- * Obtains albums based on the specified options and album type. This API uses an asynchronous callback to return 1932+ * Obtains albums based on the specified options and album type. This API uses an asynchronous callback to return
1939 * the result.1933 * the result.
1940- * 1934+ *
1941- * This API cannot be used to obtain hidden albums. Use 1935+ * This API cannot be used to obtain hidden albums. Use
1942 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}1936 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}
1943 * to obtain hidden albums.1937 * to obtain hidden albums.
1944- * 1938+ *
1945 * Before the operation, ensure that the albums to obtain exist.1939 * Before the operation, ensure that the albums to obtain exist.
1946 *1940 *
1947 * @permission ohos.permission.READ_IMAGEVIDEO1941 * @permission ohos.permission.READ_IMAGEVIDEO
@@ -1964,11 +1958,11 @@ declare namespace userFileManager {
1964 ): void;1958 ): void;
1965 /**1959 /**
1966 * Obtains albums by type. This API uses an asynchronous callback to return the result.1960 * Obtains albums by type. This API uses an asynchronous callback to return the result.
1967- * 1961+ *
1968- * This API cannot be used to obtain hidden albums. Use 1962+ * This API cannot be used to obtain hidden albums. Use
1969 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}1963 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}
1970 * to obtain hidden albums.1964 * to obtain hidden albums.
1971- * 1965+ *
1972 * Before the operation, ensure that the albums to obtain exist.1966 * Before the operation, ensure that the albums to obtain exist.
1973 *1967 *
1974 * @permission ohos.permission.READ_IMAGEVIDEO1968 * @permission ohos.permission.READ_IMAGEVIDEO
@@ -1985,11 +1979,11 @@ declare namespace userFileManager {
1985 getAlbums(type: AlbumType, subType: AlbumSubType, callback: AsyncCallback<FetchResult<Album>>): void;1979 getAlbums(type: AlbumType, subType: AlbumSubType, callback: AsyncCallback<FetchResult<Album>>): void;
1986 /**1980 /**
1987 * Obtains albums based on the specified options and album type. This API uses a promise to return the result.1981 * Obtains albums based on the specified options and album type. This API uses a promise to return the result.
1988- * 1982+ *
1989- * This API cannot be used to obtain hidden albums. Use 1983+ * This API cannot be used to obtain hidden albums. Use
1990 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}1984 * [getHiddenAlbums]{@link @ohos.file.photoAccessHelper:photoAccessHelper.PhotoAccessHelper.getHiddenAlbums(mode: HiddenPhotosDisplayMode, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>>)}
1991 * to obtain hidden albums.1985 * to obtain hidden albums.
1992- * 1986+ *
1993 * Before the operation, ensure that the albums to obtain exist.1987 * Before the operation, ensure that the albums to obtain exist.
1994 *1988 *
1995 * @permission ohos.permission.READ_IMAGEVIDEO1989 * @permission ohos.permission.READ_IMAGEVIDEO
@@ -2008,8 +2002,8 @@ declare namespace userFileManager {
2008 getAlbums(type: AlbumType, subType: AlbumSubType, options?: FetchOptions): Promise<FetchResult<Album>>;2002 getAlbums(type: AlbumType, subType: AlbumSubType, options?: FetchOptions): Promise<FetchResult<Album>>;
2009 /**2003 /**
2010 * Obtains the system album. This API uses an asynchronous callback to return the result.2004 * Obtains the system album. This API uses an asynchronous callback to return the result.
2011- * 2005+ *
2012- * This API will be deprecated. Use 2006+ * This API will be deprecated. Use
2013 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}2007 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}
2014 * instead.2008 * instead.
2015 *2009 *
@@ -2026,8 +2020,8 @@ declare namespace userFileManager {
2026 getPrivateAlbum(type: PrivateAlbumType, callback: AsyncCallback<FetchResult<PrivateAlbum>>): void;2020 getPrivateAlbum(type: PrivateAlbumType, callback: AsyncCallback<FetchResult<PrivateAlbum>>): void;
2027 /**2021 /**
2028 * Obtains the private album. This API uses a promise to return the result.2022 * Obtains the private album. This API uses a promise to return the result.
2029- * 2023+ *
2030- * This API will be deprecated. Use 2024+ * This API will be deprecated. Use
2031 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}2025 * [getAlbums]{@link userFileManager.UserFileManager.getAlbums( type: AlbumType, subType: AlbumSubType, options: FetchOptions, callback: AsyncCallback<FetchResult<Album>> )}
2032 * instead.2026 * instead.
2033 *2027 *
@@ -2071,7 +2065,7 @@ declare namespace userFileManager {
2071 */2065 */
2072 getAudioAssets(options: FetchOptions): Promise<FetchResult<FileAsset>>;2066 getAudioAssets(options: FetchOptions): Promise<FetchResult<FileAsset>>;
2073 /**2067 /**
2074- * Deletes a media file. This API uses an asynchronous callback to return the result. The deleted file is moved to 2068+ * Deletes a media file. This API uses an asynchronous callback to return the result. The deleted file is moved to
2075 * the recycle bin. This API uses an asynchronous callback to return the result.2069 * the recycle bin. This API uses an asynchronous callback to return the result.
2076 *2070 *
2077 * @permission ohos.permission.READ_IMAGEVIDEO and ohos.permission.WRITE_IMAGEVIDEO or ohos.permission.READ_AUDIO2071 * @permission ohos.permission.READ_IMAGEVIDEO and ohos.permission.WRITE_IMAGEVIDEO or ohos.permission.READ_AUDIO
@@ -2114,7 +2108,7 @@ declare namespace userFileManager {
2114 * @param { AsyncCallback<number> } callback - Callback used to return the index obtained.2108 * @param { AsyncCallback<number> } callback - Callback used to return the index obtained.
2115 * @throws { BusinessError } 401 - Parameter error. Possible causes:2109 * @throws { BusinessError } 401 - Parameter error. Possible causes:
2116 * <br>1. Mandatory parameters are left unspecified;2110 * <br>1. Mandatory parameters are left unspecified;
2117- * <br>2. Incorrect parameter types; 2111+ * <br>2. Incorrect parameter types;
2118 * <br>3. Parameter verification failed.2112 * <br>3. Parameter verification failed.
2119 * @syscap SystemCapability.FileManagement.UserFileManager.Core2113 * @syscap SystemCapability.FileManagement.UserFileManager.Core
2120 * @systemapi2114 * @systemapi
@@ -2136,7 +2130,7 @@ declare namespace userFileManager {
2136 * @returns { Promise<number> } Promise that returns the index obtained.2130 * @returns { Promise<number> } Promise that returns the index obtained.
2137 * @throws { BusinessError } 401 - Parameter error. Possible causes:2131 * @throws { BusinessError } 401 - Parameter error. Possible causes:
2138 * <br>1. Mandatory parameters are left unspecified;2132 * <br>1. Mandatory parameters are left unspecified;
2139- * <br>2. Incorrect parameter types; 2133+ * <br>2. Incorrect parameter types;
2140 * <br>3. Parameter verification failed.2134 * <br>3. Parameter verification failed.
2141 * @syscap SystemCapability.FileManagement.UserFileManager.Core2135 * @syscap SystemCapability.FileManagement.UserFileManager.Core
2142 * @systemapi2136 * @systemapi
@@ -2147,8 +2141,8 @@ declare namespace userFileManager {
2147 getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions): Promise<number>;2141 getPhotoIndex(photoUri: string, albumUri: string, options: FetchOptions): Promise<number>;
2148 /**2142 /**
2149 * Subscribes to changes of the file management library. This API uses a callback to return the result.2143 * Subscribes to changes of the file management library. This API uses a callback to return the result.
2150- * 2144+ *
2151- * This API will be deprecated. Use 2145+ * This API will be deprecated. Use
2152 * [on]{@link userFileManager.UserFileManager.on(uri: string, forSubUri: boolean, callback: Callback<ChangeData>)}2146 * [on]{@link userFileManager.UserFileManager.on(uri: string, forSubUri: boolean, callback: Callback<ChangeData>)}
2153 * instead.2147 * instead.
2154 *2148 *
@@ -2169,9 +2163,9 @@ declare namespace userFileManager {
2169 on(type: ChangeEvent, callback: Callback<void>): void;2163 on(type: ChangeEvent, callback: Callback<void>): void;
2170 /**2164 /**
2171 * Unsubscribes from changes of the file management library. This API uses a callback to return the result.2165 * Unsubscribes from changes of the file management library. This API uses a callback to return the result.
2172- * 2166+ *
2173- * This API will be deprecated. Use 2167+ * This API will be deprecated. Use
2174- * [off]{@link userFileManager.UserFileManager.off(uri: string, callback?: Callback<ChangeData>)} 2168+ * [off]{@link userFileManager.UserFileManager.off(uri: string, callback?: Callback<ChangeData>)}
2175 * instead.2169 * instead.
2176 *2170 *
2177 * @param { ChangeEvent } type - Type of event to subscribe to.2171 * @param { ChangeEvent } type - Type of event to subscribe to.
@@ -2194,14 +2188,14 @@ declare namespace userFileManager {
2194 *2188 *
2195 * @param { string } uri - URI of the file asset or album, or2189 * @param { string } uri - URI of the file asset or album, or
2196 * [DefaultChangeUri]{@link userFileManager.DefaultChangeUri}.2190 * [DefaultChangeUri]{@link userFileManager.DefaultChangeUri}.
2197- * @param { boolean } forSubUri - Whether to perform fuzzy listening. 2191+ * @param { boolean } forSubUri - Whether to perform fuzzy listening.
2198 * <br>If **uri** is the URI of the album, the2192 * <br>If **uri** is the URI of the album, the
2199 * value **true** means to listen for the file change in the album; the value **false** means to listen for the2193 * value **true** means to listen for the file change in the album; the value **false** means to listen for the
2200 * album change only. If **uri** is the URI of the file asset, there is no difference whether **forSubUri** is2194 * album change only. If **uri** is the URI of the file asset, there is no difference whether **forSubUri** is
2201 * **true** or **false**. If **uri** is **DefaultChangeUri**, the value must be **true**, otherwise, the URI2195 * **true** or **false**. If **uri** is **DefaultChangeUri**, the value must be **true**, otherwise, the URI
2202 * cannot be found and no message can be received.2196 * cannot be found and no message can be received.
2203 * @param { Callback<ChangeData> } callback - Callback used to return [ChangeData]{@link userFileManager.ChangeData}2197 * @param { Callback<ChangeData> } callback - Callback used to return [ChangeData]{@link userFileManager.ChangeData}
2204- * . 2198+ * .
2205 * <br>Note that different callbacks can be registered for a URI. You can use2199 * <br>Note that different callbacks can be registered for a URI. You can use
2206 * [off]{@link userFileManager.UserFileManager.off(uri: string, callback?: Callback<ChangeData>)}2200 * [off]{@link userFileManager.UserFileManager.off(uri: string, callback?: Callback<ChangeData>)}
2207 * to disable the specified callback or all callbacks for the URI.2201 * to disable the specified callback or all callbacks for the URI.
@@ -2221,7 +2215,7 @@ declare namespace userFileManager {
2221 * [DefaultChangeUri]{@link userFileManager.DefaultChangeUri}.2215 * [DefaultChangeUri]{@link userFileManager.DefaultChangeUri}.
2222 * @param { Callback<ChangeData> } [callback] - Callback registered by2216 * @param { Callback<ChangeData> } [callback] - Callback registered by
2223 * [on]{@link userFileManager.UserFileManager.on(uri: string, forSubUri: boolean, callback: Callback<ChangeData>)}2217 * [on]{@link userFileManager.UserFileManager.on(uri: string, forSubUri: boolean, callback: Callback<ChangeData>)}
2224- * . If this parameter is not specified, all listener callbacks registered for the URI will be unregistered. 2218+ * . If this parameter is not specified, all listener callbacks registered for the URI will be unregistered.
2225 * <br>Note that the specified callback will not be invoked.2219 * <br>Note that the specified callback will not be invoked.
2226 * @throws { BusinessError } 13900020 - if parameter is invalid2220 * @throws { BusinessError } 13900020 - if parameter is invalid
2227 * @syscap SystemCapability.FileManagement.UserFileManager.Core2221 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2273,7 +2267,7 @@ declare namespace userFileManager {
2273 getAllPeers(): Promise<Array<PeerInfo>>;2267 getAllPeers(): Promise<Array<PeerInfo>>;
2274 /**2268 /**
2275 * Releases this **UserFileManager** instance. This API uses an asynchronous callback to return the result.2269 * Releases this **UserFileManager** instance. This API uses an asynchronous callback to return the result.
2276- * 2270+ *
2277 * Call this API when the APIs in the **UserFileManager** instance are no longer used.2271 * Call this API when the APIs in the **UserFileManager** instance are no longer used.
2278 *2272 *
2279 * @param { AsyncCallback<void> } callback - Callback used to return the result.2273 * @param { AsyncCallback<void> } callback - Callback used to return the result.
@@ -2286,7 +2280,7 @@ declare namespace userFileManager {
2286 release(callback: AsyncCallback<void>): void;2280 release(callback: AsyncCallback<void>): void;
2287 /**2281 /**
2288 * Releases this **UserFileManager** instance. This API uses a promise to return the result.2282 * Releases this **UserFileManager** instance. This API uses a promise to return the result.
2289- * 2283+ *
2290 * Call this API when the APIs in the **UserFileManager** instance are no longer used.2284 * Call this API when the APIs in the **UserFileManager** instance are no longer used.
2291 *2285 *
2292 * @returns { Promise<void> } Promise that returns no value.2286 * @returns { Promise<void> } Promise that returns no value.
@@ -2318,7 +2312,7 @@ declare namespace userFileManager {
2318 * @deprecated since 26.0.02312 * @deprecated since 26.0.0
2319 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ADD2313 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ADD
2320 */2314 */
2321- NOTIFY_ADD,2315+ NOTIFY_ADD = 0,
2322 /**2316 /**
2323 * A file asset or album is updated.2317 * A file asset or album is updated.
2324 *2318 *
@@ -2328,7 +2322,7 @@ declare namespace userFileManager {
2328 * @deprecated since 26.0.02322 * @deprecated since 26.0.0
2329 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_UPDATE2323 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_UPDATE
2330 */2324 */
2331- NOTIFY_UPDATE,2325+ NOTIFY_UPDATE = 1,
2332 /**2326 /**
2333 * A file asset or album is removed.2327 * A file asset or album is removed.
2334 *2328 *
@@ -2338,7 +2332,7 @@ declare namespace userFileManager {
2338 * @deprecated since 26.0.02332 * @deprecated since 26.0.0
2339 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_REMOVE2333 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_REMOVE
2340 */2334 */
2341- NOTIFY_REMOVE,2335+ NOTIFY_REMOVE = 2,
2342 /**2336 /**
2343 * A file asset is added to the album.2337 * A file asset is added to the album.
2344 *2338 *
@@ -2348,7 +2342,7 @@ declare namespace userFileManager {
2348 * @deprecated since 26.0.02342 * @deprecated since 26.0.0
2349 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ALBUM_ADD_ASSET2343 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ALBUM_ADD_ASSET
2350 */2344 */
2351- NOTIFY_ALBUM_ADD_ASSET,2345+ NOTIFY_ALBUM_ADD_ASSET = 3,
2352 /**2346 /**
2353 * A file asset is removed from the album.2347 * A file asset is removed from the album.
2354 *2348 *
@@ -2358,7 +2352,7 @@ declare namespace userFileManager {
2358 * @deprecated since 26.0.02352 * @deprecated since 26.0.0
2359 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ALBUM_REMOVE_ASSET2353 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.NotifyType.NOTIFY_ALBUM_REMOVE_ASSET
2360 */2354 */
2361- NOTIFY_ALBUM_REMOVE_ASSET2355+ NOTIFY_ALBUM_REMOVE_ASSET = 4
2362 }2356 }
2363 2357 
2364 /**2358 /**
@@ -2372,7 +2366,7 @@ declare namespace userFileManager {
2372 */2366 */
2373 enum DefaultChangeUri {2367 enum DefaultChangeUri {
2374 /**2368 /**
2375- * Default **PhotoAsset** URI. The **PhotoAsset** change notifications are received based on this parameter and 2369+ * Default **PhotoAsset** URI. The **PhotoAsset** change notifications are received based on this parameter and
2376 * **forSubUri{true}**.2370 * **forSubUri{true}**.
2377 *2371 *
2378 * @syscap SystemCapability.FileManagement.UserFileManager.Core2372 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2381,7 +2375,7 @@ declare namespace userFileManager {
2381 * @deprecated since 26.0.02375 * @deprecated since 26.0.0
2382 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.DefaultChangeUri.DEFAULT_PHOTO_URI2376 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.DefaultChangeUri.DEFAULT_PHOTO_URI
2383 */2377 */
2384- DEFAULT_PHOTO_URI,2378+ DEFAULT_PHOTO_URI = 0,
2385 /**2379 /**
2386 * Default album URI. Album change notifications are received based on this parameter and **forSubUri{true}**.2380 * Default album URI. Album change notifications are received based on this parameter and **forSubUri{true}**.
2387 *2381 *
@@ -2391,9 +2385,9 @@ declare namespace userFileManager {
2391 * @deprecated since 26.0.02385 * @deprecated since 26.0.0
2392 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.DefaultChangeUri.DEFAULT_ALBUM_URI2386 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.DefaultChangeUri.DEFAULT_ALBUM_URI
2393 */2387 */
2394- DEFAULT_ALBUM_URI,2388+ DEFAULT_ALBUM_URI = 1,
2395 /**2389 /**
2396- * Default **AudioAsset** URI. The **AudioAsset** change notifications are received based on this parameter and 2390+ * Default **AudioAsset** URI. The **AudioAsset** change notifications are received based on this parameter and
2397 * **forSubUri{true}**.2391 * **forSubUri{true}**.
2398 *2392 *
2399 * @syscap SystemCapability.FileManagement.UserFileManager.Core2393 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2402,7 +2396,7 @@ declare namespace userFileManager {
2402 * @deprecated since 26.0.02396 * @deprecated since 26.0.0
2403 * @ohos.file.picker:picker.AudioViewPicker2397 * @ohos.file.picker:picker.AudioViewPicker
2404 */2398 */
2405- DEFAULT_AUDIO_URI2399+ DEFAULT_AUDIO_URI = 2
2406 }2400 }
2407 2401 
2408 /**2402 /**
@@ -2436,7 +2430,7 @@ declare namespace userFileManager {
2436 */2430 */
2437 uris: Array<string>;2431 uris: Array<string>;
2438 /**2432 /**
2439- * URIs of the changed files in the album. The value may be undefined. Check whether the value is undefined before 2433+ * URIs of the changed files in the album. The value may be undefined. Check whether the value is undefined before
2440 * using it.2434 * using it.
2441 *2435 *
2442 * @syscap SystemCapability.FileManagement.UserFileManager.Core2436 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2475,7 +2469,7 @@ declare namespace userFileManager {
2475 */2469 */
2476 readonly networkId: string;2470 readonly networkId: string;
2477 /**2471 /**
2478- * Whether the registered device is online. The value **true** means the registered device is online; the value 2472+ * Whether the registered device is online. The value **true** means the registered device is online; the value
2479 * **false** means the opposite.2473 * **false** means the opposite.
2480 *2474 *
2481 * @syscap SystemCapability.FileManagement.UserFileManager.DistributedCore2475 * @syscap SystemCapability.FileManagement.UserFileManager.DistributedCore
@@ -2488,8 +2482,8 @@ declare namespace userFileManager {
2488 2482 
2489 /**2483 /**
2490 * Enumerates the system album types.2484 * Enumerates the system album types.
2491- * 2485+ *
2492- * This API will be deprecated. Use [AlbumType]{@link userFileManager.AlbumType} and 2486+ * This API will be deprecated. Use [AlbumType]{@link userFileManager.AlbumType} and
2493 * [AlbumSubType]{@link userFileManager.AlbumSubType} instead.2487 * [AlbumSubType]{@link userFileManager.AlbumSubType} instead.
2494 *2488 *
2495 * @syscap SystemCapability.FileManagement.UserFileManager.Core2489 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2508,7 +2502,7 @@ declare namespace userFileManager {
2508 * @deprecated since 26.0.02502 * @deprecated since 26.0.0
2509 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.FAVORITE2503 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.FAVORITE
2510 */2504 */
2511- TYPE_FAVORITE,2505+ TYPE_FAVORITE = 0,
2512 /**2506 /**
2513 * Trash.2507 * Trash.
2514 *2508 *
@@ -2518,12 +2512,12 @@ declare namespace userFileManager {
2518 * @deprecated since 26.0.02512 * @deprecated since 26.0.0
2519 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.TRASH2513 * @useinstead @ohos.file.photoAccessHelper:photoAccessHelper.AlbumSubtype.TRASH
2520 */2514 */
2521- TYPE_TRASH2515+ TYPE_TRASH = 1
2522 }2516 }
2523 2517 
2524 /**2518 /**
2525 * Provides APIs for managing the system albums.2519 * Provides APIs for managing the system albums.
2526- * 2520+ *
2527 * This API will be deprecated. Use [Album]{@link userFileManager.Album} instead.2521 * This API will be deprecated. Use [Album]{@link userFileManager.Album} instead.
2528 *2522 *
2529 * @syscap SystemCapability.FileManagement.UserFileManager.Core2523 * @syscap SystemCapability.FileManagement.UserFileManager.Core
@@ -2534,10 +2528,10 @@ declare namespace userFileManager {
2534 */2528 */
2535 interface PrivateAlbum extends AbsAlbum {2529 interface PrivateAlbum extends AbsAlbum {
2536 /**2530 /**
2537- * Deletes a file from the system album. Only the files in the trash can be deleted. This API uses an asynchronous 2531+ * Deletes a file from the system album. Only the files in the trash can be deleted. This API uses an asynchronous
2538 * callback to return the result.2532 * callback to return the result.
2539- * 2533+ *
2540- * This API will be deprecated. Use 2534+ * This API will be deprecated. Use
2541 * [Album.deletePhotoAssets]{@link userFileManager.Album.deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}2535 * [Album.deletePhotoAssets]{@link userFileManager.Album.deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}
2542 * instead.2536 * instead.
2543 *2537 *
@@ -2553,10 +2547,10 @@ declare namespace userFileManager {
2553 */2547 */
2554 delete(uri: string, callback: AsyncCallback<void>): void;2548 delete(uri: string, callback: AsyncCallback<void>): void;
2555 /**2549 /**
2556- * Deletes a file from the system album. Only the files in the trash can be deleted. This API uses a promise to 2550+ * Deletes a file from the system album. Only the files in the trash can be deleted. This API uses a promise to
2557 * return the result.2551 * return the result.
2558- * 2552+ *
2559- * This API will be deprecated. Use 2553+ * This API will be deprecated. Use
2560 * [Album.deletePhotoAssets]{@link userFileManager.Album.deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}2554 * [Album.deletePhotoAssets]{@link userFileManager.Album.deletePhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}
2561 * instead.2555 * instead.
2562 *2556 *
@@ -2572,10 +2566,10 @@ declare namespace userFileManager {
2572 */2566 */
2573 delete(uri: string): Promise<void>;2567 delete(uri: string): Promise<void>;
2574 /**2568 /**
2575- * Recovers a file in the system album. Only the files in the trash can be recovered. This API uses an asynchronous 2569+ * Recovers a file in the system album. Only the files in the trash can be recovered. This API uses an asynchronous
2576 * callback to return the result.2570 * callback to return the result.
2577- * 2571+ *
2578- * This API will be deprecated. Use 2572+ * This API will be deprecated. Use
2579 * [Album.recoverPhotoAssets]{@link userFileManager.Album.recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}2573 * [Album.recoverPhotoAssets]{@link userFileManager.Album.recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}
2580 * instead.2574 * instead.
2581 *2575 *
@@ -2591,10 +2585,10 @@ declare namespace userFileManager {
2591 */2585 */
2592 recover(uri: string, callback: AsyncCallback<void>): void;2586 recover(uri: string, callback: AsyncCallback<void>): void;
2593 /**2587 /**
2594- * Recovers a file in the system album. Only the files in the trash can be recovered. This API uses a promise to 2588+ * Recovers a file in the system album. Only the files in the trash can be recovered. This API uses a promise to
2595 * return the result.2589 * return the result.
2596- * 2590+ *
2597- * This API will be deprecated. Use 2591+ * This API will be deprecated. Use
2598 * [Album.recoverPhotoAssets]{@link userFileManager.Album.recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}2592 * [Album.recoverPhotoAssets]{@link userFileManager.Album.recoverPhotoAssets(assets: Array<FileAsset>, callback: AsyncCallback<void>)}
2599 * instead.2593 * instead.
2600 *2594 *
@@ -2612,4 +2606,4 @@ declare namespace userFileManager {
2612 }2606 }
2613}2607}
2614 2608 
2615-export default userFileManager;2609+export default userFileManager;