WaitForWork.cs 823 B

1234567891011121314151617181920212223242526
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. using Wayne.Lib.StateEngine;
  7. using Wayne.Lib.StateEngine.Generic;
  8. namespace SinochemInternetPlusApp.EpsTrxCleanup.States
  9. {
  10. class WaitForWork : TimeoutState<EpsTrxCleanupManager>
  11. {
  12. protected override int TimeoutInterval =>
  13. TimeoutValues.GetValueInMilliSec(TimeoutValues.EpsTrxCleanup.WaitForWork, 30);
  14. protected override void HandleNonTimeoutEvent(StateEngineEvent stateEngineEvent, ref Transition transition)
  15. {
  16. DebugLog("WaitForWork state, should not be here!!!");
  17. }
  18. protected override void Timeout(ref Transition transition)
  19. {
  20. transition = new Transition(this, TransitionType.WorkStarted);
  21. }
  22. }
  23. }