OneOfMapping
Specifies a correspondence between statusCode
and output
.
A single status code can have multiple mappings, with different body content types. The mapping can then be chosen based on content type negotiation, or the content type header.
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).
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any