what are depricated methods in threads and explain the
lifecycle methods

Answers were Sorted based on User's Feedback



what are depricated methods in threads and explain the lifecycle methods..

Answer / dara

There are two deprecated methods in threads.
1.resume
2.suspend.
life cycle of methods of thread.
1.ready to run(start() method)
2.run(run() method)
3.suspend(wait() or sleep() method)
4.resume(notify() or notifyall() method)
5.death.

Is This Answer Correct ?    8 Yes 2 No

what are depricated methods in threads and explain the lifecycle methods..

Answer / prerana

The depricated methods in threads are
1. stop
2. suspend
3. Resume

Life cycle of thread
A thread can be only in one of the five states
1. New (Not alive)
2. Runnable (alive)
3. Running
4. Waiting/Blocking/Sleeping
5. Dead

Is This Answer Correct ?    5 Yes 1 No

what are depricated methods in threads and explain the lifecycle methods..

Answer / ravikiran

stop(),suspend(),resume()
start()---will start a new thread of execution nd thread
will be in runnable state
run()-----will run the current thread of execution

Is This Answer Correct ?    3 Yes 2 No

what are depricated methods in threads and explain the lifecycle methods..

Answer / ejp

Good grief. Doesn't anybody read the Javadoc? There are
*six* deprecated methods in java.lang.Thread.

Is This Answer Correct ?    2 Yes 1 No

what are depricated methods in threads and explain the lifecycle methods..

Answer / ravichandra

In threads two ways to create threads.1.by extends the
class
2.implements runnable interface

in threads the following methods are called life cycle
methods

1.start 2.run 3.dead

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More Core Java Interview Questions

What is the basic concepts of OOPS?

1 Answers   BlackRock,


What is the main advantage of passing argument by reference?

1 Answers  


What are register variables what are the advantages?

1 Answers  


Can we have more than one package statement in source file ?

1 Answers  


What's the default access specifier for variables and methods of a class?

1 Answers  


How do you format in java?

1 Answers  


We can write any Java Logics in our JSP. Then why we are using servlets(Controller Layer) to interact with the DAO ?

6 Answers   TCS,


System.out.println(101/14) what is the output? a)6 b)14 c)7.14 d)0

8 Answers   Accenture,


Is java still relevant?

1 Answers  


difference between arraylist and linkedlist otherthan performance

2 Answers   L&T,


What is the default size of set in java?

1 Answers  


Describe the various concepts related to object oriented programming (oop).

1 Answers  


Categories