A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Programmer Certification (SCJP/OCPJP)
threads - start() & run()
Joined: Oct 28, 2000
Oct 28, 2000 03:04:00
What is the name of the method used to schedule a thread for execution and that for executing a thread?
feel it is start() and run() simultaneously.
Joined: Oct 18, 2000
Oct 28, 2000 03:18:00
You are right.
Its run() - for executing a therad. &
start() - for scheduling a thread.
Joined: Mar 17, 2000
Oct 30, 2000 06:00:00
PROPER NAMES ARE NOW REQUIRED!!
for more details.
Javaranch appreciates your cooperation to comply with the official naming policy.
Open Group Certified Distinguished IT Architect. Open Group Certified Master IT Architect. Sun Certified Architect (SCEA).
Joined: Nov 07, 2000
Nov 07, 2000 08:41:00
you can not execute a thread. Calling start will put it in runnable state but calling 'run' will just use that method in the current thread. You can think of the 'thready' code existing in 'start' only.
subject: threads - start() & run()
can anybody tel me wat exactly Thread.start() will do?
Why start() method
General threading problem
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015