Class StructuredElicitResult.Builder<T>
java.lang.Object
org.springaicommunity.mcp.context.StructuredElicitResult.Builder<T>
- Enclosing class:
- StructuredElicitResult<T>
-
Method Summary
Modifier and TypeMethodDescriptionaction(io.modelcontextprotocol.spec.McpSchema.ElicitResult.Action action) Sets the action.Adds a single meta entry.build()Builds theStructuredElicitResultinstance.Sets the meta map.structuredContent(U structuredContent) Sets the structured content.
-
Method Details
-
action
public StructuredElicitResult.Builder<T> action(io.modelcontextprotocol.spec.McpSchema.ElicitResult.Action action) Sets the action.- Parameters:
action- the action to set- Returns:
- this builder instance
-
structuredContent
Sets the structured content.- Type Parameters:
U- the type of the structured content- Parameters:
structuredContent- the structured content to set- Returns:
- this builder instance with the correct type
-
meta
Sets the meta map.- Parameters:
meta- the meta map to set- Returns:
- this builder instance
-
addMeta
Adds a single meta entry.- Parameters:
key- the meta keyvalue- the meta value- Returns:
- this builder instance
-
build
Builds theStructuredElicitResultinstance.- Returns:
- a new StructuredElicitResult instance
-