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

  • Home
  • SEARCH
  • 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 854699
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T07:57:58+00:00 2026-05-15T07:57:58+00:00

Thread class has run method to implement the business logic that could be executed

  • 0

Thread class has run method to implement the business logic that could be executed in parallel.But I want implement different business logics in a single run method and to run simultaneously.How to get this feature.

thanks

  • 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-05-15T07:57:59+00:00Added an answer on May 15, 2026 at 7:57 am

    I think that the best course of action would be to have two separate threads.

    You can (and probably should) write a new class that implements Runnable and inside it place your logic.
    If there are common activities between the two business logics that you have to implement, you can use this class as a base class for the two “Runnables”.
    Each Runnable should be spawned in a separate thread.

    You can find very good reasoning for Thread vs. Runnable on this post:
    "implements Runnable" vs. "extends Thread"

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

Sidebar

Related Questions

I have a class (NamedPipeManager) which has a thread (PipeThread) that waits for a
I have already one thread that has to do following work: public class DetectionHandler
I have a DirectoryMonitor class which works on another thread. It has the following
What is the use of Thread.BeginThreadAffinity() method in Thread class ? It will be
I have come across many ad hoc implementations of thread class in C++, but
I have a custom thread pool class, that creates some threads that each wait
I'm developing a thread safe class that I'll use as cache, it should work
So I have a test case that I want to make into a thread.
In my activity class i want to perform a series of long calculations that
For manipulating a database I've created a class DBAdapter() that extends SQLiteHelper...this class has

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.