public boolean setProposedBlock(final Proposal msg) {

    if (!proposalMessage.isPresent()) {
      if (validator.validateProposal(msg)) {
        proposalMessage = Optional.of(msg);
        prepareMessages.removeIf(p -> !validator.validatePrepare(p));
        commitMessages.removeIf(p -> !validator.validateCommit(p));
        updateState();
        return true;
      }
    }

    return false;
  }
Sets proposed block.

@param msg the msg
@return the proposed block
consensus/ibft/src/main/java/org/hyperledger/besu/consensus/ibft/statemachine/RoundState.java