public interface

FilePicker

com.pspdfkit.document.editor.FilePicker

Class Overview

A file picker for retrieving a destination Uri. getDestinationUri(String) can be called whenever access to an Uri is required, for example when trying to save a PDF document to a random location. Various implementations of file pickers can exist, such as default Android SAF that shows a file browser for selecting a destination file prior to creating the exported PDFs. One usage of the FilePicker is the selection of a destination Uri for saving documents when editing using the PdfDocumentEditor.

Summary

Public Methods
abstract Maybe<Uri> getDestinationUri(String action)
The file picker opens a default Android SAF by an intent with a given action.

Public Methods

public abstract Maybe<Uri> getDestinationUri (String action)

The file picker opens a default Android SAF by an intent with a given action. The file picker might cancel the operation, in which case the returned Maybe instance completes without emitting a value. Reasons for cancellation might be user interaction, like cancelling selection of a destination inside SAF picker. Supported intent actions are ACTION_OPEN_DOCUMENT, and ACTION_CREATE_DOCUMENT.

Parameters
action Given action used to create an intent for opening Android SAF.