List of usage examples for java.lang Runnable interface-usage
From source file DaemonThread.java
public class DaemonThread implements Runnable { public void run() { System.out.println("entering run()"); try { System.out.println("in run(): currentThread() is" + Thread.currentThread());
From source file NewThread.java
class NewThread implements Runnable { Thread t; NewThread() { t = new Thread(this, "Demo Thread"); System.out.println("Child thread: " + t);
From source file caller.java
class caller implements Runnable { String msg; public caller(String s) { msg = s; new Thread(this).start();
From source file NewThread.java
class NewThread implements Runnable { String name; // name of thread Thread t; NewThread(String threadname) {
From source file MyThread.java
class MyThread implements Runnable { int count; MyThread() { count = 0; }
From source file PiInterrupt.java
public class PiInterrupt extends Object implements Runnable { private double latestPiEstimate; public void run() { try { System.out.println("for comparison, Math.PI=" + Math.PI);
From source file AlternateStop.java
public class AlternateStop extends Object implements Runnable { private volatile boolean stopRequested; private Thread runThread; public void run() {
From source file Main.java
public class Main implements Runnable { static class OverrideExceptionHandler implements Thread.UncaughtExceptionHandler { public void uncaughtException(Thread t, Throwable e) { alertAdministrator(e); }
From source file SelfRunThreadTemplate.java
public class SelfRunThreadTemplate extends Object implements Runnable { private Thread internalThread; private volatile boolean noStopRequested; public SelfRunThreadTemplate() { // add your code here ...
From source file MainClass.java
public class MainClass implements Runnable { static class OverrideThreadGroup extends ThreadGroup { public OverrideThreadGroup() { super("Administrator Alert Group"); }