Пример #1
0
 public void SetStatusReady()
 {
     status = ModuleStatusType.READY;
     if (OnStatusReady != null)
     {
         OnStatusReady();
     }
 }
Пример #2
0
 // Token: 0x06000317 RID: 791 RVA: 0x00013824 File Offset: 0x00011A24
 private static void ProcessUpdateResponse(UpdateResponse response)
 {
     if (response == null)
     {
         throw new ArgumentNullException("response");
     }
     if (!response.Success)
     {
         CoreHelper._log.Error("Process update response failed.");
         return;
     }
     if (response.Manifest != null && response.Manifest.CurrentVersions != null && response.Manifest.CurrentVersions.Length != 0)
     {
         CoreHelper._log.Debug(string.Format("ProcessUpdateResponse: Following response has been received from SolarWind's Server: {0}", Serializer.ToXmlString(response.Manifest.CurrentVersions)));
         foreach (VersionInfo versionInfo in response.Manifest.CurrentVersions)
         {
             ModuleStatusType moduleStatus = versionInfo.ModuleStatus;
             if (moduleStatus != ModuleStatusType.Updated)
             {
                 if (moduleStatus == ModuleStatusType.Current)
                 {
                     MaintenanceRenewalItemDAL itemForProduct = MaintenanceRenewalItemDAL.GetItemForProduct(versionInfo.ProductTag);
                     if (itemForProduct != null)
                     {
                         itemForProduct.Ignored = true;
                         itemForProduct.Update();
                     }
                 }
             }
             else if (CoreHelper.ShowUpdateProductNotification(versionInfo.ProductTag))
             {
                 MaintenanceRenewalItemDAL maintenanceRenewalItemDAL = MaintenanceRenewalItemDAL.GetItemForProduct(versionInfo.ProductTag);
                 if (maintenanceRenewalItemDAL == null)
                 {
                     CoreHelper._log.DebugFormat("Inserting new MaintenanceRenewalItem for product {0}.", versionInfo.ProductTag);
                     maintenanceRenewalItemDAL = MaintUpdateNotifySvcWrapper.GetNotificationItem(versionInfo);
                     MaintenanceRenewalItemDAL.Insert(Guid.NewGuid(), maintenanceRenewalItemDAL.Title, maintenanceRenewalItemDAL.Description, maintenanceRenewalItemDAL.Ignored, maintenanceRenewalItemDAL.Url, maintenanceRenewalItemDAL.AcknowledgedAt, maintenanceRenewalItemDAL.AcknowledgedBy, maintenanceRenewalItemDAL.ProductTag, maintenanceRenewalItemDAL.DateReleased, maintenanceRenewalItemDAL.NewVersion);
                 }
                 else
                 {
                     CoreHelper._log.DebugFormat("Updating existing MaintenanceRenewalItem for product {0}.", versionInfo.ProductTag);
                     MaintUpdateNotifySvcWrapper.UpdateNotificationItem(maintenanceRenewalItemDAL, versionInfo);
                     maintenanceRenewalItemDAL.Update();
                 }
             }
         }
         return;
     }
     CoreHelper._log.Info("No valid modules were submitted, nor found.");
 }
Пример #3
0
 // Use this for initialization
 void Awake()
 {
     status = ModuleStatusType.INIT;
 }