HandlerImage module¶
-
class
handler.HandlerErrors.
HandlerErrors
¶ Bases:
object
Class responsible for handling errors
-
static
sendErrorCode
(request: any, statusCode: <module 'message.StatusCode' from '/home/lucassantos/Documents/GitHub/http-api-without-lib/message/StatusCode.py'>) → bytes¶ Responsible for generating a page with the given status code
- Parameters
request – An object representing the request data. DEPRECATED
statusCode – A StatusCode object containing the the status soon to be shown in the page
- Returns
A byte object containing the response header and the error page in the body.
-
urlTable
= {'/bootstrap.min.css': {'filePath': './assets/bootstrap.min.css', 'type': 'text/css'}, '/bootstrap.min.js': {'filePath': './assets/bootstrap.min.js', 'type': 'text/css'}, '/dashboard.css': {'filePath': './assets/dashboard.css', 'type': 'text/css'}, '/error': {'filePath': './assets/public/error.html', 'type': 'text/html'}, '/logo.ico': {'filePath': './assets/bootstrap-4.0.0/favicon.ico', 'type': 'image/x-icon'}, '/popper.min.js': {'filePath': './assets/popper.min.js', 'type': 'text/css'}}¶
-
static