public class UDPTransport extends Object implements DatagramTransport
| Modifier and Type | Field and Description |
|---|---|
protected static int |
MAX_IP_OVERHEAD |
protected static int |
MIN_IP_OVERHEAD |
protected int |
receiveLimit |
protected int |
sendLimit |
protected DatagramSocket |
socket |
protected static int |
UDP_OVERHEAD |
| Constructor and Description |
|---|
UDPTransport(DatagramSocket socket,
int mtu) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
int |
getReceiveLimit() |
int |
getSendLimit() |
int |
receive(byte[] buf,
int off,
int len,
int waitMillis) |
void |
send(byte[] buf,
int off,
int len) |
protected static final int MIN_IP_OVERHEAD
protected static final int MAX_IP_OVERHEAD
protected static final int UDP_OVERHEAD
protected final DatagramSocket socket
protected final int receiveLimit
protected final int sendLimit
public UDPTransport(DatagramSocket socket, int mtu) throws IOException
IOExceptionpublic int getReceiveLimit()
getReceiveLimit in interface DatagramTransportpublic int getSendLimit()
getSendLimit in interface DatagramTransportpublic int receive(byte[] buf,
int off,
int len,
int waitMillis)
throws IOException
receive in interface DatagramTransportIOExceptionpublic void send(byte[] buf,
int off,
int len)
throws IOException
send in interface DatagramTransportIOExceptionpublic void close()
throws IOException
close in interface DatagramTransportIOExceptionCopyright © 2015–2020 The veraPDF Consortium. All rights reserved.