We start the next series of episodes with a polymorphism overview.  This is a core concept for proper object-oriented design.  Likewise, we will dig into several practical ways to use this.


Polymorphism Overview – A Definition

As with many topics, it seems best to start with a definition from Wikipedia.

In programming languages and type theory, polymorphism is the provision of a single interface to entities of different types or the use of a single symbol to represent multiple different types.

For our purposes, that symbol that is referred to can be considered a name.  The name can be a method, class, or property name.

Class Vs. Object

It is worth clarifying the difference between a class and an object.  We will be talking about these two terms a lot from here on out.  Therefore, let’s remove any confusion.  A Class is the definition of a class.  Think of it as a set of rules or a template.  A simple pseudo-code example is below.

Leaderboard Category: A Practical Approach To Object-Oriented Tag: , , Leave a comment

Rob Broadhead

Rob is a founder of, and frequent contributor to, Develpreneur. This includes the Building Better Developers podcast. He is also a longtime student of technology as a developer, designer, and manager of software solutions. Rob is a founder and principle of RB Consulting and has managed to author a book about his family experiences. In his free time, he stays busy raising five children (although a few have grown into adults). When he has a chance to breathe, he is on the ice playing hockey to relax.

Leave a Reply