Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01KqJyCidz3ZgRyHABv2GVJh
16 lines
1.1 KiB
Plaintext
16 lines
1.1 KiB
Plaintext
=== which are checked? ===
|
|
Exception CHECKED Exception -> Throwable -> Object
|
|
IOException CHECKED IOException -> Exception -> Throwable -> Object
|
|
InterruptedException CHECKED InterruptedException -> Exception -> Throwable -> Object
|
|
RuntimeException unchecked RuntimeException -> Exception -> Throwable -> Object
|
|
IllegalArgumentException unchecked IllegalArgumentException -> RuntimeException -> Exception -> Throwable -> Object
|
|
NullPointerException unchecked NullPointerException -> RuntimeException -> Exception -> Throwable -> Object
|
|
Error unchecked Error -> Throwable -> Object
|
|
OutOfMemoryError unchecked OutOfMemoryError -> VirtualMachineError -> Error -> Throwable -> Object
|
|
StackOverflowError unchecked StackOverflowError -> VirtualMachineError -> Error -> Throwable -> Object
|
|
|
|
=== checked exception inside a stream lambda: wrap in UncheckedIOException ===
|
|
contents of a.txt
|
|
caught: java.io.UncheckedIOException: java.io.IOException: cannot read bad.txt
|
|
original cause: java.io.IOException: cannot read bad.txt
|