Mechanism of multithreading in java -
when call #start()
method of thread, calls #run()
method. after invocation of #start()
, control returns #main()
method (or thread created).
why happen? why doesn't control jump #run()
method?
that point of multithreading.
the new thread starts executing code (from run
method) , main 1 continues executing code, code being executed in parallel.
Comments
Post a Comment