Note: Same action method name should be registered several times.
Note: Same action method name should be registered several times. For example, put("/members/:id")(...).as('update) and patch("/members/:id")(...).as('update).
Adds action definition
Adds error handler which doesn't return result to SkinnyController.
Adds error handler which doesn't return result to SkinnyController.
Add param to params in the request scope.
Registers afterAction to this controller.
Registers afterAction to this controller.
this action should be applied only for these action methods
this action should not be applied for these action methods
action
If you prefer #afterFilter than #afterAction, keep going!
If you prefer #afterFilter than #afterAction, keep going!
Registers beforeAction to this controller.
Registers beforeAction to this controller.
this action should be applied only for these action methods
this action should not be applied for these action methods
action
If you prefer #beforeFilter than #beforeAction, keep going!
If you prefer #beforeFilter than #beforeAction, keep going!
Creates skinny.
Creates skinny.I18n instance for current locale.
current locale
i18n provider
Creates a RenderContext instance for Skinny app.
Creates a RenderContext instance for Skinny app.
Creates TemplateEngine instance for Skinny app.
Creates TemplateEngine instance for Skinny app.
configuration
TemplateEngine instance
Overrides Scalatra's default key name.
Overrides Scalatra's default key name.
Returns action name for this request.
Returns current locale for this request.
Returns current locale for this request.
current locale
Returns default locale.
Returns default locale.
Overrides to make the template path simpler.
Overrides to make the template path simpler.
paths
Returns errorMessages in the RequestScope.
Returns errorMessages in the RequestScope.
Generates a sample page for absent page.
Generates a sample page for absent page.
Fetches value from request scope.
Fetches value from request scope.
type
key
value if exists
Halts with body which responds to the specified format.
Halts with body which responds to the specified format.
response type
http status
format (HTML,JSON,XML...)
body if possible
Overrides to skip execution when the current request matches excluded patterns.
Overrides to skip execution when the current request matches excluded patterns.
Handles when CSRF is detected.
Handles when CSRF is detected.
To deal with exceptions.
To deal with exceptions.
http://www.scalatra.org/guides/views/scalate.html#toc_303
Returns keyAndErrorMessages in the RequestScope.
Returns keyAndErrorMessages in the RequestScope.
Replaces layout template for this action.
Replaces layout template for this action.
the layout template path, including extension, e.g. "custom.jade"
The Scalate template type that is searched for first.
The Scalate template type that is searched for first.
Declarative activation of CSRF protection.
Declarative activation of CSRF protection. Of course, highly inspired by Ruby on Rails.
should be applied only for these action methods
should not be applied for these action methods
Renders body with template.
Renders body with template.
path name
format (HTML,JSON,XML...)
body
Renders body which responds to the specified format (JSON, XML) if possible.
Renders body which responds to the specified format (JSON, XML) if possible.
entity
format (HTML,JSON,XML...)
body if possible
Renders body with template.
Renders body with template.
path name
format (HTML,JSON,XML...)
true/false
Set attributes to request scope.
Set attributes to request scope.
collection of key and value.
self
Set attribute to request scope.
Set attribute to request scope.
key and value
self
Returns whole request scope attributes.
Returns whole request scope attributes.
whole attributes
Scalate extension names.
Scalate extension names. Skinny will search for templates in this order.
If you'd like to change the search order, or you want to restrict the search to fewer template languages, override this attribute.
Note that removing unnecessary items from this list will improve the performance of the template engine.
Creates a DecimalFormat instance to be use by default.
Creates a DecimalFormat instance to be use by default.
Returns registered sensitive parameter names.
Returns registered sensitive parameter names.
Session key to store current locale string.
Set attributes to request scope.
Set attributes to request scope.
Set attribute to request scope.
Set attribute to request scope.
Set params which is generated from a model object using Java reflection APIs.
Set params which is generated from a model object using Java reflection APIs.
model instance
Set Content-Type for the format if absent.
Set Content-Type for the format if absent.
format
Set current locale.
Set {{skinny.
Set {{skinny.I18n}} object for the current request to request scope.
context
self
Set params to request scope.
Set params to request scope.
Set params to request scope.
Set params to request scope.
Registered error handlers.
Registered error handlers.
Predicates the template path is available.
Predicates the template path is available.
path name
format (HTML,JSON,XML...)
true/false
Returns the actual template path for the name.
Returns the actual template path for the name.
path name
format (HTML,JSON,XML...)
actual path
Converts string value to snake_case'd value.
Converts string value to snake_case'd value.
string value
snake_case'd value
Defines use snake_case'd keys.
Defines use snake_case'd keys.
true if use snake_case keys (default: false)
Creates new validation form.
Creates new validation form.
params
validations
current locale
validator
Creates new validation form.
Creates new validation form.
validations
current locale
validator
Creates new validation form.
Creates new validation form.
key prefix for error message
params
validations
current locale
validator
Creates new validation form.
Creates new validation form.
params
key prefix for error message
validations
validator
Provides code block with format.
Provides code block with format. If absent, halt as status 406.
response type
format
action
result
(Since version 1.0.0) Use FutureWithContext { implicit ctx => ... } instead
(Since version 2.0.0) format
now means the same as responseFormat
, responseFormat
will be removed eventually
SkinnyController as a Servlet.