pretty_http_logger library

Classes

HttpClientWithMiddleware
Class to be used by the user to set up a new http.Client with middleware supported. call the build() constructor passing in the list of middlewares. Example:
HttpLogger
A custom Middleware interface for http. It extends `MiddlewareContract`` class and override the three functions to intercept.
HttpWithMiddleware
Class to be used by the user as a replacement for 'http' with middleware supported. call the build() constructor passing in the list of middlewares. Example:
Logger
Logger interface to log out request and response data on console. Use this class as a parameter of HttpWithMiddleware or HttpClientWithMiddleware such as
MiddlewareContract
Middleware interface to create custom middleware for http. Extend this class and override the functions that you want to intercept.
RequestData
Request object, internally used by the library. The network request app makes is broken down into pieces to be used by the library. You can also modify the RequestData before the request is made For Example, if you want to wrap your data in a particular structure before sending, or you want every request header to have Content-Type set to application/json.
ResponseData
Response object, internally used by the library. The network request is received it is broken down into pieces to be used by the library. You can also modify every ResponseData after every response is received. For Example, if you want to only deal with data of the response.

Enums

LogLevel
Log level of BASIC will print only the basic info to console such as Method Type, Request URL and Request Body. In case of Response it will print only status code and content-length
Method

Functions

methodFromString(String method) Method