com.threerings.presents.client
Class BlockingCommunicator.Reader

java.lang.Object
  extended by java.lang.Thread
      extended by com.samskivert.util.LoopingThread
          extended by com.threerings.presents.client.BlockingCommunicator.Reader
All Implemented Interfaces:
Runnable
Enclosing class:
BlockingCommunicator

protected class BlockingCommunicator.Reader
extends LoopingThread

The reader encapsulates the authentication and message reading process. It calls back to the Communicator class to do things, but the general flow of the reader thread is encapsulated in this class.


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
 
Field Summary
 
Fields inherited from class com.samskivert.util.LoopingThread
_running
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
BlockingCommunicator.Reader()
           
 
Method Summary
protected  void connect()
           
protected  void didShutdown()
           
protected  void handleIterateFailure(Exception e)
           
protected  void iterate()
           
protected  void kick()
           
protected  void willStart()
           
 
Methods inherited from class com.samskivert.util.LoopingThread
isRunning, run, shutdown
 
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
 

Constructor Detail

BlockingCommunicator.Reader

public BlockingCommunicator.Reader()
Method Detail

willStart

protected void willStart()
Overrides:
willStart in class LoopingThread

connect

protected void connect()
                throws IOException
Throws:
IOException

iterate

protected void iterate()
Overrides:
iterate in class LoopingThread

handleIterateFailure

protected void handleIterateFailure(Exception e)
Overrides:
handleIterateFailure in class LoopingThread

didShutdown

protected void didShutdown()
Overrides:
didShutdown in class LoopingThread

kick

protected void kick()
Overrides:
kick in class LoopingThread