Class EmbeddedChannel.Builder
java.lang.Object
io.netty.channel.embedded.EmbeddedChannel.Builder
- Enclosing class:
EmbeddedChannel
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Create the channel.TheChannelIdthat will be used to identify this channel.config(ChannelConfig config) TheChannelConfigwhich will be returned byEmbeddedChannel.config().handlers(ChannelHandler handler) TheChannelHandlerwhich will be added to theChannelPipeline.handlers(ChannelHandler... handlers) TheChannelHandlers which will be added to theChannelPipeline.hasDisconnect(boolean hasDisconnect) falseif thisChannelwill delegateEmbeddedChannel.disconnect()toEmbeddedChannel.close(),trueotherwise.The parentChannelof thisEmbeddedChannel.register(boolean register) Configure a custom ticker for this event loop.
-
Method Details
-
parent
The parentChannelof thisEmbeddedChannel.- Parameters:
parent- the parentChannelof thisEmbeddedChannel.- Returns:
- This builder
-
channelId
-
register
trueif thisChannelis registered to theEventLoopin the constructor. Iffalsethe user will need to callEmbeddedChannel.register().- Parameters:
register-trueif thisChannelis registered to theEventLoopin the constructor. Iffalsethe user will need to callEmbeddedChannel.register().- Returns:
- This builder
-
hasDisconnect
falseif thisChannelwill delegateEmbeddedChannel.disconnect()toEmbeddedChannel.close(),trueotherwise.- Parameters:
hasDisconnect-falseif thisChannelwill delegateEmbeddedChannel.disconnect()toEmbeddedChannel.close(),trueotherwise- Returns:
- This builder
-
handlers
TheChannelHandlers which will be added to theChannelPipeline.- Parameters:
handlers- theChannelHandlers which will be added to theChannelPipeline- Returns:
- This builder
-
handlers
TheChannelHandlerwhich will be added to theChannelPipeline.- Parameters:
handler- theChannelHandlers which will be added to theChannelPipeline- Returns:
- This builder
-
config
TheChannelConfigwhich will be returned byEmbeddedChannel.config().- Parameters:
config- theChannelConfigwhich will be returned byEmbeddedChannel.config()- Returns:
- This builder
-
ticker
Configure a custom ticker for this event loop.- Parameters:
ticker- The custom ticker- Returns:
- This builder
-
build
Create the channel. If you wish to extendEmbeddedChannel, please use theconstructor instead.invalid reference
#EmbeddedChannel(Builder)- Returns:
- The channel
-