Document Sharing Intent Helper
Helper for creating share intents.
Functions
Link copied to clipboard
open fun getShareIntent(@NonNull context: Context, @NonNull shareUri: Uri, @NonNull shareAction: ShareAction): Intent
Creates share intent for sharing
shareUri
using given shareAction
.open fun getShareIntent(@NonNull context: Context, @NonNull shareUri: Uri, @NonNull shareTarget: ShareTarget): Intent
Creates share intent for sharing
shareUri
to given shareTarget
.open fun getShareIntent(@NonNull context: Context, @NonNull shareAction: ShareAction, @Nullable sharedFileName: String): Intent
Creates share intent for sharing PDF file from DocumentSharingProvider with
shareAction
.Link copied to clipboard
open fun getShareIntents(@NonNull context: Context, @NonNull shareUri: Uri, @NonNull shareActions: Array<ShareAction>): List<Intent>
Generates list of sharing intents for all apps supporting given ShareAction.
Link copied to clipboard
open fun getShareIntentsAsync(@NonNull context: Context, @NonNull shareUri: Uri, @NonNull shareAction: ShareAction): Observable<List<Intent>>
Generates list of sharing intents for all apps supporting given ShareAction asynchronously.
Link copied to clipboard
open fun getShareTarget(@NonNull context: Context, @NonNull shareAction: ShareAction, @NonNull targetPackageName: String): ShareTarget
open fun getShareTarget(@NonNull context: Context, @NonNull shareAction: ShareAction, @NonNull targetPackageName: String, @Nullable sharedFileName: String): ShareTarget
Link copied to clipboard
open fun getShareTargets(@NonNull context: Context, @NonNull intents: List<Intent>): List<ShareTarget>
Generates list of share targets for all apps handling given intents.
Link copied to clipboard
open fun getShareTargetsAsync(@NonNull context: Context, @NonNull intents: List<Intent>): Observable<List<ShareTarget>>
Generates list of share targets for all apps handling given intents.
Link copied to clipboard
Generates intent for sharing plain text.
Link copied to clipboard
Show application details settings screen for given share target.