<<< Thread -- Runnable -- Object | Index | The life cycle of a thread >>> |
Inherit the Thread class
Implement the Runnable interface, then
pass a reference to the Runnable object to the constructor of the Thread class.
This is useful if the thread needs to inherit a class other than the Thread class.
<<< Thread -- Runnable -- Object | Index | The life cycle of a thread >>> |