In this course, key concepts will be covered by learning how large programs are constructed, and how to use C# to perform object-oriented programming. Throughout the course, I will explore the many features of C# that support object-oriented programming, including objects, classes, inheritance, interfaces, and generic types. To make easier to learn a real-world context to these concepts, I will demonstrate how to use these features by writing real-world example code.
What you will learn
1. How to design application with objects
The object holds data and it also does things for us.
Design a system by deciding what objects are required, what data they must store and what they need to do for us.
2. Protecting Data in the Class
3. Accessor and Mutator methods
How to write a method which provides read access to the data field inside the object which is called get method
Accessor methods return a value of some kind.
Mutator method allows to change(mutate) a data field (sometimes called a set method)
4. Testing
All the behaviours (class methods) need to be tested, particularly in terms of their error conditions.
Whenever we create a behaviour, we should also create tests for that behaviour. So, we will create a test for each behaviour.
Learn how to use unit testing to test all the behaviours of the classes using visual studio test framework.
5. Constructing Class Instances
How to use constructor to get control at the point where a new object is created
To make sure that a given system only contains object that are valid according to the Business Rules that apply to our solution.
6. How to Design Static Members
7. Design with properties
How to use properties to make to code clearer.
How to make the code easier.
The C# language provides properties to make getting and setting data easier.
8. Inheritance
Using inheritance, one of the key concepts of OOP how to take the existing classes and reuse them by extending them.
How to achieve code reuse by extending a parent class and making a child class
Method can be marked as virtual so that they can be overridden by code in the child class. Using this how to create child classes with customised behaviours.
How to reference to the parent class can refer to any of the child classes.
9. Abstract Classes