OO Basics
Components can be objects, variables, methods etc...
- Abstraction - group together common components.
- Inheritance - extend and gain components from a parent.
- Polymorphism - entities that can take on multiple forms.
- Encapsulation - restrict access to components that logically sit together.
OO Design Principles
- Identify what varies and keep it from what stays the same.
- Program to interfaces not implementations.
- Favour composition over inheritance.
- Aim for loosely coupled objects.
OO Patterns
- Strategy - interchangeable algorithms.
- Observer - publish/subscribe model.