KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > java > util > concurrent > RejectedExecutionException


1 /*
2  * @(#)RejectedExecutionException.java 1.3 03/12/19
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7
8 package java.util.concurrent;
9
10 /**
11  * Exception thrown by an {@link Executor} when a task cannot be
12  * accepted for execution.
13  *
14  * @since 1.5
15  * @author Doug Lea
16  */

17 public class RejectedExecutionException extends RuntimeException JavaDoc {
18     private static final long serialVersionUID = -375805702767069545L;
19
20     /**
21      * Constructs a <tt>RejectedExecutionException</tt> with no detail message.
22      * The cause is not initialized, and may subsequently be
23      * initialized by a call to {@link #initCause(Throwable) initCause}.
24      */

25     public RejectedExecutionException() { }
26
27     /**
28      * Constructs a <tt>RejectedExecutionException</tt> with the
29      * specified detail message. The cause is not initialized, and may
30      * subsequently be initialized by a call to {@link
31      * #initCause(Throwable) initCause}.
32      *
33      * @param message the detail message
34      */

35     public RejectedExecutionException(String JavaDoc message) {
36         super(message);
37     }
38
39     /**
40      * Constructs a <tt>RejectedExecutionException</tt> with the
41      * specified detail message and cause.
42      *
43      * @param message the detail message
44      * @param cause the cause (which is saved for later retrieval by the
45      * {@link #getCause()} method)
46      */

47     public RejectedExecutionException(String JavaDoc message, Throwable JavaDoc cause) {
48         super(message, cause);
49     }
50
51     /**
52      * Constructs a <tt>RejectedExecutionException</tt> with the
53      * specified cause. The detail message is set to: <pre> (cause ==
54      * null ? null : cause.toString())</pre> (which typically contains
55      * the class and detail message of <tt>cause</tt>).
56      *
57      * @param cause the cause (which is saved for later retrieval by the
58      * {@link #getCause()} method)
59      */

60     public RejectedExecutionException(Throwable JavaDoc cause) {
61         super(cause);
62     }
63 }
64
Popular Tags