module HelloWorld
A simple middleware that always returns "Hello World!".
Definitions
def self.close
Close the middleware - idempotent no-op.
Implementation
def self.close
end
def self.call(request)
Call the middleware with the given request.
Signature
-
parameter
request
Request
The request object.
-
returns
Response
The response object, whihc always contains "Hello World!".
Implementation
def self.call(request)
Response[200, Headers["content-type" => "text/plain"], ["Hello World!"]]
end