public static class McpStatelessServerFeatures.SyncToolSpecification
extends java.lang.Object
| 限定符和类型 | 类和说明 |
|---|---|
static class |
McpStatelessServerFeatures.SyncToolSpecification.Builder
Builder for creating SyncToolSpecification instances.
|
| 构造器和说明 |
|---|
SyncToolSpecification(McpSchema.Tool tool,
java.util.function.BiFunction<McpTransportContext,McpSchema.CallToolRequest,McpSchema.CallToolResult> callHandler) |
| 限定符和类型 | 方法和说明 |
|---|---|
static McpStatelessServerFeatures.SyncToolSpecification.Builder |
builder() |
java.util.function.BiFunction<McpTransportContext,McpSchema.CallToolRequest,McpSchema.CallToolResult> |
callHandler() |
McpSchema.Tool |
tool() |
public SyncToolSpecification(McpSchema.Tool tool, java.util.function.BiFunction<McpTransportContext,McpSchema.CallToolRequest,McpSchema.CallToolResult> callHandler)
tool - The tool definition including name, description, and parameter schemacallHandler - The function that implements the tool's logic, receiving a
McpSchema.CallToolRequest and returning results.public McpSchema.Tool tool()
public java.util.function.BiFunction<McpTransportContext,McpSchema.CallToolRequest,McpSchema.CallToolResult> callHandler()
public static McpStatelessServerFeatures.SyncToolSpecification.Builder builder()