Tagged articles
6 articles
Page 1 of 1
Lisa Notes
Lisa Notes
Apr 26, 2026 · Fundamentals

Master Java Object Type Conversion: Upcasting and Downcasting Basics

This article explains Java object type conversion, covering upcasting (implicit parent‑to‑child casting) and downcasting (explicit child‑to‑parent casting), their safety rules, static method behavior, and how to use the instanceof operator to avoid runtime errors.

DowncastingInstanceofJava
0 likes · 5 min read
Master Java Object Type Conversion: Upcasting and Downcasting Basics
Programmer DD
Programmer DD
May 7, 2022 · Backend Development

How Java 17’s Switch Pattern Matching Simplifies Type Checks

This article demonstrates how Java 17’s enhanced switch statement with pattern matching replaces cumbersome instanceof‑based if‑else chains, providing concise type‑checking and casting for Map values such as String, Integer, and Double, while noting its preview status.

InstanceofJDK 17Java
0 likes · 5 min read
How Java 17’s Switch Pattern Matching Simplifies Type Checks
Qunar Tech Salon
Qunar Tech Salon
Mar 21, 2015 · Fundamentals

Understanding Null in Java: Causes, Behaviors, and Best Practices

This article explains the role of the null keyword in Java, its default value for reference types, common pitfalls such as NullPointerException caused by autoboxing, improper primitive assignments, instanceof checks, static method calls on null references, and safe handling techniques to write null‑safe code.

Best PracticesInstanceofJava
0 likes · 12 min read
Understanding Null in Java: Causes, Behaviors, and Best Practices