net.i2p.router.transport.udp
class UDPReceiver extends Object
PacketHandler
Constructor and Description |
---|
UDPReceiver(RouterContext ctx,
UDPTransport transport,
DatagramSocket socket,
String name) |
Modifier and Type | Method and Description |
---|---|
UDPPacket |
receiveNext()
Blocking call to retrieve the next inbound packet, or null if we have
shut down.
|
void |
shutdown() |
void |
startup() |
DatagramSocket |
updateListeningPort(DatagramSocket socket,
int newPort)
Replace the old listen port with the new one, returning the old.
|
public UDPReceiver(RouterContext ctx, UDPTransport transport, DatagramSocket socket, String name)
public void startup()
public void shutdown()
public DatagramSocket updateListeningPort(DatagramSocket socket, int newPort)
public UDPPacket receiveNext()