Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

More interfaces that were missed previously.

  • Loading branch information...
commit 2aa9de3dfbbd0687522123f42682f9360b97b6fd 1 parent ac27ebd
Mike Jensen authored
View
20 classpath/java/util/concurrent/BlockingQueue.java
@@ -0,0 +1,20 @@
+package java.util.concurrent;
+
+import java.util.Collection;
+import java.util.Queue;
+
+public interface BlockingQueue<T> extends Queue<T> {
+ public void put(T e) throws InterruptedException;
+
+ public boolean offer(T e, long timeout, TimeUnit unit) throws InterruptedException;
+
+ public T take() throws InterruptedException;
+
+ public T poll(long timeout, TimeUnit unit) throws InterruptedException;
+
+ public int remainingCapacity();
+
+ public int drainTo(Collection<? super T> c);
+
+ public int drainTo(Collection<? super T> c, int maxElements);
+}
View
13 classpath/java/util/concurrent/CompletionService.java
@@ -0,0 +1,13 @@
+package java.util.concurrent;
+
+public interface CompletionService<T> {
+ public Future<T> submit(Callable<T> task);
+
+ public Future<T> submit(Runnable task, T result);
+
+ public Future<T> take() throws InterruptedException;
+
+ public Future<T> poll();
+
+ public Future<T> poll(long timeout, TimeUnit unit) throws InterruptedException;
+}
View
5 classpath/java/util/concurrent/RunnableFuture.java
@@ -0,0 +1,5 @@
+package java.util.concurrent;
+
+public interface RunnableFuture<T> extends Runnable, Future<T> {
+ // nothing added to interface
+}
View
19 classpath/java/util/concurrent/ScheduledExecutorService.java
@@ -0,0 +1,19 @@
+package java.util.concurrent;
+
+public interface ScheduledExecutorService extends ExecutorService {
+ public ScheduledFuture<?> schedule(Runnable command,
+ long delay, TimeUnit unit);
+
+ public <V> ScheduledFuture<V> schedule(Callable<V> callable,
+ long delay, TimeUnit unit);
+
+ public ScheduledFuture<?> scheduleAtFixedRate(Runnable command,
+ long initialDelay,
+ long period,
+ TimeUnit unit);
+
+ public ScheduledFuture<?> scheduleWithFixedDelay(Runnable command,
+ long initialDelay,
+ long delay,
+ TimeUnit unit);
+}
View
5 classpath/java/util/concurrent/ThreadFactory.java
@@ -0,0 +1,5 @@
+package java.util.concurrent;
+
+public interface ThreadFactory {
+ public Thread newThread(Runnable r);
+}
Please sign in to comment.
Something went wrong with that request. Please try again.