Record Class MessageResult
java.lang.Object
java.lang.Record
bg.codexio.ai.openai.api.sdk.message.MessageResult
public record MessageResult(String message, FileResult.Builder fileResult, String imageFileId)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionMessageResult(String message, FileResult.Builder fileResult, String imageFileId) Creates an instance of aMessageResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic MessageResult.Builderbuilder()download(File targetFolder, RetrieveFileContentHttpExecutor httpExecutor) download(File targetFolder, HttpExecutorContext context) static MessageResultempty()final booleanIndicates whether some other object is "equal to" this one.file()Returns the value of thefileResultrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theimageFileIdrecord component.message()Returns the value of themessagerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
MessageResult
Creates an instance of aMessageResultrecord class.- Parameters:
message- the value for themessagerecord componentfileResult- the value for thefileResultrecord componentimageFileId- the value for theimageFileIdrecord component
-
-
Method Details
-
empty
-
builder
-
file
-
download
- Throws:
IOException
-
download
- Throws:
IOException
-
download
- Throws:
IOException
-
download
public String download(File targetFolder, RetrieveFileContentHttpExecutor httpExecutor) throws IOException - Throws:
IOException
-
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). -
message
Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
fileResult
Returns the value of thefileResultrecord component.- Returns:
- the value of the
fileResultrecord component
-
imageFileId
Returns the value of theimageFileIdrecord component.- Returns:
- the value of the
imageFileIdrecord component
-