Redirect
class¶
esmerald.datastructures.redirect.Redirect
¶
Bases: ResponseContainer[RedirectResponse]
path
instance-attribute
¶
path
The url path to redirect.
This should be in format of /<str>
.
Example: /redirect-page
.
to_response
¶
to_response(headers, media_type, status_code, app)
PARAMETER | DESCRIPTION |
---|---|
headers
|
TYPE:
|
media_type
|
TYPE:
|
status_code
|
TYPE:
|
app
|
TYPE:
|
Source code in esmerald/datastructures/redirect.py
26 27 28 29 30 31 32 33 34 35 36 37 38 |
|