com.sonyericsson.hudson.plugins.gerrit.gerritevents.workers
Class EventThread

java.lang.Object
  extended by java.lang.Thread
      extended by com.sonyericsson.hudson.plugins.gerrit.gerritevents.workers.EventThread
All Implemented Interfaces:
Runnable

public class EventThread
extends Thread

A basic event thread. The idea is to split up as much work as possible to be able to quickly handle the next event from Gerrit

Author:
Robert Sandell <robert.sandell@sonyericsson.com>

Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
EventThread(Coordinator coordinator)
          Constructs an Event thread worker.
EventThread(Coordinator coordinator, String name)
          Constructs an Event thread worker.
 
Method Summary
 void run()
           
 void shutdown()
          Ends this worker's reign and ends the thread.
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EventThread

public EventThread(Coordinator coordinator)
Constructs an Event thread worker.

Parameters:
coordinator - the master.

EventThread

public EventThread(Coordinator coordinator,
                   String name)
Constructs an Event thread worker.

Parameters:
coordinator - the master.
name - the name of the thread.
Method Detail

run

public void run()
Specified by:
run in interface Runnable
Overrides:
run in class Thread

shutdown

public void shutdown()
Ends this worker's reign and ends the thread.



Copyright © 2004-2012 Hudson. All Rights Reserved.