Interface McpResourceTemplateHandler.ReadFunction
- Enclosing interface:
- McpResourceTemplateHandler
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A three-argument function from (
uri, variables, ctx) to a
McpResourceOutcome, matching read(String, Map, BeanStore)'s signature.
A dedicated functional interface rather than BiFunction because
read(...) takes three parameters, not two.
-
Method Summary
-
Method Details
-
read
Reads the resource body for a concrete URI matched against the template.- Parameters:
uri- The original concrete URI from theresources/readrequest.variables- An immutable, insertion-ordered map of the template's declared variables to their decoded values, captured fromuri.ctx- Per-request bean store. Nevernull.- Returns:
- The resource contents, or
nullif this template does not serveuri.
-