Class QuicServerCodecBuilder
java.lang.Object
io.netty.handler.codec.quic.QuicCodecBuilder<QuicServerCodecBuilder>
io.netty.handler.codec.quic.QuicServerCodecBuilder
QuicCodecBuilder that configures and builds a ChannelHandler that should be added to the
ChannelPipeline of a QUIC server.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionattr(AttributeKey<T> key, T value) Allow to specify an initial attribute of the newly createdQuicChannel.clone()Clone the builderconnectionIdAddressGenerator(QuicConnectionIdGenerator connectionIdAddressGenerator) Sets theQuicConnectionIdGeneratorto use.handler(ChannelHandler handler) option(ChannelOption<T> option, T value) Allow to specify aChannelOptionwhich is used for theQuicChannelinstances once they got created.resetTokenGenerator(@Nullable QuicResetTokenGenerator resetTokenGenerator) Set theQuicResetTokenGeneratorthat is used to generate stateless reset tokens ornullif the default should be used.streamAttr(AttributeKey<T> key, T value) Allow to specify an initial attribute of the newly createdQuicStreamChannel.streamHandler(ChannelHandler streamHandler) streamOption(ChannelOption<T> option, T value) Allow to specify aChannelOptionwhich is used for theQuicStreamChannelinstances once they got created.tokenHandler(@Nullable QuicTokenHandler tokenHandler) Set theQuicTokenHandlerthat is used to generate and validate tokens ornullif no tokens should be used at all.protected voidvalidate()Validate the configuration before building the codec.Methods inherited from class QuicCodecBuilder
ackDelayExponent, activeConnectionIdLimit, activeMigration, build, congestionControlAlgorithm, datagram, discoverPmtu, flushStrategy, grease, hystart, initialCongestionWindowPackets, initialMaxData, initialMaxStreamDataBidirectionalLocal, initialMaxStreamDataBidirectionalRemote, initialMaxStreamDataUnidirectional, initialMaxStreamsBidirectional, initialMaxStreamsUnidirectional, localConnectionIdLength, maxAckDelay, maxIdleTimeout, maxRecvUdpPayloadSize, maxSendUdpPayloadSize, self, sslContext, sslEngineProvider, sslTaskExecutor, statelessResetToken, version
-
Constructor Details
-
QuicServerCodecBuilder
public QuicServerCodecBuilder()Creates a new instance.
-
-
Method Details
-
clone
Description copied from class:QuicCodecBuilderClone the builder- Specified by:
clonein classQuicCodecBuilder<QuicServerCodecBuilder>- Returns:
- the new instance that is a clone if this instance.
-
option
Allow to specify aChannelOptionwhich is used for theQuicChannelinstances once they got created. Use a value ofnullto remove a previous setChannelOption.- Type Parameters:
T- the type of the value.- Parameters:
option- theChannelOptionto apply to theQuicChannel.value- the value of the option.- Returns:
- this instance.
-
attr
Allow to specify an initial attribute of the newly createdQuicChannel. If thevalueisnull, the attribute of the specifiedkeyis removed.- Type Parameters:
T- the type of the value.- Parameters:
key- theAttributeKeyto apply to theQuicChannel.value- the value of the attribute.- Returns:
- this instance.
-
handler
- Parameters:
handler- theChannelHandlerthat is added to theQuicChannelsChannelPipeline.- Returns:
- this instance.
-
streamOption
Allow to specify aChannelOptionwhich is used for theQuicStreamChannelinstances once they got created. Use a value ofnullto remove a previous setChannelOption.- Type Parameters:
T- the type of the value.- Parameters:
option- theChannelOptionto apply to theQuicStreamChannels.value- the value of the option.- Returns:
- this instance.
-
streamAttr
Allow to specify an initial attribute of the newly createdQuicStreamChannel. If thevalueisnull, the attribute of the specifiedkeyis removed.- Type Parameters:
T- the type of the value.- Parameters:
key- theAttributeKeyto apply to theQuicStreamChannels.value- the value of the attribute.- Returns:
- this instance.
-
streamHandler
- Parameters:
streamHandler- theChannelHandlerthat is added to theQuicStreamChannelsChannelPipeline.- Returns:
- this instance.
-
connectionIdAddressGenerator
public QuicServerCodecBuilder connectionIdAddressGenerator(QuicConnectionIdGenerator connectionIdAddressGenerator) Sets theQuicConnectionIdGeneratorto use.- Parameters:
connectionIdAddressGenerator- theQuicConnectionIdGeneratorto use.- Returns:
- this instance.
-
tokenHandler
Set theQuicTokenHandlerthat is used to generate and validate tokens ornullif no tokens should be used at all.- Parameters:
tokenHandler- theQuicTokenHandlerto use.- Returns:
- this instance.
-
resetTokenGenerator
public QuicServerCodecBuilder resetTokenGenerator(@Nullable @Nullable QuicResetTokenGenerator resetTokenGenerator) Set theQuicResetTokenGeneratorthat is used to generate stateless reset tokens ornullif the default should be used.- Parameters:
resetTokenGenerator- theQuicResetTokenGeneratorto use.- Returns:
- this instance.
-
validate
protected void validate()Description copied from class:QuicCodecBuilderValidate the configuration before building the codec.- Overrides:
validatein classQuicCodecBuilder<QuicServerCodecBuilder>
-