Record Class McpEndpointRegistration

java.lang.Object
java.lang.Record
com.soklet.McpEndpointRegistration

@Immutable public record McpEndpointRegistration(@NonNull Class<? extends McpEndpoint> endpointClass, @NonNull ResourcePathDeclaration endpointPathDeclaration, @NonNull String name, @NonNull String version, @Nullable String instructions, @Nullable String title, @Nullable String description, @Nullable String websiteUrl, @NonNull Set<@NonNull String> toolNames, @NonNull Set<@NonNull String> promptNames, @NonNull Set<@NonNull String> resourceUris, @NonNull Boolean hasResourceListHandler) extends Record
Immutable metadata describing a resolved MCP endpoint registration.
Author:
Mark Allen
  • Constructor Details

    • McpEndpointRegistration

      public McpEndpointRegistration(@NonNull Class<? extends McpEndpoint> endpointClass, @NonNull ResourcePathDeclaration endpointPathDeclaration, @NonNull String name, @NonNull String version, @Nullable String instructions, @Nullable String title, @Nullable String description, @Nullable String websiteUrl, @NonNull Set<@NonNull String> toolNames, @NonNull Set<@NonNull String> promptNames, @NonNull Set<@NonNull String> resourceUris, @NonNull Boolean hasResourceListHandler)
      Creates an instance of a McpEndpointRegistration record class.
      Parameters:
      endpointClass - the value for the endpointClass record component
      endpointPathDeclaration - the value for the endpointPathDeclaration record component
      name - the value for the name record component
      version - the value for the version record component
      instructions - the value for the instructions record component
      title - the value for the title record component
      description - the value for the description record component
      websiteUrl - the value for the websiteUrl record component
      toolNames - the value for the toolNames record component
      promptNames - the value for the promptNames record component
      resourceUris - the value for the resourceUris record component
      hasResourceListHandler - the value for the hasResourceListHandler record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • endpointClass

      public @NonNull Class<? extends McpEndpoint> endpointClass()
      Returns the value of the endpointClass record component.
      Returns:
      the value of the endpointClass record component
    • endpointPathDeclaration

      Returns the value of the endpointPathDeclaration record component.
      Returns:
      the value of the endpointPathDeclaration record component
    • name

      public @NonNull String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • version

      Returns the value of the version record component.
      Returns:
      the value of the version record component
    • instructions

      Returns the value of the instructions record component.
      Returns:
      the value of the instructions record component
    • title

      Returns the value of the title record component.
      Returns:
      the value of the title record component
    • description

      Returns the value of the description record component.
      Returns:
      the value of the description record component
    • websiteUrl

      Returns the value of the websiteUrl record component.
      Returns:
      the value of the websiteUrl record component
    • toolNames

      Returns the value of the toolNames record component.
      Returns:
      the value of the toolNames record component
    • promptNames

      Returns the value of the promptNames record component.
      Returns:
      the value of the promptNames record component
    • resourceUris

      Returns the value of the resourceUris record component.
      Returns:
      the value of the resourceUris record component
    • hasResourceListHandler

      Returns the value of the hasResourceListHandler record component.
      Returns:
      the value of the hasResourceListHandler record component