class PacketQueue extends Object implements SendMessageStatusListener, Closeable
MessageOutputStream -> ConnectionDataReceiver -> Connection -> PacketQueue -> I2PSession
STATUS_CANCELLED
Constructor and Description |
---|
PacketQueue(I2PAppContext context,
SimpleTimer2 timer) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Cannot be restarted.
|
boolean |
enqueue(PacketLocal packet)
Add a new packet to be sent out ASAP.
|
void |
messageStatus(I2PSession session,
long msgId,
int status)
SendMessageStatusListener interface
Tell the client of an update in the send status for a message
previously sent with I2PSession.sendMessage().
|
public PacketQueue(I2PAppContext context, SimpleTimer2 timer)
public void close()
close
in interface Closeable
close
in interface AutoCloseable
public boolean enqueue(PacketLocal packet)
public void messageStatus(I2PSession session, long msgId, int status)
messageStatus
in interface SendMessageStatusListener
session
- session notifyingmsgId
- message number returned from a previous sendMessage() callstatus
- of the message, as defined in MessageStatusMessage and this class.