DocumentSource

Represents a document source which may be a DataProvider or a file Uri.

Constructors

Link copied to clipboard
constructor(@NonNull fileUri: Uri)
Creates a new DocumentSource with file Uri as a source.
constructor(@NonNull fileUri: Uri, @Nullable password: String)
Creates a new DocumentSource with file Uri as a source.
constructor(@NonNull fileUri: Uri, @Nullable password: String, @Nullable contentSignature: String)
Creates a new DocumentSource with file Uri as a source.
constructor(@NonNull dataProvider: DataProvider)
Creates a new DocumentSource with a DataProvider as a source.
constructor(@NonNull dataProvider: DataProvider, @Nullable password: String)
Creates a new DocumentSource with a DataProvider as a source.
constructor(@NonNull dataProvider: DataProvider, @Nullable password: String, @Nullable contentSignature: String)
Creates a new DocumentSource with a DataProvider as a source.

Properties

Link copied to clipboard
The checkpoint file for incremental loading.
Link copied to clipboard
The RSA encrypted SHA256 hash of the document if required by license.
Link copied to clipboard
The data provider if this source uses a custom data provider.
Link copied to clipboard
The file URI if this source is a file-based source.
Link copied to clipboard
The password to unlock the document.
Link copied to clipboard
open val uid: String
Holds the UID of the URI-based or file-based source.

Functions

Link copied to clipboard
Returns a copy of this source with new password set.
Link copied to clipboard
open fun equals(o: Any): Boolean
Compares this document source to another object for equality.
Link copied to clipboard
fun DocumentSource.getDataProviderFromDocumentSource(): ERROR CLASS: Symbol not found for DataProvider

This function returns the data provider from the DocumentSource. If the document source is a file, it creates a data provider from the file. If the document source is not a file, it returns the data provider from the document source.

Link copied to clipboard
open fun hashCode(): Int
Returns a hash code value for this document source.
Link copied to clipboard
open fun isFileSource(): Boolean
Returns true if the source is a file URI not a data provider.
Link copied to clipboard
Returns true if the source is remote (http/https) URL.
Link copied to clipboard
open fun toString(): String
Returns a string representation of this document source.