what is daemon thread and which method is used to create the daemon thread? : Java thread



what is daemon thread and which method is used to create the daemon thread? : Java thread..

Answer / Brijesh Pal Singh

A Daemon thread is a background thread in Java that runs as part of a program but does not prevent the program from terminating. These threads are useful for performing tasks like garbage collection, disk I/O, and network connections. The setDaemon(boolean) method is used to create a daemon thread by setting the thread's daemon status to true.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

Explain OOPs concept.

1 Answers   Syntel, Visa,


Hai all I want to print given array in reverse order Ex: int a[]={1,2,3,4,5};display this array in reverse order.

4 Answers  


What is arraylist class in java?

1 Answers  


Tell me a few examples of final classes defined in Java API?

1 Answers   DELL,


what is deadlock? : Java thread

1 Answers  


What is a map? What are the implementations of map?

1 Answers  


what is the constructor and how many types of constructors are used in java?

1 Answers  


what is difference between abstract factory and factory design patterns?

0 Answers  


what is the reason behind non static method cannot be referenced from a static Context?

2 Answers  


What is ph and buffers?

1 Answers  


How do you use equal in java?

1 Answers  


How can you say HashMap is syncronized?

14 Answers   Arete, IBM,


Categories