Refactor and fix some docs

This commit is contained in:
Serdar Dogruyol 2018-03-17 15:35:33 +03:00
parent 11295f0584
commit 536108c71b
5 changed files with 1 additions and 5 deletions

View file

@ -2,7 +2,7 @@ module Kemal
# `Kemal::Handler` is a subclass of `HTTP::Handler`. # `Kemal::Handler` is a subclass of `HTTP::Handler`.
# #
# It adds `only`, `only_match?`, `exclude`, `exclude_match?`. # It adds `only`, `only_match?`, `exclude`, `exclude_match?`.
# These methods are useful for custom handlers for conditional execution. # These methods are useful for the conditional execution of custom handlers .
class Handler class Handler
include HTTP::Handler include HTTP::Handler
@@only_routes_tree = Radix::Tree(String).new @@only_routes_tree = Radix::Tree(String).new

View file

@ -1,8 +1,6 @@
require "radix" require "radix"
module Kemal module Kemal
# Main handler which handles all the HTTP requests.
# Routing, parsing, rendering e.g are done in this handler.
class RouteHandler class RouteHandler
include HTTP::Handler include HTTP::Handler
INSTANCE = new INSTANCE = new

View file

@ -1,6 +1,4 @@
module Kemal module Kemal
# Used for building a WebSocket route.
# For each WebSocket route a new handler is created and registered to global handlers.
class WebSocketHandler class WebSocketHandler
include HTTP::Handler include HTTP::Handler
INSTANCE = new INSTANCE = new