
Explore the foundations of object oriented programming in C#, defining classes, constructors, methods, properties, and core concepts like abstraction, encapsulation, inheritance, interfaces, and polymorphism.
Install the dotnet core sdk and Visual Studio (preferably 2019 or newer) using the free community edition, then begin exploring object oriented programming in C#.
Create an empty Visual Studio solution, organize it with numbered folders for classes, abstraction, encapsulation, inheritance, interfaces, and polymorphism, and prepare for the object oriented C# masterclass.
Define a public class Account with private fields name and balance, implement an empty constructor, and expose properties with getters and setters to encapsulate data and control access.
Define and instantiate an account class with new, set public properties for name and balance, contrast fields and properties, and create three accounts to illustrate debugging with breakpoints and watches.
Explore constructors in object oriented c# masterclass part 1 by implementing default and overloaded constructors. Learn to chain constructors and implement getters and setters for account name and balance.
Create three account instances using distinct constructors—empty, with balance, and with name and balance—to illustrate constructor chaining, base constructor calls, balance initialization, and default names.
Explore defining methods in a C# class by extending a customer with a private accounts list, adding accounts via a method, and retrieving the largest account by balance.
Create a customer object, add three accounts with balances of 10, 20, and 30, then retrieve and display the largest account’s name and balance.
Explore class separation and abstraction by modeling an account with private fields and public getters, using separate debit card, statement, and transaction classes, connected via a constructor.
Add properties to the debit card class, including a private int pin and a CVC, expose a public get and a private set, and initialize both via a public constructor.
Define a bank statement class with pages and format properties, expose them via public getters and private setters, and initialize through a constructor.
Define a transaction class with a double amount and a time stamp, using private set accessors and public getters to ensure only the constructor can assign values.
Learn to separate classes in a C# program by composing an account with a debit card, statement, and transactions, illustrating abstraction and client-side business logic.
Describe base constructors and constructor chaining across separated classes, exposing private members via public getters and setters in an account model with a debit card, paperless status, and date opened.
Showcases a debit card class with private fields (name, number, CVC) and a nullable pin, exposed via public getters and private setters, using base constructors for flexible initialization.
Explore base constructors and constructor chaining to create flexible debit cards and accounts for different clients, with optional pin, cvc, date opened, and paperless settings.
Learn to use abstraction to override the to string method in an account class, build a report of checking and savings accounts with a string builder, including constructors and accessors.
Create and manage a customer account with empty and parameterized constructors, add checking and savings accounts, and override to string to abstract and print a report for clients.
Demonstrates encapsulation by converting public fields to private, using a constant for minimum balance, and introducing getters, setters, and validation to enforce business logic.
Contrast a bad account with a public balance to a private field protected by a constructor and a minimum balance constant, illustrating encapsulation and future validation.
Encapsulate fields by making them private and create public getters and setters for name and balance to control access.
Create an account instance to see getters and setters in action, exposing public name and balance while private members stay hidden, with potential validation behind the scenes.
Encapsulate fields with private setters and implement getters for name and balance. Enforce validation in setters, throwing exceptions for empty names and insufficient balances with a minimum balance rule.
In this validation client, the presenter demonstrates encapsulation step three by using try-catch to enforce account name non-empty and a minimum balance of 100, tested with multiple account scenarios.
Learn to encapsulate business logic by exposing a read-only account level property and a private display account level method, mapping balance to silver, gold, or platinum.
Encapsulate logic in the account class by exposing a public account level while hiding the underlying private methods, illustrating how the client accesses the level.
Explore single level inheritance in object oriented C# masterclass part 1, showing how a savings account is a type of account that inherits balance retrieval and adds interest earned.
Demonstrate single level inheritance by creating a base account class with a get balance method, and a savings account that inherits it, gaining base methods and get interest earned.
Learn how multiple level inheritance works in C#, building a chain from account to savings account to flexible savings account, and add specific methods like pay health care costs.
Explore multiple level inheritance by inspecting a flexible savings account that inherits from savings and account, and exposes get balance, interest earned, and health care costs.
Explore hierarchical inheritance by extending a base account class to create savings and checking accounts. Compare methods like get balance, get interest earned, and withdraw funds specific to checking accounts.
Demonstrates hierarchical inheritance by modeling a base account with derived savings and checking accounts, and implements get balance, withdraw funds, and get interest earned.
Define an interface as a contract named I account with a balance property and a display method, then implement it in a class using the colon syntax and Intellisense.
Explore interfaces in C# by defining IAccount with a display method, then cast objects with the as keyword and check for null to display account info or show a message.
Use the is keyword to detect accounts that implement the AI account interface and display their information, illustrated by auto, checking, and savings account examples.
Learn how to pass interfaces as method arguments by implementing the ITransferable interface on accounts, calling transfer on transferable accounts, and handling non-transferable accounts.
Learn how to return an interface from a method by selecting the first transferable account from a collection, then invoke its transfer behavior via the interface.
Create an array of interfaces to hold transferable accounts, filter out non-transferable ones, iterate with foreach, and execute the transfer logic across all eligible accounts.
Learn how abstract classes enable partial implementation and enforce overrides in derived accounts, using virtual deposits and concrete checking and savings implementations to illustrate polymorphism in C#.
Explore abstract classes and polymorphism in C# by comparing a base account with checking and savings accounts, highlighting deposits, withdrawals, and earned interest.
Design a bank system in c# using an abstract account class with checking and savings accounts, a transferable interface, and overdraft, account limit, and customer limit exceptions.
Create a new solution folder, add a console project named Bank of Dunnett, and remove the default program as you prepare to build the Bank of DotNet.
Design an abstract account class in C# with protected balance and account id, public properties, and virtual deposit and withdraw methods; include an abstract display for specific account types.
Design and throw a custom overdraft exception in the account withdrawal, including a deficit amount property and constructor chaining to the base exception, to signal insufficient funds.
Create a checking account class that extends the account base, featuring overdraft balance, constructor chaining, and overridden display and withdraw methods to handle overdraft logic.
Introduce a savings account class inheriting from the abstract account, with an interest rate field and a constructor that passes the initial balance to the base, overriding display.
Create an ITransferable interface with a void transfer method, then implement it in a savings account to withdraw from the source and deposit into the target account.
Define a customer class with a max of two accounts, manage customer id, first name, last name, and a private accounts list; include add, retrieve, and get first transferable account.
Create a public account limit exception by extending the exception class, expose a public number of accounts property, and throw this exception when a customer exceeds the maximum allowed accounts.
Develop a bank class managing multiple customers, with add and get operations, a to-string override for display, and a generate report that lists each customer's accounts under a 10-customer limit.
Add a customer limit exception extending the exception class, store the customer count in a private field with a public property, and throw it when max customers are reached.
Create a bank instance using object oriented programming, with customers and a joint checking account. Handle errors with a try catch and a custom customer limit exception; display the message.
Handle account limit exceptions while adding accounts in a bank client, create Jane Doe's checking and savings with overdraft protection and interest, and establish a joint account with John Doe.
Generate a full customer balance report, fetch Jane Doe's checking account, perform deposits and withdrawals, handle overdraft exceptions, and display account details.
Demonstrates creating and testing bank transactions for John Doe and Jane Doe's joint accounts, including deposits, withdrawals, overdraft handling, and transfers using transferable accounts.
Debug bank client by creating a bank, add Jane Doe and John Doe, and set up checking and savings accounts with a joint account, overdraft handling, transactions, transfers, and reports.
Get Started with Object Oriented C# MasterClass Part 1!
Are you a student or professional in the field of software engineering or maybe contemplating an educational or career move to the software engineering world? Have you been looking for a quick and easy way to get up and running with Object Oriented C# using .NET Core and don't want to go through an overwhelming amount of material just to get your environment setup and ready for building your own apps? Don't worry as THIS IS THE COURSE FOR YOU!
In my course, I will teach you how to get your environment setup for .NET Core and help you to gain a strong foundation in C# Object Oriented Programming quickly and through a step-by-step guided approach. I will be showing you all the necessary installation and setup needed for .NET Core and Visual Studio IDE.
Learning Object-Oriented Programming (OOP) is an essential skill for any software developer. It provides a structured and efficient way of designing and organizing code, making it easier to maintain and scale applications. With C# as your language of choice, you'll have access to a powerful and versatile toolset within the .NET ecosystem.
In this comprehensive MasterClass, we will delve deep into the core principles of OOP, such as encapsulation, inheritance, and polymorphism. You'll discover how to create classes, define properties, and implement methods that unleash the full potential of C#. Through hands-on exercises and real-world examples, you will gain the confidence to tackle complex projects and design elegant solutions.
Moreover, we will explore the benefits of using .NET Core, a cross-platform framework that enables you to build applications that run on Windows, macOS, and Linux. You'll learn how to set up your development environment to take advantage of .NET Core's performance and flexibility.
By the end of this MasterClass, you will be equipped with the knowledge and skills to craft sophisticated C# applications, opening doors to exciting job opportunities and advancements in your software engineering career. So don't wait any longer; let's embark on this journey together and become a C# OOP expert in no time!
Take this course and feel proud of the fact that you will be one step closer towards the rewarding field of Software Engineering using .NET technologies!