ClosedByInterruptException

  • ClosedByInterruptException signals that a thread's I/O operation on a channel was interrupted by another thread, leading to the channel's closure.

  • This exception is checked and extends AsynchronousCloseException, indicating an asynchronous closure due to the interrupt.

  • Before the exception is thrown, the channel is closed and the interrupted thread's interrupt status is set.

  • It provides a single public constructor with no parameters to create an instance of the exception.

  • Inherited methods from Throwable and Object offer functionalities like stack trace handling, cause analysis, and object management.

public class ClosedByInterruptException extends AsynchronousCloseException

Checked exception received by a thread when another thread interrupts it while it is blocked in an I/O operation upon a channel. Before this exception is thrown the channel will have been closed and the interrupt status of the previously-blocked thread will have been set.

Public Constructor Summary

ClosedByInterruptException()
Constructs an instance of this class.

Inherited Method Summary

Public Constructors

public ClosedByInterruptException ()

Constructs an instance of this class.