Searched defs:task (Results 1 - 23 of 23) sorted by relevance

/packages/apps/Dialer/src/com/android/dialer/util/
H A DAsyncTaskExecutor.java43 * The identifier supplied is any Object that can be used to identify the task later. Most
45 * accepted, though of course this won't help in identifying the task later.
47 <T> AsyncTask<T, ?, ?> submit(Object identifier, AsyncTask<T, ?, ?> task, T... params); argument
H A DAsyncTaskExecutors.java94 public <T> AsyncTask<T, ?, ?> submit(Object identifer, AsyncTask<T, ?, ?> task, argument
97 return task.executeOnExecutor(mExecutor, params);
/packages/apps/Gallery2/gallerycommon/src/com/android/gallery3d/common/
H A DAsyncTaskUtil.java49 public static <Param> void executeInParallel(AsyncTask<Param, ?, ?> task, Param... params) { argument
51 task.execute(params);
54 sMethodExecuteOnExecutor.invoke(task, sExecutor, params);
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/util/
H A DNamedTaskExecutor.java25 * Schedules a task for execution. Implementations should not throw
26 * {@link java.util.concurrent.RejectedExecutionException} if the task
29 void execute(NamedTask task); argument
H A DPerNameExecutor.java23 * Uses a separate executor for each task name.
51 public synchronized void execute(NamedTask task) { argument
55 String name = task.getName();
61 executor.execute(task);
H A DBatchingNamedTaskExecutor.java48 public void execute(NamedTask task) { argument
50 if (DBG) Log.d(TAG, "Queuing " + task);
51 mQueuedTasks.add(task);
55 private void dispatch(NamedTask task) { argument
56 if (DBG) Log.d(TAG, "Dispatching " + task);
57 mExecutor.execute(task);
74 for (NamedTask task : batch) {
75 dispatch(task);
H A DSingleThreadNamedTaskExecutor.java56 public void execute(NamedTask task) { argument
60 mQueue.add(task);
76 NamedTask task;
78 task = mQueue.take();
82 currentThread.setName(threadName + " " + task.getName());
84 if (DBG) Log.d(TAG, "Running task " + task.getName());
85 task.run();
86 if (DBG) Log.d(TAG, "Task " + task.getName() + " complete");
88 Log.e(TAG, "Task " + task
[all...]
/packages/apps/QuickSearchBox/tests/src/com/android/quicksearchbox/util/
H A DMockExecutor.java23 * A simple executor that maintains a queue and executes one task synchronously every
33 public void execute(Runnable task) { argument
35 mQueue.addLast(task);
H A DMockNamedTaskExecutor.java23 * A simple executor that maintains a queue and executes one task synchronously every
31 public void execute(NamedTask task) { argument
32 mExecutor.execute(task);
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/pipeline/
H A DProcessingTaskController.java42 ProcessingTask task = mTasks.get(msg.what);
43 if (task != null) {
45 task.onResult((ProcessingTask.Result) msg.obj);
47 task.onUpdate((ProcessingTask.Update) msg.obj);
57 ProcessingTask task = mTasks.get(msg.what);
58 if (task != null) {
59 task.processRequest((ProcessingTask.Request) msg.obj);
89 public void add(ProcessingTask task) { argument
90 task.added(this);
91 mTasks.put(task
[all...]
/packages/apps/UnifiedEmail/src/com/android/bitmap/
H A DContiguousFIFOAggregator.java30 * An implementation of a task aggregator that executes tasks in the order that they are expected
33 * The task will be scheduled to run when its corresponding key becomes the first expected key
36 * If on {@link #execute(Object, Runnable)} the key is not expected, the task will be executed
43 * <li>Execute task <b>2</b> for key <b>B</b>. The first expected key is <b>A</b>,
44 * which has no task associated with it, so we store task <b>2</b>. </li>
45 * <li>Execute task <b>4</b> for key <b>Z</b>. We store task <b>4</b>. </li>
46 * <li>Execute task <b>1</b> for key <b>A</b>. We run task <
162 execute(final T key, final Runnable task) argument
292 Runnable task; field in class:ContiguousFIFOAggregator.Value
294 Value(final Callback<T> callback, final Runnable task) argument
[all...]
/packages/apps/UnifiedEmail/src/com/android/mail/ui/
H A DThumbnailLoadTask.java52 ThumbnailLoadTask task, final AttachmentBitmapHolder holder,
71 // cancel/dispose any existing task and start a new one
72 if (task != null) {
73 task.cancel(true);
76 task = new ThumbnailLoadTask(
78 task.execute(thumbnailUri, contentUri);
51 setupThumbnailPreview( ThumbnailLoadTask task, final AttachmentBitmapHolder holder, final Attachment attachment, final Attachment prevAttachment) argument
/packages/apps/Dialer/tests/src/com/android/dialer/util/
H A DFakeAsyncTaskExecutor.java68 /** Encapsulates an async task with the params and identifier it was submitted with. */
125 AsyncTask<T, ?, ?> task, T... params) {
130 Assert.assertNotNull("Already had a valid task.\n"
132 + "onPreExecute() method of another task being submitted?\n"
133 + "Sorry! Not that's not supported.", task);
134 mNextTask = task;
136 return task.executeOnExecutor(this, params);
141 public <T> AsyncTask<T, ?, ?> submit(Object identifier, AsyncTask<T, ?, ?> task, T... params) { argument
143 return mBlockingExecutor.submit(identifier, task, params);
147 * Runs a single task matchin
124 submit(Object identifier, AsyncTask<T, ?, ?> task, T... params) argument
[all...]
/packages/apps/Email/emailcommon/src/com/android/emailcommon/service/
H A DServiceProxy.java34 * connecting to the service, running a task supplied by the subclass when the connection is ready,
83 * This function is called after the proxy connects to the service but before it runs its task.
118 // Each ServiceProxy handles just one task, so we unbind after we're
159 protected boolean setTask(ProxyTask task, String name) throws IllegalStateException { argument
165 mTask = task;
168 LogUtils.v(mTag, "Bind requested for task " + mName);
175 * {@link #setTask}. This will wait until the task completes, up to the timeout (which can be
193 LogUtils.v(mTag, "Waiting for task " + mName + " to complete...");
/packages/apps/Email/tests/src/com/android/email/
H A DThrottleTest.java183 public void schedule(TimerTask task, long delay) { argument
185 task.run();
189 e.mTask = task;
/packages/apps/Email/emailcommon/src/com/android/emailcommon/utility/
H A DEmailAsyncTask.java52 private void add(EmailAsyncTask<?, ?, ?> task) { argument
54 mTasks.add(task);
58 private void remove(EmailAsyncTask<?, ?, ?> task) { argument
60 mTasks.remove(task);
69 for (EmailAsyncTask<?, ?, ?> task : mTasks) {
70 task.cancel(true);
85 for (EmailAsyncTask<?, ?, ?> task : mTasks) {
86 if ((task != current) && task.getClass().equals(clazz)) {
87 task
101 containsTaskForTest(EmailAsyncTask<?, ?, ?> task) argument
[all...]
H A DUtility.java437 public static void cancelTaskInterrupt(AsyncTask<?, ?, ?> task) { argument
438 cancelTask(task, true);
444 public static void cancelTaskInterrupt(EmailAsyncTask<?, ?, ?> task) { argument
445 if (task != null) {
446 task.cancel(true);
454 * task should be interrupted; otherwise, in-progress tasks are allowed
457 public static void cancelTask(AsyncTask<?, ?, ?> task, boolean mayInterruptIfRunning) { argument
458 if (task != null && task.getStatus() != AsyncTask.Status.FINISHED) {
459 task
[all...]
/packages/providers/ContactsProvider/tests/src/com/android/providers/contacts/
H A DSynchronousContactsProvider2.java125 protected void scheduleBackgroundTask(int task) { argument
126 performBackgroundTask(task, null);
130 protected void scheduleBackgroundTask(int task, Object arg) { argument
131 performBackgroundTask(task, arg);
/packages/apps/Launcher2/src/com/android/launcher2/
H A DAppsCustomizePagedView.java63 * A simple callback interface which also provides the results of the task.
66 void run(AppsCustomizeAsyncTask task, AsyncTaskPageData data); argument
111 * A generic template for an async task used in AppsCustomize.
139 // The page that this async task is associated with
938 AppsCustomizeAsyncTask task = (AppsCustomizeAsyncTask) iter.next();
939 task.cancel(false);
941 mDirtyPageContent.set(task.page, true);
944 View v = getPageAt(task.page);
968 AppsCustomizeAsyncTask task = (AppsCustomizeAsyncTask) iter.next();
969 int pageIndex = task
1276 loadWidgetPreviewsInBackground(AppsCustomizeAsyncTask task, AsyncTaskPageData data) argument
[all...]
H A DLauncherModel.java896 // If there is already a loader task running, tell it to stop.
897 // returns true if isLaunching() was true on the old task
1990 void enqueuePackageUpdated(PackageUpdatedTask task) { argument
1991 sWorker.post(task);
/packages/apps/Launcher3/src/com/android/launcher3/
H A DAppsCustomizePagedView.java60 * A simple callback interface which also provides the results of the task.
63 void run(AppsCustomizeAsyncTask task, AsyncTaskPageData data); argument
108 * A generic template for an async task used in AppsCustomize.
136 // The page that this async task is associated with
922 AppsCustomizeAsyncTask task = (AppsCustomizeAsyncTask) iter.next();
923 task.cancel(false);
925 mDirtyPageContent.set(task.page, true);
928 View v = getPageAt(task.page);
956 AppsCustomizeAsyncTask task = (AppsCustomizeAsyncTask) iter.next();
957 int pageIndex = task
1242 loadWidgetPreviewsInBackground(AppsCustomizeAsyncTask task, AsyncTaskPageData data) argument
[all...]
H A DLauncherModel.java1156 // If there is already a loader task running, tell it to stop.
1157 // returns true if isLaunching() was true on the old task
2445 void enqueuePackageUpdated(PackageUpdatedTask task) { argument
2446 sWorker.post(task);
/packages/providers/ContactsProvider/src/com/android/providers/contacts/
H A DContactsProvider2.java1569 protected void scheduleBackgroundTask(int task) { argument
1570 mBackgroundHandler.sendEmptyMessage(task);
1573 protected void scheduleBackgroundTask(int task, Object arg) { argument
1574 mBackgroundHandler.sendMessage(mBackgroundHandler.obtainMessage(task, arg));
1577 protected void performBackgroundTask(int task, Object arg) { argument
1580 switch (task) {
1707 * If not, changes the database locale to the current locale using an asynchronous task.
4883 // (But make sure it's not scheduled yet. We schedule this task in initialize()
7881 * Async task that monitors the given file descriptor (the read end of a pipe) for

Completed in 2739 milliseconds