private void InstallCompleteHandler(object sender, EventArgs eventArgs) { lock (_lock) { _installationStatus = EWPIServiceStatus.InstallationComplete; } CheckIISAlive(); }
private void InternalBeginInstallation() { _wpiHelper.InstallProducts( _productsToInstall, true, //search and install dependencies WpiHelper.DeafultLanguage, InstallStatusUpdatedHandler, InstallCompleteHandler ); lock (_lock) { _installationStatus = EWPIServiceStatus.InstallationComplete; } }
public override void Initialize(string[] feeds) { lock (_lock) { if (_installationStatus == EWPIServiceStatus.Installation) { throw new Exception("Invalid state, already in Installation process"); } _installationStatus = EWPIServiceStatus.Initialised; if (_wpiHelper == null) { _wpiHelper = new WpiHelper(feeds); Console.WriteLine("_wpiHelper initialized"); } } }
public override void BeginInstallation(string[] productsToInstall) { lock (_lock) { if (_installationStatus != EWPIServiceStatus.Initialised) { throw new Exception("Invalid state, expected EWPIServiceStatus.Initialised. now: " + _installationStatus); } _installationStatus = EWPIServiceStatus.Installation; _statusMessage = "Preparing for install"; _productsToInstall = new string[productsToInstall.Length]; productsToInstall.CopyTo(_productsToInstall, 0); _installerThread = new Thread(new ThreadStart(InternalBeginInstallation)); _installerThread.Start(); } }