add method

void add(
  1. FittorInterceptor interceptor
)

Adds an interceptor to the end of the chain

Interceptors are executed in the order they are added:

  • For requests: first added = first executed
  • For responses: first added = last executed (reverse order)
  • For errors: first added = first chance to handle

Implementation

void add(FittorInterceptor interceptor) {
  _interceptors.add(interceptor);
}