public static class McpServerFeatures.Sync extends Object
| Constructor and Description |
|---|
Sync(McpSchema.Implementation serverInfo,
McpSchema.ServerCapabilities serverCapabilities,
List<McpServerFeatures.SyncToolSpecification> tools,
Map<String,McpServerFeatures.SyncResourceSpecification> resources,
List<McpSchema.ResourceTemplate> resourceTemplates,
Map<String,McpServerFeatures.SyncPromptSpecification> prompts,
Map<McpSchema.CompleteReference,McpServerFeatures.SyncCompletionSpecification> completions,
List<BiConsumer<McpSyncServerExchange,List<McpSchema.Root>>> rootsChangeConsumers,
String instructions)
Create an instance and validate the arguments.
|
public Sync(McpSchema.Implementation serverInfo, McpSchema.ServerCapabilities serverCapabilities, List<McpServerFeatures.SyncToolSpecification> tools, Map<String,McpServerFeatures.SyncResourceSpecification> resources, List<McpSchema.ResourceTemplate> resourceTemplates, Map<String,McpServerFeatures.SyncPromptSpecification> prompts, Map<McpSchema.CompleteReference,McpServerFeatures.SyncCompletionSpecification> completions, List<BiConsumer<McpSyncServerExchange,List<McpSchema.Root>>> rootsChangeConsumers, String instructions)
serverInfo - The server implementation detailsserverCapabilities - The server capabilitiestools - The list of tool specificationsresources - The map of resource specificationsresourceTemplates - The list of resource templatesprompts - The map of prompt specificationsrootsChangeConsumers - The list of consumers that will be notified when
the roots list changesinstructions - The server instructions textCopyright © 2025. All rights reserved.