RestResponse class
- Implemented types
Constructors
- RestResponse(HttpResponse _httpResponse)
Properties
-
bodyData
→ Stream<
List< int> > -
Returns the raw body data.
no setteroverride
- charset → Encoding
-
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
-
headers
→ Map<
String, List< String> > -
no setteroverride
- requestUrl → Uri
-
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- statusCode → int
-
no setteroverride
Methods
-
discard(
) → Future< void> - Discards the body stream.
-
getBody<
T> () → Future< T> -
Returns the response body as
TResult. -
getByteBody(
) → Future< Uint8List> - Returns the response body as Uint8List.
-
getData<
T extends DataObject> (DataBean< T> bean) → Future<T> -
getJsonBody(
) → Future< Map< String, dynamic> > - Returns the response body as json map.
-
getJsonListBody(
) → Future< List> - Returns the response body as json list.
-
getList<
T extends DataObject> (DataBean< T> bean) → Future<List< T> > -
getTextBody(
) → Future< String> - Returns the response body as string.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
throwOnError(
) → Future< void> - Throws an ApiRequestException if the status code is greater or equal to 400.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited