openDocumentsAsync

open fun openDocumentsAsync(@NonNull context: Context, @NonNull @Size(min = 1) sources: List<DocumentSource>): Single<PdfDocument>

Opens multiple PDF document from a list Uris. The documents will be displayed as a single continuous document. Note that currently only local files are supported and passing remote or non-file Uris will throw an java.io.IOException. The returned Single will fail with an InvalidPasswordException when trying to open a password protected document with no or a wrong password. To specify a password, create the instances using one of the constructors taking a password.

Return

Observable which returns a compound document when called successfully.

Parameters

context

Application context.

sources

List of DocumentSources for this document.

Throws

If PSPDFKit was not initialized with initialize call.


open fun openDocumentsAsync(@NonNull context: Context, @NonNull @Size(min = 1) sources: List<DocumentSource>, multithreadedRenderingEnabled: Boolean): Single<PdfDocument>

Opens multiple PDF document from a list Uris. The documents will be displayed as a single continuous document. Note that currently only local files are supported and passing remote or non-file Uris will throw an java.io.IOException. The returned Single will fail with an InvalidPasswordException when trying to open a password protected document with no or a wrong password. To specify a password, create the instances using one of the constructors taking a password.

Return

Observable which returns a compound document when called successfully.

Parameters

context

Application context.

sources

List of DocumentSources for this document.

multithreadedRenderingEnabled

Whether the multithreaded rendering should be enabled when rendering document pages.

Throws

If PSPDFKit was not initialized with initialize call.