${header}

meteor.util
Class MeteorMessageReceiver

java.lang.Object
  extended byjava.lang.Thread
      extended bymeteor.util.MeteorMessageReceiver
All Implemented Interfaces:
net.jxta.resolver.QueryHandler, java.lang.Runnable

public class MeteorMessageReceiver
extends java.lang.Thread
implements net.jxta.resolver.QueryHandler

The Receiver Thread enqueues every received messages and runs in a loop by notifying the messageHandler of new messages Originally the run() method was in the MessageHandler and should be considered moving back there if any problems are encountered.

Author:
Vincent Matossian January 2004

Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
MeteorMessageReceiver()
           
MeteorMessageReceiver(MessageHandler mh, MeteorMessageQueue mq)
           
 
Method Summary
 int processQuery(net.jxta.protocol.ResolverQueryMsg query)
           
 void processResponse(net.jxta.protocol.ResolverResponseMsg response)
           
 void run()
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, 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

MeteorMessageReceiver

public MeteorMessageReceiver()

MeteorMessageReceiver

public MeteorMessageReceiver(MessageHandler mh,
                             MeteorMessageQueue mq)
Method Detail

processQuery

public int processQuery(net.jxta.protocol.ResolverQueryMsg query)
Specified by:
processQuery in interface net.jxta.resolver.QueryHandler

processResponse

public void processResponse(net.jxta.protocol.ResolverResponseMsg response)
Specified by:
processResponse in interface net.jxta.resolver.QueryHandler

run

public void run()
Specified by:
run in interface java.lang.Runnable

${header}