类 McpToolParameterConverter

java.lang.Object
com.github.codeboyzhou.mcp.declarative.server.converter.AbstractParameterConverter<McpToolParam>
com.github.codeboyzhou.mcp.declarative.server.converter.McpToolParameterConverter
所有已实现的接口:
ParameterConverter<McpToolParam>

public class McpToolParameterConverter extends AbstractParameterConverter<McpToolParam>
This class is used to convert the value of a parameter annotated with McpToolParam to the required type.
作者:
codeboyzhou
  • 构造器详细资料

    • McpToolParameterConverter

      public McpToolParameterConverter()
  • 方法详细资料

    • convert

      public Object convert(Parameter parameter, McpToolParam annotation, Map<String,Object> args)
      Converts the value of the parameter annotated with McpToolParam to the required type.
      参数:
      parameter - the parameter annotated with McpToolParam
      annotation - the annotation instance
      args - the arguments passed to the method
      返回:
      the converted value of the parameter
    • getAnnotationType

      public Class<McpToolParam> getAnnotationType()
      Returns the type of the annotation this converter handles.
      返回:
      the type of the annotation this converter handles