Package EDU.oswego.cs.dl.util.concurrent
Class TimeoutException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.InterruptedException
EDU.oswego.cs.dl.util.concurrent.TimeoutException
- All Implemented Interfaces:
Serializable
Thrown by synchronization classes that report
timeouts via exceptions. The exception is treated
as a form (subclass) of InterruptedException. This both
simplifies handling, and conceptually reflects the fact that
timed-out operations are artificially interrupted by timers.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal long
The approximate time that the operation lasted before this timeout exception was thrown. -
Constructor Summary
ConstructorsConstructorDescriptionTimeoutException
(long time) Constructs a TimeoutException with given duration value.TimeoutException
(long time, String message) Constructs a TimeoutException with the specified duration value and detail message. -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
duration
public final long durationThe approximate time that the operation lasted before this timeout exception was thrown.
-
-
Constructor Details
-
TimeoutException
public TimeoutException(long time) Constructs a TimeoutException with given duration value. -
TimeoutException
Constructs a TimeoutException with the specified duration value and detail message.
-