Record Class HostedTool.Raw
java.lang.Object
java.lang.Record
org.springframework.ai.openai.responses.HostedTool.Raw
- Record Components:
tool- the tool object, e.g.Map.of("type", "local_shell")
- All Implemented Interfaces:
HostedTool
- Enclosing interface:
- HostedTool
A tool declared as the raw request JSON, for tools this class does not type yet.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.springframework.ai.openai.responses.HostedTool
HostedTool.CodeInterpreter, HostedTool.FileSearch, HostedTool.ImageGeneration, HostedTool.Mcp, HostedTool.Raw, HostedTool.WebSearch -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.tool()Returns the value of thetoolrecord component.final StringtoString()Returns a string representation of this record class.com.openai.models.responses.TooltoTool()Convert this tool to the SDK request representation.
-
Constructor Details
-
Raw
Creates an instance of aRawrecord class.- Parameters:
tool- the value for thetoolrecord component
-
-
Method Details
-
toTool
public com.openai.models.responses.Tool toTool()Description copied from interface:HostedToolConvert this tool to the SDK request representation.- Specified by:
toToolin interfaceHostedTool
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
tool
Returns the value of thetoolrecord component.- Returns:
- the value of the
toolrecord component
-