public class JsonDecoder extends Object implements MediaTypeDecoder
| Modifier and Type | Field and Description |
|---|---|
static com.fasterxml.jackson.databind.ObjectMapper |
mapper |
| Constructor and Description |
|---|
JsonDecoder(HttpRequest request) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canDecode(List<MediaType> mediaType) |
void |
finished(io.netty.channel.ChannelHandlerContext ctx)
Invoked when all the HTTP content for the request has een received.
|
void |
offer(io.netty.handler.codec.http.HttpContent chunk)
Called each time a chunk of data is received for the request
|
DependencyProvider |
provider() |
public JsonDecoder(HttpRequest request)
public boolean canDecode(List<MediaType> mediaType)
canDecode in interface MediaTypeDecodermediaType - the media type to check compatibility forpublic void offer(io.netty.handler.codec.http.HttpContent chunk)
MediaTypeDecoderoffer in interface MediaTypeDecoderchunk - the chunk to decode or bufferpublic void finished(io.netty.channel.ChannelHandlerContext ctx)
MediaTypeDecoderMediaTypeDecoder.offer(HttpContent) will not be
called after this and whatever is decoded will be passed to the target methodfinished in interface MediaTypeDecoderctx - the contextpublic DependencyProvider provider()
provider in interface MediaTypeDecoderCopyright © 2012-2015. All Rights Reserved.