app.util
Class CASDeliveryThread

java.lang.Object
  extended by java.lang.Thread
      extended by app.util.CASDeliveryThread
All Implemented Interfaces:
SToC.CASDataReceiver, java.lang.Runnable

public class CASDeliveryThread
extends java.lang.Thread
implements SToC.CASDataReceiver

A thread that provides a delivery mechanism for a sequence of CAS chunks, providing a suitable means for a SToC CAS data generator to deliver the results of an individual SiGML-to-CAS request.


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
CASDeliveryThread(SToCThread.CASDataDelivery cassink, SToCApplet.SToCALogger logger)
           
 
Method Summary
 void postNextCASChunk(java.lang.String caschunk)
          Posts the given CAS data chunk onto this thread's input queue.
 void run()
          This thread's main processing method: takes successive CAS data chunks from the queue and posts them (synchronously) to the thread's receiver.
 void terminateCASSequence()
          Indicates the completion of CAS generation, that is, that all CAS data chunks have now been posted onto this thread's input queue.
 
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
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CASDeliveryThread

public CASDeliveryThread(SToCThread.CASDataDelivery cassink,
                         SToCApplet.SToCALogger logger)
Method Detail

postNextCASChunk

public void postNextCASChunk(java.lang.String caschunk)
Posts the given CAS data chunk onto this thread's input queue.

Specified by:
postNextCASChunk in interface SToC.CASDataReceiver

terminateCASSequence

public void terminateCASSequence()
Indicates the completion of CAS generation, that is, that all CAS data chunks have now been posted onto this thread's input queue.

Specified by:
terminateCASSequence in interface SToC.CASDataReceiver

run

public void run()
This thread's main processing method: takes successive CAS data chunks from the queue and posts them (synchronously) to the thread's receiver.

Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread