title: new Thread(Runnable runnableObj) Vs. extends Thread
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/541487/java-implements-runnable-vs-extends-thread">Java: &ldquo;implements Runnable&rdquo; vs. &ldquo;extends Thread&rdquo;</a>  </p>
  </blockquote>
  
  
  
  <p>I'm just wondering is there some subtle difference between creating your own custom object that extends Thread and creating a thread using the Thread(Runnable) constructor?</p>
  
  <p>I have some code that works fine when I use classes that extend Thread, but if I try to use logic that creates Threads by using the Thread(Runnable) constructor the new threads do not seem to work properly - I can't detect that they are alive in the same way as when I use the custom sub-classes I made and they do not seem to end, ever.</p>
  
  <p>In my code I'm just spawning a few threads then searching through my list of threads to find one that is alive and joining with it until it dies. Then I once again search for a thread in the list that is alive and join to it.. this continues until all threads die. </p>
  
  <p>Thanks for reading.</p>