Exemplo n.º 1
0
 public ReturnValue StopCurrentBikeTest(out BikeTest oldBikeTest)
 {
     if (TestStatus == BikeTestStatus.Started)
     {
         oldBikeTest = _lastBikeTestBuff;
         return ReturnValue.Success;
     }
     else if (TestStatus == BikeTestStatus.Stopped)
     {
         oldBikeTest = null;
         return ReturnValue.AlreadyStopped;
     }
     else
     {
         oldBikeTest = null;
         return ReturnValue.Error;
     }
 }
Exemplo n.º 2
0
 public void AddBikeTest(BikeTest bikeTest)
 {
     _bikeTests.Add(bikeTest);
 }
Exemplo n.º 3
0
 public ReturnValue StartNewBikeTest(BikeTest bikeTest)
 {
     if (TestStatus == BikeTestStatus.Stopped)
     {
         if (bikeTest != null)
         {
             _lastBikeTestBuff = bikeTest;
         }
         return ReturnValue.Success;
     }
     else if (TestStatus == BikeTestStatus.Started)
     {
         return ReturnValue.AlreadyStarted;
     }
     else
     {
         return ReturnValue.Error;
     }
 }