WIP - Classes, Modules and Exceptions
Class Principles
Classes define what an object will look like.
Exercise:
Class methods may be defined in a few other ways
Using the class name instead of
self
keywordUsing the
<<
notation: this is useful when you work with classes that have been already defined.
A class variable must start with special characters @@ and it is shared among all class instances:
Method Visibility
Subclassing and Inheritance
Modules
Exceptions
Conclusion
Last updated