struct Athena::Routing::Converters::RequestBody(T)
- Athena::Routing::Converters::RequestBody(T)
- Struct
- Value
- Object
Overview
Resolves the request body into type T
.
Defined in:
routing/converters.crConstructors
Class Method Summary
-
.convert(body : String) : T
Deserializes the request body into an object of
T
.
Instance Method Summary
Constructor Detail
Class Method Detail
def self.convert(body : String) : T
#
Deserializes the request body into an object of T
.
Raises a CrSerializer::Exceptions::ValidationException
if the object is not valid.
NOTE Requires T
to include CrSerializer
or implements a self.deserialize(body : String) : self
method to instantiate the object from the request body.