TypeRequest

class TypeRequest<T : Any> constructor(val type: Class<T>, val message: String? = null, val hint: T? = null, persistent: Boolean = false) : AbstractAwaitable<Class<T>, TypeResponse<T>>

Request a value of type T from the user.

The UX layer will typically generate a form from the type's schema and present it to the user. When the user provides the value, it is added to the blackboard and execution can continue.

Parameters

T

The type of value to request

type

The class of the requested type (for reflection/schema generation)

message

Optional message to display to the user explaining what's needed

hint

Optional pre-populated value to show as a starting point

persistent

Whether this request should be persisted

Constructors

Link copied to clipboard
constructor(type: Class<T>, message: String? = null, hint: T? = null, persistent: Boolean = false)

Properties

Link copied to clipboard
val hint: T? = null
Link copied to clipboard
open val id: String
Link copied to clipboard
val message: String? = null
Link copied to clipboard
open override val payload: Class<T>
Link copied to clipboard
open val timestamp: Instant
Link copied to clipboard
val type: Class<T>

Functions

Link copied to clipboard
open override fun infoString(verbose: Boolean?, indent: Int): String
Link copied to clipboard
open override fun onResponse(response: TypeResponse<T>, agentProcess: AgentProcess): ResponseImpact

Update process state based on this response

Link copied to clipboard
open fun persistent(): Boolean
Link copied to clipboard
open override fun toString(): String