org.jbehave.core.embedder
Class Embedder.NonThreadingExecutorService

java.lang.Object
  extended by org.jbehave.core.embedder.Embedder.NonThreadingExecutorService
All Implemented Interfaces:
Executor, ExecutorService
Enclosing class:
Embedder

public static class Embedder.NonThreadingExecutorService
extends Object
implements ExecutorService

Non-threading ExecutorService for situations where thread count = 1


Constructor Summary
Embedder.NonThreadingExecutorService()
           
 
Method Summary
 boolean awaitTermination(long l, TimeUnit timeUnit)
           
 void execute(Runnable runnable)
           
<T> List<Future<T>>
invokeAll(Collection<? extends Callable<T>> callables)
           
<T> List<Future<T>>
invokeAll(Collection<? extends Callable<T>> callables, long l, TimeUnit timeUnit)
           
<T> T
invokeAny(Collection<? extends Callable<T>> callables)
           
<T> T
invokeAny(Collection<? extends Callable<T>> callables, long l, TimeUnit timeUnit)
           
 boolean isShutdown()
           
 boolean isTerminated()
           
 void shutdown()
           
 List<Runnable> shutdownNow()
           
<T> Future<T>
submit(Callable<T> callable)
           
 Future<?> submit(Runnable runnable)
           
<T> Future<T>
submit(Runnable runnable, T t)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Embedder.NonThreadingExecutorService

public Embedder.NonThreadingExecutorService()
Method Detail

shutdown

public void shutdown()
Specified by:
shutdown in interface ExecutorService

shutdownNow

public List<Runnable> shutdownNow()
Specified by:
shutdownNow in interface ExecutorService

isShutdown

public boolean isShutdown()
Specified by:
isShutdown in interface ExecutorService

isTerminated

public boolean isTerminated()
Specified by:
isTerminated in interface ExecutorService

awaitTermination

public boolean awaitTermination(long l,
                                TimeUnit timeUnit)
                         throws InterruptedException
Specified by:
awaitTermination in interface ExecutorService
Throws:
InterruptedException

submit

public <T> Future<T> submit(Callable<T> callable)
Specified by:
submit in interface ExecutorService

submit

public <T> Future<T> submit(Runnable runnable,
                            T t)
Specified by:
submit in interface ExecutorService

submit

public Future<?> submit(Runnable runnable)
Specified by:
submit in interface ExecutorService

invokeAll

public <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> callables)
                          throws InterruptedException
Specified by:
invokeAll in interface ExecutorService
Throws:
InterruptedException

invokeAll

public <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> callables,
                                     long l,
                                     TimeUnit timeUnit)
                          throws InterruptedException
Specified by:
invokeAll in interface ExecutorService
Throws:
InterruptedException

invokeAny

public <T> T invokeAny(Collection<? extends Callable<T>> callables)
            throws InterruptedException,
                   ExecutionException
Specified by:
invokeAny in interface ExecutorService
Throws:
InterruptedException
ExecutionException

invokeAny

public <T> T invokeAny(Collection<? extends Callable<T>> callables,
                       long l,
                       TimeUnit timeUnit)
            throws InterruptedException,
                   ExecutionException,
                   TimeoutException
Specified by:
invokeAny in interface ExecutorService
Throws:
InterruptedException
ExecutionException
TimeoutException

execute

public void execute(Runnable runnable)
Specified by:
execute in interface Executor


Copyright © 2003-2011. All Rights Reserved.