SimpleInterceptor class
An interceptor where you can specify the behavior in the constructor without creating a new class.
- Inheritance
-
- Object
- Interceptor
- SimpleInterceptor
Constructors
-
SimpleInterceptor.new({Future<
InterceptorResult< beforeRequest(HttpRequest request)?, Future<HttpRequest> >InterceptorResult< afterResponse(HttpResponse response)?, Future<HttpResponse> >InterceptorResult< onError(RhttpException exception)?})RhttpException> >
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
-
afterResponse(
HttpResponse response) → Future< InterceptorResult< HttpResponse> > -
Called before the response is returned.
override
-
beforeRequest(
HttpRequest request) → Future< InterceptorResult< HttpRequest> > -
Called before the request is sent.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
onError(
RhttpException exception) → Future< InterceptorResult< RhttpException> > -
Called when an exception is thrown.
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited