view¶
| authors: | Rémi GATTAZ |
|---|---|
| copyright: | Copyright 2015, IsandlaTech |
| license: | Apache Software License 2.0 |
-
class
restbuilder.views.view.AbstractView¶ Bases:
objectAbstract view
-
redirect(aResponse, aCode, aPath)¶ Send a redirection message
-
show200(aResponse)¶ Return an empty message with a 200 http code
Parameters: aReponse – Response handler
-
show404(aResponse)¶ Return an empty message with a 404 HTTP-code
Parameters: aReponse – Response handler
-
showError(aResponse, aCode, aException)¶ Display an error message containing the exception message. The exception is also logged
Parameters: - aReponse – Response handler
- aCode – http-code of the response
- aException – the exception
-
showMessage(aResponse, aCode, aMessage)¶ Display a message
Parameters: - aReponse – Response handler
- aCode – http-code of the response
- aMessage – a message
-