|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.limegroup.gnutella.UDPService
This class handles UDP messaging services. It both sends and receives messages, routing received messages to their appropriate handlers. This also handles issues related to the GUESS proposal, such as making sure that the UDP and TCP port match and sending UDP acks for queries.
UDPReplyHandler
,
MessageRouter
,
QueryUnicaster
Method Summary | |
boolean |
canReceiveSolicited()
Returns whether or not this node is capable of receiving SOLICITED UDP packets. |
boolean |
canReceiveUnsolicited()
Returns whether or not this node is capable of receiving UNSOLICITED UDP packets. |
GUID |
getConnectBackGUID()
|
static UDPService |
instance()
Instance accessor. |
boolean |
isGUESSCapable()
Returns whether or not this node is capable of sending its own GUESS queries. |
boolean |
isListening()
Returns whether or not the UDP socket is listening for incoming messsages. |
void |
run()
Busy loop that accepts incoming messages sent over UDP and dispatches them to their appropriate handlers. |
void |
send(Message msg,
java.net.InetAddress ip,
int port)
Sends the Message via UDP to the port and IP address specified. |
void |
start()
Starts the UDP Service. |
java.lang.String |
toString()
Overrides Object.toString to give more informative information about the class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Method Detail |
public static UDPService instance()
public void start()
public GUID getConnectBackGUID()
public void run()
run
in interface java.lang.Runnable
public void send(Message msg, java.net.InetAddress ip, int port) throws java.io.IOException
msg
- the Message to sendip
- the InetAddress to send toport
- the port to send to
java.io.IOException
public boolean isGUESSCapable()
public boolean canReceiveUnsolicited()
public boolean canReceiveSolicited()
public boolean isListening()
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |