Record Class McpServerChangeNotification
java.lang.Object
java.lang.Record
com.github.codeboyzhou.mcp.declarative.configuration.McpServerChangeNotification
public record McpServerChangeNotification(Boolean resource, Boolean prompt, Boolean tool)
extends Record
This record represents a change notification for MCP (Model Context Protocol) server
capabilities.
It contains boolean flags indicating whether the server supports resource, prompt, and tool change notification.
- 作者:
- codeboyzhou
-
嵌套类概要
嵌套类修饰符和类型类说明static classBuilder class forMcpServerChangeNotification. -
构造器概要
构造器构造器说明McpServerChangeNotification(Boolean resource, Boolean prompt, Boolean tool) 创建McpServerChangeNotification记录的实例。 -
方法概要
修饰符和类型方法说明builder()Creates a new instance ofBuilderto buildMcpServerChangeNotification.final boolean指示某个其他对象是否“等于”此对象。static McpServerChangeNotificationReturns the default change notification of the MCP server.final inthashCode()返回此对象的哈希代码值。prompt()返回prompt记录组件的值。resource()返回resource记录组件的值。tool()返回tool记录组件的值。final StringtoString()返回此记录的字符串表示形式。
-
构造器详细资料
-
McpServerChangeNotification
创建McpServerChangeNotification记录的实例。- 参数:
resource-resource记录组件的值prompt-prompt记录组件的值tool-tool记录组件的值
-
-
方法详细资料
-
builder
Creates a new instance ofBuilderto buildMcpServerChangeNotification.- 返回:
- A new instance of
Builder.
-
getDefault
Returns the default change notification of the MCP server.By default, all change notification flags are set to
true.- 返回:
- The default change notification of the MCP server.
-
toString
返回此记录的字符串表示形式。此表示形式包含类型的名称,后跟每个记录组件的名称和值。 -
hashCode
public final int hashCode()返回此对象的哈希代码值。此值派生自每个记录组件的哈希代码。 -
equals
指示某个其他对象是否“等于”此对象。如果两个对象属于同一个类,而且所有记录组件都相等,则这两个对象相等。 此记录中的所有组件都使用Objects::equals(Object,Object)进行比较。 -
resource
返回resource记录组件的值。- 返回:
resource记录组件的值
-
prompt
返回prompt记录组件的值。- 返回:
prompt记录组件的值
-
tool
返回tool记录组件的值。- 返回:
tool记录组件的值
-