This week's book giveaway is in the JavaFX forum.
We're giving away four copies of Introducing JavaFX 8 Programming and have Herbert Schildt on-line!
See this thread for details.
The moose likes Threads and Synchronization and the fly likes setDaemon not present in Runnable Interface Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Introducing JavaFX 8 Programming this week in the JavaFX forum!
JavaRanch » Java Forums » Java » Threads and Synchronization
Bookmark "setDaemon not present in Runnable Interface" Watch "setDaemon not present in Runnable Interface" New topic
Author

setDaemon not present in Runnable Interface

Santosh Kumar Nayak
Ranch Hand

Joined: Aug 02, 2011
Posts: 141
Why the setDaemon() is not present when we implement the Runnable Interface.

The method is only present when we extend the Thread class.
Sergey Korytnikov
Greenhorn

Joined: Sep 14, 2013
Posts: 10

Because Runnable has nothing to do with threads, it's just an interface with run() method, which is assumed to be executed by thread.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: setDaemon not present in Runnable Interface
 
It's not a secret anymore!