In the past I mentioned a few libraries that make it easier to test reachability, but unfortunately some issues have come up with updates to the iOS platform.
Here’s a nice up-to-date library for tracking reachability changes with a nice simple blocks based callback called JTSReachability from Jared Sinclair.
This code example from the readme shows how to set up the block to be executed on network status changes:
[responder addHandler:^(JTSNetworkStatus status) {
// Respond to the value of "status"
} forKey:@"MyReachabilityKey"];
And in the dealloc be sure to remove MyReachabilityKey.
You can find JTSReachability on Github here.
A nice simple way to keep track of reachability.
- Open Source: Easy To Use ARC Compatible iOS Reachability Class That Uses GCD And Blocks
- Handy UI Control For Automatically Alerting User When Reachability Is Lost
- Best Resources In iOS Development – March 12, 2012
- Open Source: New Easy Facebook API Helper Library Using Blocks
- Tutorial: How To Avoid Issues When Using Blocks With NSNotificationCenter
Original article: Open Source iOS Library For Easy Blocks Based Reachability Updates
©2014 iOS App Dev Libraries, Controls, Tutorials, Examples and Tools. All Rights Reserved.