Java Exceptions Vocabulary

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/19

flashcard set

Earn XP

Description and Tags

Vocabulary flashcards covering core Java Exception handling concepts, methods, keywords, and hierarchies.

Last updated 2:56 PM on 8/27/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

20 Terms

1
New cards

Exception

An event or problem that arises during the execution of a program, causing the normal flow of the program to be disrupted and terminating the application abnormally if not handled.

2
New cards

Checked Exceptions

Exceptions checked (notified) by the compiler at compilation-time, also known as compile time exceptions, which must be handled or declared by the programmer.

3
New cards

Unchecked Exceptions

Exceptions that occur at execution time, also called Runtime Exceptions, including programming bugs such as logic errors or improper API use; they are ignored during compilation.

4
New cards

Errors

Abnormal conditions and severe failures that arise beyond the control of the user or programmer (e.g., stack overflow or JVM out of memory) from which programs typically cannot recover.

5
New cards

Throwable Class

The top-level class in the Java exception hierarchy from which both Exception and Error classes derive, which itself extends java.lang.Object.

6
New cards

java.lang.Exception Class

A subclass of Throwable that serves as the parent class for exceptions, having two main subclasses: IOException and RuntimeException.

7
New cards

getMessage()

A method in the Throwable class that returns a detailed message string about the exception that has occurred, initialized in the Throwable constructor.

8
New cards

getCause()

A method in the Throwable class that returns the cause of the exception as represented by a Throwable object.

9
New cards

toString()

A method in the Throwable class that returns the name of the class concatenated with the result of getMessage().

10
New cards

printStackTrace()

A method in the Throwable class that prints the result of toString() along with the stack trace to System.err, the error output stream.

11
New cards

getStackTrace()

A method in the Throwable class that returns an array containing each element on the stack trace, where index 0 represents the top of the call stack.

12
New cards

fillInStackTrace()

A method in the Throwable class that fills the stack trace of the Throwable object with the current stack trace, adding to any previous information.

13
New cards

Protected Code

The code placed inside a try/catch block that might generate an exception.

14
New cards

throws Keyword

A keyword appearing at the end of a method's signature used to declare checked exceptions that the method does not handle, postponing exception handling.

15
New cards

throw Keyword

A keyword used to explicitly invoke or throw an exception, either a newly instantiated one or one that was just caught.

16
New cards

finally Block

A block of code following a try or catch block that always executes regardless of whether an exception occurs, commonly used for cleanup statements.

17
New cards

try-with-resources

An exception handling feature introduced in Java 7 (automatic resource management) that automatically closes resources declared within parentheses at the end of the block.

18
New cards

AutoCloseable Interface

An interface that a class must implement to be used in a try-with-resources statement, causing its close() method to be invoked automatically at runtime.

19
New cards

JVM Exceptions

A category of exceptions or errors explicitly or logically thrown by the JVM, such as NullPointerException, ArrayIndexOutOfBoundsException, and ClassCastException.

20
New cards

Programmatic Exceptions

Exceptions thrown explicitly by application or API programmers, such as IllegalArgumentException and IllegalStateException.