SharedStorageFileAccessor

class SharedStorageFileAccessor(registry: ActivityResultRegistry, fileExtension: FileExtension = FileExtension.TtpExtension)

Access a file picker from the device shared storage using Storage Access Framework. The reference to SharedStorageFileAccessor cannot live longer than the activity of the registry.

Important: This is a Public Preview API. It may be changed or removed at any time.

Constructors

Link copied to clipboard
constructor(registry: ActivityResultRegistry, fileExtension: FileExtension = FileExtension.TtpExtension)

Types

Link copied to clipboard

Callback which is responsible to inform about a Uri of the picked file.

Functions

Link copied to clipboard

Pick the document from the device shared storage. The successful file picking is notified with the callback. The picked file has to be of the provided extension.