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...

How many ways can a thread be used?

Answer Posted / muruganantham

Two ways we can using in Thread. One is Thread class and
another one is Runnable interface. If we are using extends
Thread class means you must override the run() method. We
can create a thread object after that we used start method.
Its only one waiting (wait())thread can be executed
Ex:
Thread t=new Thread();
t.start();

If we are using implement Runnable Interface means you need
not override the run() method. We can passing the parameter
is thread . Its more than one waiting (wait())thread can be
executed.


Hi
This is Muruga. Sorry for gramatical mistake bze that my
level. If any feed back pl reply to my mail id
sunjavamuruga@gmail.com

Is This Answer Correct ?    8 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between the ‘font’ and ‘fontmetrics’ class?

1164


Why a component architecture for the java platform?

1230


Which are the different segments of memory?

1088


What is the difference between system.out ,system.err and system.in?

1110


What is clustering? What are the different algorithms used for clustering?

1083


What is the purpose of the notifyall() method?

1045


If I wanted to use a solarisui for just a jtabbedpane, and the metal ui for everything else, how would I do that?

1077


Why won’t the jvm terminate when I close all the application windows?

1252


Explain about thread synchronization inside a monitor?

2553


Name three component subclasses that support painting?

1090


What is scalable, portability in the view of J2EE?

2533


In inglish: How to convert jar to exe files? Em português: Como converter arquivos .jar para .exe?

2675


Why use POJO when I can use hashmap

2660


What is mdb and what is the special feature of that?

1058


What is meant by method chaining?

1161