|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.i2p.client.streaming.MessageHandler
class MessageHandler
Receive raw information from the I2PSession and turn it into Packets, if we can.
I2PSession -> MessageHandler -> PacketHandler -> ConnectionPacketHandler -> MessageInputStream
| Constructor Summary | |
|---|---|
MessageHandler(I2PAppContext ctx,
ConnectionManager mgr)
|
|
| Method Summary | |
|---|---|
void |
addDisconnectListener(I2PSocketManager.DisconnectListener lsnr)
|
void |
disconnected(I2PSession session)
Notify the client that the session has been terminated |
void |
errorOccurred(I2PSession session,
String message,
Throwable error)
Notify the client that some error occurred |
void |
messageAvailable(I2PSession session,
int msgId,
long size)
Instruct the client that the given session has received a message with size # of bytes. |
void |
messageAvailable(I2PSession session,
int msgId,
long size,
int proto,
int fromPort,
int toPort)
Instruct the client that the given session has received a message with size # of bytes. |
void |
removeDisconnectListener(I2PSocketManager.DisconnectListener lsnr)
|
void |
reportAbuse(I2PSession session,
int severity)
Instruct the client that the session specified seems to be under attack and that the client may wish to move its destination to another router. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MessageHandler(I2PAppContext ctx,
ConnectionManager mgr)
| Method Detail |
|---|
public void messageAvailable(I2PSession session,
int msgId,
long size)
messageAvailable in interface I2PSessionListenermessageAvailable in interface I2PSessionMuxedListenersession - session to notifymsgId - message number availablesize - size of the message
public void messageAvailable(I2PSession session,
int msgId,
long size,
int proto,
int fromPort,
int toPort)
messageAvailable in interface I2PSessionMuxedListenersession - session to notifymsgId - message number availablesize - size of the messageproto - 1-254 or 0 for unspecifiedfromPort - 1-65535 or 0 for unspecifiedtoPort - 1-65535 or 0 for unspecified
public void reportAbuse(I2PSession session,
int severity)
reportAbuse in interface I2PSessionListenerreportAbuse in interface I2PSessionMuxedListenersession - session to report abuse toseverity - how bad the abuse ispublic void disconnected(I2PSession session)
disconnected in interface I2PSessionListenerdisconnected in interface I2PSessionMuxedListenersession - that has been terminated
public void errorOccurred(I2PSession session,
String message,
Throwable error)
errorOccurred in interface I2PSessionListenererrorOccurred in interface I2PSessionMuxedListenersession - of the clientmessage - to send to the client about the errorerror - the actual errorpublic void addDisconnectListener(I2PSocketManager.DisconnectListener lsnr)
public void removeDisconnectListener(I2PSocketManager.DisconnectListener lsnr)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||