net.codescore.exe
Class GradingThread

java.lang.Object
  extended by java.lang.Thread
      extended by net.codescore.exe.GradingThread
All Implemented Interfaces:
Runnable

public class GradingThread
extends Thread

A thread for listening to a competition manager for submissions to grade

Author:
Adam Cornett

Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
private  CompetitionManager compManager
           
private  DataContext context
           
private  Grader g
           
private  org.apache.commons.logging.Log log
           
private  GradingMode mode
           
private  String status
           
private  AtomicBoolean stopRunning
           
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
GradingThread(CompetitionManager cm)
           
GradingThread(CompetitionManager cm, GradingMode m)
           
 
Method Summary
 String getStatus()
           
 void run()
           
 void stopGrading()
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, 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
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

compManager

private final CompetitionManager compManager

context

private DataContext context

g

private Grader g

log

private org.apache.commons.logging.Log log

status

private volatile String status

mode

private GradingMode mode

stopRunning

private AtomicBoolean stopRunning
Constructor Detail

GradingThread

public GradingThread(CompetitionManager cm)

GradingThread

public GradingThread(CompetitionManager cm,
                     GradingMode m)
Method Detail

getStatus

public String getStatus()

run

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

stopGrading

public void stopGrading()


Copyright 2008 © Adam Cornett, Andrew Conner All Rights Reserved.