public <T extends Exception> Javalin wsException(@NotNull Class<T> exceptionClass, @NotNull WsExceptionHandler<? super T> exceptionHandler) {
        wsServlet.getWsExceptionMapper().getHandlers().put(exceptionClass, (WsExceptionHandler<Exception>) exceptionHandler);
        return this;
    }
public < T extends Exception > Javalin wsException ( @ NotNull Class < T > exceptionClass , @ NotNull WsExceptionHandler < ? super T > exceptionHandler ) { wsServlet . getWsExceptionMapper ( ) . getHandlers ( ) . put ( exceptionClass , ( WsExceptionHandler < Exception > ) exceptionHandler ) ; return this ; }
Adds a WebSocket exception mapper to the instance.

@see <a href="https://javalin.io/documentation#exception-mapping">Exception mapping in docs</a>