An interface for implementing request and response converters.
Converters convert objects to and from their representation in HTTP.
convertRequest is called before RequestInterceptors and convertResponse is called just after the HTTP response, before ResponseInterceptors.
See JsonConverter and FormUrlEncodedConverter for example implementations.
- Implementers
- Annotations
-
- @immutable
Constructors
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
-
convertRequest(
Request request) → FutureOr< Request> -
Converts the received
Request
to aRequest
which has a body with the HTTP representation of the original body. -
convertResponse<
BodyType, InnerType> (Response response) → FutureOr< Response< BodyType> > -
Converts the received
Response
to aResponse
which has a body of the typeBodyType
. -
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