List of usage examples for java.lang Thread subclass-usage
From source file TwoThread.java
public class TwoThread extends Thread { public void run() { for (int i = 0; i < 10; i++) { System.out.println("New thread"); } }
From source file ThreadDemo.java
class ThreadDemo extends Thread { public void run() { // returns the thread group to which this thread belongs System.out.println(getThreadGroup()); }
From source file ThreadDemo.java
class ThreadDemo extends Thread { public void run() { System.out.println("Thread priority = " + getPriority()); } }
From source file MyThread.java
class MyThread extends Thread { MyThread() { setDaemon(true); } public void run() {
From source file ThreadDemo.java
class ThreadDemo extends Thread { public void run() { System.out.println("Thread = " + getName()); Thread.UncaughtExceptionHandler handler = Thread.getDefaultUncaughtExceptionHandler(); System.out.println(handler);
From source file ThreadDemo.java
class ThreadDemo extends Thread { public void run() { // returns the name of this Thread. System.out.println("Name = " + getName()); } }
From source file ThreadDemo.java
class ThreadDemo extends Thread { public void run() { System.out.println("Thread = " + getName()); Thread.UncaughtExceptionHandler handler = getUncaughtExceptionHandler();
From source file Message.java
class Message extends Thread { public void run() { System.out.println("Bye."); } }
From source file MyThread.java
class MyThread extends Thread { MyThread() { setDaemon(false); } public void run() {
From source file TwoThreadGetName.java
public class TwoThreadGetName extends Thread { public void run() { for (int i = 0; i < 10; i++) { printMsg(); } }