PotentialAction.Builder
public final class PotentialAction.Builder
Builder for PotentialAction.
Summary
Public constructors |
|---|
Builder()Constructor for |
Builder(@NonNull PotentialAction potentialAction)Constructor with all the existing values. |
Public methods |
|
|---|---|
@NonNull PotentialAction |
build()Builds the |
@NonNull PotentialAction.Builder |
setDescription(@Nullable String description)Sets the description of the action, such as "Call". |
@NonNull PotentialAction.Builder |
Sets the name of the action. |
@NonNull PotentialAction.Builder |
Sets the deeplink URI of the Action. |
Public constructors
Builder
public Builder()
Constructor for PotentialAction.Builder.
As PotentialAction is used as a DocumentProperty of Thing, it does not need an id or namespace.
Builder
public Builder(@NonNull PotentialAction potentialAction)
Constructor with all the existing values.
As PotentialAction is used as a DocumentProperty of Thing, it does not need an id or namespace.
Public methods
setDescription
public @NonNull PotentialAction.Builder setDescription(@Nullable String description)
Sets the description of the action, such as "Call".
setName
public @NonNull PotentialAction.Builder setName(@Nullable String name)
Sets the name of the action.
setUri
public @NonNull PotentialAction.Builder setUri(@Nullable String uri)
Sets the deeplink URI of the Action.
A deeplink URI is a URI that lets a user access a specific content or feature within an app directly. Users can create one by adding parameters to the app's base URI. To use a deeplink URI in an Android application, users can create an android.content.Intent object by calling parseUri with the deeplink URI. Creating a deeplink URI, and adding intent extras, can be done by building an intent and calling toUri.