/libcore/luni/src/main/java/java/util/concurrent/ |
Executor.java | 13 * use, scheduling, etc. An <tt>Executor</tt> is normally used 19 * Executor executor = <em>anExecutor</em>; 20 * executor.execute(new RunnableTask1()); 21 * executor.execute(new RunnableTask2()); 25 * However, the <tt>Executor</tt> interface does not strictly 27 * executor can run the submitted task immediately in the caller's 31 * class DirectExecutor implements Executor { 38 * than the caller's thread. The executor below spawns a new thread 42 * class ThreadPerTaskExecutor implements Executor { [all...] |
ExecutorCompletionService.java | 10 * A {@link CompletionService} that uses a supplied {@link Executor} 27 * void solve(Executor e, 47 * void solve(Executor e, 79 private final Executor executor; field in class:ExecutorCompletionService 111 * executor for base task execution and a 114 * @param executor the executor to use 115 * @throws NullPointerException if executor is {@code null} 117 public ExecutorCompletionService(Executor executor) [all...] |
ExecutorService.java | 14 * An {@link Executor} that provides methods to manage termination and 24 * Upon termination, an executor has no tasks actively executing, no 30 * Executor#execute} by creating and returning a {@link Future} that 39 * executor services provided in this package. 112 public interface ExecutorService extends Executor { 144 * Returns <tt>true</tt> if this executor has been shut down. 146 * @return <tt>true</tt> if this executor has been shut down 166 * @return <tt>true</tt> if this executor terminated and
|
/external/guava/src/com/google/common/util/concurrent/ |
AbstractListenableFuture.java | 19 import java.util.concurrent.Executor; 24 * guarantee that all registered listeners will be executed. Listener/Executor 33 * {@link #addListener(Runnable, Executor)} and {@link #done()} methods to it. 45 * Adds a listener/executor pair to execution list to execute when this task 48 public void addListener(Runnable listener, Executor exec) {
|
ListenableFuture.java | 19 import java.util.concurrent.Executor; 26 * executor, and is invoked using this executor once the {@code Future}'s 51 * <p>Adds a listener and executor to the ListenableFuture. 52 * The listener will be {@linkplain Executor#execute(Runnable) passed 53 * to the executor} for execution when the {@code Future}'s computation is 62 * @param exec the executor to run the listener in. 63 * @throws NullPointerException if the executor or listener was null. 65 * immediately but the executor rejected it. 67 public void addListener(Runnable listener, Executor exec) [all...] |
ListenableFutureTask.java | 20 import java.util.concurrent.Executor; 66 public void addListener(Runnable listener, Executor exec) {
|
ExecutionList.java | 23 import java.util.concurrent.Executor; 28 * <p>A list of ({@code Runnable}, {@code Executor}) pairs that guarantees 30 * executed in its associated {@code Executor} after {@link #run()} is called. 44 // The list of runnable,executor pairs to execute. Only modified within 53 * Add the runnable/executor pair to the list of pairs to execute. Executes 56 public void add(Runnable runnable, Executor executor) { 59 // Executor states that it throws NPE on null listener, so we propagate 62 Preconditions.checkNotNull(executor, "Executor was null.") 108 final Executor executor; field in class:ExecutionList.RunnableExecutorPair [all...] |
AbstractExecutionThreadService.java | 22 import java.util.concurrent.Executor; 39 executor().execute(new Runnable() { 104 * Returns the {@link Executor} that will be used to run this service. 105 * Subclasses may override this method to use a custom {@link Executor}, which 107 * priority. The returned executor's {@link Executor#execute(Runnable) 111 protected Executor executor() { method in class:AbstractExecutionThreadService 112 return new Executor() {
|
AbstractIdleService.java | 23 import java.util.concurrent.Executor; 30 * which run in a executor which by default uses a separate thread 41 executor(State.STARTING).execute(new Runnable() { 55 executor(State.STOPPING).execute(new Runnable() { 76 * Returns the {@link Executor} that will be used to run this service. 77 * Subclasses may override this method to use a custom {@link Executor}, which 79 * priority. The returned executor's {@link Executor#execute(Runnable) 86 protected Executor executor(final State state) method in class:AbstractIdleService [all...] |
AbstractCheckedFuture.java | 21 import java.util.concurrent.Executor; 112 public void addListener(Runnable listener, Executor exec) {
|
Futures.java | 24 import java.util.concurrent.Executor; 245 * <p>This version allows an arbitrary executor to be passed in for running 254 * @param exec Executor to run the function in. 259 Executor exec) { 295 * <p>This version allows an arbitrary executor to be passed in for running 304 * @param exec Executor to run the function in. 309 final Function<? super I, ? extends O> function, Executor exec) { 516 private static final Executor adapterExecutor = 539 public void addListener(Runnable listener, Executor exec) {
|
/external/chromium/net/proxy/ |
multi_threaded_proxy_resolver.h | 106 class Executor; 113 typedef std::vector<scoped_refptr<Executor> > ExecutorList; 124 Executor* FindIdleExecutor(); 127 Executor* AddNewExecutor(); 130 void OnExecutorReady(Executor* executor);
|
multi_threaded_proxy_resolver.cc | 36 // An "executor" is a job-runner for PAC requests. It encapsulates a worker 39 class MultiThreadedProxyResolver::Executor 40 : public base::RefCountedThreadSafe<MultiThreadedProxyResolver::Executor > { 43 // signal when the executor is ready to receive work by calling 47 Executor(MultiThreadedProxyResolver* coordinator, 51 // Submit a job to this executor. 54 // Callback for when a job has completed running on the executor's thread. 57 // Cleanup the executor. Cancels all outstanding work, and frees the thread 71 friend class base::RefCountedThreadSafe<Executor>; 72 ~Executor(); 117 Executor* executor() { function in class:net::MultiThreadedProxyResolver::Job 416 Executor* executor = FindIdleExecutor(); local 477 Executor* executor = *it; local 500 Executor* executor = AddNewExecutor(); local 511 const Executor* executor = *it; local 527 Executor* executor = *it; local 538 Executor* executor = *it; local 552 Executor* executor = new Executor( local [all...] |
/packages/apps/QuickSearchBox/tests/src/com/android/quicksearchbox/util/ |
MockExecutor.java | 20 import java.util.concurrent.Executor; 23 * A simple executor that maintains a queue and executes one task synchronously every 27 public class MockExecutor implements Executor {
|
/packages/apps/Contacts/src/com/android/contacts/util/ |
AsyncTaskExecutor.java | 21 import java.util.concurrent.Executor; 26 * This interface has a direct parallel with the {@link Executor} interface. It exists to decouple 39 * Executes the given AsyncTask with the default Executor.
|
AsyncTaskExecutors.java | 25 import java.util.concurrent.Executor; 87 private final Executor mExecutor; 89 public SimpleAsyncTaskExecutor(Executor executor) { 90 mExecutor = executor;
|
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/ |
SearchableCorpusFactory.java | 27 import java.util.concurrent.Executor; 42 private final Factory<Executor> mWebCorpusExecutorFactory; 45 Factory<Executor> webCorpusExecutorFactory) { 67 protected Executor createWebCorpusExecutor() { 119 Executor executor = createWebCorpusExecutor(); local 120 return new WebCorpus(mContext, mConfig, mSettings, executor, webSource, browserSource);
|
MultiSourceCorpus.java | 27 import java.util.concurrent.Executor; 34 private final Executor mExecutor; 46 Executor executor, Source... sources) { 48 mExecutor = executor;
|
QsbApplication.java | 44 import java.util.concurrent.Executor; 243 protected Factory<Executor> createExecutorFactory(final int numThreads) { 245 return new Factory<Executor>() { 246 public Executor create() { 283 Executor logExecutor = Executors.newSingleThreadExecutor(logThreadFactory); 306 * Gets the source task executor.
|
/frameworks/base/core/java/android/os/ |
AsyncTask.java | 23 import java.util.concurrent.Executor; 175 * An {@link Executor} that can be used to execute tasks in parallel. 177 public static final Executor THREAD_POOL_EXECUTOR 182 * An {@link Executor} that executes tasks one at a time in serial 185 public static final Executor SERIAL_EXECUTOR = new SerialExecutor(); 192 private static volatile Executor sDefaultExecutor = SERIAL_EXECUTOR; 200 private static class SerialExecutor implements Executor { 251 public static void setDefaultExecutor(Executor exec) { 520 * AsyncTask, however you can also use your own {@link Executor} for custom 536 * @param exec The executor to use. {@link #THREAD_POOL_EXECUTOR} is available as [all...] |
/packages/apps/QuickSearchBox/tests/src/com/android/quicksearchbox/ |
MultiSourceCorpusTest.java | 28 import java.util.concurrent.Executor; 45 Executor executor = Executors.newSingleThreadExecutor(); local 46 mCorpus = new SkeletonMultiSourceCorpus(getContext(), config, executor, 81 public SkeletonMultiSourceCorpus(Context context, Config config, Executor executor, 83 super(context, config, executor, sources);
|
/frameworks/support/v4/java/android/support/v4/content/ |
ModernAsyncTask.java | 23 import java.util.concurrent.Executor; 66 * An {@link Executor} that can be used to execute tasks in parallel. 68 public static final Executor THREAD_POOL_EXECUTOR 77 private static volatile Executor sDefaultExecutor = THREAD_POOL_EXECUTOR; 110 public static void setDefaultExecutor(Executor exec) { 380 * AsyncTask, however you can also use your own {@link Executor} for custom 394 * @param exec The executor to use. {@link #THREAD_POOL_EXECUTOR} is available as a 404 public final ModernAsyncTask<Params, Progress, Result> executeOnExecutor(Executor exec,
|
/packages/apps/Email/emailcommon/src/com/android/emailcommon/utility/ |
EmailAsyncTask.java | 24 import java.util.concurrent.Executor; 40 private static final Executor SERIAL_EXECUTOR = AsyncTask.SERIAL_EXECUTOR; 41 private static final Executor PARALLEL_EXECUTOR = AsyncTask.THREAD_POOL_EXECUTOR; 215 private final EmailAsyncTask<Params, Progress, Result> executeInternal(Executor executor, 224 mInnerTask.executeOnExecutor(executor, params); 242 private static EmailAsyncTask<Void, Void, Void> runAsyncInternal(Executor executor, 251 return task.executeInternal(executor, false, (Void[]) null);
|
/frameworks/ex/variablespeed/src/com/android/ex/variablespeed/ |
VariableSpeed.java | 28 import java.util.concurrent.Executor; 52 private final Executor mExecutor; 69 private VariableSpeed(Executor executor) throws UnsupportedOperationException { 70 Preconditions.checkNotNull(executor); 71 mExecutor = executor; 82 public static MediaPlayerProxy createVariableSpeed(Executor executor) 84 return new SingleThreadedMediaPlayerProxy(new VariableSpeed(executor));
|
/frameworks/base/core/java/com/android/internal/os/ |
SamplingProfilerIntegration.java | 32 import java.util.concurrent.Executor; 48 private static final Executor snapshotWriter;
|