Introduction to Object‐Oriented Programming
Benjamin Perkins, Jacob Vibe Hammer, Jon D. Reid · 2018
To access the real power of the C# language and the .NET Framework, the users need to make use of object-oriented programming (OOP) techniques. An object is a building block of an OOP application. This chapter explores what objects are and how they work. Classes are type definitions that are used to instantiate objects. Objects can contain data and/or expose operations that other code can use. Data can be made available to external code through properties, and operations can be made available to external code through methods. Both properties and methods are referred to as class members. The chapter then looks at some of the other features of objects: Interfaces; inheritance; polymorphism; relationships between objects; operator overloading; events; and reference versus value types. Furthermore, it looks at an area requiring a thorough understanding of OOP: desktop applications.