edu.columbia.coms6901.pingtel.pingim
Class ExpirationThread

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--edu.columbia.coms6901.pingtel.pingim.ExpirationThread
All Implemented Interfaces:
java.lang.Runnable

class ExpirationThread
extends java.lang.Thread

Thread responsible for checking subscriptions to make sure that none have expired. For all expired subscriptions, sends another subscription request. Also, sends SUBSCRIBE messages to buddies who we don't have subscriptions for.

Author:
Micah Sherr

Field Summary
private  PingIM application
          the current PingIM XPression
private  boolean bStop
          stop signal for this thread
 
Fields inherited from class java.lang.Thread
contextClassLoader, daemon, eetop, group, inheritableThreadLocals, inheritedAccessControlContext, MAX_PRIORITY, MIN_PRIORITY, name, NORM_PRIORITY, priority, single_step, stillborn, stopThreadPermission, target, threadInitNumber, threadLocals, threadQ
 
Constructor Summary
ExpirationThread(PingIM application)
          Creates a new instance of ExpirationThread
 
Method Summary
 void run()
          Starts execution of the thread
 void setApplication(PingIM application)
          Re-initializes to the current instance of PingIM
 void stopThread()
          Stops the thread
 
Methods inherited from class java.lang.Thread
, activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, exit, getContextClassLoader, getName, getPriority, getThreadGroup, init, interrupt, interrupt0, interrupted, isAlive, isDaemon, isInterrupted, isInterrupted, join, join, join, nextThreadNum, registerNatives, resume, resume0, setContextClassLoader, setDaemon, setName, setPriority, setPriority0, sleep, sleep, start, stop, stop, stop0, suspend, suspend0, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

application

private PingIM application
the current PingIM XPression

bStop

private boolean bStop
stop signal for this thread
Constructor Detail

ExpirationThread

public ExpirationThread(PingIM application)
Creates a new instance of ExpirationThread
Parameters:
application - the current PingIM Xpression
Method Detail

setApplication

public void setApplication(PingIM application)
Re-initializes to the current instance of PingIM
Parameters:
application - Current instance of PingIM

run

public void run()
Starts execution of the thread
Overrides:
run in class java.lang.Thread

stopThread

public void stopThread()
Stops the thread