class NioDatagramSessionConfig extends AbstractDatagramSessionConfig
| Modifier and Type | Field and Description |
|---|---|
private java.nio.channels.DatagramChannel |
channel
The associated channel
|
| Constructor and Description |
|---|
NioDatagramSessionConfig(java.nio.channels.DatagramChannel channel)
Creates a new instance of NioDatagramSessionConfig, associated
with the given DatagramChannel.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getReceiveBufferSize()
Get the Socket receive buffer size for this DatagramChannel.
|
int |
getSendBufferSize() |
int |
getTrafficClass()
Get the current Traffic Class for this Socket, if any.
|
boolean |
isBroadcast()
Tells if SO_BROADCAST is enabled.
|
boolean |
isReuseAddress()
Tells if SO_REUSEADDR is enabled.
|
void |
setBroadcast(boolean broadcast) |
void |
setReceiveBufferSize(int receiveBufferSize)
Set the Socket receive buffer size for this DatagramChannel.
|
void |
setReuseAddress(boolean reuseAddress) |
void |
setSendBufferSize(int sendBufferSize) |
void |
setTrafficClass(int trafficClass) |
doSetAll, isBroadcastChanged, isCloseOnPortUnreachable, isReceiveBufferSizeChanged, isReuseAddressChanged, isSendBufferSizeChanged, isTrafficClassChanged, setCloseOnPortUnreachablegetBothIdleTime, getBothIdleTimeInMillis, getIdleTime, getIdleTimeInMillis, getMaxReadBufferSize, getMinReadBufferSize, getReadBufferSize, getReaderIdleTime, getReaderIdleTimeInMillis, getThroughputCalculationInterval, getThroughputCalculationIntervalInMillis, getWriterIdleTime, getWriterIdleTimeInMillis, getWriteTimeout, getWriteTimeoutInMillis, isUseReadOperation, setAll, setBothIdleTime, setIdleTime, setMaxReadBufferSize, setMinReadBufferSize, setReadBufferSize, setReaderIdleTime, setThroughputCalculationInterval, setUseReadOperation, setWriterIdleTime, setWriteTimeoutclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetBothIdleTime, getBothIdleTimeInMillis, getIdleTime, getIdleTimeInMillis, getMaxReadBufferSize, getMinReadBufferSize, getReadBufferSize, getReaderIdleTime, getReaderIdleTimeInMillis, getThroughputCalculationInterval, getThroughputCalculationIntervalInMillis, getWriterIdleTime, getWriterIdleTimeInMillis, getWriteTimeout, getWriteTimeoutInMillis, isUseReadOperation, setAll, setBothIdleTime, setIdleTime, setMaxReadBufferSize, setMinReadBufferSize, setReadBufferSize, setReaderIdleTime, setThroughputCalculationInterval, setUseReadOperation, setWriterIdleTime, setWriteTimeoutNioDatagramSessionConfig(java.nio.channels.DatagramChannel channel)
channel - The associated DatagramChannelpublic int getReceiveBufferSize()
RuntimeIoException - if the socket is closed or if we
had a SocketExceptionDatagramSocket.getReceiveBufferSize()public void setReceiveBufferSize(int receiveBufferSize)
receiveBufferSize - the DatagramChannel receive buffer size.RuntimeIoException - if the socket is closed or if we
had a SocketExceptionDatagramSocket#setReceiveBufferSize()public boolean isBroadcast()
true if SO_BROADCAST is enabledRuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.getBroadcast()public void setBroadcast(boolean broadcast)
DatagramSocket.setBroadcast(boolean)public int getSendBufferSize()
RuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.getSendBufferSize()public void setSendBufferSize(int sendBufferSize)
RuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.setSendBufferSize(int)public boolean isReuseAddress()
true if SO_REUSEADDR is enabledRuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.getReuseAddress()public void setReuseAddress(boolean reuseAddress)
RuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.setReuseAddress(boolean)public int getTrafficClass()
RuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.getTrafficClass()public void setTrafficClass(int trafficClass)
RuntimeIoException - If the socket is closed or if we get an
SocketExceptionDatagramSocket.setTrafficClass(int)