|I have a Masters in computer science. I can answer questions on core J2SE, swing and graphics. Please no questions about JSP or J2ME.|
Those constructors are not useful for non-subclasses. If you don't subclass Thread you should use the Thread(Runnable target) or Thread(Runnable target, String name) constructor. If you subclass Thread
1. Creating a thread allows you to run multiple pieces of code at the same time. This can use multiple processors, or can allow one thread to continue while another one is waiting on a response or resource
I don't see what JLabel, JButton, and JTextField have to do with drawing a line. Unless perhaps you want a bit more interactivity. In any case you will want to create a custom component to draw the
1. It is possible to put any object in a synchronized block. When a thread enters a synchronization block, it is said to have a lock on that object. That lock is released once the block is left.
This is a bit more complex than bouncing off of walls as you need to determine 2 things: 1. Which balls if any are bouncing off each other? 2. What angle do they rebound at? 1. If you have a few balls