Easy app version transition recognizer with delegate pattern.
- Import the
RMUpdateDetection.h
in your application. - Download and import @danhanly's awesome
VersionComparator
library from, e.g. GitHub: https://github.com/danhanly/VersionComparator - In your
-(void) applicationDidFinishLoading;
method, set the delegate and trigger the checking.
[[RMUpdateDetection sharedInstance] setDelegate:self];
[[RMUpdateDetection sharedInstance] check];
Implement the delegate protocol, e.g.:
- (void) userDidUpdateFrom: (NSString *) oldVersion to: (NSString *) currentVersion {
// Hurray, the user did update to our most recent version!
}
That's it!
- Raffael Hannemann
- @raffael_me
- http://www.raffael.me/
Copyright (c) 2013 Raffael Hannemann Under BSD License.
Follow @raffael_me for similar releases.