Class AprSocketSession.SessionConfigImpl
java.lang.Object
org.apache.mina.core.session.AbstractIoSessionConfig
org.apache.mina.transport.socket.AbstractSocketSessionConfig
org.apache.mina.transport.socket.apr.AprSocketSession.SessionConfigImpl
- All Implemented Interfaces:
IoSessionConfig, SocketSessionConfig
- Enclosing class:
AprSocketSession
The implementation for the
IoSessionConfig related to APR TCP socket.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintintintPlease note that enablingSO_LINGERin Java NIO can result in platform-dependent behavior and unexpected blocking of I/O thread.intbooleanbooleannot supported for the momentbooleanbooleanvoidsetKeepAlive(boolean on) voidsetOobInline(boolean on) not supported for the momentvoidsetReceiveBufferSize(int size) voidsetReuseAddress(boolean on) voidsetSendBufferSize(int size) voidsetSoLinger(int linger) Please note that enablingSO_LINGERin Java NIO can result in platform-dependent behavior and unexpected blocking of I/O thread.voidsetTcpNoDelay(boolean on) voidsetTrafficClass(int tc) Methods inherited from class AbstractSocketSessionConfig
isKeepAliveChanged, isOobInlineChanged, isReceiveBufferSizeChanged, isReuseAddressChanged, isSendBufferSizeChanged, isSoLingerChanged, isTcpNoDelayChanged, isTrafficClassChanged, setAllMethods inherited from class AbstractIoSessionConfig
getBothIdleTime, getBothIdleTimeInMillis, getIdleTime, getIdleTimeInMillis, getMaxReadBufferSize, getMinReadBufferSize, getReadBufferSize, getReaderIdleTime, getReaderIdleTimeInMillis, getThroughputCalculationInterval, getThroughputCalculationIntervalInMillis, getWriterIdleTime, getWriterIdleTimeInMillis, getWriteTimeout, getWriteTimeoutInMillis, isUseReadOperation, setBothIdleTime, setIdleTime, setMaxReadBufferSize, setMinReadBufferSize, setReadBufferSize, setReaderIdleTime, setThroughputCalculationInterval, setUseReadOperation, setWriterIdleTime, setWriteTimeoutMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface IoSessionConfig
getBothIdleTime, getBothIdleTimeInMillis, getIdleTime, getIdleTimeInMillis, getMaxReadBufferSize, getMinReadBufferSize, getReadBufferSize, getReaderIdleTime, getReaderIdleTimeInMillis, getThroughputCalculationInterval, getThroughputCalculationIntervalInMillis, getWriterIdleTime, getWriterIdleTimeInMillis, getWriteTimeout, getWriteTimeoutInMillis, isUseReadOperation, setBothIdleTime, setIdleTime, setMaxReadBufferSize, setMinReadBufferSize, setReadBufferSize, setReaderIdleTime, setThroughputCalculationInterval, setUseReadOperation, setWriterIdleTime, setWriteTimeout
-
Constructor Details
-
SessionConfigImpl
private SessionConfigImpl()
-
-
Method Details
-
isKeepAlive
public boolean isKeepAlive()- Returns:
trueifSO_KEEPALIVEis enabled.- See Also:
-
setKeepAlive
public void setKeepAlive(boolean on) - Parameters:
on- ifSO_KEEPALIVEis to be enabled- See Also:
-
isOobInline
public boolean isOobInline()not supported for the moment- Returns:
trueifSO_OOBINLINEis enabled.- See Also:
-
setOobInline
public void setOobInline(boolean on) not supported for the moment- Parameters:
on- ifSO_OOBINLINEis to be enabled- See Also:
-
isReuseAddress
public boolean isReuseAddress()- Returns:
trueif SO_REUSEADDR is enabled.- See Also:
-
setReuseAddress
public void setReuseAddress(boolean on) - Parameters:
on- Tells if SO_REUSEADDR is enabled or disabled- See Also:
-
getSoLinger
public int getSoLinger()Please note that enablingSO_LINGERin Java NIO can result in platform-dependent behavior and unexpected blocking of I/O thread.- Returns:
- The value for
SO_LINGER - See Also:
-
setSoLinger
public void setSoLinger(int linger) Please note that enablingSO_LINGERin Java NIO can result in platform-dependent behavior and unexpected blocking of I/O thread.- Parameters:
linger- Please specify a negative value to disableSO_LINGER.- See Also:
-
isTcpNoDelay
public boolean isTcpNoDelay()- Returns:
trueifTCP_NODELAYis enabled.- See Also:
-
setTcpNoDelay
public void setTcpNoDelay(boolean on) - Parameters:
on-trueifTCP_NODELAYis to be enabled- See Also:
-
getTrafficClass
public int getTrafficClass()- Returns:
- the traffic class
- See Also:
-
setTrafficClass
public void setTrafficClass(int tc) - Parameters:
tc- The traffic class to set, one ofIPTOS_LOWCOST(0x02)IPTOS_RELIABILITY(0x04),IPTOS_THROUGHPUT(0x08) orIPTOS_LOWDELAY(0x10)- See Also:
-
getSendBufferSize
public int getSendBufferSize()- Returns:
- the size of the send buffer
- See Also:
-
setSendBufferSize
public void setSendBufferSize(int size) - Parameters:
size- The size of the send buffer- See Also:
-
getReceiveBufferSize
public int getReceiveBufferSize()- Returns:
- the size of the receive buffer
- See Also:
-
setReceiveBufferSize
public void setReceiveBufferSize(int size) - Parameters:
size- The size of the receive buffer- See Also:
-