Top Fields Constructors Methods
org.glassfish.grizzly.http2

pack-priv Class AlpnClientNegotiatorImpl

extends AlpnNegotiatorBase
implements AlpnClientNegotiator
Class Inheritance
All Implemented Interfaces
org.glassfish.grizzly.npn.AlpnClientNegotiator
Imports
java.util.Arrays, java.util.logging.Level, .Logger, javax.net.ssl.SSLEngine, org.glassfish.grizzly.Connection, .Grizzly, org.glassfish.grizzly.npn.AlpnClientNegotiator

Field Summary

Modifier and TypeField and Description
private final Http2ClientFilter
private static final Logger
Inherited from org.glassfish.grizzly.http2.AlpnNegotiatorBase:
HTTP11HTTP2SUPPORTED_PROTOCOLS

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public String[]
getProtocols(final SSLEngine sslEngine)

Implements org.glassfish.grizzly.npn.AlpnClientNegotiator.getProtocols.

Return the supported protocols.

public void
protocolSelected(final SSLEngine sslEngine, final String selectedProtocol)

Implements org.glassfish.grizzly.npn.AlpnClientNegotiator.protocolSelected.

Inform the implementor which of the protocols returned from getProtocols(javax.net.ssl.SSLEngine) was actually selected.

Field Detail

filterback to summary
private final Http2ClientFilter filter
LOGGERback to summary
private static final Logger LOGGER

Constructor Detail

AlpnClientNegotiatorImplback to summary
public AlpnClientNegotiatorImpl(final Http2ClientFilter filter)

Method Detail

getProtocolsback to summary
public String[] getProtocols(final SSLEngine sslEngine)

Implements org.glassfish.grizzly.npn.AlpnClientNegotiator.getProtocols.

Doc from org.glassfish.grizzly.npn.AlpnClientNegotiator.getProtocols.

Return the supported protocols. For HTTP/2 this should be the two literal strings "h2" and "http/1.1", without the quotes. This method is called by the underlying SSL framework.

Annotations
@Override
protocolSelectedback to summary
public void protocolSelected(final SSLEngine sslEngine, final String selectedProtocol)

Implements org.glassfish.grizzly.npn.AlpnClientNegotiator.protocolSelected.

Doc from org.glassfish.grizzly.npn.AlpnClientNegotiator.protocolSelected.

Inform the implementor which of the protocols returned from getProtocols(javax.net.ssl.SSLEngine) was actually selected.

For HTTP/2, if the argument is "h2", proceed to use the HTTP/2 protocol for the remainder of this connection. Otherwise, take the necessary action to use HTTP/1.1.

Annotations
@Override