Package io.modelcontextprotocol.spec
Record Class McpSchema.BlobResourceContents
java.lang.Object
java.lang.Record
io.modelcontextprotocol.spec.McpSchema.BlobResourceContents
- Record Components:
uri- the URI of this resource.mimeType- the MIME type of this resource.blob- a base64-encoded string representing the binary data of the resource. This must only be set if the resource can actually be represented as binary data (not text).meta- See specification for notes on _meta usage
- All Implemented Interfaces:
McpSchema.ResourceContents
- Enclosing class:
- McpSchema
public static record McpSchema.BlobResourceContents(String uri, String mimeType, String blob, Map<String,Object> meta)
extends Record
implements McpSchema.ResourceContents
Binary contents of a resource.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionblob()Returns the value of theblobrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.meta()Returns the value of themetarecord component.mimeType()Returns the value of themimeTyperecord component.final StringtoString()Returns a string representation of this record class.uri()Returns the value of theurirecord component.
-
Constructor Details
-
BlobResourceContents
-
BlobResourceContents
Creates an instance of aBlobResourceContentsrecord class.
-
-
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). -
uri
Returns the value of theurirecord component.- Specified by:
uriin interfaceMcpSchema.ResourceContents- Returns:
- the value of the
urirecord component
-
mimeType
Returns the value of themimeTyperecord component.- Specified by:
mimeTypein interfaceMcpSchema.ResourceContents- Returns:
- the value of the
mimeTyperecord component
-
blob
Returns the value of theblobrecord component.- Returns:
- the value of the
blobrecord component
-
meta
Returns the value of themetarecord component.- Specified by:
metain interfaceMcpSchema.ResourceContents- Returns:
- the value of the
metarecord component - See Also:
-
- Specification for notes on _meta usage
-