[To advertise Java(tm) Events here, contact us!]

by example!

New @

  gb  In-house search engine for better results!

  gb  Get updates with the

 Browse Categories 
 Ask a Java Question 
  For Java Tips & Tricks, subscribe to the newsletter!
Search Java Q&A, Links, API's:   adv 

Become a member to observe this category

A thread is a separate flow of execution. Several threads can be run concurrently, at the same time. Theoretically this is possible with multi-cpu machines but the usual context is that a machine has only one CPU. In that case, each thread gets a piece of CPU time allotted and is then preempted to make room for another thread. Threads can be assigned priorities in which case a thread with a high priority will be given more CPU time than a lower-priority thread. Check out the excellent book on Java threads by Doug Lea: Concurrent Programming in Java , Second Edition: Design Principles and Patterns (The Java Series)

Featured Books


      Questions & Answers
      = answered, = unanswered


        What is a thread and how do I create and start one?
        When should I use Runnable over extending the Thread class?
        What threads are executed with a Hello, World application?
        When should I use the synchronized modifier?
        How do I implement a timer thread?
        How do I assign a priority to a thread?
        How do I synchronize threads?
        How do I use wait() and notify()?
        What is a ThreadGroup?
        How do I list all threads that are running?
        What is a daemon thread?
        How do I suspend a thread for a certain time?
        How do I check the state of a thread?
        How do I create a thread pool?
        Why is Thread.stop() deprecated?
        So, how do I stop a thread then?
        How do I pause a thread?
        How do I interrupt a thread?
        What is the AWT Thread and when is it started?
        What is the event dispatch thread?
        What does it mean for an object or method to be thread-safe?
        How can I restart a thread that has stopped execution?
        What is InterruptedException and how do I use it?
        What is a deadlock? What is starvation?
        Which thread is notified when notify() is invoked?
        How much slower is a synchronized method?
        How do I wait for a thread to finish?
        What does Thread-safe mean?
        When is a thread object garbage collected?
        How do I pass the output of one thread as the input to another (using Readers/Writers)?
        How do I pass the output of one thread as the input to another (using InputStream/OutputStream)?
        What is a ThreadLocal variable?

      Further Information (sorted alphabetically)





      Related Books:

      Terms of Service | Privacy Policy | Contact

      Copyright © 2000-2003 - All Rights Reserved 
      Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. is independent of Sun Microsystems, Inc. All other trademarks are the sole property of their respective owners.