Class AbstractSessionMessageHandler<T>

  • All Implemented Interfaces:
    io.netty.channel.ChannelHandler, io.netty.channel.ChannelInboundHandler
    Direct Known Subclasses:
    SessionMessageHandler, SessionWebSocketMessageHandler

    public abstract class AbstractSessionMessageHandler<T>
    extends io.netty.channel.SimpleChannelInboundHandler<T>
    Author:
    Grégory Van den Borre
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface io.netty.channel.ChannelHandler

        io.netty.channel.ChannelHandler.Sharable
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected be.yildizgames.module.network.AbstractHandler handler  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected AbstractSessionMessageHandler​(be.yildizgames.module.network.AbstractHandler handler)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void exceptionCaught​(io.netty.channel.ChannelHandlerContext ctx, Throwable e)  
      protected Optional<be.yildizgames.module.network.server.Session> getSession()  
      protected void setSession​(be.yildizgames.module.network.server.Session session)  
      • Methods inherited from class io.netty.channel.SimpleChannelInboundHandler

        acceptInboundMessage, channelRead, channelRead0
      • Methods inherited from class io.netty.channel.ChannelInboundHandlerAdapter

        channelActive, channelInactive, channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, userEventTriggered
      • Methods inherited from class io.netty.channel.ChannelHandlerAdapter

        ensureNotSharable, handlerAdded, handlerRemoved, isSharable
      • Methods inherited from interface io.netty.channel.ChannelHandler

        handlerAdded, handlerRemoved
    • Field Detail

      • handler

        protected final be.yildizgames.module.network.AbstractHandler handler
    • Constructor Detail

      • AbstractSessionMessageHandler

        protected AbstractSessionMessageHandler​(be.yildizgames.module.network.AbstractHandler handler)
    • Method Detail

      • exceptionCaught

        public final void exceptionCaught​(io.netty.channel.ChannelHandlerContext ctx,
                                          Throwable e)
        Specified by:
        exceptionCaught in interface io.netty.channel.ChannelHandler
        Specified by:
        exceptionCaught in interface io.netty.channel.ChannelInboundHandler
        Overrides:
        exceptionCaught in class io.netty.channel.ChannelInboundHandlerAdapter
      • getSession

        protected final Optional<be.yildizgames.module.network.server.Session> getSession()
        Returns:
        The associated session.
      • setSession

        protected final void setSession​(be.yildizgames.module.network.server.Session session)