iOS 13 Programming Fundamentals with Swift - Programming Ebook


Download Programming Ebook

Monday, September 30, 2019

iOS 13 Programming Fundamentals with Swift

iOS 13 Programming Fundamentals with Swift
iOS 13 Programming Fundamentals with Swift

Book Details 
             TitleiOS 13 Programming Fundamentals with Swift
         Author: Matt Neuburg
    Language: English
        SubjectSwift / Computers & Technology / Programming / Apple Programming
No. of pages: 1199
         Format: PDF, EPUB

Preface With the arrival of Swift 5 in early 2019, the stamp of maturity has been placed upon the Swift language. When Swift was introduced to the public in 2014, it was a sort second-class citizen. The Cocoa frameworks that give an iOS app its functionality expect to be spoken to in Objective-C, and several megabytes of libraries had to be included in every Swift app, effectively containing the whole of the Swift language and translating everything into Objective-C. But Swift 5 introduces ABI stability, which means that, starting in iOS 10.2, the Swift language has become part of the system. Swift is now on a par with Objective-C, and Swift apps are smaller and faster. 

When Swift first appeared, I immediately translated my own existing iOS apps into Swift, and found them easier to undertand and maintain than their Objective-C originals. Objective-C is a powerful language with some remarkable capabilities, but it is safe to say that the vast majority of new iOS programmers will adopt Swift. It is a superb language to learn, even (perhaps especially) if you’ve never programmed before, and is the easiest and clearest way to program iOS. Swift has these salient features:

Object-orientation Swift is a modern, object-oriented language. It is purely objectoriented: “Everything is an object.”

Clarity Swift is easy to read and easy to write. Its syntax is clear, consistent, and explicit, with few hidden shortcuts and minimal syntactic trickery.

Safety Swift enforces strong typing to ensure that it knows, and that you know, what the type of every object reference is at every moment.

Economy Swift is a fairly small language, providing some basic types and functionalities and no more. The rest must be provided by your code, or by libraries of code that you use — such as Cocoa

Memory management Swift manages memory automatically. You will rarely have to concern yourself with memory management.

Cocoa compatibility The Cocoa APIs are written primarily in C and Objective-C. Swift is explicitly designed to interface with most of the Cocoa APIs.

Even when your code is in Swift, some awareness of Objective-C (including C) can be useful. The Foundation and Cocoa APIs are still written in C and Objective-C. In order to interact with them, you might have to know what those languages would expect. Therefore in this book I describe Objective-C in enough detail to allow you to read it when you encounter it in the documentation and on the Internet, and I occasionally show some Objective-C code. Part III, on Cocoa, is largely about learning to think the way Objective-C thinks — because the structure and behavior of the Cocoa APIs are fundamentally based on Objective-C. And the book ends with an appendix that details how Swift and Objective-C communicate with one another, as well as explaining how your app can be written partly in Swift and partly in Objective-C.

Advanced iOS Summer Bundle 2019:

No comments:

Post a Comment