code: public void setState(S state){
  		Integer id = definition.getStateId(state);
  		currentStateId.set(id);
  	}
docs: Set current state of the state machine. This method is multi-thread safe.
  @param state  the current state to be, must have already been defined.