·
Here's a clean and focused Java Exception Tree containing only the exceptions relevant to the Java certifications (like 1Z0-819, 1Z0-830), with a clear emphasis on:
- ✅ Runtime vs checked
- ✅ Certification usage context
- ✅ Avoiding noise from obscure exceptions
🧠 What to Know for Each (Certification-Relevant Exceptions)
- 📄 IOException – Checked: File or stream operations, often used in try-with-resources.
- 📁 FileNotFoundException – Checked: Thrown when attempting to open a non-existent file.
- 📤 EOFException – Checked: End of stream reached unexpectedly during input.
- 📦 UncheckedIOException – Unchecked: Wraps IOException in functional interfaces or streams.
- 💤 InterruptedException – Checked: Thrown when a thread is interrupted (e.g., during Thread.sleep()).
- ⏱️ TimeoutException – Checked: Occurs when waiting too long for a task to complete (e.g., Future.get() with timeout).
- 💥 ExecutionException – Checked: Wraps exceptions thrown in async tasks (e.g., from Future).
- 🔍 InvocationTargetException – Checked: Thrown when a reflected method throws an exception.
- 🔐 IllegalAccessException – Checked: Reflection access to a field/method is illegal.
- 🧱 InstantiationException – Checked: Attempt to instantiate an abstract class or interface via reflection.
- 🧭 NoSuchMethodException – Checked: Requested method does not exist (common in reflection).
- 🌍 MissingResourceException – Unchecked: Missing key in a ResourceBundle.
- ➗ ArithmeticException – Unchecked: Arithmetic error, like division by zero.
- ❌ NullPointerException – Unchecked: Dereferencing a null reference.
- 📉 IndexOutOfBoundsException – Unchecked: General out-of-bounds for collections/arrays.
- 🧮 ArrayIndexOutOfBoundsException – Unchecked: Specifically for arrays.
- ✂️ StringIndexOutOfBoundsException – Unchecked: Specifically for strings.
- 🧪 IllegalArgumentException – Unchecked: Invalid method parameter passed.
- 🔢 NumberFormatException – Unchecked: Failed conversion from string to number (e.g., "abc" to int).
- 🌀 IllegalStateException – Unchecked: Method invoked at an inappropriate time (e.g., reusing a closed stream).
- 🔄 ClassCastException – Unchecked: Invalid casting between incompatible types.
- 🚫 UnsupportedOperationException – Unchecked: Operation not supported, such as on unmodifiable collections.
- 🔁 ConcurrentModificationException – Unchecked: Modifying a collection during iteration.
- 📝 InputMismatchException – Unchecked: Scanner receives input of unexpected type.
- 📭 NoSuchElementException – Unchecked: Accessing elements from an exhausted iterator or empty optional/stream.
- 🛡️ SecurityException – Unchecked: Access control violation (e.g., attempting a restricted operation).