Marten::HTTP::Request
Inherits Marten::Template::Object::Auto / Marten::Template::Object / Marten::Template::CanDefineTemplateAttributes / Reference / Object
Represents an HTTP request processed by Marten.
When a page is request, Marten creates a Marten::HTTP::Request that gives access to all the information and
metadata of the incoming request.
Constructors
Instance methods
Returns true if the passed media type is accepted by the request.
Allows to assign a new content security policy to the request (or reset it if the passed value is nil).
Returns the value of a Content-Security-Policy nonce associated with the request.
Returns the flash store for the considered request.
If no flash store was previously set (for example if the flash middleware is not used), a NilAssertionError
exception will be raised.
Returns a string representation of HTTP method that was used in the request.
The returned method name (eg. "GET" or "POST") is completely uppercase.
Returns the request path as a string.
Only the path of the request is included (without scheme or domain).
Returns the session store for the considered request.
If no session store was previously set (for example if the session middleware is not set), a NilAssertionError
exception will be raised.
Allows to set the session store for the request.