English 中文(简体)
是否有任何方法在ThreadPoolExecutor找到多少任务?
原标题:is there any method to find how many task remaing in ThreadPoolExecutor?

Im利用ThreadPoolExecutor执行一些任务。 我需要了解ThreadPoolExecutor是否拥有以及如何找到在分配任务中留下多少任务。 是可能的? 取决于回报价值,即重新分派任务,我不知道早期分配的任务有多少。

问题回答

采用ThreadPoolExecutors saskCount()方法,在座执行任务。 这是一种大约值,因为任务 co本的消费是动态的,这一价值可以改变。





相关问题
Silverlight, Updating the UI during processing

I have a simple silverlight multifile upload application, and i want to provide the user with some feedback, right now its only in a test phase and i dont have the webservice. Somehow i cant get the ...

Is reading from an XmlDocument object thread safe?

I was wondering if i could safely read from an XmlDocument object using SelectNodes() and SelectSingleNode() from multiple threads with no problems. MSDN says that they are not guaranteed to be ...

Terminating a thread gracefully not using TerminateThread()

My application creates a thread and that runs in the background all the time. I can only terminate the thread manually, not from within the thread callback function. At the moment I am using ...

热门标签