Added in API level 29

Builder


class Builder
kotlin.Any
   ↳ android.view.textclassifier.ConversationAction.Builder

Builder class to construct ConversationAction.

Summary

Public constructors
Builder(actionType: String)

Public methods
ConversationAction

Builds the ConversationAction object.

ConversationAction.Builder

Sets an action that may be performed on the given conversation.

ConversationAction.Builder

Sets the confident score.

ConversationAction.Builder
setExtras(extras: Bundle?)

Sets the extended data for the conversation action object.

ConversationAction.Builder

Sets a text reply that may be performed on the given conversation.

Public constructors

Public methods

build

Added in API level 29
fun build(): ConversationAction

Builds the ConversationAction object.

Return
ConversationAction This value cannot be null.

setAction

Added in API level 29
fun setAction(action: RemoteAction?): ConversationAction.Builder

Sets an action that may be performed on the given conversation.

Parameters
action RemoteAction?: This value may be null.
Return
ConversationAction.Builder This value cannot be null.

setConfidenceScore

Added in API level 29
fun setConfidenceScore(score: Float): ConversationAction.Builder

Sets the confident score.

Parameters
score Float: Value is between 0 and 1 inclusive
Return
ConversationAction.Builder This value cannot be null.

setExtras

Added in API level 29
fun setExtras(extras: Bundle?): ConversationAction.Builder

Sets the extended data for the conversation action object.

Parameters
extras Bundle?: This value may be null.
Return
ConversationAction.Builder This value cannot be null.

setTextReply

Added in API level 29
fun setTextReply(textReply: CharSequence?): ConversationAction.Builder

Sets a text reply that may be performed on the given conversation.

Parameters
textReply CharSequence?: This value may be null.
Return
ConversationAction.Builder This value cannot be null.