FetchlyConfig constructor
Constructs a FetchlyConfig instance with optional parameters.
The connectTimeout parameter specifies the connectTimeout duration for HTTP requests,
in seconds. The default value is 60 seconds.
The receiveTimeout parameter specifies the receiveTimeout duration for HTTP requests,
in seconds. The default value is 200 seconds.
The printLimit parameter specifies the limit for printing HTTP response bodies.
If the body exceeds this limit, it will be truncated. The default print limit
is 2500 characters.
The headerLimit parameter specifies the limit for printing HTTP headers.
If the header content exceeds this limit, it will be truncated. The default
header limit is 120 characters.
The showHeader parameter specifies whether HTTP headers should be printed in the logs.
The default value is false.
Example usage:
FetchlyConfig config = FetchlyConfig(connectTimeout: 30, printLimit: 2000);
Implementation
FetchlyConfig(
{this.connectTimeout = 60,
this.receiveTimeout = 200,
this.printLimit = 2500,
this.headerLimit = 120,
this.showHeader = false});