(host?: string)
| 22 | } |
| 23 | |
| 24 | function _getReachabilityFlags(host?: string): number { |
| 25 | const reachability = _createReachability(host); |
| 26 | const flagsRef = new interop.Reference<number>(); |
| 27 | const gotFlags = SCNetworkReachabilityGetFlags(reachability, flagsRef); |
| 28 | if (!gotFlags) { |
| 29 | return null; |
| 30 | } |
| 31 | |
| 32 | return flagsRef.value; |
| 33 | } |
| 34 | |
| 35 | function _getConnectionType(host?: string): number { |
| 36 | const flags = _getReachabilityFlags(host); |
no test coverage detected