public static class McpServerFeatures.AsyncToolSpecification.Builder extends Object
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
McpServerFeatures.AsyncToolSpecification |
build()
Builds the AsyncToolSpecification instance.
|
McpServerFeatures.AsyncToolSpecification.Builder |
callHandler(BiFunction<McpAsyncServerExchange,McpSchema.CallToolRequest,reactor.core.publisher.Mono<McpSchema.CallToolResult>> callHandler)
Sets the call tool handler function.
|
McpServerFeatures.AsyncToolSpecification.Builder |
tool(McpSchema.Tool tool)
Sets the tool definition.
|
public McpServerFeatures.AsyncToolSpecification.Builder tool(McpSchema.Tool tool)
tool - The tool definition including name, description, and parameter
schemapublic McpServerFeatures.AsyncToolSpecification.Builder callHandler(BiFunction<McpAsyncServerExchange,McpSchema.CallToolRequest,reactor.core.publisher.Mono<McpSchema.CallToolResult>> callHandler)
callHandler - The function that implements the tool's logicpublic McpServerFeatures.AsyncToolSpecification build()
IllegalArgumentException - if required fields are not setCopyright © 2025. All rights reserved.