Swift
Essentials book http://bit.ly/SwE6701 written by Dr Alex Blewitt and published by Packt is a basic
introduction to Swift, new programming language introduced by Apple for Mac OS
and iOS. No prior knowledge of Swift or Objective-C is required for reading
this book however it is useful to have some experience as Mac OS user. To run
sample code written by Dr Alex Blewitt for Swift Essentials you need Mac OS
10.9 with Xcode installed.
Before
Swift most code for Mac OS and iOS was written in Objective-C. Swift adds more
modern runtime and automatic memory
management.
Author
starts his book with description of Swift interpreter which can be easily
launched from Xcode tools. We are getting acquainted with Swift basics:
literals, difference between variables and constants, two collection types
(arrays and dictionaries), control flow, functions, running of simple scripts.
After you've got familiar with command line interpreter Dr Alex Blewitt
presents you a graphical interface called playground which allows to compile
and execute code interactively. In the book he describes how to create
playground, how to mix code and documentation within the playground, how to
look at the state of executing program.
Then Dr
Alex Blewitt shows the reader how to create single view iOS application, how to
create master-detail iOS application, how to work with storyboard application
and create custom views. The final
target of the book is to build a fully functional iOS application which is
repository browser working with GitHub API.
This book
will be interesting for everyone who would like to get acquainted with Swift
and start creating applications for Mac OS and especially iOS using Swift.