Part 3 of the taste of Swift explores class objects in Apple's Swift language. A class allows you to group methods (class functions) together that belong together. Class Person groups some information of people working in an office. Class Pay inherits class Person and adds pay information. Class File groups file read and write methods. By convention class names start with a capital letter. Once a class is written it can be inherited by another class which eliminates a lot of extra code writing. Part 4 will talk about a related object, the structure. Swift has elevated the structure to be almost a class.
At least Swift isn't one of those languages that forces you to start with a class no matter what. A class is a nice coding tool, and that's all.
Swift uses three access levels:
public (can be imported by other modules/frameworks)
internal (default, no import by other modules/frameworks))
private (access only within the defining source code)
If no access level is used, Swift defaults to internal.
Coming in the fall of 2015 ...
Swift2 replaces println() with just print() that has a newline default. There are some other syntax changes and a much improved error handling.
The good news is, there will be a Swift 1-to-2 migrator utility to change Swift1 syntax to Swift2 syntax.
Edited by vegaseat: class func added