ccd
Class AsynchronousCcdDriver.ExposureThread

java.lang.Object
  extended by java.lang.Thread
      extended by util.ExitThread
          extended by ccd.AsynchronousCcdDriver.ExposureThread
All Implemented Interfaces:
Runnable
Enclosing class:
AsynchronousCcdDriver<T>

protected class AsynchronousCcdDriver.ExposureThread
extends ExitThread

An exposure thread start an exposure in its run method by calling the appropriate driver method. It then simly waits the exposure time plus the readout time, then starts querying until AsynchronousCcdDriver.isExposing() returns false. Before exiting, all waiters are notified.


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
private  long cycle
          The wait time for exposure finished queries.
private  AbstractCcdDriver.Exposure how
          The flag to the method to call.
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
protected AsynchronousCcdDriver.ExposureThread(AbstractCcdDriver.Exposure flag, long querycycle)
          Constructs a new exposure thread without starting it.
 
Method Summary
protected  boolean runner()
          Does the expoure by calling the appropriate outer class method.
 
Methods inherited from class util.ExitThread
getEnterTime, getError, getExecutionTime, getExitTime, run, wasSuccess
 
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
 

Field Detail

how

private AbstractCcdDriver.Exposure how
The flag to the method to call.


cycle

private long cycle
The wait time for exposure finished queries.

Constructor Detail

AsynchronousCcdDriver.ExposureThread

protected AsynchronousCcdDriver.ExposureThread(AbstractCcdDriver.Exposure flag,
                                               long querycycle)
Constructs a new exposure thread without starting it. The argument specifies the action undertaken in the run method.

Parameters:
flag - Either #EXPOSURE or #DARKEXPOSURE
Method Detail

runner

protected boolean runner()
                  throws Exception
Does the expoure by calling the appropriate outer class method. If an IOException happens during the exposure, the thread is interrupted.

Specified by:
runner in class ExitThread
Throws:
Exception