NetworkRequest class

Constructors

NetworkRequest({required dynamic api, dynamic data, bool callDefaults = true, dynamic timeOut = const Duration(seconds: 30), bool handleErrors = true, bool handleSuccess = true, dynamic retry(bool force, NetworkResponse response)?, void onReceiveProgress(int, int)?, String? savePath, String compressDataKey = "Body", bool useCompression = false})
factory

Properties

api String
final
callDefaults bool
final
compressDataKey String
final
data → dynamic
final
dio → Dio
final
handleErrors bool
final
handleSuccess bool
final
hashCode int
The hash code for this object.
no setterinherited
isCancelable bool
final
onReceiveProgress → (dynamic Function(int, int)?)
final
options NetworkOption
final
retry → (dynamic Function(bool force, NetworkResponse response)?)
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
savePath String?
final
timeOut Duration
final
useCompression bool
final

Methods

delete() Future<NetworkResponse>
download() Future<NetworkResponse>
get() Future<NetworkResponse>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
post() Future<NetworkResponse>
put() Future<NetworkResponse>
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited