add method

Cascade add(
  1. Handler handler
)

Returns a new Cascade instance with the handler added to the end.

The provided handler will only be called if all previous handlers in the cascade return unacceptable responses.

Implementation

Cascade add(Handler handler) {
  return Cascade._(_cascade.add(toShelfHandler(handler)));
}