5 #include "IConnectivityService.h"
6 #include "Reachability.h"
8 #include "CallbackCollection.h"
14 class iOSConnectivityService;
19 Reachability* reachability;
20 NetworkStatus internetStatus;
24 - (NSString *) getCurrentWifiHotSpotName;
26 - (id) initWithConnectivityCallback: (Eegeo::Helpers::TCallback1<Eegeo::iOS::iOSConnectivityService, const
bool&>*) callback;
30 - (void) handleNetworkChange_Callback:(NSNotification *)notice;
45 iOSConnectivityService();
47 ~iOSConnectivityService();
49 bool HasConnectivity();
51 Web::ConnectivityType GetConnectivityType();
53 void RegisterConnectivityChangedCallback(Helpers::ICallback1<const bool&>& callback);
54 void UnregisterConnectivityChangedCallback(Helpers::ICallback1<const bool&>& callback);
56 void SetHasConnectivity(
const bool& hasConnectivity);
58 void ForceConnectivityChangedCallback();
60 const std::string& GetSSIDForCurrentWifi();
63 bool m_hasConnectivity;
64 std::string m_currentSSID;
66 Helpers::CallbackCollection1<const bool&> m_callbacks;
68 static void NetworkChangeCallback(CFNotificationCenterRef center,
void* observer, CFStringRef name,
const void *
object, CFDictionaryRef userInfo);