Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

MOnitor inforomation?  RSS feed

 
Anthony Yulo
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HellO!!
Is there a way for us to query what thread has the lock on the monitor and what threads are waiting for the monitor>?
 
Mr. C Lamont Gilbert
Ranch Hand
Posts: 1170
Eclipse IDE Hibernate Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not directly. You can extend the Thread class and add a method that will return the value of the call
Thread.holdsLock(monitor);
as long as you have a reference to the threads in question, this will give you your answer.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!