| Modifier and Type | Field and Description |
|---|---|
protected InetAddress |
remoteHost |
protected int |
remotePort |
protected DatagramSocket |
sock |
| Constructor and Description |
|---|
UDPSink(InetAddress host,
int port) |
| Modifier and Type | Method and Description |
|---|---|
int |
getPort() |
DatagramSocket |
getSocket()
to pass to UDPSource constructor
|
void |
send(Destination src,
byte[] data) |
void |
stop() |
protected final DatagramSocket sock
protected final InetAddress remoteHost
protected final int remotePort
public UDPSink(InetAddress host, int port)
IllegalArgumentException - on DatagramSocket IOExceptionpublic void send(Destination src, byte[] data)
send in interface Sinksrc - ignoredRuntimeException - on DatagramSocket IOExceptionpublic int getPort()
public DatagramSocket getSocket()
public void stop()