/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());
|
/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...] |
FakeTimeLimiter.java | 21 import java.util.concurrent.Callable; 43 public <T> T callWithTimeout(Callable<T> callable, long timeoutDuration, 45 return callable.call(); // fooled you
|
TimeLimiter.java | 21 import java.util.concurrent.Callable; 82 * Invokes a specified Callable, timing out after the specified time limit. 91 * @param callable the Callable to execute 98 * @return the result returned by the Callable 104 <T> T callWithTimeout(Callable<T> callable, long timeoutDuration,
|
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/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/chromium_org/base/test/android/javatests/src/org/chromium/base/test/util/ |
InstrumentationUtils.java | 9 import java.util.concurrent.Callable; 22 Callable<R> callable) throws Throwable { 23 FutureTask<R> task = new FutureTask<R>(callable);
|
/external/chromium_org/third_party/WebKit/Tools/Scripts/webkitpy/common/ |
webkitunittest.py | 41 def _assertRaisesRegexp(self, expected_exception, regex_message, callable, *args): 43 callable(*args)
|
/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);
|
/libcore/luni/src/main/java/java/util/concurrent/ |
ScheduledExecutorService.java | 88 * @param callable the function to execute 94 * @throws NullPointerException if callable is null 96 public <V> ScheduledFuture<V> schedule(Callable<V> callable,
|
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() */ 98 * given {@code Callable}. 100 * @param callable the callable task 101 * @throws NullPointerException if the callable is null 103 public FutureTask(Callable<V> callable) [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 {@code Callable}. 334 * Returns a {@link Callable} object that, when 337 * {@code Callable} to an otherwise resultless action. 340 * @return a callable object 343 public static <T> Callable<T> callable(Runnable task, T result) { method in class:Executors 350 * Returns a {@link Callable} object that, when 353 * @return a callable objec 356 public static Callable<Object> callable(Runnable task) { method in class:Executors 369 public static Callable<Object> callable(final PrivilegedAction<?> action) { method in class:Executors [all...] |
ScheduledThreadPoolExecutor.java | 65 * {@code Callable}) that can be used to customize the concrete task 84 * Callable<V> c, RunnableScheduledFuture<V> task) { 200 ScheduledFutureTask(Callable<V> callable, long ns) { 201 super(callable); 376 * Modifies or replaces the task used to execute a callable. 381 * @param callable the submitted Callable 382 * @param task the task created to execute the callable 383 * @return a task that can execute the callable [all...] |
/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();
|
/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/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();
|
/external/chromium_org/third_party/WebKit/Tools/Scripts/webkitpy/test/ |
skip.py | 37 if not callable(attr):
|
/external/chromium_org/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.
|
json.js | 60 valueOf: "not callable", 67 valueOf: "not callable", 68 toString: "not callable either", 73 valueOf: "not callable", 83 ISOString: "not callable"}; 402 numFoo.valueOf = "not callable"; 412 str37.toString = "not callable"; 418 var func = function() { /* Is callable */ }; 420 var funcJSON = function() { /* Is callable */ }; 423 var re = /Is callable/; [all...] |
/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.
|
json.js | 60 valueOf: "not callable", 67 valueOf: "not callable", 68 toString: "not callable either", 73 valueOf: "not callable", 83 ISOString: "not callable"}; 356 numFoo.valueOf = "not callable"; 366 str37.toString = "not callable"; 372 var func = function() { /* Is callable */ }; 374 var funcJSON = function() { /* Is callable */ }; 377 var re = /Is callable/; [all...] |
/prebuilts/python/darwin-x86/2.7.5/lib/python2.7/test/ |
test_sys_setprofile.py | 93 def check_events(self, callable, expected): 94 events = capture_events(callable, self.new_watcher()) 355 def capture_events(callable, p=None): 364 protect(callable, p) 372 def show_events(callable): 374 pprint.pprint(capture_events(callable))
|
/prebuilts/python/linux-x86/2.7.5/lib/python2.7/test/ |
test_sys_setprofile.py | 93 def check_events(self, callable, expected): 94 events = capture_events(callable, self.new_watcher()) 355 def capture_events(callable, p=None): 364 protect(callable, p) 372 def show_events(callable): 374 pprint.pprint(capture_events(callable))
|
/external/junit/src/org/junit/internal/runners/ |
MethodRoadie.java | 6 import java.util.concurrent.Callable; 60 Callable<Object> callable= new Callable<Object>() { 66 Future<Object> result= service.submit(callable);
|
/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();
|