🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #14460

Re: Java Multithreading

#14460
From: Steve Horsley
Date: Wed, 01 Sep 1999 00:00
31 lines
1438 bytes
How about creating an interface, maybe ThreadFinishedNotifiable that
goes someting like:

interface ThreadFinishedNotifiable {
    public void threadFinishedNotify();
}

Then have you main class (or an inner class of it) implement this
interface, and give the refernece to the thread when it creates it
(as a ThreadFinishedNotifiable object).

Then when the thread has finished, it can call threadFinishedNotify()
just before exiting.

Just a thought.
Steve

//----------------------------
Kevin D wrote:
> 
> I need to be able to catch when a thread has finished executing.
> 
> I have a frame which starts two threads, then control returns to the frame.
> These threads move/message data from one database to another.
> 
> From within the frame how can I capture the fact that a thread has died,
> most likely due to an error.
> 
> Thanks Much
> 
> KD
Technical Details
Message-ID: <37CCF076.ACAC4834@cwcom.co.uk>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <7q49s5$p6m12@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,513bff9c58505db2
X-Google-Attributes: gidf74b3,public
From: Steve Horsley <steve.horsley@cwcom.co.uk>
Subject: Re: Java Multithreading
Date: 1999/09/01
Message-ID: <37CCF076.ACAC4834@cwcom.co.uk>
X-Deja-AN: 519664430
Content-Transfer-Encoding: 7bit
References: <7q49s5$p6m12@forums.borland.com>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Cable & Wireless Communications
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.language