Package io.modelcontextprotocol.spec
Record Class McpSchema.AudioContent
java.lang.Object
java.lang.Record
io.modelcontextprotocol.spec.McpSchema.AudioContent
- Record Components:
annotations- Optional annotations for the clientdata- The base64-encoded audio datamimeType- The MIME type of the audio. Different providers may support different audio typesmeta- See specification for notes on _meta usage
- All Implemented Interfaces:
McpSchema.Annotated,McpSchema.Content
- Enclosing class:
- McpSchema
public static record McpSchema.AudioContent(McpSchema.Annotations annotations, String data, String mimeType, Map<String,Object> meta)
extends Record
implements McpSchema.Annotated, McpSchema.Content
Audio provided to or from an LLM.
-
Constructor Summary
ConstructorsConstructorDescriptionAudioContent(McpSchema.Annotations annotations, String data, String mimeType) AudioContent(McpSchema.Annotations annotations, String data, String mimeType, Map<String, Object> meta) Creates an instance of aAudioContentrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theannotationsrecord 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.meta()Returns the value of themetarecord component.mimeType()Returns the value of themimeTyperecord 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
-
AudioContent
-
AudioContent
public AudioContent(McpSchema.Annotations annotations, String data, String mimeType, Map<String, Object> meta) Creates an instance of aAudioContentrecord class.- Parameters:
annotations- the value for theannotationsrecord componentdata- the value for thedatarecord componentmimeType- the value for themimeTyperecord componentmeta- the value for themetarecord 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). -
annotations
Returns the value of theannotationsrecord component.- Specified by:
annotationsin interfaceMcpSchema.Annotated- Returns:
- the value of the
annotationsrecord 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
-
meta
Returns the value of themetarecord component.- Specified by:
metain interfaceMcpSchema.Content- Returns:
- the value of the
metarecord component
-