TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Mar 2017 |
Maintained by Ulaş Sancak.
Depends on: | |
AFNetworking | ~> 3.1 |
JSONModel | ~> 1.7 |
To run the example project, clone the repo, and run pod install
from the Example directory first.
openweathermap-objc-sdk is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "openweathermap-objc-sdk"
#import <openweathermap_objc_sdk/OWMSDK.h>
[[OWMAPIClient client] getWeatherByCityName:@"istanbul" block:^(OWMWeather *weatherData, NSError *error) {
if (!error && [weatherData.code isEqual:@"200"]) {
//Data received
}
}];
#import <openweathermap_objc_sdk/OWMSDK.h>
[[OWMAPIClient client] getWeatherByCityIDs:@[@524901,@703448,@2643743] limitResultByCount:0 block:^(OWMWeatherArrayResult *result, NSError *error) {
if (!error && [result.code isEqual:@"200"]) {
//Data received
}
}];
#import <openweathermap_objc_sdk/OWMSDK.h>
[[OWMAPIClient client] getForecastByCityName:@"istanbul" countryCode:@"tr" limitResultByCount:0 block:^(OWMWeatherArrayResult *result, NSError *error) {
if (!error && [result.code isEqual:@"200"]) {
//Data received
}
}];
#import <openweathermap_objc_sdk/OWMSDK.h>
[[OWMAPIClient client] getDailyForecastByCityName:@"istanbul" countryCode:@"tr" limitResultByCount:0 block:^(OWMDailyForecastResult *result, NSError *error) {
if (!error && [result.code isEqual:@"200"]) {
//Data received
}
}];
Ulaş Sancak, [email protected]
openweathermap-objc-sdk is available under the MIT license. See the LICENSE file for more info.