public static class McpSchema.ResourceTemplate extends java.lang.Object implements McpSchema.Annotated, McpSchema.Identifier, McpSchema.Meta
| 限定符和类型 | 类和说明 |
|---|---|
static class |
McpSchema.ResourceTemplate.Builder |
| 构造器和说明 |
|---|
ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations) |
ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String title,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations) |
ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String title,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations,
java.util.Map<java.lang.String,java.lang.Object> meta) |
| 限定符和类型 | 方法和说明 |
|---|---|
McpSchema.Annotations |
annotations() |
static McpSchema.ResourceTemplate.Builder |
builder() |
java.lang.String |
description() |
java.util.Map<java.lang.String,java.lang.Object> |
meta() |
java.lang.String |
mimeType() |
java.lang.String |
name()
Intended for programmatic or logical use, but used as a display name in past
specs or fallback (if title isn't present).
|
java.lang.String |
title()
Intended for UI and end-user contexts — optimized to be human-readable and
easily understood, even by those unfamiliar with domain-specific terminology.
|
java.lang.String |
uriTemplate() |
public ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String title,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations,
java.util.Map<java.lang.String,java.lang.Object> meta)
uriTemplate - A URI template that can be used to generate URIs for this
resource.name - A human-readable name for this resource. This can be used by clients to
populate UI elements.title - An optional title for this resource.description - A description of what this resource represents. This can be used
by clients to improve the LLM's understanding of available resources. It can be
thought of like a "hint" to the model.mimeType - The MIME type of this resource, if known.annotations - Optional annotations for the client. The client can use
annotations to inform how objects are used or displayed.meta - See specification for notes on _meta usagepublic ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String title,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations)
public ResourceTemplate(java.lang.String uriTemplate,
java.lang.String name,
java.lang.String description,
java.lang.String mimeType,
McpSchema.Annotations annotations)
public java.lang.String uriTemplate()
public java.lang.String name()
McpSchema.Identifiername 在接口中 McpSchema.Identifierpublic java.lang.String title()
McpSchema.Identifiertitle 在接口中 McpSchema.Identifierpublic java.lang.String description()
public java.lang.String mimeType()
public McpSchema.Annotations annotations()
annotations 在接口中 McpSchema.Annotatedpublic java.util.Map<java.lang.String,java.lang.Object> meta()
meta 在接口中 McpSchema.Metapublic static McpSchema.ResourceTemplate.Builder builder()