Module org.elasticsearch.server
Record Class ContentObject.ContentObjectImage.ContentObjectImageUrl
java.lang.Object
java.lang.Record
org.elasticsearch.inference.completion.ContentObject.ContentObjectImage.ContentObjectImageUrl
- All Implemented Interfaces:
Writeable,ToXContent,ToXContentObject
- Enclosing class:
ContentObject.ContentObjectImage
public static record ContentObject.ContentObjectImage.ContentObjectImageUrl(String url, ContentObject.ContentObjectImage.ContentObjectImageUrl.ImageUrlDetail detail)
extends Record
implements Writeable, ToXContentObject
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumNested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
Fields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Constructor Summary
ConstructorsConstructorDescriptionContentObjectImageUrl(String url, ContentObject.ContentObjectImage.ContentObjectImageUrl.ImageUrlDetail detail) Creates an instance of aContentObjectImageUrlrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondetail()Returns the value of thedetailrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.toXContent(XContentBuilder builder, ToXContent.Params params) url()Returns the value of theurlrecord component.voidwriteTo(StreamOutput out) Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragment
-
Constructor Details
-
ContentObjectImageUrl
- Throws:
IOException
-
ContentObjectImageUrl
public ContentObjectImageUrl(String url, @Nullable ContentObject.ContentObjectImage.ContentObjectImageUrl.ImageUrlDetail detail) Creates an instance of aContentObjectImageUrlrecord class.- Parameters:
url- the value for theurlrecord componentdetail- the value for thedetailrecord component
-
-
Method Details
-
fromMap
public static ContentObject.ContentObjectImage.ContentObjectImageUrl fromMap(Map<String, Object> map) -
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceToXContent- 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). -
url
Returns the value of theurlrecord component.- Returns:
- the value of the
urlrecord component
-
detail
Returns the value of thedetailrecord component.- Returns:
- the value of the
detailrecord component
-