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

Can you explain the Java thread lifecycle?

Answer Posted / nashiinformaticssolutions

In Java, a thread can exist in any of the following states. The states are as follows:

New: When a new thread is first created, it is always in the new state. For a thread in the new state, the function hasn't begun to execute because it hasn't been performed yet.

Active: When a thread invokes the start() method, it moves from the new state to the active state. The active state contains both the running state and the runnable state.

Blocked or Waiting: When a thread is not active for a period of time (but not forever), it is either in the blocked state or the waiting state.

Timed waiting is what happens when we apply the sleep() technique to a certain thread.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to sort list of list in java?

1031


What environment variables do I need to set on my machine in order to be able to run java programs?

960


What is __ init __ functions?

1036


What is the difference between double and float variables in java?

1081


What is the base class of all exception classes?

1019


What do you know about the garbate collector?

977


Hi friends am new to java. I read jar file means collection of java files. For executing struts application what are the necessary jar files. " struts.jar " file contains what. can u explain

1863


What is object class in java?

868


What is a predicate method?

957


What is super keyword explain with example?

1203


Is vector ordered in java?

956


Name four container classes.

928


what are the disadvantages of indexes in oracle?

2439


Can you inherit from an abstract class java?

935


Can a constructor be private and how are this() and super() method used with constructor?

936