[3507] in java-interest
Re: java threads.
daemon@ATHENA.MIT.EDU (Michael Lorton)
Tue Nov 14 22:57:40 1995
Date: Tue, 14 Nov 1995 17:34:18 -0800
From: Michael Lorton <mlorton@eshop.com>
To: Cristinij@segaoa.com
Cc: java-interest@java.sun.com
In-Reply-To: <30A8F492@blackhole.segaoa.com> (Cristinij@segaoa.com)
>
> I then make my main function to create the seperate threads(I think).
> This is where I get my errors. I'm not sure what I'm doing wrong.
>
> class testanimate
> {
> public static void main(String args[])
> {
> new animate(8, 10, 10).start();
> new animate(16, 10, 10).start();
> }
> }
>
You don't start() a Runnable; you create a Thread with Runnable as
its argument.
new Thread(new animate(8, 10, 10)).start();
I am not sure about the new class.method() either, but I don't have a
compiler or the spec handy.
M.
-
This message was sent to the java-interest mailing list
Info: send 'help' to java-interest-request@java.sun.com