public class TUdpServer extends TUdpTransport implements java.lang.AutoCloseable
logger, open, PACKET_DATA_PAYLOAD_MAX_SIZE, sendLock, socket, socketAddress, writeBuffer| Constructor and Description |
|---|
TUdpServer(java.net.SocketAddress socketAddress)
Constructs a UDP server with the given host and port.
|
TUdpServer(java.net.SocketAddress socketAddress,
int timeoutMillis)
Constructs a UDP server with the given host and port.
|
| Modifier and Type | Method and Description |
|---|---|
void |
flush() |
void |
open() |
close, consumeBuffer, getBuffer, getBufferPosition, getBytesRemainingInBuffer, isOpen, read, writepublic TUdpServer(java.net.SocketAddress socketAddress)
throws java.net.SocketException
socketAddress - the SocketAddress for this transportjava.net.SocketException - if the underlying socket cannot be openedpublic TUdpServer(java.net.SocketAddress socketAddress,
int timeoutMillis)
throws java.net.SocketException
socketAddress - the SocketAddress for this transporttimeoutMillis - the timeout in millisecondsjava.net.SocketException - if the underlying socket cannot be openedpublic void open()
throws org.apache.thrift.transport.TTransportException
open in class TUdpTransportorg.apache.thrift.transport.TTransportExceptionpublic void flush()
throws org.apache.thrift.transport.TTransportException
flush in class TUdpTransportorg.apache.thrift.transport.TTransportException