when<T> abstract method

T when<T>({
  1. required T request(
    1. RequestChatEvent
    ),
  2. required T response(
    1. ResponseChatEvent
    ),
})

Implementation

T when<T>({
  required T Function(RequestChatEvent) request,
  required T Function(ResponseChatEvent) response,
});