AuthorizationInterceptor class
Interceptor that attaches the authorziation header if needed. If the request already contains the header, it is not overwritten. The token is public, so it can be updated in later stages of the application, for example when rolling tokens are used.
Constructors
- AuthorizationInterceptor(String token, {String type = 'Bearer'})
Properties
Methods
-
interceptStreaming<
TRequest, TResponse> (ClientMethod< TRequest, TResponse> method, Stream<TRequest> requests, CallOptions options, ClientStreamingInvoker<TRequest, TResponse> invoker) → ResponseStream<TResponse> -
interceptUnary<
TRequest, TResponse> (ClientMethod< TRequest, TResponse> method, TRequest request, CallOptions options, ClientUnaryInvoker<TRequest, TResponse> invoker) → ResponseFuture<TResponse> -
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