public void handleBftEvent(final BftEvent bftEvent) {
    try {
      switch (bftEvent.getType()) {
        case MESSAGE:
          final BftReceivedMessageEvent rxEvent = (BftReceivedMessageEvent) bftEvent;
          eventHandler.handleMessageEvent(rxEvent);
          break;
        case ROUND_EXPIRY:
          final RoundExpiry roundExpiryEvent = (RoundExpiry) bftEvent;
          eventHandler.handleRoundExpiry(roundExpiryEvent);
          break;
        case NEW_CHAIN_HEAD:
          final NewChainHead newChainHead = (NewChainHead) bftEvent;
          eventHandler.handleNewBlockEvent(newChainHead);
          break;
        case BLOCK_TIMER_EXPIRY:
          final BlockTimerExpiry blockTimerExpiry = (BlockTimerExpiry) bftEvent;
          eventHandler.handleBlockTimerExpiry(blockTimerExpiry);
          break;
        default:
          throw new RuntimeException("Illegal event in queue.");
      }
    } catch (final Exception e) {
      LOG.error("State machine threw exception while processing event \\{" + bftEvent + "\\}", e);
    }
  }
Handle bft event.

@param bftEvent the bft event
consensus/common/src/main/java/org/hyperledger/besu/consensus/common/bft/EventMultiplexer.java