logo       

Re: Await...Signal - CatchingIllegalMonitorStateException???: msg#00054

java.jsr.166-concurrency

Subject: Re: Await...Signal - CatchingIllegalMonitorStateException???

Thanks Tim,

I will do take (another :-)) look at the chapter.

-d=avid=-

On 10/24/06, Tim Peierls <tim@xxxxxxxxxxx > wrote:
On 10/24/06, David Holmes <dcholmes@xxxxxxxxxxxxxxx> wrote:
It seems like what you might have here is a use for FutureTask. Your main thread will create the FutureTask and do a timed get() to wait for the result. You pass the FutureTask to your parseThread and it does the actual parsing and upon completion marks the Future task as done.

Also take (another?) look at chapter 6 of JCiP, especially section 6.3, which has an extended example of an activity that waits for another to complete.

--tim

_______________________________________________
Concurrency-interest mailing list
Concurrency-interest@xxxxxxxxxxxxxxxxxxxx
http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest
<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise