ConversationActions.Request


class ConversationActions.Request


A request object for generating conversation action suggestions.

Summary

Constants

const String!
HINT_FOR_IN_APP = "in_app"

To indicate the generated actions will be used within the app.

const String!
HINT_FOR_NOTIFICATION = "notification"

To indicate the generated actions will be used for notification.

Public functions

java-static ConversationActions.Request

Converts a bundle that was created using toBundle to a ConversationActions.Request.

(Mutable)List<ConversationActions.Message!>

Returns an immutable list of messages that make up the conversation.

Bundle

Returns the extended data related to this request.

(Mutable)List<String!>

Returns an immutable list of hints

@IntRange(from = "-1") Int

Return the maximal number of suggestions the caller wants, value -1 means no restriction and this is the default.

TextClassifier.EntityConfig

Returns the type config.

Bundle

Adds this object to a Bundle that can be read back with the same parameters to createFromBundle.

Constants

HINT_FOR_IN_APP

const val HINT_FOR_IN_APP = "in_app": String!

To indicate the generated actions will be used within the app.

HINT_FOR_NOTIFICATION

const val HINT_FOR_NOTIFICATION = "notification": String!

To indicate the generated actions will be used for notification.

Public functions

createFromBundle

java-static fun createFromBundle(bundle: Bundle): ConversationActions.Request

Converts a bundle that was created using toBundle to a ConversationActions.Request.

getConversation

fun getConversation(): (Mutable)List<ConversationActions.Message!>

Returns an immutable list of messages that make up the conversation.

getExtras

fun getExtras(): Bundle

Returns the extended data related to this request.

NOTE: Do not modify this bundle.

getHints

fun getHints(): (Mutable)List<String!>

Returns an immutable list of hints

getMaxSuggestions

fun getMaxSuggestions(): @IntRange(from = "-1") Int

Return the maximal number of suggestions the caller wants, value -1 means no restriction and this is the default.

getTypeConfig

fun getTypeConfig(): TextClassifier.EntityConfig

Returns the type config.

toBundle

fun toBundle(): Bundle

Adds this object to a Bundle that can be read back with the same parameters to createFromBundle.