Book Image

Mastering Swift

By : Jon Hoffman
Book Image

Mastering Swift

By: Jon Hoffman

Overview of this book

Table of Contents (22 chapters)
Mastering Swift
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

What is mix and match?


Swift's compatibility with Objective-C allows us to create a project in either language and include files written in the other language. This feature is called mix and match and was arguably one of the most important features that came out with Swift.

The reason why this feature was so important is that there are, well, a million apps written in Objective-C in Apple's App Store and it would not be feasible for developers to spend the resources required for converting those apps from Objective-C to Swift. Without mix and match, the adaptation of the Swift language would be very slow. With mix and match, developers can begin to use Swift in their present apps that are written in Objective-C, without having to convert the entire code base to Swift.

With mix and match, we can update our current Objective-C project using Swift. We can also use any framework written in Objective-C within our Swift projects and use newer frameworks, written in Swift, in our Objective-C projects...