HulkRepository constructor
HulkRepository({
- InterceptorSendCallback? requestInterceptor,
- InterceptorSuccessCallback? responseInterceptor,
- InterceptorErrorCallback? errorInterceptor,
Implementation
HulkRepository({
InterceptorSendCallback? requestInterceptor,
InterceptorSuccessCallback? responseInterceptor,
InterceptorErrorCallback? errorInterceptor,
}) {
httpClient = Dio();
httpClient.options.headers[HttpHeaders.contentTypeHeader] =
'application/json';
addInterceptors(
requestInterceptor: requestInterceptor,
responseInterceptor: responseInterceptor,
errorInterceptor: errorInterceptor,
);
_instances.add(this);
}