5 posts about Downcasting by 3 contributors.
Know Downcasting? Share what you know with developers who are learning it.
Learn how type casting works in Java, including primitive and object casting, upcasting, downcasting, and common pitfalls like ClassCastException with practical examples and inheritance-based scenarios.
This article gives an introduction to polymorphism in C#. Using the example created in this introduction, the article then goes on to describe how we up-cast and down-cast objects.
This article describes a simple approach to downcasting in Visual Basic; downcasting merely refers to the process of casting an object of a base class type to a derived class type.
This article describes a simple approach to downcasting in Visual Basic; downcasting merely refers to the process of casting an object of a base class type to a derived class type. Upcasting is legal in Visual Basic as the process there is to convert an object of a derived class type into an object of its base class type. In spite of the general illegality of downcasting you may find that when working with generics it is sometimes handy to do it anyway.
This article describes a simple approach to downcasting in C#; downcasting merely refers to the process of casting an object of a base class type to a derived class type. Upcasting is legal in C# as the process there is to convert an object of a derived class type into an object of its base class type. In spite of the general illegality of downcasting you may find that when working with generics it is sometimes handy to do it anyway.
DevSocialUpcoming · 3rd editionAI Agents ConferenceNov 23–27, 2026Live onlineMembers only16days leftRegisterPublish an article in this category and earn +1,000 SHARP when it is approved.
Write an article