Record Class HostedTool.ImageGeneration
java.lang.Object
java.lang.Record
org.springframework.ai.openai.responses.HostedTool.ImageGeneration
- Record Components:
model- the image model, ornullfor the provider defaultsize- e.g.1024x1024, ornullfor the provider default
- All Implemented Interfaces:
HostedTool
- Enclosing interface:
- HostedTool
public static record HostedTool.ImageGeneration(@Nullable String model, @Nullable String size)
extends Record
implements HostedTool
Generate images. Generated images are surfaced as
Media on the assistant message.-
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
ConstructorsConstructorDescriptionImageGeneration(@Nullable String model, @Nullable String size) Creates an instance of aImageGenerationrecord class. -
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.@Nullable Stringmodel()Returns the value of themodelrecord component.static HostedTool.ImageGenerationof()@Nullable Stringsize()Returns the value of thesizerecord 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
-
Method Details
-
of
-
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). -
model
Returns the value of themodelrecord component.- Returns:
- the value of the
modelrecord component
-
size
Returns the value of thesizerecord component.- Returns:
- the value of the
sizerecord component
-