Our Aeris iOS Weather Framework has been in the hands of developers and Aeris users for about two and a half years already and has received a lot of positive feedback from everyone who has been using it within their own iOS applications. Our goal with the iOS framework has always been to make interacting and integrating with our core AerisWeather API quick and painless so you can focus your time on building great applications instead of worrying about fetching, parsing and displaying weather data. Now, after months of planning and development behind the scenes, we’re excited to give our first public preview of what the new 2.0 version of our iOS weather framework will bring! Instead of trying to build new features on top of the old legacy code, we decided to start from scratch using modernized Objective-C code, new Objective-C literals and new iOS APIs with a huge number of improvements. As a result, we went straight to 2.0 with a complete rewrite, so let’s review some of the major changes and improvements.
When developing 2.0 to use AFNetworking instead of the abandoned ASIHTTPRequest, we found our old AF namespace conflicted with that of AFNetworking and oftentimes resulted in confusion. Therefore, we have changed our iOS framework’s namespace to AWF, “Aeris Weather Framework”, instead. We have also updated all class category methods defined within our framework to use the similar awf_ prefix to avoid conflicts with Apple’s APIs and other third-party libraries if they happen to declare the same method.
It’s been several years since Apple introduced ARC (automatic reference counting) to Xcode, but the 1.0 version of our Aeris iOS framework was built using the old-school retain/release pattern of memory management. With the fairly large codebase powering our framework, it was going to be quite time-consuming to go through and convert the code to ARC. And while Xcode can do some of this refactoring for you, many developers have found it’s not always without issues, especially for complex projects. With 2.0, we use ARC for everything that supports it. Additionally, we now support blocks throughout the framework, specifically when requesting data from the API via an AFObjectLoader (now AWFObjectLoader in version 2.0). So instead of handling responses from these object loaders via delegate methods, you can handle their returned data at the same point in your code where the data is being requested using blocks.
The release of iOS 7.0 last year with its entirely new interface redesign made it clear the direction in which Apple wanted their platform to go. Therefore, on top of rewriting all of the built-in weather views to use the newest iOS APIs, such as UICollectionView, we also added support for custom stylesheet-type objects to be applied to them. These stylesheets will allow you to customize things like backgrounds, colors, fonts and weather icons for all of the built-in weather views. We’ve also updated their default aesthetic to match that of iOS 7. Since all of the built-in views look exactly as they did in version 1 of the framework, we also added a separate stylesheet you can apply to your weather views that retains the look and feel of the default views from version 1.
Stylesheets don’t stop with the built-in weather views, however. The same stylesheet concept has been applied to the mapping framework as well, allowing you to apply your own custom styles to map annotations, legends and more. In version 2.0, all of these items are drawn dynamically based on the stylesheet applied to them, so you no longer have to worry about providing static image assets. Just apply your own stylesheet object to either the view or the weather map’s configuration and you’re done.
Graphs are extremely useful when visualizing weather data and trends versus textual content, so it makes sense we’ve been wanting to add our own graphing library to our Aeris iOS framework. In the new version 2.0, we have developed the start of a graphing library that is extremely flexible and follows the delegate/data source pattern any iOS developer is quite used to from UITableView and UICollectionView. Initially, we support line and bar graphs, which should cover the majority of weather visualizations a user would want. However, we plan to expand this to other types of graphs or visualizations in later versions to the framework.
Check back later this month when we get closer to releasing the first public beta of our Aeris iOS Weather SDK 2.0 where we will give you a preview of the improvements and new features coming in the mapping component of our framework! Until then, you can sign up for a free Aeris API developer account and download the latest version of the iOS framework to get started.
Also, follow us on Twitter for all the latest news and updates.
[…] 3.0 expands on all of the improvements and features we outlined in part one and part two of our 2.0 preview while making a lot of architectural and code improvements […]