ReachabilityMonitor
public class ReachabilityMonitor
The ReachabilityMonitor
class is used to monitor the network reachability. Any changes to the reachability causes a
message to be sent to the delegate, indicating a change in network reachability has occurred.
-
The object that acts as the delegate for the monitor.
Declaration
Swift
public weak var delegate: ReachabilityMonitorDelegate?
-
Indicates whether the monitor is active or not.
Declaration
Swift
public fileprivate(set) var isActive = false
-
Indicates whether or not the device is connected to the internet.
Declaration
Swift
public var isConnectedToInternet: Bool
-
Initializes an instance of the
ReachabilityMonitor
class.Declaration
Swift
public init()
-
Starts monitoring the device’s internet reachability.
Declaration
Swift
public func start() throws
-
Stops monitoring the device’s internet reachability.
Declaration
Swift
public func stop()