Interface McpServerSession.Factory

Enclosing class:
McpServerSession
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface McpServerSession.Factory
Factory for creating server sessions which delegate to a provided 1:1 transport with a connected client.
  • Method Summary

    Modifier and Type
    Method
    Description
    create(McpServerTransport sessionTransport)
    Creates a new 1:1 representation of the client-server interaction.
  • Method Details

    • create

      McpServerSession create(McpServerTransport sessionTransport)
      Creates a new 1:1 representation of the client-server interaction.
      Parameters:
      sessionTransport - the transport to use for communication with the client.
      Returns:
      a new server session.