Module: Roda::RodaPlugins::TypecastParams::InstanceMethods
- Defined in:
- lib/roda/plugins/typecast_params.rb
Instance Method Summary collapse
-
#typecast_body_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to parameters in the request’s body.
-
#typecast_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to the request’s params (merging query string params and body params).
-
#typecast_query_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to parameters in the request’s query string.
Instance Method Details
#typecast_body_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to parameters in the request’s body. Type conversion methods will be called on the result of this method.
1175 1176 1177 |
# File 'lib/roda/plugins/typecast_params.rb', line 1175 def typecast_body_params @_typecast_body_params ||= self.class::TypecastParams.new(@_request.POST) end |
#typecast_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to the request’s params (merging query string params and body params). Type conversion methods will be called on the result of this method.
1161 1162 1163 |
# File 'lib/roda/plugins/typecast_params.rb', line 1161 def typecast_params @_typecast_params ||= self.class::TypecastParams.new(@_request.params) end |
#typecast_query_params ⇒ Object
Return and cache the instance of the TypecastParams class wrapping access to parameters in the request’s query string. Type conversion methods will be called on the result of this method.
1168 1169 1170 |
# File 'lib/roda/plugins/typecast_params.rb', line 1168 def typecast_query_params @_typecast_query_params ||= self.class::TypecastParams.new(@_request.GET) end |