Java tutorial
class ThreadDemo extends Thread { public void run() { System.out.println("Thread = " + getName()); Thread.UncaughtExceptionHandler handler = getUncaughtExceptionHandler(); System.out.println(handler); } } public class Main { public static void main(String[] args) { ThreadDemo t = new ThreadDemo(); t.start(); } }