Record Class ToolInputResponse
java.lang.Object
java.lang.Record
com.suncode.pwfl.ai.tool.ToolInputResponse
- Record Components:
action-accept,declineorcancelcontent- data the user entered;nullwhen nothing was enteredresumeState- state the tool put into, returned unchanged so the tool can continue where it stoppedinvalid reference
ToolInputRequiredException#getResumeState()
@Api
public record ToolInputResponse(String action, ToolPayload content, ToolPayload resumeState)
extends Record
The user's answer to a
ToolInputRequiredException, passed to the tool when it is called again.-
Constructor Summary
ConstructorsConstructorDescriptionToolInputResponse(String action, ToolPayload content, ToolPayload resumeState) Creates an instance of aToolInputResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionaction()Returns the value of theactionrecord component.content()Returns the value of thecontentrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of theresumeStaterecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ToolInputResponse
Creates an instance of aToolInputResponserecord class.- Parameters:
action- the value for theactionrecord componentcontent- the value for thecontentrecord componentresumeState- the value for theresumeStaterecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
action
-
content
-
resumeState
Returns the value of theresumeStaterecord component.- Returns:
- the value of the
resumeStaterecord component
-