Swift in Depth

1st Edition
376
English
1617295183
9781617295188
16 Dec
Summary

Now updated for Swift 5! Swift is more than just a fun language to build iOS applications with. It features a host of powerful tools that, if effectively used, can help you create even better apps with clean, crystal-clear code and awesome features. Swift in Depth is designed to help you unlock these tools and quirks and get developing next-gen apps, web services, and more!

Purchase of the print book includes a free eBook in PDF, Kindle, and ePub formats from Manning Publications.

About the Technology

It's fun to create your first toy iOS or Mac app in Swift. Writing secure, reliable, professional-grade software is a different animal altogether. The Swift language includes an amazing set of high-powered features, and it supports a wide range of programming styles and techniques. You just have to roll up your sleeves and learn Swift in depth.

About the Book

Swift in Depth guides you concept by concept through the skills you need to build professional software for Apple platforms, such as iOS and Mac; also on the server with Linux. By following the numerous concrete examples, enlightening explanations, and engaging exercises, you'll finally grok powerful techniques like generics, efficient error handling, protocol-oriented programming, and advanced Swift patterns. Author Tjeerd in 't Veen reveals the high-value, difficult-to-discover Swift techniques he's learned through his own hard-won experience.

What's inside
  • Covers Swift 5
  • Writing reusable code with generics
  • Iterators, sequences, and collections
  • Protocol-oriented programming
  • Understanding map, flatMap, and compactMap
  • Asynchronous error handling with ResultBest practices in Swift

About the Reader

Written for advanced-beginner and intermediate-level Swift programmers.

About the Author

Tjeerd in 't Veen is a senior software engineer and architect in the mobile division of a large international banking firm.

Table of Contents
  1. Introducing Swift in depth
  2. Modeling data with enums
  3. Writing cleaner properties
  4. Making optionals second nature
  5. Demystifying initializers
  6. Effortless error handling
  7. Generics
  8. Putting the pro in protocol-oriented programming
  9. Iterators, sequences, and collections
  10. Understanding map, flatMap, and compactMap
  11. Asynchronous error handling with Result
  12. Protocol extensions
  13. Swift patterns
  14. Delivering quality Swift code
  15. Where to Swift from here

 

 

Reviews (6)

Very interesting book for the experienced iOS developers

This is a book for experienced programmers. This is an excellent book to take your Swift programming to a higher level. It is not for someone new to the Swift programming language. I suggest you have a least 6 months of experience with Swift before tackling this excellent book. The chapter on initializers was very helpful for filling in some gaps in my knowledge. There is a good chapter called "Effortless Error Handling." The bottom line - this is a must own book for the advanced iOS developers out there.

Great content if you want to understand swift in depth.

There are a lot of hard concepts explained very well which isn't easy to find on the internet or any other place. I really enjoy reading this book. Highly recommended if you want to understand swift in depth

Highly recommend

If you want to know the core feature of swift and want to be master of swift patterns. just buy it and read it.

This is a tremendous book

This is a tremendous book. Aimed at developers that already have some experience with Swift, the book’s promise is to help them write better code in their real-world Swift projects. In a handful of words, this means balancing the right techniques and Swift features to craft more robust code (think compile-time safety), code that better expresses intent and is thus more easily maintaned, and why not, code that’s also quite ellegant. The book is fairly easy to read. Concepts are explored gradually, with a focus on how to reason about the various constructs of Swift. Different approaches to solving a certain problem are presented side by side, with pro’s and con’s presented for all cases. Theoretical aspects are balanced by an abundance of code examples, more than you’d normally find in a programming book. The author has put a lot of effort into demystifying abstract concepts on the spot into the mundane (but useful) examples you’re likely to encounter in your day to day work as a programmer. There’s little place in this book for highly theoretical constructs, and focus is clearly set on exemplyfing techniques with code samples. Worth noting, these are less like “class Foo” of “func Bar()” geeky examples, and more like snippets you’d see in a real project, such as a Network Layer with monadic error handling, or useful additions you can make to Swift’s built in Sequence/Collection types. In my case, the list of takeaways after finishing “Swift in Depth” is by no means short: How to reason about generics and protocols with associated types. When to favor compile-time generics, and when usage of run-time protocols will save you some embarrassment. Asynchronous error handling, with a touch of ellegance. Harvesting the power of enums. The benefits of conditional conformance. High-order functions (flatMap, anyone?). And how to nod politely when colleagues mention rigid class hierarchies in the days of protocol oriented design. And when it is socially acceptable to use forced unwrapping of optionals …was that in the mornings, right before going to lunch? Oh, nevermind. There’s bits as well for those more willing to explore the really shady/difficult constructs of Swift. Think type erasure, and others. There’s also bits of comical relief here and there … I’ll just note down my favourite, which is when the author feeds the “OMG Shoes!” text to an URL initializer.

Excellent Explanations of Tricky Concepts

As others have noted, this book is aimed at experienced Swift developers, and does a great job of explaining some of the more tricky features of the language. The book's section on Generics is worth the price of admission. Cannot recommend highly enough.

This book is basicly the same as Objcio's Advanced Swift or the Swift language book by Apple

This book is basicly the same as ObjcIO’s Advanced Swift or the Swift language book by Apple. It does not necessarily contain anything Cocoa[ Touch ], it’s Swift language centric book, and though I say it’s the same, it’s not, even though these books cover the same type of knowledge the point of view is subjective and each authors’. I have all these 3 books on my iPad together with a similar book by Paul Hudson, I forget the name at the moment. One thing that is reflected in each book is each author’s personal experience, and these different experiences make more of these books have a higher value combined as a synergy than the sum of all the books’ core knowledge alone.

Trending Books