Package io.modelcontextprotocol.spec
Record Class McpSchema.LegacyTitledEnumSchema
java.lang.Object
java.lang.Record
io.modelcontextprotocol.spec.McpSchema.LegacyTitledEnumSchema
- Record Components:
title- Optional title for the enum fielddescription- Optional description for the enum fieldenumValues- Array of enum values to choose fromenumNames- Optional display names for enum values (non-standard per JSON Schema 2020-12)defaultValue- Optional default value
- Enclosing class:
- McpSchema
@Deprecated
public static record McpSchema.LegacyTitledEnumSchema(String title, String description, List<String> enumValues, List<String> enumNames, String defaultValue)
extends Record
Deprecated.
Legacy enum schema with optional display names via the non-standard
enumNames property. Use McpSchema.TitledSingleSelectEnumSchema instead.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classDeprecated. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Deprecated.Deprecated.Returns the value of thedefaultValuerecord component.Deprecated.Returns the value of thedescriptionrecord component.Deprecated.Returns the value of theenumNamesrecord component.Deprecated.Returns the value of theenumValuesrecord component.final booleanDeprecated.Indicates whether some other object is "equal to" this one.final inthashCode()Deprecated.Returns a hash code value for this object.title()Deprecated.Returns the value of thetitlerecord component.final StringtoString()Deprecated.Returns a string representation of this record class.type()Deprecated.
-
Constructor Details
-
LegacyTitledEnumSchema
public LegacyTitledEnumSchema(String title, String description, List<String> enumValues, List<String> enumNames, String defaultValue) Deprecated.Creates an instance of aLegacyTitledEnumSchemarecord class.- Parameters:
title- the value for thetitlerecord componentdescription- the value for thedescriptionrecord componentenumValues- the value for theenumValuesrecord componentenumNames- the value for theenumNamesrecord componentdefaultValue- the value for thedefaultValuerecord component
-
-
Method Details
-
type
Deprecated. -
builder
Deprecated. -
toString
Deprecated.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. -
hashCode
public final int hashCode()Deprecated.Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Deprecated.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 withObjects::equals(Object,Object). -
title
Deprecated.Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
description
Deprecated.Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-
enumValues
Deprecated.Returns the value of theenumValuesrecord component.- Returns:
- the value of the
enumValuesrecord component
-
enumNames
Deprecated.Returns the value of theenumNamesrecord component.- Returns:
- the value of the
enumNamesrecord component
-
defaultValue
Deprecated.Returns the value of thedefaultValuerecord component.- Returns:
- the value of the
defaultValuerecord component
-
McpSchema.TitledSingleSelectEnumSchemainstead