Reputation: 866
I'm trying to check if a Host is available in Swift, I am using Apple's Reachability, but I can't get it to work giving it an IP Address and Port, I think my problem is that this requires a struct for the address or something, can somebody please explain / lead me into the right way to do this?
Thanks!
Upvotes: 1
Views: 3417
Reputation: 53231
for a drop in solution in Swift, you might want to take a look here:
https://github.com/ashleymills/Reachability.swift
There are a couple of unsolved issues to (see README), but apart from that it works pretty well.
Upvotes: 1