SUVersionComparison
Objective-C
@protocol SUVersionComparison
Swift
protocol SUVersionComparison
Provides version comparison facilities for Sparkle.
-
An abstract method to compare two version strings.
Should return NSOrderedAscending if b > a, NSOrderedDescending if b < a, and NSOrderedSame if they are equivalent.
Declaration
Objective-C
- (NSComparisonResult)compareVersion:(nonnull NSString *)versionA toVersion:(nonnull NSString *)versionB;
Swift
func compareVersion(_ versionA: String, toVersion versionB: String) -> ComparisonResult