Top Description Methods
org.xnio.channels

public Interface SslChannel

extends ConnectedChannel
Known Direct Subinterfaces
org.xnio.channels.ConnectedSslStreamChannel
Known Direct Implementers
org.xnio.ssl.SslConnection, org.xnio.channels.AssembledSslChannel
Imports
java.io.IOException, javax.net.ssl.SSLSession, org.xnio.ChannelListener

A channel which can use SSL/TLS to negotiate a security layer.

Method Summary

Modifier and TypeMethod and Description
public ChannelListener.Setter<? extends SslChannel>
getCloseSetter()

Redeclares org.xnio.channels.ConnectedChannel.getCloseSetter.

Get the setter which can be used to change the close listener for this channel.

public ChannelListener.Setter<? extends SslChannel>

Returns:

the setter
getHandshakeSetter
()

Get the setter which can be used to change the handshake listener for this channel.

public SSLSession

Returns:

the current SSLSession
getSslSession
()

Get the current SSLSession for this channel.

public void
startHandshake()

Start or restart the SSL/TLS handshake.

Inherited from org.xnio.channels.ConnectedChannel:
getPeerAddressgetPeerAddress

Method Detail

getCloseSetterback to summary
public ChannelListener.Setter<? extends SslChannel> getCloseSetter()

Redeclares org.xnio.channels.ConnectedChannel.getCloseSetter.

Doc from org.xnio.channels.ConnectedChannel.getCloseSetter.

Get the setter which can be used to change the close listener for this channel. If the channel is already closed, then the listener will not be called.

Returns:ChannelListener.Setter<? extends SslChannel>

Doc from org.xnio.channels.CloseableChannel.getCloseSetter.

the setter

getHandshakeSetterback to summary
public ChannelListener.Setter<? extends SslChannel> getHandshakeSetter()

Get the setter which can be used to change the handshake listener for this channel.

Returns:ChannelListener.Setter<? extends SslChannel>

the setter

getSslSessionback to summary
public SSLSession getSslSession()

Get the current SSLSession for this channel.

Returns:SSLSession

the current SSLSession

startHandshakeback to summary
public void startHandshake() throws IOException

Start or restart the SSL/TLS handshake. To force a complete SSL/TLS session renegotiation, the current session should be invalidated prior to calling this method. This method is not needed for the initial handshake as sending or receiving over the channel will automatically initiate it.

Exceptions
IOException:
if an I/O error occurs