In my second week at Tong Hin, I started up by studying object-oriented programming (OOP) and learnt that OOP is a programming paradigm that is widely used in C#. It is a way of programming that focuses on creating objects that interact with each other to accomplish tasks. In OOP, objects are created from classes, which define their properties and behaviors.
The main concepts of OOP in C# include encapsulation, inheritance, and polymorphism. Encapsulation is the practice of hiding data and methods within an object, so that they cannot be accessed from outside the object. As for Inheritance is a concept that allows classes to inherit properties and methods from other classes where inheritance creates a hierarchy of classes, with each class having a parent class, except for the root class, which has no parent. Inheritance also enables developers to create new classes based on existing classes (parent class). Thus, reducing code duplication and promoting code reuse. The derived class inherits all the properties and methods of the parent class, and can also add new properties and methods.
Later on the same week, I started to go through another module which is Entity Framework (EF), it is an object-relational mapping (ORM) framework for .NET applications that provides a simplified approach to working with databases, and the latest version, Entity Framework Core 5 (EF Core 5), offers several new features and improvements compared to the earlier versions. When I first started learning Entity Framework, I was impressed by its ability to simplify data access by mapping database tables to classes and providing a LINQ-based query syntax. EF made it easy to create, read, update, and delete records in a database without needing to write complex SQL statements. I also learnt that EF Core is cross-platform support where it can run on multiple operating systems, including Linux and macOS. This makes it easier to develop and deploy applications on a wider range of platforms.
Another significant feature in EF Core 5 is its support for multiple databases. While EF only supports Microsoft SQL Server, EF Core 5 supports a variety of databases, including PostgreSQL, MySQL, SQLite, and more. As a result, working with various data sources is made simpler without the need to learn additional frameworks or languages.
Overall, EF Core 5 is a valuable tool for developers who need to work with data in .NET applications. It simplifies the process of data access and provides a range of features to enhance performance and improve developer productivity.
