Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #12604
| From | Knute Johnson <nospam@knutejohnson.com> |
|---|---|
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Strange Socket problem |
| Date | 2012-03-02 15:33 -0800 |
| Organization | A noiseless patient Spider |
| Message-ID | <jirlbi$745$2@dont-email.me> (permalink) |
| References | <jiojsa$5ol$1@dont-email.me> <4f512b27$0$26687$65785112@news.neostrada.pl> |
On 3/2/2012 12:18 PM, x wrote: > Knute Johnson pisze: >> I'm having a problem in some production code that I can't figure out. > > Can you please describe the usage of your class ? > > I'm rather puzzled about having a Thread object inside a Runnable. Your > class makes it is extremely easy to have TWO threads accessing private > fields, this is rarely a good idea. (yes, I have recreated it :-) > > What exactly is the point of the public start() method? I must say it > looks suspicious to me. > > Best regards, > Marcin Jaskolski Another class instantiates this class and starts it. It is never started again because it should not ever stop unless some runtime exception is thrown. It's not a Thread object inside a Runnable, it is a reference to the Thread object. The Runnable is just that. If two of these got started, it still probably wouldn't hurt anything. -- Knute Johnson
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar
Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 11:49 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-01 20:59 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 13:30 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-01 22:54 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:32 -0800
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-03 09:08 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:48 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-01 14:08 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:48 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-02 08:33 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:29 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-03 09:33 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:55 -0800
Re: Strange Socket problem markspace <-@.> - 2012-03-03 20:06 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 21:02 -0800
Re: Strange Socket problem "John B. Matthews" <nospam@nospam.invalid> - 2012-03-05 00:00 -0500
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-05 09:44 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-01 22:15 +0000
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:43 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:01 +0000
Reiteration: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-01 16:51 -0800
Re: Reiteration: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:02 +0000
Re: Strange Socket problem x <x@x.x> - 2012-03-02 21:18 +0100
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-02 15:06 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:38 -0800
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-02 16:00 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 17:18 -0800
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 02:13 +0000
Re: Strange Socket problem Steven Simpson <ss@domain.invalid> - 2012-03-03 08:41 +0000
Re: Strange Socket problem Martin Gregorie <martin@address-in-sig.invalid> - 2012-03-03 18:26 +0000
Re: Strange Socket problem x <x@x.x> - 2012-03-03 11:32 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 17:59 -0800
Re: Strange Socket problem Lew <noone@lewscanon.com> - 2012-03-03 23:21 -0800
Re: Strange Socket problem x <x@x.x> - 2012-03-03 10:59 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:08 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-02 15:33 -0800
Re: Strange Socket problem Paka Small <paka-en@tumia.org> - 2012-03-03 03:32 -0800
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:00 -0800
Re: Strange Socket problem x <x@x.x> - 2012-03-03 12:45 +0100
Re: Strange Socket problem Knute Johnson <nospam@knutejohnson.com> - 2012-03-03 18:02 -0800
csiph-web