Package io.modelcontextprotocol.spec
Record Class McpSchema.ImageContent
java.lang.Object
java.lang.Record
io.modelcontextprotocol.spec.McpSchema.ImageContent
- All Implemented Interfaces:
McpSchema.Content
- Enclosing class:
- McpSchema
public static record McpSchema.ImageContent(List<McpSchema.Role> audience, Double priority, String data, String mimeType)
extends Record
implements McpSchema.Content
-
Constructor Summary
ConstructorsConstructorDescriptionImageContent(List<McpSchema.Role> audience, Double priority, String data, String mimeType) Creates an instance of aImageContentrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaudience()Returns the value of theaudiencerecord component.data()Returns the value of thedatarecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.mimeType()Returns the value of themimeTyperecord component.priority()Returns the value of thepriorityrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.modelcontextprotocol.spec.McpSchema.Content
type
-
Constructor Details
-
ImageContent
Creates an instance of aImageContentrecord class.- Parameters:
audience- the value for theaudiencerecord componentpriority- the value for thepriorityrecord componentdata- the value for thedatarecord componentmimeType- the value for themimeTyperecord component
-
-
Method Details
-
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). -
audience
Returns the value of theaudiencerecord component.- Returns:
- the value of the
audiencerecord component
-
priority
Returns the value of thepriorityrecord component.- Returns:
- the value of the
priorityrecord component
-
data
Returns the value of thedatarecord component.- Returns:
- the value of the
datarecord component
-
mimeType
Returns the value of themimeTyperecord component.- Returns:
- the value of the
mimeTyperecord component
-