HeaderInterceptor class
An interceptor that adds common headers to all requests
- Inheritance
-
- Object
- Interceptor
- HeaderInterceptor
Constructors
-
HeaderInterceptor(Map<
String, String> headers) - Creates a header interceptor with the specified headers
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
-
onError(
Object error) → Future< void> -
Called when an error occurs.
inherited
-
onRequest(
BaseRequest request) → Future< void> -
Called before a request is sent.
override
-
onResponse(
Response response) → Future< void> -
Called after a response is received.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited