Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

To make an object to begin executing as a separate thread,
what method is used?

Answer Posted / anonymous

Public void run() ---- method should be used.

myClass mc= new myClass();
Thread t1= new Thread(mc);

thatClass tc= new thatClass();
Thread t2= new Thread(tc);

t1.run();
t2.run();



Two Objects
Two Threads

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Have you used threads in Servelet?

2509


How can I scroll through list of pages like the search results in google?

969


hi friends, i have done my BE(CSE)at 2011 then i have joined one company before they asked me 50k so i paid but now they telling no project here so we r going to close like that so now i need any job i have good knowledge in core java and j2ee(jsp,servlet,jdbc) so if u know any job pl help me

2221


Is the ternary operator written x : y ? Z or x ? Y : z ?

1114


what is Activation Instantinator?

2451


Can you give me a simple example of using the requiredif validator rule?

1127


What is Remote Server?

2202


Should synchronization primitives be used on bean methods?

1069


Can I run seam outside of jboss as?

1078


What is ioc concept?

1207


How messaging services are done, before release of JMS?

2145


What is table mutation and how do you avoid it?

2470


What you mean by COM and DCOM?

1065


How are the elements of a cardlayout organized?

1085


Are we allowed to change the transaction isolation property in middle of a transaction?

1030