HomeSort by relevance Sort by last modified time
    Searched full:callable (Results 1 - 25 of 332) sorted by null

1 2 3 4 5 6 7 8 91011>>

  /external/guava/guava/src/com/google/common/util/concurrent/
ListenableFutureTask.java 19 import java.util.concurrent.Callable;
42 * given {@code Callable}.
44 * @param callable the callable task
47 public static <V> ListenableFutureTask<V> create(Callable<V> callable) {
48 return new ListenableFutureTask<V>(callable);
68 private ListenableFutureTask(Callable<V> callable) {
69 super(callable);
    [all...]
Callables.java 19 import java.util.concurrent.Callable;
24 * Static utility methods pertaining to the {@link Callable} interface.
33 * Creates a {@code Callable} which immediately returns a preset value each
36 public static <T> Callable<T> returning(final @Nullable T value) {
37 return new Callable<T>() {
FakeTimeLimiter.java 21 import java.util.concurrent.Callable;
43 public <T> T callWithTimeout(Callable<T> callable, long timeoutDuration,
45 return callable.call(); // fooled you
AbstractListeningExecutorService.java 23 import java.util.concurrent.Callable;
54 @Override public <T> ListenableFuture<T> submit(Callable<T> task) {
63 private <T> T doInvokeAny(Collection<? extends Callable<T>> tasks, boolean timed, long nanos)
81 Iterator<? extends Callable<T>> it = tasks.iterator();
132 @Override public <T> T invokeAny(Collection<? extends Callable<T>> tasks)
142 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
147 @Override public <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> tasks)
155 for (Callable<T> t : tasks) {
181 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
190 for (Callable<T> t : tasks)
    [all...]
ForwardingExecutorService.java 23 import java.util.concurrent.Callable;
55 Collection<? extends Callable<T>> tasks) throws InterruptedException {
61 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
67 public <T> T invokeAny(Collection<? extends Callable<T>> tasks)
74 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
104 public <T> Future<T> submit(Callable<T> task) {
SimpleTimeLimiter.java 31 import java.util.concurrent.Callable;
100 Callable<Object> callable = new Callable<Object>() {
111 return callWithTimeout(callable, timeoutDuration, timeoutUnit,
120 public <T> T callWithTimeout(Callable<T> callable, long timeoutDuration,
122 checkNotNull(callable);
126 Future<T> future = executor.submit(callable);
  /external/guava/guava-bootstrap/src/java/util/concurrent/
ExecutorService.java 28 <T> Future<T> submit(Callable<T> task);
34 <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> tasks)
38 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
41 <T> T invokeAny(Collection<? extends Callable<T>> tasks)
45 Collection<? extends Callable<T>> tasks, long timeout, TimeUnit unit)
  /external/guava/guava-tests/test/com/google/common/util/concurrent/
CallablesTest.java 21 import java.util.concurrent.Callable;
34 Callable<Object> callable = Callables.returning(value); local
35 assertSame(value, callable.call());
37 assertSame(value, callable.call());
AbstractListeningExecutorServiceTest.java 24 import java.util.concurrent.Callable;
67 * Completed submit(callable) returns result
104 Future future = e.submit(Executors.callable(
127 Future future = e.submit(Executors.callable(
147 Future future = e.submit(Executors.callable(
176 * submit(null callable) throws NPE
181 e.submit((Callable<?>) null);
187 * submit(callable).get() throws InterruptedException if interrupted
196 final Callable<Void> awaiter = new CheckedCallable<Void>() {
221 * get of submit(callable) throws ExecutionException if callabl
    [all...]
  /frameworks/ex/variablespeed/tests/src/com/android/ex/variablespeed/
RealMediaPlayerTest.java 21 import java.util.concurrent.Callable;
34 Callable<MediaPlayer> callable = new Callable<MediaPlayer>() { local
40 FutureTask<MediaPlayer> future = new FutureTask<MediaPlayer>(callable);
  /external/jmonkeyengine/engine/src/core/com/jme3/app/
AppTask.java 51 private final Callable<V> callable; field in class:AppTask
61 * {@link Callable}.
63 * @param callable The callable to be executed
65 public AppTask(Callable<V> callable) {
66 this.callable = callable;
136 public Callable<V> getCallable()
    [all...]
  /external/robolectric/src/main/java/com/xtremelabs/robolectric/util/
RobolectricBackgroundExecutorService.java 7 import java.util.concurrent.Callable;
42 public <T> Future<T> submit(Callable<T> tCallable) {
68 public <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> callables) throws InterruptedException {
73 public <T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> callables, long l, TimeUnit timeUnit) throws InterruptedException {
78 public <T> T invokeAny(Collection<? extends Callable<T>> callables) throws InterruptedException, ExecutionException {
83 public <T> T invokeAny(Collection<? extends Callable<T>> callables, long l, TimeUnit timeUnit) throws InterruptedException, ExecutionException, TimeoutException {
  /external/junit/src/org/junit/rules/
ErrorCollector.java 10 import java.util.concurrent.Callable;
64 checkSucceeds(new Callable<Object>() {
73 * Adds to the table the exception, if any, thrown from {@code callable}.
75 * {@code callable} threw an exception.
77 public Object checkSucceeds(Callable<Object> callable) {
79 return callable.call();
  /libcore/luni/src/test/java/sun/misc/
UnsafeTest.java 22 import java.util.concurrent.Callable;
40 Callable<Object> callable = Executors.callable(new Runnable() { local
47 callable.call();
  /libcore/luni/src/main/java/java/util/concurrent/
AbstractExecutorService.java 30 * protected <V> RunnableFuture<V> newTaskFor(Callable<V> c) {
61 * Returns a <tt>RunnableFuture</tt> for the given callable task.
63 * @param callable the callable task being wrapped
65 * underlying callable and which, as a <tt>Future</tt>, will yield
66 * the callable's result as its result and provide for
70 protected <T> RunnableFuture<T> newTaskFor(Callable<T> callable) {
71 return new FutureTask<T>(callable);
100 public <T> Future<T> submit(Callable<T> task)
    [all...]
Executors.java 22 * ThreadFactory}, and {@link Callable} classes defined in this
35 * <li> Methods that create and return a {@link Callable}
37 * in execution methods requiring <tt>Callable</tt>.
297 * Returns a {@link Callable} object that, when
300 * <tt>Callable</tt> to an otherwise resultless action.
303 * @return a callable object
306 public static <T> Callable<T> callable(Runnable task, T result) { method in class:Executors
313 * Returns a {@link Callable} object that, when
316 * @return a callable objec
319 public static Callable<Object> callable(Runnable task) { method in class:Executors
332 public static Callable<Object> callable(final PrivilegedAction<?> action) { method in class:Executors
    [all...]
Callable.java 14 * <p>The <tt>Callable</tt> interface is similar to {@link
21 * convert from other common forms to <tt>Callable</tt> classes.
28 public interface Callable<V> {
FutureTask.java 21 * <p>A {@code FutureTask} can be used to wrap a {@link Callable} or
72 /** The underlying callable; nulled out after running */
73 private Callable<V> callable; field in class:FutureTask
76 /** The thread running the callable; CASed during run() */
99 * given {@code Callable}.
101 * @param callable the callable task
102 * @throws NullPointerException if the callable is null
104 public FutureTask(Callable<V> callable)
    [all...]
  /external/guava/guava-gwt/src-super/java/util/super/java/util/concurrent/
Callable.java 20 * Emulation of Callable.
24 public interface Callable<V> {
  /external/robolectric/src/test/java/com/xtremelabs/robolectric/shadows/
ProgressDialogTest.java 13 import java.util.concurrent.Callable;
80 assertLatestDialogsSet("Title", "Message", false, false, null, new Callable<ProgressDialog>() {
91 assertLatestDialogsSet("Title", "Message", true, false, null, new Callable<ProgressDialog>() {
101 assertLatestDialogsSet("Title", "Message", true, true, null, new Callable<ProgressDialog>() {
117 assertLatestDialogsSet("Title", "Message", true, true, cancelListener, new Callable<ProgressDialog>() {
127 Callable<ProgressDialog> callable) throws Exception {
131 dialog = callable.call();
  /frameworks/base/docs/html/sdk/api_diff/9/changes/
java.util.concurrent.ExecutorService.html 86 <A NAME="java.util.concurrent.ExecutorService.invokeAll_removed(java.util.Collection<java.util.concurrent.Callable<T>>)"></A>
87 <nobr><code>List&lt;Future&lt;T&gt;&gt;</code>&nbsp;invokeAll(<code>Collection&lt;Callable&lt;T&gt;&gt;</code>)</nobr>
93 <A NAME="java.util.concurrent.ExecutorService.invokeAll_removed(java.util.Collection<java.util.concurrent.Callable<T>>, long, java.util.concurrent.TimeUnit)"></A>
94 <nobr><code>List&lt;Future&lt;T&gt;&gt;</code>&nbsp;invokeAll(<code>Collection&lt;Callable&lt;T&gt;&gt;,</nobr> long<nobr>,</nobr> TimeUnit<nobr><nobr></code>)</nobr>
100 <A NAME="java.util.concurrent.ExecutorService.invokeAny_removed(java.util.Collection<java.util.concurrent.Callable<T>>)"></A>
101 <nobr><code>T</code>&nbsp;invokeAny(<code>Collection&lt;Callable&lt;T&gt;&gt;</code>)</nobr>
107 <A NAME="java.util.concurrent.ExecutorService.invokeAny_removed(java.util.Collection<java.util.concurrent.Callable<T>>, long, java.util.concurrent.TimeUnit)"></A>
108 <nobr><code>T</code>&nbsp;invokeAny(<code>Collection&lt;Callable&lt;T&gt;&gt;,</nobr> long<nobr>,</nobr> TimeUnit<nobr><nobr></code>)</nobr>
122 <A NAME="java.util.concurrent.ExecutorService.invokeAll_added(java.util.Collection<? extends java.util.concurrent.Callable<T>>)"></A>
123 <nobr><code>List&lt;Future&lt;T&gt;&gt;</code>&nbsp;<A HREF="../../../../reference/java/util/concurrent/ExecutorService.html#invokeAll(java.util.Collection<? extends java.util.concurrent.Callable<T>>)" target="_top"><code>invokeAll</code></A>(<code>Collection&lt;Callable&lt;T&gt;&gt;</code>)</ (…)
    [all...]
  /external/jmonkeyengine/engine/src/core/com/jme3/scene/control/
UpdateControl.java 38 import java.util.concurrent.Callable;
47 * mySpatial.getControl(UpdateControl.class).enqueue(new Callable() {
61 * Enqueues a task/callable object to execute in the jME3
64 public <V> Future<V> enqueue(Callable<V> callable) {
65 AppTask<V> task = new AppTask<V>(callable);
  /external/smack/src/com/kenai/jbosh/
HTTPSender.java 41 * Create a {@code Callable} instance which can be used to send the
44 * of the returned {@code Callable} should send the request (if it has
50 * @return callable used to access the response
  /cts/tests/tests/app/src/android/app/cts/
IntentServiceTest.java 26 import java.util.concurrent.Callable;
62 new Callable<Boolean>() {
69 PollingCheck.check("accumulator not correct", TIMEOUT_MSEC, new Callable<Boolean>() {
76 PollingCheck.check("onDestroyCalled not called", TIMEOUT_MSEC, new Callable<Boolean>() {
  /external/v8/test/mjsunit/
array-tostring.js 29 // is callable. Otherwise, just use the original Object.toString function.
52 // Non-callable join function is ignored and Object.prototype.toString is
55 a3.join = "not callable";
58 // Non-existing join function is treated same as non-callable.
90 // Non-callable join works same as for Array.
93 join: "not callable"};
131 // If toLocaleString of element is not callable, throw a TypeError.
132 var la2 = [1, {toLocaleString: "not callable"}, 3];
135 // If toLocaleString of element is callable, call it.

Completed in 651 milliseconds

1 2 3 4 5 6 7 8 91011>>