ExceptionFilter<T> class abstract interface

Exception filter interface.

The use of interfaces is to create filters in a more standardized manner.

Example

class MyException {}

class MyExceptionFilter implements ExceptionFilter<MyException> {
    Future<Response> process(Event event, ExceptionSource<MyException> source) {
        return Response.text('My exception');
    }
}

app.use(withExceptionFilter(MyExceptionFilter()));

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
process(Event event, ExceptionSource<T> source) Future<Response?>
Handling exceptions.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited