OneOfVariant
sttp.tapir.EndpointOutput$.OneOfVariant
Specifies one possible output
.
When encoding to a response, this output is used if:
appliesTo
applied to the output value (as returned by the server logic) returnstrue
.- when a fixed content type specified by the output matches the request's
Accept
header
When decoding from a response, this output is used if it decodes successfully.
The appliesTo
function should determine, whether a runtime value matches the type O
. This check cannot be in general done by
checking the run-time class of the value, due to type erasure (if O
has type parameters).
Attributes
- Graph
- Supertypes
- trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any