From: "Berin Loritsch" <[EMAIL PROTECTED]>

> > From: Nicola Ken Barozzi [mailto:[EMAIL PROTECTED]]
> >
> > Threads?
> > What does start-stop have to do with threads?
> > Startable has no notion of concurrency.
>
> An active component is running all the time in the background.
> Hense, it needs to be start()ed.  What other things require
> start()ing?

*Any* component that does something.
To make it do what it needs to, you start it.

This is why you don't need stop here: it stops by itself.

> > You also assume that stop() has no side-effects, which is
> > wishfull thinking.
>
> Question:
>
> At this stage what can you do about it?  You are getting ready
> to remove the component.  If there is information to be passed
> regarding the stop()ing of something then we should return it
> as information--not throw an exception.
>
> An exception is for exceptionnal occasions--Not for passing
> information.  Using it to pass information is not good, and
> an expensive way to do it.
>
> Just do what you mean.

Ok, then let's say I'm in the army.
I tell my soldier to do standups for as long as I tell him.
START!
then he collapses just before starting.

Is it reasonable that I only know that he failed?

Who is going to heal him?
If I don't get to know it, who does?

I am responsible for *anything* that happens to him, not just of the fact
that he didn't start.

> > > Now, if you start up a thread that only needs to run to completion,
> > > that is another thing entirely.  The concept behind the Startable
> > > interface is an active component that has a thread running in the
> > > background at all times, until it is stop()ed.
> >
> > I just use the common meaning.
> >
> > Configure: On your marks
> >
> > Init: get ready.
> > Start: GO!
> >
> > Suspend: Freeze!
> > Resume: Continue!
> > Suspend: Freeze!
> > Resume: Continue!
> >
> > Stop: Stop!
> > Dispose: Get Off!
> >
> > Now, what does this have to do with threads?
>
> Practically speaking, what types of components do you develop that
> implement Startable and don't involve a background thread?  Check
> out the Connection handling stuff in Cornerstone.  Check out
> Monitor.  Practically speaking, that is.

http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/krysalis/krysalis-monarch/src
/java/org/krysalis/swallowtail/sheets/text/NetBeansEditor.java?rev=HEAD&cont
ent-type=text/vnd.viewcvs-markup


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to