Package io.hekate.network.netty
Class NettyServerHandlerConfig<T>
- java.lang.Object
-
- io.hekate.network.NetworkServerHandlerConfig<T>
-
- io.hekate.network.netty.NettyServerHandlerConfig<T>
-
- Type Parameters:
T
- Base type of messages that can be processed byNetworkServerHandler
.
public class NettyServerHandlerConfig<T> extends NetworkServerHandlerConfig<T>
Netty-specific extension ofNetworkServerHandlerConfig
.- See Also:
NettyServerFactory.setHandlers(List)
-
-
Constructor Summary
Constructors Constructor Description NettyServerHandlerConfig()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description io.netty.channel.EventLoopGroup
getEventLoop()
Returns the event loop of this handler (seesetEventLoop(EventLoopGroup)
).void
setEventLoop(io.netty.channel.EventLoopGroup eventLoop)
Sets the event loop to be used by this handler.NettyServerHandlerConfig<T>
withEventLoop(io.netty.channel.EventLoopGroup eventLoop)
Fluent-style version ofsetEventLoop(EventLoopGroup)
.-
Methods inherited from class io.hekate.network.NetworkServerHandlerConfig
getCodecFactory, getHandler, getLoggerCategory, getProtocol, setCodecFactory, setHandler, setLoggerCategory, setProtocol, toString, withCodecFactory, withHandler, withLoggerCategory, withProtocol
-
-
-
-
Method Detail
-
getEventLoop
public io.netty.channel.EventLoopGroup getEventLoop()
Returns the event loop of this handler (seesetEventLoop(EventLoopGroup)
).- Returns:
- Event loop.
-
setEventLoop
public void setEventLoop(io.netty.channel.EventLoopGroup eventLoop)
Sets the event loop to be used by this handler.If not specified then all network operations will be handled by the the
NetworkServer
'score event loop
.- Parameters:
eventLoop
- Event loop.
-
withEventLoop
public NettyServerHandlerConfig<T> withEventLoop(io.netty.channel.EventLoopGroup eventLoop)
Fluent-style version ofsetEventLoop(EventLoopGroup)
.- Parameters:
eventLoop
- Event loop.- Returns:
- This instance.
-
-