Package org.eclipse.jetty.alpn
Interface ALPN.ClientProvider
- All Superinterfaces:
ALPN.Provider
- Enclosing class:
ALPN
The client-side provider interface that applications must
implement to interact with the negotiation of the protocol.
-
Method Summary
Modifier and TypeMethodDescriptionCallback invoked to let the implementation know the list of protocols that should be added to the ALPN extension in a ClientHello TLS message.void
Callback invoked to let the client application know the protocol chosen by the server.void
Callback invoked to let the client application know that the server does not support ALPN.
-
Method Details
-
protocols
Callback invoked to let the implementation know the list of protocols that should be added to the ALPN extension in a ClientHello TLS message.
- Returns:
- the list of protocols supported by the client;
if
null
or empty, the ALPN extension is not sent
-
unsupported
void unsupported()Callback invoked to let the client application know that the server does not support ALPN. -
selected
Callback invoked to let the client application know the protocol chosen by the server.
The implementation may throw an exception to indicate that the protocol selected by the server is not acceptable, causing the connection to be closed with a TLS alert of type
no_application_protocol(120)
.- Parameters:
protocol
- the protocol selected by the server.- Throws:
SSLException
- if the protocol negotiation failed.
-