Class McpImplementation
java.lang.Object
com.soklet.McpImplementation
Immutable MCP implementation metadata.
Servers use this value to identify themselves to MCP clients. Client implementation information received from the wire is informational and is not an authenticated identity.
String factories and setters reject unpaired UTF-16 surrogates with
IllegalArgumentException; well-formed Unicode is preserved exactly.
- Author:
- Mark Allen
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilder for immutableMcpImplementationvalues. -
Method Summary
Modifier and TypeMethodDescriptionbooleanThe optional human-readable implementation description.getName()The implementation name.getTitle()The optional human-readable implementation title.The implementation version.The optional absolute website URI for this implementation.inthashCode()withNameAndVersion(@NonNull String name, @NonNull String version) Vends a builder primed with the required implementation name and version.
-
Method Details
-
withNameAndVersion
public static @NonNull McpImplementation.Builder withNameAndVersion(@NonNull String name, @NonNull String version) Vends a builder primed with the required implementation name and version. Client-provided strings are preserved, including blank values. Endpoints require a nonblank name and version for configured server information.- Parameters:
name- the implementation nameversion- the implementation version- Returns:
- a builder for implementation metadata
- Throws:
NullPointerException- ifnameorversionis null
-
getName
-
getVersion
The implementation version.- Returns:
- the implementation version, which may be blank for client information
-
getTitle
-
getDescription
The optional human-readable implementation description.- Returns:
- the description, or the empty optional if none was configured
-
getWebsiteUrl
The optional absolute website URI for this implementation.- Returns:
- the website URI, or the empty optional if none was configured
-
equals
-
hashCode
-