ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/main/java/util/concurrent/Executor.java
(Generate patch)

Comparing jsr166/src/main/java/util/concurrent/Executor.java (file contents):
Revision 1.29 by jsr166, Thu Jun 9 07:48:43 2011 UTC vs.
Revision 1.30 by jsr166, Wed Jan 16 01:59:47 2013 UTC

# Line 10 | Line 10 | package java.util.concurrent;
10   * An object that executes submitted {@link Runnable} tasks. This
11   * interface provides a way of decoupling task submission from the
12   * mechanics of how each task will be run, including details of thread
13 < * use, scheduling, etc.  An <tt>Executor</tt> is normally used
13 > * use, scheduling, etc.  An {@code Executor} is normally used
14   * instead of explicitly creating threads. For example, rather than
15 < * invoking <tt>new Thread(new(RunnableTask())).start()</tt> for each
15 > * invoking {@code new Thread(new(RunnableTask())).start()} for each
16   * of a set of tasks, you might use:
17   *
18   * <pre>
# Line 22 | Line 22 | package java.util.concurrent;
22   * ...
23   * </pre>
24   *
25 < * However, the <tt>Executor</tt> interface does not strictly
25 > * However, the {@code Executor} interface does not strictly
26   * require that execution be asynchronous. In the simplest case, an
27   * executor can run the submitted task immediately in the caller's
28   * thread:
# Line 45 | Line 45 | package java.util.concurrent;
45   *   }
46   * }}</pre>
47   *
48 < * Many <tt>Executor</tt> implementations impose some sort of
48 > * Many {@code Executor} implementations impose some sort of
49   * limitation on how and when tasks are scheduled.  The executor below
50   * serializes the submission of tasks to a second executor,
51   * illustrating a composite executor.
# Line 82 | Line 82 | package java.util.concurrent;
82   *   }
83   * }}</pre>
84   *
85 < * The <tt>Executor</tt> implementations provided in this package
85 > * The {@code Executor} implementations provided in this package
86   * implement {@link ExecutorService}, which is a more extensive
87   * interface.  The {@link ThreadPoolExecutor} class provides an
88   * extensible thread pool implementation. The {@link Executors} class
# Line 101 | Line 101 | public interface Executor {
101      /**
102       * Executes the given command at some time in the future.  The command
103       * may execute in a new thread, in a pooled thread, or in the calling
104 <     * thread, at the discretion of the <tt>Executor</tt> implementation.
104 >     * thread, at the discretion of the {@code Executor} implementation.
105       *
106       * @param command the runnable task
107       * @throws RejectedExecutionException if this task cannot be

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines