Skip to content

krushnajena/APPublicIP

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

APPublicIP

Get the device's current public IP Address. Based on https://www.ipify.org/ (unlimited requests for free)

One shot

let ipChecker = APPublicIP();
ipChecker.getCurrentIP { (ip) -> Void in
        println(ip)
}

Listen to any IP Address change.

let ipChecker = APPublicIP();
ipChecker.checkForCurrentIP({ (ip) -> Void in
        println(ip)
}, interval: 0.5.second)

Installation

As for now please clone the repository and drag the source folder into your project to use APPublicIP

This project uses https://github.com/radex/SwiftyTimer from Radek Pietruszewski

License

APPublicIP is available under the MIT license. See the LICENSE file for more info.

About

Swift library to get the device's current public IP Address. Based on https://www.ipify.org/

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Swift 100.0%