Esempio n. 1
0
 public override void ProcessInput(object input, out State newState)
 {
     if (input.Equals(PrivateInput.GoToReadyToInstall))
     {
         newState = new ReadyToInstallState(this.installerPath, this.newVersionInfo);
     }
     else if (input.Equals(PrivateInput.GoToError))
     {
         string errorMessage = PdnResources.GetString("Updates.ExtractingState.GenericError");
         newState = new ErrorState(this.exception, errorMessage);
     }
     else if (input.Equals(PrivateInput.GoToAborted))
     {
         newState = new AbortedState();
     }
     else
     {
         throw new ArgumentException();
     }
 }
Esempio n. 2
0
 public override void ProcessInput(object input, out State newState)
 {
     if (input.Equals(PrivateInput.GoToReadyToInstall))
     {
         newState = new ReadyToInstallState(this.installerPath, this.newVersionInfo);
     }
     else if (input.Equals(PrivateInput.GoToError))
     {
         string errorMessage = PdnResources.GetString("Updates.ExtractingState.GenericError");
         newState = new ErrorState(this.exception, errorMessage);
     }
     else if (input.Equals(PrivateInput.GoToAborted))
     {
         newState = new AbortedState();
     }
     else
     {
         throw new ArgumentException();
     }
 }