GetHttpClient class
Constructors
-
GetHttpClient({String userAgent = 'getx-client', Duration timeout = const Duration(seconds: 8), bool followRedirects = true, int maxRedirects = 5, bool sendUserAgent = false, int maxAuthRetries = 1, bool allowAutoSignedCert = false, String? baseUrl, List<
TrustedCertificate> ? trustedCertificates, bool withCredentials = false})
Properties
- baseUrl ↔ String?
-
getter/setter pair
- defaultContentType ↔ String
-
getter/setter pair
- defaultDecoder ↔ Decoder?
-
getter/setter pair
- errorSafety ↔ bool
-
getter/setter pair
- followRedirects ↔ bool
-
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- maxAuthRetries ↔ int
-
getter/setter pair
- maxRedirects ↔ int
-
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- sendUserAgent ↔ bool
-
getter/setter pair
- timeout ↔ Duration
-
getter/setter pair
- userAgent ↔ String
-
getter/setter pair
Methods
-
addAuthenticator<
T> (RequestModifier< T> auth) → void -
addRequestModifier<
T> (RequestModifier< T> interceptor) → void -
addResponseModifier<
T> (ResponseModifier< T> interceptor) → void -
close(
) → void -
delete<
T> (String url, {Map< String, String> ? headers, String? contentType, Map<String, dynamic> ? query, Decoder<T> ? decoder}) → Future<Response< T> > -
get<
T> (String url, {Map< String, String> ? headers, String? contentType, Map<String, dynamic> ? query, Decoder<T> ? decoder}) → Future<Response< T> > -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
patch<
T> (String url, {dynamic body, String? contentType, Map< String, String> ? headers, Map<String, dynamic> ? query, Decoder<T> ? decoder, Progress? uploadProgress}) → Future<Response< T> > -
post<
T> (String? url, {dynamic body, String? contentType, Map< String, String> ? headers, Map<String, dynamic> ? query, Decoder<T> ? decoder, Progress? uploadProgress}) → Future<Response< T> > -
put<
T> (String url, {dynamic body, String? contentType, Map< String, String> ? headers, Map<String, dynamic> ? query, Decoder<T> ? decoder, Progress? uploadProgress}) → Future<Response< T> > -
removeRequestModifier<
T> (RequestModifier< T> interceptor) → void -
removeResponseModifier<
T> (ResponseModifier< T> interceptor) → void -
request<
T> (String url, String method, {dynamic body, String? contentType, Map< String, String> ? headers, Map<String, dynamic> ? query, Decoder<T> ? decoder, Progress? uploadProgress}) → Future<Response< T> > -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited