Title: Key Concept - Interrupting a thread
Course: CPS 189: Java Certification - Review, Practice & Prepare (Development) > Section: Learning Modules

- An interrupt is a signal from outside a thread that it should change or stop what it is doing.
- A thread is interrupted with the Thread.interrupt method.
- There are two ways a thread can respond to an interrupt:
  - Include a try statement that catches an InterruptedException exception.
  - Include a condition that calls the Thread.interrupted method and optionally throws an InterruptedException exception.

For additional study, view the resources under:

- Level 2 Study Materials: Unit 7