fileUri

Overview

File Uniform Resource Identifier (fileUri).

Supports conversion between fileUri and paths, as well as format validation of fileUri. This module is mainly used for URI format validation and URI conversion. URIs are used in file sharing scenarios between applications. An application sandbox path can be converted into a URI according to system rules, avoiding direct transfer of the sandbox path. Callers must ensure the validity of all API input parameters. The APIs convert and output results according to fixed rules and do not check whether the corresponding file or directory exists.

System capability: SystemCapability.FileManagement.AppFileService

Since: 12

Files

Name Description
oh_file_uri.h Provides methods for mutual conversion between URIs and paths, directory URI retrieval, and URI format validation, applicable to URI conversion and validation in file sharing scenarios.