public static class McpSchema.CallToolResult extends java.lang.Object implements McpSchema.Result
限定符和类型 | 类和说明 |
---|---|
static class |
McpSchema.CallToolResult.Builder
Builder for
McpSchema.CallToolResult . |
构造器和说明 |
---|
CallToolResult(java.util.List<McpSchema.Content> content,
java.lang.Boolean isError) |
CallToolResult(java.util.List<McpSchema.Content> content,
java.lang.Boolean isError,
java.util.Map<java.lang.String,java.lang.Object> structuredContent) |
CallToolResult(java.lang.String content,
java.lang.Boolean isError)
Creates a new instance of
McpSchema.CallToolResult with a string containing the
tool result. |
限定符和类型 | 方法和说明 |
---|---|
static McpSchema.CallToolResult.Builder |
builder()
Creates a builder for
McpSchema.CallToolResult . |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getMeta
public CallToolResult(java.util.List<McpSchema.Content> content, java.lang.Boolean isError)
public CallToolResult(java.util.List<McpSchema.Content> content, java.lang.Boolean isError, java.util.Map<java.lang.String,java.lang.Object> structuredContent)
public CallToolResult(java.lang.String content, java.lang.Boolean isError)
McpSchema.CallToolResult
with a string containing the
tool result.content
- The content of the tool result. This will be mapped to a
one-sized list with a McpSchema.TextContent
element.isError
- If true, indicates that the tool execution failed and the
content contains error information. If false or absent, indicates successful
execution.public static McpSchema.CallToolResult.Builder builder()
McpSchema.CallToolResult
.