swift 2.0

26
Swift 2.0 The programming language Get ready for a change

Upload: chromeinfo-technologies

Post on 12-Feb-2017

2.239 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Swift 2.0

Swift 2.0

The programming language

Get ready for a change

Page 2: Swift 2.0

A modern programming

language that is safe, fast,

and interactive.

Page 3: Swift 2.0

Apple Gives Open Source a Swift 2 Kick

Page 4: Swift 2.0

Swift is a powerful and intuitive programming language for iOS, OS X, and iWatchOS.

WHAT IS SWIFT?

Page 5: Swift 2.0

Swift is a powerful and intuitive programming language for iOS, OS X, and iWatchOS.

Writing Swift is interactive and fun, the syntax is concise yet expressive, and apps run lightning-fast.

WHAT IS SWIFT?

Page 6: Swift 2.0

Swift is a powerful and intuitive programming language for iOS, OS X, and iWatchOS.

Writing Swift is interactive and fun, the syntax is concise yet expressive, and apps run lightning-fast.

Swift is ready for your next project — or addition into your current app — because Swift code works side-by-side with Objective-C.

WHAT IS SWIFT?

Page 7: Swift 2.0

SWIFT

FEATURES

Page 8: Swift 2.0

ERROR HANDLING MODEL

An advanced error handling model provides clear, expressive syntax for catching and throwing errors.

Page 9: Swift 2.0

ERROR HANDLING MODEL

An advanced error handling model provides clear, expressive syntax for catching and throwing errors.

The new error model was designed to work seamlessly with NSError and the Cocoa frameworks.

Page 10: Swift 2.0

ERROR HANDLING MODEL

An advanced error handling model provides clear, expressive syntax for catching and throwing errors.

The new error model was designed to work seamlessly with NSError and the Cocoa frameworks.

Error handling code now looks like :

Page 11: Swift 2.0

ERROR HANDLING MODEL

Page 12: Swift 2.0

SYNTAX IMPROVEMENTS

New syntax features let you write more expressive code while improving consistency across the language.

Page 13: Swift 2.0

SYNTAX IMPROVEMENTS

New syntax features let you write more expressive code while improving consistency across the language.

Here is just a sampling of Swift 2.0 enhancements.

Page 14: Swift 2.0

SYNTAX IMPROVEMENTS

- Powerful control flow with do, guard, defer, and repeat

- Keyword naming rules unified for functions and methods

- Protocol extensions and default implementations

- Extended pattern matching to work in if clauses and for loops

New syntax features let you write more expressive code while improving consistency across the language.

Here is just a sampling of Swift 2.0 enhancements.

Page 15: Swift 2.0

AVAILABILITY

It has built-in availability checking to make it easy to build the best possible app for each target OS version.

Page 16: Swift 2.0

The compiler will give you an error when using an API too new for your minimum target OS, and a new keyword lets you wrap blocks of code in a conditional version check to run only on specific OS releases.

AVAILABILITY

It has built-in availability checking to make it easy to build the best possible app for each target OS version.

Page 17: Swift 2.0

OPEN SOURCE

Unique combination of elegance, power, and safety has the opportunity to move the entire software industry forward. It is exciting to imagine what we will build together.

Page 18: Swift 2.0

MODERN

Swift is the result of the latest research on programming languages, combined with decades of experience building Apple platforms.

Memory is managed automatically, and you don’t even need to type semi-colons. All this modern thinking results in a language that is easy and fun to use.

Page 20: Swift 2.0

INTERACTIVE PLAYGROUNDS

Playgrounds make writing Swift code incredibly simple and

fun. The Playground let you do following :

- Share curriculum to teach programming with beautiful text and interactive code.

- Design a new algorithm and watch its results every step of the way.

- Create new tests and verify they work before promoting into your test suite.

- Experiment with new APIs to hone your Swift coding skills.

- Turn your experiments into documentation with example code that runs within

the playground.

Page 21: Swift 2.0

OBJECTIVE-C INTEROPERABILITY

Swift code co-exists along side your existing Objective-C files in the same project, with full access to your Objective-C API, making it easy to adopt.

Page 22: Swift 2.0

OTHER FEATURES

- Swift has many other features to make your code more expressive:

- Closures unified with function pointers

- Tuples and multiple return values

- Generics

- Fast and concise iteration over a range or collection

- Structs that support methods, extensions, and protocols

- Functional programming patterns, e.g., map and filter

- Native error handling using try / catch / throw

Page 23: Swift 2.0

References

https://developer.apple.com/swift/

Page 24: Swift 2.0

ABOUT Us

We are ChromeInfo Technologies, a Mobile App Development,Web Development and Software Testing company withdevelopment center in India.

Mobile Application Development

Android Application Development

iPhone Application Development

iPad Application Development

Web Development

Software Testing