All Projects → modernistik → TimeZoneLocate

modernistik / TimeZoneLocate

Licence: MIT license
Time zone for locations offline in Swift (iOS).

Programming Languages

swift
15916 projects
ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to TimeZoneLocate

Timezonefinder
fast python package for finding the timezone of any point on earth (coordinates) offline
Stars: ✭ 242 (+706.67%)
Mutual labels:  timezone, location
simple-location
Adds Basic Location Support to Wordpress
Stars: ✭ 26 (-13.33%)
Mutual labels:  timezone, location
Friend-Time
Discord bot - Friend Time helps your server coordinate times and events by converting times mentioned in chat between time zones!
Stars: ✭ 62 (+106.67%)
Mutual labels:  timezone, time-zones
Googleapi
C# .NET Core Google Api (Maps, Places, Roads, Search, Translate). Supports all endpoints and requests / responses.
Stars: ✭ 346 (+1053.33%)
Mutual labels:  timezone, location
llttz
The easy way to get java TimeZone from latitude/longitude
Stars: ✭ 27 (-10%)
Mutual labels:  timezone, location
flutter examples
Random flutter examples
Stars: ✭ 18 (-40%)
Mutual labels:  location
hms-location-demo
HUAWEI Location Kit sample code encapsulates APIs of the HUAWEI Location Kit. It provides many sample programs for your reference or usage.
Stars: ✭ 32 (+6.67%)
Mutual labels:  location
tz
Time zone support for Elixir
Stars: ✭ 73 (+143.33%)
Mutual labels:  timezone
compact-timezone-list
Simple array of timezones with their long name, tz code, and UTC offset.
Stars: ✭ 33 (+10%)
Mutual labels:  timezone
timezones
Nim timezone library compatible with the standard library.
Stars: ✭ 37 (+23.33%)
Mutual labels:  timezone
locationestimatr.github.io
This is a game where you are put anywhere on earth, and you have to figure out where you are
Stars: ✭ 46 (+53.33%)
Mutual labels:  location
WhirlyGlobe
WhirlyGlobe Development
Stars: ✭ 767 (+2456.67%)
Mutual labels:  location
gpx-builder
Builder of GPX files
Stars: ✭ 25 (-16.67%)
Mutual labels:  location
Positional
An elegant and colorful location information app for Android with Compass, Clock, Level, Sun, Moon, Trail Marker and many other features.
Stars: ✭ 72 (+140%)
Mutual labels:  timezone
wordpress-geo-mashup
Official repository for Geo Mashup, the plugin that makes WordPress into a GeoCMS. Documentation:
Stars: ✭ 60 (+100%)
Mutual labels:  location
slack-timezone-bot
🤖⏰ Slack bot to show time in users' timezones
Stars: ✭ 51 (+70%)
Mutual labels:  timezone
s60-maps
Yet another maps for Symbian OS
Stars: ✭ 27 (-10%)
Mutual labels:  location
VzAddress-Craft
Address fieldtype for the Craft CMS
Stars: ✭ 30 (+0%)
Mutual labels:  location
google streetview
A command line tool and module for Google Street View Image API
Stars: ✭ 77 (+156.67%)
Mutual labels:  location
timezone
Timezone project providing a simple way to turn location and unix timestamp into timezone and local time.
Stars: ✭ 24 (-20%)
Mutual labels:  timezone

TimeZoneLocate

CI Status Version License Platform

This utility is the Swift port of the APTimeZones library with the support for bundled frameworks. If your project is Objective-C, we recommend using theirs.

  • For Swift 5 version, use version ~> 0.5.0.
  • For Swift 4 version, use version ~> 0.4.0.
  • For Swift 3 version, use version ~> 0.3.0.
  • For Swift 2 version, use version ~> 0.1.0.

Usage:

    //San Diego, CA, USA
    let location = CLLocation(latitude: 32.88, longitude: -117.15)

    //TimeZone from extension (fast, synchronous, approximate)
    var timeZone = location.timeZone
    print(timeZone)

    //or calling the class method
    timeZone = TimeZoneLocate.timeZone(location: location)
    print(timeZone)

    //if you have the country code, you can speed things up.
    timeZone = TimeZoneLocate.timeZone(location: location, countryCode: "US")

    // A MORE accurate time zone if you are connected to network. (iOS 9.0 or later)
    location.timeZone { (tz) -> (Void) in
      guard let tz = tz else { return }
      // got a more accureate timezone from the network
      print("Network TimeZone: \(tz.identifier)")
    }

    // Same thing
    TimeZoneLocate.geocodeTimeZone(location: location) { (tz) -> (Void) in
      guard let tz = tz else { return }
      print("Network TimeZone: \(tz.identifier) (class method)")
    }

Installation

To install it, simply add the following line to your Podfile:

pod "TimeZoneLocate"

Authors

License

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

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].