XenAdmin.Wizards.PatchingWizard.PatchingWizard_SelectServers.disableNotApplicableHosts C# (CSharp) Méthode

disableNotApplicableHosts() private méthode

private disableNotApplicableHosts ( PatchingHostsDataGridViewRow row, List selectedHosts, XenAPI.Host host ) : void
row PatchingHostsDataGridViewRow
selectedHosts List
host XenAPI.Host
Résultat void
        private void disableNotApplicableHosts(PatchingHostsDataGridViewRow row, List<Host> selectedHosts, Host host)
        {
            if (selectedHosts != null && !selectedHosts.Contains(host))
            {
                string patchUuidFromAlert = null;
                if (SelectedUpdateAlert != null && SelectedUpdateAlert.Patch != null)
                {
                    patchUuidFromAlert = SelectedUpdateAlert.Patch.Uuid;
                }
                else if (FileFromDiskAlert != null)
                {
                    patchUuidFromAlert = FileFromDiskAlert.Patch.Uuid;
                }

                if (!string.IsNullOrEmpty(patchUuidFromAlert))
                {
                    if (isPatchApplied(patchUuidFromAlert, host))
                    {
                        row.Cells[3].ToolTipText = Messages.PATCHINGWIZARD_SELECTSERVERPAGE_PATCH_ALREADY_APPLIED;
                    }
                    else
                    {
                        row.Cells[3].ToolTipText = Messages.PATCHINGWIZARD_SELECTSERVERPAGE_PATCH_NOT_APPLICABLE;
                    }
                    row.Enabled = false;
                }
            }
        }