/// <summary> /// Returns if the <paramref name="version"/> is a valid database version. /// </summary> /// <param name="version">The version to compare.</param> /// <returns><c>true</c> if <paramref name="version"/> is a valid database version, /// <c>false</c> otherwise.</returns> /// <remarks>A valid version must be greater than <see cref="validDatabaseVersion"/>.</remarks> public static bool IsValidVersion(string version) { var versionComparer = new ProjectVersionComparer(); return(versionComparer.Compare(version, validDatabaseVersion) >= 0); }
/// <summary> /// Returns if the <paramref name="version"/> is newer than the current database version. /// </summary> /// <param name="version">The version to compare.</param> /// <returns><c>true</c> if <paramref name="version"/> is newer than the current /// database version, <c>false</c> otherwise.</returns> public static bool IsNewerThanCurrent(string version) { var versionComparer = new ProjectVersionComparer(); return(versionComparer.Compare(version, currentDatabaseVersion) > 0); }