After a frantic few days at WWDC, the dust has now settled on the announcements made at the WWDC Keynote on Monday morning. There are a couple of changes introduced with iOS9, a new Watch Operating System, and better development and testing tools to round it off.

At the same time – while there was a lot to get excited about – some of the announcements mean there will now need to be important changes made to existing legacy applications as we move towards adoption of Swift, as well as support for multitasking.

iOS9 Multitasking

The biggest announcement for me on Monday was the introduction of iOS9 Multitasking on the iPad. As I wrote in my WWDC Wishlist last month, Apple have now introduced a couple of new features to enable multitasking on the iPad, such as Side by Side applications and Picture in Picture video.

AutoLayout is now a must

Multitasking has some important impacts for legacy applications. Traditionally the enterprise has been slow to adopt new technology as Apple has rolled out updates, with support for up to 3 iOS versions still common; the introduction of Side by Side will result in many iPad apps that have been slow to fully adopt AutoLayout (iOS6) and Size classes (iOS8) requiring a large UI rewrite to bring them into line.

Memory Management

In the same vein, apps can no longer afford to be poor ecosystem citizens when it comes to memory management. Leaks and memory that haven’t been marked as dirty or bad caching (or no caching) could result in unexpected terminations as the operating system handles the increased memory requirements of two applications running at the same time. If you are running applications in the app store with iPad support – you can start using the instruments now to look at your resource profiles and make necessary improvements.

Stack Layouts

Another announcement that will please developers is the introduction of stack layouts. Stack layouts bring the “grouping” concept introduced in WatchOS 1 to iOS. They greatly improve the workflow and complexity required to implement complex UI layouts by managing a lot of the logic for you, and they reduce the number of constraints required. As a best practice, devs should now be looking to stack first, and only then constrain when required going forward.

Storyboard References

Storyboards have had a bit of dev resistance in the past because of the fact that multiple developers working on the same file at the same time would result in merge issues. This has now been fixed by Apple introducing Storyboard references. Now, developers can select several views in their Storyboard and – by selecting ‘Editor -> Refactor to Storyboard’ – can move these views to their own Storyboard file. In the past, some complex and obscure code was required to break storyboards up into separate files, and the ability to pass objects around was limited; with storyboard references, this is no longer an issue.

image3

Xcode7 & App Store

Xcode7 introduces a couple of tools that will really help developers. Application thinning and on-demand resources will reduce file sizes, while UI automation testing and code coverage will make big steps in increasing the overall quality of applications.

Application Thinning

Applications have been getting larger and larger, and Apple have moved to address this by introducing application thinning and on-demand resources. In the past, if you were on an iPhone and you downloaded a Universal application from the app store, you would also download the iPad equivalent of the application, which would lay dormant on your iPhone.

This is a major waste of space and download time. Similarly, embedded in iOS applications currently are all the images required for the different screen resolutions supported by the growing number of iOS devices; now, when a user downloads the application from the App Store, it will determine the files used by the device and strip out the rest. Further, applications with both 32 and 64 bit support will be cut to only deliver the required architecture for the device.

UI Testing

One area I was particularly excited about was the introduction of UI testing to Xcode. Now, UI Automation tests can be written (and macro recorded) within Xcode and in a language that is native to the developer. UI testing can be added as a new target on an iOS project, and can be executed also via the xcodebuild command line tools.

Code Coverage

Until now, code coverage on iOS projects had to be done using external tools such as gcovr, which is based on the C language and bent to work with iOS. With Xcode7, you can now turn on code coverage on your targets and Xcode will generate reports of your unit test coverage. Given this is written for iOS, I would expect much better results and less “tailoring” to the needs of each project.

image1[1]

WatchOS 2.0

Apple made a major announcement with a new version of the Watch OS – impressive considering the device was released only a month ago.

If you have WatchKit apps already in the store, this could mean that you need to migrate your users given the new architecture introduced.

PickerView

Apple also made a couple of the device’s core hardware sensors available to developers. The introduction of the WKPickerView now means that developers can use the Digital Crown on the device for fine grain scrolling of views and UI Elements. The PickerView introduces three types and can be tailored in several ways, such as outlines and captions.

Complications

Another new watch feature announcement was the introduction of application complications. Complications are small “widgets” that can be added to your watch face and provide short views of your application data that are always available.

Swift

Apple introduced Swift at WWDC 2014, but the adoption in the enterprise has been slow given the learning curve and the investment required to bring developers up to speed with slower initial output. I personally believe enterprises now need to start investing in Swift. It is clear that Objective-C is on a short runway at Apple, so much so that I have not yet seen a presentation slide with Objective-C code.

There are several strategies teams can take to introduce Swift to existing projects, but the longer teams wait to adopt it, the larger the conversion cost will be at a later point. With Swift 2.0 a lot of the early issues have been ironed out, but with the announcement that Swift will be open sourced, it is unlikely it will remain static.

There were several language changes that I’ll go into more detail about in a later blog – protocol extensions, error handling, and more – that promise improvements all devs will enjoy working with.

image4

Conclusion

iOS9, Xcode7 and Watch OS 2 deliver some features that will change the way developers write and test code. Further, the iPad moves more towards PC functionality, with productivity improvements that will change the way people interact with the device.

The Apple Watch is improved, with new opportunities for developers to surprise and delight customers and craft fun and engaging applications.

In general, there are some great improvements on the way. Enterprise dev teams will now need to start moving on addressing some key engineering challenges to stay in touch.

This blog was also posted on my company’s website.

FacebookTwitterPinterestGoogle +Stumbleupon
Written by forbze