module Orion::Controller

Overview

The Orion::Controller module can be included in any struct or class to add the various helpers methods to make constructing your application easier.

Included Modules

Defined in:

orion/controller.cr
orion/controller/request_helpers.cr

Instance Method Summary

Instance methods inherited from module Orion::Controller::ResponseHelpers

content_type=(content_type) content_type=, response response, status=(status) status=, status_code=(status_code) status_code=

Instance methods inherited from module Orion::Controller::RequestHelpers

format format, formats formats, host host, hostname hostname, path_params path_params, query_params query_params, remote_address remote_address, request request, resource resource

Instance Method Detail

def context : Server::Context #

The http context


[View source]
def websocket : HTTP::WebSocket #

The websocket, if the controller was initialized from a ws route.


[View source]
def websocket? : HTTP::WebSocket | Nil #

The websocket, if the controller was initialized from a ws route.


[View source]