private void setNextState(final int stateId) {
    nextState = stateId;
  }
Set the next state for the procedure.

@param stateId the ordinal() of the state enum (or state id)
iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/procedure/impl/StateMachineProcedure.java