docs: public final void onEvent(EventType event, Selector selector) {
      if (isClosed()) {
        return;
      }
      SelectionKey key = selectableChannel.keyFor(selector);
  
      switch (event) {
        case EXPIRED:
          onExpired();
          break;
        case WRITEABLE:
          onWrite(key);
          break;
        case READABLE:
          onRead(key);
          break;
        case ENABLE_WRITE:
          enableWrite(selector);
          break;
        case ENABLE_READ:
          enableRead(selector);
          break;
        case IDLE:
          onIdle();
          break;
        case CONNECTED:
          onConnected();
          break;
        default:
          log.error("Unknown event:" + event.name());
          break;
      }
    }