예제 #1
0
        public override void ChannelRead(IChannelHandlerContext ctx, object msg)
        {
            var buffer = msg as IByteBuffer;

            if (buffer != null)
            {
                if (Logger.IsEnabled(InternalLevel))
                {
                    Logger.Log(InternalLevel, FormatByteBuffer("RECV", buffer));
                }
            }
            ctx.FireChannelRead(msg);
        }
예제 #2
0
 public bool IsEnabled() => _logger.IsEnabled(_level);
예제 #3
0
 public override void ChannelRegistered(IChannelHandlerContext ctx)
 {
     if (Logger.IsEnabled(InternalLevel))
     {
         Logger.Log(InternalLevel, Format(ctx, "REGISTERED"));
     }
     ctx.FireChannelRegistered();
 }