Package org.jppf.nio
Class AbstractSSLHandler
java.lang.Object
org.jppf.nio.AbstractSSLHandler
- All Implemented Interfaces:
SSLHandler
- Direct Known Subclasses:
SSLHandlerImpl
Wrapper for an
SSLEngine and an associated channel.-
Constructor Summary
ConstructorsConstructorDescriptionAbstractSSLHandler(SocketChannel channel, SSLEngine sslEngine) Instantiate this SSLHandler with the specified channel and SSL engine. -
Method Summary
Modifier and TypeMethodDescriptionGet the application receive buffer.Get the application send buffer.longGet the count of bytes read from the channel, including hansdhaking and encrypted data.longGet the count of bytes written to the channel, including hansdhaking and encrypted data.Get the channel receive buffer.Get the channel send buffer.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.jppf.nio.SSLHandler
close, read, write
-
Constructor Details
-
AbstractSSLHandler
Instantiate this SSLHandler with the specified channel and SSL engine.- Parameters:
channel- the channel from which data is read or to which data is written.sslEngine- performs the SSL-related operations before sending data/after receiving data.- Throws:
Exception- if any error occurs.
-
-
Method Details
-
getAppReceiveBuffer
Description copied from interface:SSLHandlerGet the application receive buffer.- Specified by:
getAppReceiveBufferin interfaceSSLHandler- Returns:
- a
ByteBufferinstance.
-
getAppSendBuffer
Description copied from interface:SSLHandlerGet the application send buffer.- Specified by:
getAppSendBufferin interfaceSSLHandler- Returns:
- a
ByteBufferinstance.
-
getNetReceiveBuffer
Description copied from interface:SSLHandlerGet the channel receive buffer.- Specified by:
getNetReceiveBufferin interfaceSSLHandler- Returns:
- a
ByteBufferinstance.
-
getNetSendBuffer
Description copied from interface:SSLHandlerGet the channel send buffer.- Specified by:
getNetSendBufferin interfaceSSLHandler- Returns:
- a
ByteBufferinstance.
-
getChannelReadCount
public long getChannelReadCount()Description copied from interface:SSLHandlerGet the count of bytes read from the channel, including hansdhaking and encrypted data.- Specified by:
getChannelReadCountin interfaceSSLHandler- Returns:
- the byte count as a long value.
-
getChannelWriteCount
public long getChannelWriteCount()Description copied from interface:SSLHandlerGet the count of bytes written to the channel, including hansdhaking and encrypted data.- Specified by:
getChannelWriteCountin interfaceSSLHandler- Returns:
- the byte count as a long value.
-
toString
-
getSslEngine
- Specified by:
getSslEnginein interfaceSSLHandler- Returns:
- the SSLEngine.
-