A thread is represented by a Thread object. You create a Thread object as an anonymous inner class or by subclassing Thread with your own class that implements run(). Here is the anonymous version.
Thread t = new Thread() {
public void run() {
// Do something on another thread
}
}
Here is the subclass version
class MyThread extends Thread() {
public void run() {
// Do something on another thread
}
}
Thread t = new MyThread();
Typically you use an anonymous class for a quick and dirty operation and you create a subclass if the thread has a payload (parameters, result etc.)
Note that these snippets just declare the thread. To actually run the thread you must call start():
t.start();
That's it. When the thread starts, it invokes the run() on the new thread. The main thread and the new thread run in parallel.
More advanced topics like thread synchronisation should really be tackled when you've got the basics worked out.