Objective-C


Today I embarked on a new journey — iOS development.


To define a new class in Objective-C:

  1. inherit from NSObject
  2. In the header file, define all the instance attributes and methods (just function name, type of return value, name and type of the)
  3. In the implementation file, define the concrete body of instance methods.
  4. Attributes defined as @property have the shortcuts of getter and setter methods, as well as the dot notation.