DeepLinkRequest.Companion


Summary

Nested types

The RequestExtrasKey for the mimeType stored inside the RequestExtras returned by mimeTypeExtra.

Public functions

RequestExtras
mimeTypeExtra(mimeType: String)

Returns a RequestExtras that stores the provided mimeTypeExtra with the key MimeTypeExtrasKey.

Cmn

Extension functions

RequestExtras

Returns a RequestExtras that stores the provided actionExtra with the key ActionExtrasKey.

android
operator DeepLinkRequest

Creates a DeepLinkRequest with an Intent.

android

Extension properties

RequestExtrasKey<String>

The RequestExtrasKey for the Action stored inside the RequestExtras returned by actionExtra.

android
RequestExtrasKey<Bundle>

The RequestExtrasKey for the Intent.extras stored in DeepLinkRequest.extras when the Request is created with DeepLinkRequest.Companion.invoke factory method.

android

Public functions

mimeTypeExtra

fun mimeTypeExtra(mimeType: String): RequestExtras

Returns a RequestExtras that stores the provided mimeTypeExtra with the key MimeTypeExtrasKey.

The value can be retrieved via extras[MimeTypeExtrasKey].

Extension functions

DeepLinkRequest.Companion.actionExtra

fun DeepLinkRequest.Companion.actionExtra(action: String): RequestExtras

Returns a RequestExtras that stores the provided actionExtra with the key ActionExtrasKey.

The value can be retrieved via extras[ActionExtrasKey].

DeepLinkRequest.Companion.invoke

operator fun DeepLinkRequest.Companion.invoke(
    intent: Intent,
    extras: RequestExtras = emptyRequestExtras()
): DeepLinkRequest

Creates a DeepLinkRequest with an Intent.

The returned DeepLinkRequest will be populated with the following data:

  1. DeepLinkRequest.uri will be Intent.getData if not null

  2. DeepLinkRequest.extras will contain any non-null information from Intent.getType, Intent.getAction, and Intent.getExtras.

Parameters
intent: Intent

The Intent with the metadata to construct a DeepLinkRequest

extras: RequestExtras = emptyRequestExtras()

The RequestExtras holding key-value pairs of RequestExtrasKey<T> to T to provide extra information to the DeepLinkRequest. If extras contains an Action stored under ActionExtrasKey or a MimeType stored under MimeTypeExtrasKey, their values will override any Action or MimeType stored in the intent.

Returns
DeepLinkRequest

a DeepLinkRequest instance

Extension properties

DeepLinkRequest.Companion.ActionExtrasKey

val DeepLinkRequest.Companion.ActionExtrasKeyRequestExtrasKey<String>

The RequestExtrasKey for the Action stored inside the RequestExtras returned by actionExtra.

DeepLinkRequest.Companion.IntentExtrasKey

val DeepLinkRequest.Companion.IntentExtrasKeyRequestExtrasKey<Bundle>

The RequestExtrasKey for the Intent.extras stored in DeepLinkRequest.extras when the Request is created with DeepLinkRequest.Companion.invoke factory method.

The android.os.Bundle is stored as a SavedState.