- java.lang.Object
-
- io.netty5.handler.ssl.ApplicationProtocolConfig
-
public final class ApplicationProtocolConfig extends Object
Provides anSSLEngine
agnostic way to configure aApplicationProtocolNegotiator
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ApplicationProtocolConfig.Protocol
Defines which application level protocol negotiation to use.static class
ApplicationProtocolConfig.SelectedListenerFailureBehavior
Defines the most common behaviors for the peer which is notified of the selected protocol.static class
ApplicationProtocolConfig.SelectorFailureBehavior
Defines the most common behaviors for the peer that selects the application protocol.
-
Field Summary
Fields Modifier and Type Field Description static ApplicationProtocolConfig
DISABLED
The configuration that disables application protocol negotiation.
-
Constructor Summary
Constructors Constructor Description ApplicationProtocolConfig(ApplicationProtocolConfig.Protocol protocol, ApplicationProtocolConfig.SelectorFailureBehavior selectorBehavior, ApplicationProtocolConfig.SelectedListenerFailureBehavior selectedBehavior, Iterable<String> supportedProtocols)
Create a new instance.ApplicationProtocolConfig(ApplicationProtocolConfig.Protocol protocol, ApplicationProtocolConfig.SelectorFailureBehavior selectorBehavior, ApplicationProtocolConfig.SelectedListenerFailureBehavior selectedBehavior, String... supportedProtocols)
Create a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ApplicationProtocolConfig.Protocol
protocol()
Get which application level protocol negotiation to use.ApplicationProtocolConfig.SelectedListenerFailureBehavior
selectedListenerFailureBehavior()
Get the desired behavior for the peer who is notified of the selected protocol.ApplicationProtocolConfig.SelectorFailureBehavior
selectorFailureBehavior()
Get the desired behavior for the peer who selects the application protocol.List<String>
supportedProtocols()
The application level protocols supported.
-
-
-
Field Detail
-
DISABLED
public static final ApplicationProtocolConfig DISABLED
The configuration that disables application protocol negotiation.
-
-
Constructor Detail
-
ApplicationProtocolConfig
public ApplicationProtocolConfig(ApplicationProtocolConfig.Protocol protocol, ApplicationProtocolConfig.SelectorFailureBehavior selectorBehavior, ApplicationProtocolConfig.SelectedListenerFailureBehavior selectedBehavior, Iterable<String> supportedProtocols)
Create a new instance.- Parameters:
protocol
- The application protocol functionality to use.selectorBehavior
- How the peer selecting the protocol should behave.selectedBehavior
- How the peer being notified of the selected protocol should behave.supportedProtocols
- The order of iteration determines the preference of support for protocols.
-
ApplicationProtocolConfig
public ApplicationProtocolConfig(ApplicationProtocolConfig.Protocol protocol, ApplicationProtocolConfig.SelectorFailureBehavior selectorBehavior, ApplicationProtocolConfig.SelectedListenerFailureBehavior selectedBehavior, String... supportedProtocols)
Create a new instance.- Parameters:
protocol
- The application protocol functionality to use.selectorBehavior
- How the peer selecting the protocol should behave.selectedBehavior
- How the peer being notified of the selected protocol should behave.supportedProtocols
- The order of iteration determines the preference of support for protocols.
-
-
Method Detail
-
supportedProtocols
public List<String> supportedProtocols()
The application level protocols supported.
-
protocol
public ApplicationProtocolConfig.Protocol protocol()
Get which application level protocol negotiation to use.
-
selectorFailureBehavior
public ApplicationProtocolConfig.SelectorFailureBehavior selectorFailureBehavior()
Get the desired behavior for the peer who selects the application protocol.
-
selectedListenerFailureBehavior
public ApplicationProtocolConfig.SelectedListenerFailureBehavior selectedListenerFailureBehavior()
Get the desired behavior for the peer who is notified of the selected protocol.
-
-