Bookmark Topic Watch Topic
  • New Topic

How can i get completion status of runnable object which is dispatched to executor class?  RSS feed

 
Mitesh Soni
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Report post to moderator

Thread communication problem.

I have one class say A which periodically cretes runnable object of class B and put it in a queue and then it is dispatched to the executor class for thread execution. lets sat b1 is in execution and at that time new runnable object is triggered and pushed into queue named b2. b2 will be dispatched only when b1 will be completed. now the problem is how i will determine that runnable object which is dispatched to the executor is completed?

what are the ways to determine it? and which is the efficient way?
 
Henry Wong
author
Sheriff
Posts: 23295
125
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Report post to moderator
Duplicate topic

Please do not crosspost. It wastes people time and effort.

http://www.coderanch.com/t/458453/Threads-Synchronization/java/get-completion-status-runnable-object





 
    Bookmark Topic Watch Topic
  • New Topic
Boost this thread!