类 McpServerComponentRegister

java.lang.Object
com.github.codeboyzhou.mcp.declarative.server.component.McpServerComponentRegister

public final class McpServerComponentRegister extends Object
Registers MCP server components (resources, prompts, and tools) with the specified server.
作者:
codeboyzhou
  • 构造器详细资料

    • McpServerComponentRegister

      public McpServerComponentRegister(io.modelcontextprotocol.server.McpSyncServer server)
      Creates a new instance of McpServerComponentRegister with the specified server.
      参数:
      server - the MCP sync server to register components with
  • 方法详细资料

    • of

      public static McpServerComponentRegister of(io.modelcontextprotocol.server.McpSyncServer server)
      Creates a new instance of McpServerComponentRegister with the specified server.
      参数:
      server - the MCP sync server to register components with
      返回:
      a new instance of McpServerComponentRegister with the specified server
    • registerComponents

      public void registerComponents()
      Registers MCP server components (resources, prompts, and tools) with the specified server.