summaryrefslogtreecommitdiffstats
path: root/OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h
diff options
context:
space:
mode:
authorSimon Rettberg2019-02-18 11:55:41 +0100
committerSimon Rettberg2019-02-18 11:55:41 +0100
commitae69a754244c4e475c8d2591772ca8e005071d83 (patch)
tree58b3fa7abc2dcfe3c23e1c0ce108950c720826ab /OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h
parentUpdate gitignore (diff)
downloadxscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.tar.gz
xscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.tar.xz
xscreensaver-ae69a754244c4e475c8d2591772ca8e005071d83.zip
Update to 5.42
Diffstat (limited to 'OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h')
-rw-r--r--OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h52
1 files changed, 52 insertions, 0 deletions
diff --git a/OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h b/OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h
new file mode 100644
index 0000000..ed11921
--- /dev/null
+++ b/OSX/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h
@@ -0,0 +1,52 @@
+//
+// SUStandardVersionComparator.h
+// Sparkle
+//
+// Created by Andy Matuschak on 12/21/07.
+// Copyright 2007 Andy Matuschak. All rights reserved.
+//
+
+#ifndef SUSTANDARDVERSIONCOMPARATOR_H
+#define SUSTANDARDVERSIONCOMPARATOR_H
+
+#if __has_feature(modules)
+@import Foundation;
+#else
+#import <Foundation/Foundation.h>
+#endif
+#import "SUExport.h"
+#import "SUVersionComparisonProtocol.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+/*!
+ Sparkle's default version comparator.
+
+ This comparator is adapted from MacPAD, by Kevin Ballard.
+ It's "dumb" in that it does essentially string comparison,
+ in components split by character type.
+*/
+SU_EXPORT @interface SUStandardVersionComparator : NSObject <SUVersionComparison>
+
+/*!
+ Initializes a new instance of the standard version comparator.
+ */
+- (instancetype)init;
+
+/*!
+ Returns a singleton instance of the comparator.
+
+ It is usually preferred to alloc/init new a comparator instead.
+*/
++ (SUStandardVersionComparator *)defaultComparator;
+
+/*!
+ Compares version strings through textual analysis.
+
+ See the implementation for more details.
+*/
+- (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB;
+@end
+
+NS_ASSUME_NONNULL_END
+#endif