@ChannelHandler.Sharable public class TextWebsocketEncoder extends io.netty.handler.codec.MessageToMessageEncoder<Event>
Event object) to a TextWebSocketFrame object. It uses
ObjectMapper from jackson library to do the Object to JSon String
encoding.| Modifier and Type | Field and Description |
|---|---|
private org.codehaus.jackson.map.ObjectMapper |
jackson |
| Constructor and Description |
|---|
TextWebsocketEncoder() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
encode(io.netty.channel.ChannelHandlerContext ctx,
Event msg,
List<Object> out) |
org.codehaus.jackson.map.ObjectMapper |
getJackson() |
void |
setJackson(org.codehaus.jackson.map.ObjectMapper jackson) |
acceptOutboundMessage, writebind, close, connect, deregister, disconnect, flush, readexceptionCaught, handlerAdded, handlerRemovedCopyright © 2013. All Rights Reserved.