Define high-level thread states?, JAVA Programming

The state chart diagram given below defines the thread states.

372_Untitled.png

 

 

1.      Runnable - waiting for its turn to be picked for performing by the thread scheduler based on thread priorities.

2.   Running: The processor is actively running the thread code. It performs until it becomes blocked, or voluntarily makes up its turn with that static function Thread.yield(). Because of context switching overhead, yield() could not be used very commonly.

3.   Waiting: A thread is in a blocked state while it waits for some external programming such as file I/O to complete.

4.   Sleeping:   Java   threads   are   forcibly   put   to   suspended (sleep)   with   this overloaded   method: Thread.sleep(milliseconds, nanoseconds), Thread.sleep(milliseconds);

5.   Blocked on I/O: Will go to runnable after I/O condition like reading bytes of data etc modifies.

6.   Blocked on synchronization: Will go to Runnable when a lock is acquired.

7.   Dead: The thread is completed working.

 

Posted Date: 7/25/2012 3:04:51 AM | Location : United States







Related Discussions:- Define high-level thread states?, Assignment Help, Ask Question on Define high-level thread states?, Get Answer, Expert's Help, Define high-level thread states? Discussions

Write discussion on Define high-level thread states?
Your posts are moderated
Related Questions
WHAT IS THE INTRODUCTION OF JAVA APPLET GAMES IN CONNECT4

i am doing java and want projects with solutions to practice more and more

Project Description: Modules of software: 1 - Serial RS232 comm port comunication 2 - NanoHTTPD serving some processed pages 3 - System tray application to indicate sta


Question 1: a) What is the meaning of an object-oriented programming? b) List eight simple types of data in Java c) Explain how objects and classes are closely related.

Write nonrecursive implementations of the min() and floor() methods in BST.java. Make sure to use only one return in your method. Use an insertion sort (discussed in class) to s

In programming, what is a loop? A loop is a programming language statement that permits your code to be repeatedly executed LOOP is a pedagogical programming language designed

What is basic of android?

OOPS with Java 1. Explain any five buzz words in Java. 2. Explain exception classes and also explain common exceptions in java. 3. Explain primitive and abstract data typ

A for loop repeats until a specified condition evaluates to false. For for loop the JavaScript is similar to the Java and C for loops. A for statement looks as:  for ([initial-