Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8478091
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:38:56+00:00 2026-06-10T18:38:56+00:00

I am using Android HoneyComb.I need to execute some tasks parallely and I am

  • 0

I am using Android HoneyComb.I need to execute some tasks parallely and I am using AsyncTask’s
public final AsyncTask executeOnExecutor (Executor exec, Params… params) method.In each separate thread I am computing some values and I need to store then in an ArrayList.I must then sort all the values in the arrayList and then display it in the UI.Now my question is if one of the thread gets completed earlier than the other then will it immediately call the onPostExecute method or onPostExecute method will be called after all the background threads have been completed?MY program implementation depends on what occurs here.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T18:38:58+00:00Added an answer on June 10, 2026 at 6:38 pm

    Even though using onexecuteExecutor will give you parallel execution, postexecute will be called by each asynctask as soon as it’s finished.

    But the asynctask will return itself so that you can know which is which if necessary and track their return order.

    The doc

    As for managing an arraylist from multiple threads, I think you should take a look at Vectors as they are synchronized with a fail-fast behavior. http://docs.oracle.com/javase/1.4.2/docs/api/java/util/Vector.html

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am used to building lists in android using adapters. If I need some
Using Android opengl I need to move an object from point A to point
I currently using android NDK to write some native code in C. I have
I am using Android SDK 1.6 and developing some simple apps. It seems everytime
I'm using Android's SQLite to create a database of levels, based on some files.
I'm using Android 2.2, which comes with a version of STLport. For some reason,
I've been using Android ProgressBar quite a lot. The only thing here is for
I'm using Android and Google Maps at API level 10, and I get latitude
I am using android 2.1 platform.The code I have will display the Name number
I am using Android 2.1 platform, I have 7 contacts in my emulator when

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.