An open API service indexing awesome lists of open source software.

https://github.com/sger/sgreachabilitycontroller


https://github.com/sger/sgreachabilitycontroller

Last synced: 4 months ago
JSON representation

Awesome Lists containing this project

README

          

# Reachability Helper

## Requirements

[https://github.com/tonymillion/Reachability](https://github.com/tonymillion/Reachability)

//Initialize
[TLIReachabilityController sharedController];

//NSNotification example
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(reachabilityDidChange:) name:kReachabilityChangedNotification object:nil];

- (void)reachabilityDidChange:(NSNotification *)notification {
Reachability *reachability = (Reachability *)[notification object];

if ([reachability isReachable]) {
NSLog("Reachable");
} else {
NSLog(@"Not reachable");
}
}