Defines an error handler for exceptions thrown in either the before block or a route action.
Defines an error handler for exceptions thrown in either the before block or a route action.
If the error handler does not match, the result falls through to the previously defined error handler. The default error handler simply rethrows the exception.
The error handler is run before the after filters, and the result is rendered like a standard response. It is the error handler's responsibility to set any appropriate status code.
Defines a block to run if matching routes are found only for other methods.
Defines a block to run if matching routes are found only for other methods. The set of matching methods is passed to the block.
Defines a block to run if no matching routes are found, or if all matching routes pass.
Defines a block to run if no matching routes are found, or if all matching routes pass.
The base path for URL generation
The base path for URL generation
Prepends a new route for the given HTTP method.
Prepends a new route for the given HTTP method.
Can be overriden so that subtraits can use their own logic. Possible examples: $ - restricting protocols $ - namespace routes based on class name $ - raising errors on overlapping entries.
This is the method invoked by get(), post() etc.
skinny.micro.SkinnyMicroKernel#removeRoute
Adds a filter to run after the route.
Adds a filter to run after the route. The filter only runs if each routeMatcher returns Some. If the routeMatchers list is empty, the filter runs for all routes.
Adds a filter to run before the route.
Adds a filter to run before the route. The filter only runs if each routeMatcher returns Some. If the routeMatchers list is empty, the filter runs for all routes.
The configuration, typically a ServletConfig or FilterConfig.
The configuration, typically a ServletConfig or FilterConfig.
Immediately halts processing of a request.
Immediately halts processing of a request. Can be called from either a before filter or a route.
the status to set on the response, or null to leave the status unchanged.
a result to render through the render pipeline as the body
headers to add to the response
the HTTP status reason to set, or null to leave unchanged.
Gets an init parameter from the config.
Gets an init parameter from the config.
the name of the key
an option containing the value of the parameter if defined, or
None
if the parameter is not set.
Initializes the kernel.
Initializes the kernel. Used to provide context that is unavailable
when the instance is constructed, for example the servlet lifecycle.
Should set the config
variable to the parameter.
the configuration.
Immediately exits from the current route.
Immediately exits from the current route.
The routes registered in this kernel.
The routes registered in this kernel.
The servlet context in which this kernel runs.
The servlet context in which this kernel runs.
A hook to shutdown the class.
A hook to shutdown the class. Bridges the gap between servlet's destroy and filter's destroy.
Skinny Micro Context
Skinny Micro Context
trap
Error handler for HTTP response status code range.
Error handler for HTTP response status code range. You can intercept every response code previously specified with #status or even generic 404 error.
trap(403) { "You are not authorized" } }*
}}
Enables unstable access validation.
Enables unstable access validation.
Enables mostly stable Servlet HttpSession implementation instead.
Enables mostly stable Servlet HttpSession implementation instead.
Executes the block with the given request bound to the request
method.
Executes the block with the given request bound to the request
method.
Executes the block with the given response bound to the response
method.
Executes the block with the given response bound to the response
method.
Built-in features in SkinnyMicroFilter/SkinnyMicroServlet. These traits should not be mixed in SkinnyMicroBase.