java.lang
Class Thread

java.lang.Object
  extended by java.lang.Thread
All Implemented Interfaces:
Runnable, NonCopyable

public final class Thread
extends Object
implements Runnable, NonCopyable


Field Summary
static int MAX_PRIORITY
          The maximum priority that a thread can have.
static int MIN_PRIORITY
          The minimum priority that a thread can have.
static int NORM_PRIORITY
          The default priority that is assigned to a thread.
 
Method Summary
static int activeCount()
           
static Thread currentThread()
           
 String getName()
           
 int getPriority()
           
 void interrupt()
           
 boolean isAlive()
           
 void join()
           
 void run()
          This method will be called by whoever wishes to run your class implementing Runnable.
 void setDaemon(boolean setting)
           
 void setPriority(int newPriority)
           
static void sleep(long millis)
           
 void start()
           
 String toString()
           
static void yield()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait
 

Field Detail

MAX_PRIORITY

public static final int MAX_PRIORITY
The maximum priority that a thread can have.

See Also:
Constant Field Values

MIN_PRIORITY

public static final int MIN_PRIORITY
The minimum priority that a thread can have.

See Also:
Constant Field Values

NORM_PRIORITY

public static final int NORM_PRIORITY
The default priority that is assigned to a thread.

See Also:
Constant Field Values
Method Detail

activeCount

public static int activeCount()

currentThread

public static Thread currentThread()

getName

public String getName()

getPriority

public int getPriority()

interrupt

public void interrupt()

isAlive

public boolean isAlive()

join

public void join()

run

public void run()
Description copied from interface: Runnable
This method will be called by whoever wishes to run your class implementing Runnable. Note that there are no restrictions on what you are allowed to do in the run method, except that you cannot throw a checked exception.

Specified by:
run in interface Runnable

setPriority

public void setPriority(int newPriority)

sleep

public static void sleep(long millis)

start

public void start()

toString

public String toString()
Overrides:
toString in class Object

yield

public static void yield()

setDaemon

public void setDaemon(boolean setting)