diff --git a/api/@ohos.file.photoAccessHelper.d.ts b/api/@ohos.file.photoAccessHelper.d.ts index 51a7c65e0943c0ee69c7ea13c10a1d5f0e672171..9b312eb35c06859fc2d57db713ca321fd72c2afb 100644 --- a/api/@ohos.file.photoAccessHelper.d.ts +++ b/api/@ohos.file.photoAccessHelper.d.ts @@ -2165,7 +2165,6 @@ declare namespace photoAccessHelper { * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform * @since arkts {'1.1':'12','1.2':'20'} - * @arkts 1.1&1.2 */ URI = 'uri', /** @@ -2271,7 +2270,15 @@ declare namespace photoAccessHelper { * * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @crossplatform - * @since arkts {'1.1':'12','1.2':'20'} + * @since 12 + */ + /** + * Modified date of the asset, read only + * + * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core + * @crossplatform + * @atomicservice + * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 */ DATE_MODIFIED = 'date_modified', @@ -2808,6 +2815,7 @@ declare namespace photoAccessHelper { * URI of the album. * * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core + * @crossplatform * @atomicservice * @since arkts {'1.1':'20','1.2':'20'} * @arkts 1.1&1.2 @@ -3243,11 +3251,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the total number of files in the result set. + * Obtains the total number of objects in the fetch result. * * @returns { number } Total number of objects. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3283,12 +3289,10 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Checks whether the cursor is in the last row of the result set. + * Checks whether the result set points to the last row. * You need to check whether the object is the last one before calling getNextObject. * * @returns { boolean } Whether the object is the last one in the fetch result. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3321,11 +3325,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the first file asset in the result set. This API uses an asynchronous callback to return the result. + * Obtains the first object in the fetch result. * * @param { AsyncCallback } callback - Callback used to return the first file asset obtained. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3359,11 +3361,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the first file asset in the result set. This API uses a promise to return the result. + * Obtains the first object in the fetch result. * * @returns { Promise } Returns the first object in the fetch result. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3399,12 +3399,11 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the next file asset in the result set. This API uses an asynchronous callback to return the result. + * Obtains the next objext in the fetch result. * Before using this API, you must use isAfterLast() to check whether the current position is the end of the result set. + * in the fetch result. This method only works when the current position is not the last row. * * @param { AsyncCallback } callback - Callback used to return the next file asset obtained. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3440,12 +3439,11 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the next file asset in the result set. This API uses a promise to return the result. + * Obtains the next objext in the fetch result. * Before using this API, you must use isAfterLast() to check whether the current position is the end of the result set. + * in the fetch result. This method only works when the current position is not the last row. * * @returns { Promise } Returns the next object - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3479,11 +3477,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the last file asset in the result set. This API uses an asynchronous callback to return the result. + * Obtains the last object asset in the fetch result. * * @param { AsyncCallback } callback - Callback used to return the last file asset obtained. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3516,11 +3512,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains the last file asset in the result set. This API uses a promise to return the result. + * Obtains the last object asset in the fetch result. * * @returns { Promise } Returns the last object - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3555,12 +3549,10 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains a file asset with the specified index in the result set. This API uses an asynchronous callback to return the result. + * Obtains the object with the specified index in the result set. * * @param { number } index - Index of the file asset to obtain. The value starts from 0. * @param { AsyncCallback } callback - Callback used to return the file asset obtained. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3596,12 +3588,10 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains a file asset with the specified index in the result set. This API uses a promise to return the result. + * Obtains the object with the specified index in the result set. * * @param { number } index - Index of the file asset to obtain. The value starts from 0. * @returns { Promise } Returns the object - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3635,11 +3625,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains all the file assets in the result set. This API uses an asynchronous callback to return the result. + * Obtains all objects in the fetch result. * * @param { AsyncCallback> } callback - Callback used to return an array of all file assets in the result set. - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3673,11 +3661,9 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains all the file assets in the result set. This API uses a promise to return the result. + * Obtains all objects in the fetch result. * * @returns { Promise> } Returns all the objects - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -3709,10 +3695,8 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Closes this FetchResult instance to invalidate it. After this instance is released, the APIs in this instance cannot be invoked. + * Release the fetch result. * - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types. * @throws { BusinessError } 13900020 - Invalid argument * @throws { BusinessError } 14000011 - System inner fail * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core @@ -4722,15 +4706,13 @@ declare namespace photoAccessHelper { * @since 12 */ /** - * Obtains burst assets. This API uses a promise to return the result. + * Fetch a group of burst assets * * @permission ohos.permission.READ_IMAGEVIDEO * @param { string } burstKey - UUID of a set of burst photos (BURST_KEY of PhotoKeys). The value is a string of 36 characters. * @param { FetchOptions } options - Options for fetching the burst photos. * @returns { Promise> } Returns the fetch result. * @throws { BusinessError } 201 - Permission denied - * @throws { BusinessError } 401 - Parameter error. Possible causes: 1. Mandatory parameters are left unspecified; - *
2. Incorrect parameter types; 3. Parameter verification failed. * @throws { BusinessError } 14000011 - Internal system error * @syscap SystemCapability.FileManagement.PhotoAccessHelper.Core * @atomicservice