UHttpClient class abstract

Constructors

UHttpClient()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

onAuthFailed Future<void> Function()?
getter/setter pair

Static Methods

multipartFileFromFile(String fieldName, File file, {String? filename, MediaType? contentType}) Future<MultipartFile>
multipartFileFromUint8List(String fieldName, Uint8List bytes, {String? filename, MediaType? contentType}) Future<MultipartFile>
removeNullEntries<T>(T? json) → T?
send({required String method, required String endpoint, required dynamic onSuccess(Response), required dynamic onError(Response), required dynamic onException(String), Map<String, String>? headers, Map<String, dynamic>? queryParams, dynamic body, URequestBodyType bodyType = URequestBodyType.json, String? noNetworkMessage, String? unexpectedErrorMessage, bool offline = false, Duration? cacheDuration, int retryAmount = 3, Duration timeout = const Duration(seconds: 30), void onProgress(int percent)?, bool isRetryAfterRefresh = false}) Future<UHttpClientResponse>
upload({required String endpoint, required List<MultipartFile> files, required dynamic onSuccess(Response)?, required dynamic onError(Response)?, required VoidCallback onException, Map<String, dynamic>? fields, Map<String, String>? headers, Map<String, dynamic>? queryParams, String method = "POST", Duration timeout = const Duration(minutes: 5), void onProgress(int percent)?}) Future<void>