HBResponseEncodable
public protocol HBResponseEncodable : HBResponseGenerator, Encodable
Protocol for encodable object that can generate a response. The router will encode
the response using the encoder stored in HBApplication.encoder
.
-
response(from:)
Extension methodDeclaration
Swift
public func response(from request: HBRequest) throws -> HBResponse