# @ohos.data.fileAccess (User File Access and Management)
# @ohos.file.fileAccess (User File Access and Management)
The **fileAccess** module is a framework for accessing and operating user files based on the Extension ability mechanism. This module interacts with diverse file management services, such as the media library and external storage management service, and provides a set of file access and management APIs for system applications. The media library service allows access to user files on local devices and distributed devices. The external storage management service allows access to the user files stored on devices such as shared disks, USB flash drives, and SD cards.
...
...
@@ -10,7 +10,7 @@ The **fileAccess** module is a framework for accessing and operating user files
## Modules to Import
```js
importfileAccessfrom'@ohos.data.fileAccess';
importfileAccessfrom'@ohos.file.fileAccess';
```
## fileAccess.getFileAccessAbilityInfo
...
...
@@ -38,7 +38,41 @@ Obtains information about all wants with **extension** set to **fileAcesss** in
Obtains information about all wants with **extension** set to **fileAcesss** in the system. A want is a basic communication component used to start services. This API uses an asynchronous callback to return the result.
Obtains information about the device root nodes of the file management service type connected to the **Helper** object. This API uses an asynchronous callback to return the result.
The callback has a **RootIterator** object, which returns [RootInfo](#rootinfo) through [next()](#rootiteratornext).
@@ -390,7 +468,7 @@ Creates a file in a directory. This API uses a promise to return the result.
| Name| Type| Mandatory| Description|
| --- | --- | --- | -- |
| uri | string | Yes| URI of the parent directory for the file to create.|
| displayName | string | Yes| Name of the file to create. A file name extension must be added for a local file. It is not required for a file stored in a shared disk.|
| displayName | string | Yes| Name of the file to create. By default, the name of a local file must contain the file name extension.|
**Return value**
...
...
@@ -414,9 +492,49 @@ Creates a file in a directory. This API uses a promise to return the result.