// Override of the ToString Method public string ToString() { // Serializing Object as CSV return(String.Join(",", ("\"" + Url + "\""), ("\"" + ReferenceDate.ToString("yyyy-MM-dd").Replace(",", "") + "\""), ("\"" + Name.Replace(",", "") + "\" "), ("\"" + Developer.Replace(",", "") + "\""), ("\"" + IsTopDeveloper + "\""), ("\"" + DeveloperURL.Replace(",", "") + "\""), ("\"" + PublicationDate.ToString("yyyy-MM-dd").Replace(",", "") + "\""), ("\"" + Category.Replace(",", "") + "\""), ("\"" + IsFree + "\""), ("\"" + Price + "\""), ("\"" + Reviewers + "\""), ("\"" + Score.Total + "\""), ("\"" + Score.Count + "\""), ("\"" + Score.FiveStars + "\""), ("\"" + Score.FourStars + "\""), ("\"" + Score.ThreeStars + "\""), ("\"" + Score.TwoStars + "\""), ("\"" + Score.OneStars + "\""), ("\"" + LastUpdateDate.ToString("yyyy-MM-dd") + "\""), //("\"" + AppSize + "\""), ("\"" + Instalations.Replace(",", ".") + "\""), ("\"" + CurrentVersion.Replace(",", "") + "\""), ("\"" + MinimumOSVersion.Replace(",", "") + "\""), ("\"" + ContentRating.Replace(",", "") + "\""), ("\"" + HaveInAppPurchases + "\""), ("\"" + DeveloperEmail.Replace(",", "") + "\""), ("\"" + DeveloperWebsite.Replace(",", "") + "\""), ("\"" + DeveloperPrivacyPolicy.Replace(",", "") + "\""), ("\"" + Description.Replace(",", "") + "\""))); }
public Update(UpdateType build) { UpdateType = build; Task.Run(() => SetVersion()).Wait(); switch (UpdateType) { case UpdateType.MapleSeed: CurrentVersion = Assembly.GetEntryAssembly().GetName().Version.ToString(); if (VersionStrings.Length == 2) { LatestVersion = VersionStrings[0]; } break; case UpdateType.MapleSeed2: CurrentVersion = Settings.Version; if (VersionStrings.Length == 2) { LatestVersion = VersionStrings[1]; } break; default: throw new ArgumentOutOfRangeException(); } int currentVersion = int.Parse(CurrentVersion.Replace(".", "")); int latestVersion = int.Parse(LatestVersion.Replace(".", "")); if (currentVersion != latestVersion) { TextLog.MesgLog.WriteLog($"[Version Mismatch] Latest Release: {LatestVersion}", Color.Gray); } if (currentVersion < latestVersion) { IsAvailable = true; } }