Apple got back to its roots with the WWDC 2014 keynote this year, providing developers with sneak peaks of the latest and greatest versions of OS X and iOS. Then, Apple spent the remaining 1/3 of the keynote talking about developer tools and technologies. It turns out Apple has been busy creating a new programming language, a new version of Xcode, and other tools to make developers’ lives much easier.
Apple surprised developers with another update of Xcode, the Apple-provided IDE for developing for iOS and OS X applications. Xcode 6 includes Playgrounds, which gives you the ability to try out code without creating an entire project. When you type in a bit of code, it’s instantly processed, and the output appears in the sidebar. The interactive sidebar can display variables in a graph, allow you to inspect each step in a drawing, or watch animated SpriteKit or SceneKit animations.
Xcode 6 also includes live debugging tools like a UI inspector (Figure A) that is similar to third-party tools such as Spark Inspector and Reveal. This is great for debugging hard to find UI bugs in a running application, and having this built-in means that developers won’t need to purchase additional debugging tools.
Live debugging tools let you inspect UI elements in applications while the app is running, showing exactly where errors are occurring. (Image: Apple)
Swift (Figure B) is the announcement that no developer saw coming from WWDC 14: A new, modern, and completely re-architected programming language for developing iOS and OS X applications. You’ll still be able to write Objective-C code alongside Swift code. The code written in Swift is optimized into native code, and includes all of the features that you’ve come to love with modern languages, including generics, fast iteration, and functional programing patterns.
Swift allows for the live debugging features in the Xcode 6 Playgrounds feature. (Image: Apple)
Swift is also incredibly fast: Apple showed in the WWDC 14 keynote how much faster Swift code can run compared to the existing Objective-C language and Python. Apple has provided a free iBook about Swift so you can learn all about the language and then start using it.
Applications built using Swift will be able to ship to the iTunes and Mac App Stores later this year when iOS 8 and OS X Yosemite are out of beta.
If you’ve built applications that rely on custom-built web services, you know that creating these services are time-consuming and require switching to another language such as PHP, Ruby, or Node.js. With CloudKit (Figure C), Apple hopes to expand the functionality of iCloud so developers will be able to extend their cloud services to iCloud, leaving the provisioning, hosting, and most importantly cost behind.
iCloud has evolved to include a lot of new developer tools that allow for authentication and many more conveniences never before possible. (Image: Apple)
With CloudKit, you can now handle user authentication, utilization of private and public databases, and other asset storage solutions. These all come provisioned for the number of users for your application, and with very high limits, and are free for developers to implement.
Applications on the iTunes App Store and the Mac App Store are sandboxed and cannot talk to each other — until now. With extensions (Figure D), your application can provide an extension as a service that other applications can tap into.
Extensions make it easier to allow users to perform tasks external to your apps. (Image: Apple)
As Apple showed in the keynote, the Pinterest application could provide a service to pin an item to your account. This Pinterest pin button could appear in the share sheet of other applications as long as your application advertises this functionality. When the button is tapped, your application will be called to provide a UI for performing the extension task.
PhotoKit and Manual Camera Controls
AV Foundation has been upgraded to include a lot of new functionality for applications that utilize the Camera and Photo services in iOS. With PhotoKit, your application can now do non-destructive photo edits for photos that are managed by the Photos app, or other photos stored in the user’s iCloud albums without having to import them first, and then save them back out after the edits.
With the Manual Camera Controls, your application can now take control over the lower-level camera applications to tweak things like focus, white balance, and exposure settings.
These two APIs will be great for camera apps that have always wanted finer access to the camera and photo album.
HealthKit and HomeKit
HealthKit is a new API provided by Apple that basically turns your device into a profile of your physical health, allowing applications that monitor health and fitness to report their stats into your profile to have a better understanding of your overall health. The HomeKit API allows home automation applications to integrate with each other more seamlessly, with iOS talking to your application to control the user’s environment.
SpriteKit and SceneKit
SpriteKit provides a simple canvas for developers to create basic 2D games. Its first release was last year; SpriteKit now includes the live debugging in Xcode and other niceties such as better battery efficiency, shaders, lighting, and physics effects.
SceneKit was also introduced last year and largely used by developers to create models and not really used for gaming. Apple has improved on the SceneKit basics to allow for collision detection, gravity and force simulation, and more geometry and materials, which means it can be used to create amazing 3D games and animated scenes.
Storyboards for OS X
iOS developers have had the ability to create application interfaces with ease using Storyboards (Figure E). Storyboards on the Mac means that developers can now layout interfaces easier and faster than the older XIBs that were previously used. Like with iOS, this will also lead to better application design and better Xcode project organization. Instead of having multiple XIBs scattered about your project, you can now have a single Storyboard file that contains your entire UI elements.
Storyboards, a long-time staple of iOS development, can now be used to create Mac applications. (Image: Apple)
The bottom line
All of this new functionality allows developers to create better, more seamless experiences for users of iOS and Mac applications. From Swift to Xcode 6 to App Extensions, I think the WWDC 2014 announcements include something that will be of interest to any Apple developer.
Do you have a favorite new API announcement, perhaps one we didn’t mention? Let us know in the discussion.
More WWDC 2014 coverage on TechRepublic
- Apple put the Developer back in WWDC, and it’s fantastic news for the rest of us
- OS X Yosemite: Apple’s biggest Mac redesign in years
- Photos: A look at some of the new features in OS X Yosemite
- Apple’s Health app and other new features in iOS 8
- Mac OS X Yosemite offers compelling highlights for business users
- Touch ID for apps could be WWDC’s biggest little update
- Apple’s Continuity vision: bringing better device options to business users
- iCloud Drive: Apple’s appealing recipe for cloud storage