// Checking void CheckState(DNMState expectedState) { if (state != expectedState) { WrongState(state.ToString()); } }
void SetState(DNMState newState) { if (state == newState) { Log.Warn("Repeated state"); return; } state = newState; Info.Set("DNMState", state.ToString()); OnStateChanged(state); }