public class AsciiMemcacheDecoder
extends io.netty.handler.codec.ByteToMessageDecoder
| Modifier and Type | Field and Description |
|---|---|
private long |
cas |
private java.nio.charset.Charset |
charset |
private boolean |
consumed |
private byte[] |
key |
private java.nio.ByteBuffer |
line |
private static int |
MAX_RESPONSE_LINE |
private StatsAsciiResponse |
statsAsciiResponse |
private java.nio.ByteBuffer |
token |
private byte[] |
value |
private boolean |
valueMode |
private int |
valueOffset |
private ValueAsciiResponse |
valueResponse |
| Constructor and Description |
|---|
AsciiMemcacheDecoder(java.nio.charset.Charset charset) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
decode(io.netty.channel.ChannelHandlerContext ctx,
io.netty.buffer.ByteBuf buf,
java.util.List<java.lang.Object> out) |
private void |
expect(byte firstChar,
java.lang.String compareTo) |
private java.io.IOException |
fail() |
private long |
parseLong(byte firstChar,
java.nio.ByteBuffer token) |
private java.nio.ByteBuffer |
readLine(io.netty.buffer.ByteBuf buf,
int available) |
private void |
readNextToken() |
private java.lang.String |
toString(java.nio.ByteBuffer buf) |
actualReadableBytes, callDecode, channelInactive, channelRead, channelReadComplete, decodeLast, discardSomeReadBytes, handlerRemoved, handlerRemoved0, internalBuffer, isSingleDecode, setCumulator, setDiscardAfterReads, setSingleDecode, userEventTriggeredchannelActive, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaughtensureNotSharable, handlerAdded, isSharableprivate static final int MAX_RESPONSE_LINE
private final java.nio.ByteBuffer line
private final java.nio.ByteBuffer token
private final java.nio.charset.Charset charset
private boolean valueMode
private ValueAsciiResponse valueResponse
private StatsAsciiResponse statsAsciiResponse
private boolean consumed
private byte[] key
private byte[] value
private long cas
private int valueOffset
public AsciiMemcacheDecoder(java.nio.charset.Charset charset)
protected void decode(io.netty.channel.ChannelHandlerContext ctx,
io.netty.buffer.ByteBuf buf,
java.util.List<java.lang.Object> out)
throws java.lang.Exception
decode in class io.netty.handler.codec.ByteToMessageDecoderjava.lang.Exceptionprivate void readNextToken()
private java.io.IOException fail()
private java.lang.String toString(java.nio.ByteBuffer buf)
private void expect(byte firstChar,
java.lang.String compareTo)
throws java.io.IOException
java.io.IOExceptionprivate long parseLong(byte firstChar,
java.nio.ByteBuffer token)
throws java.io.IOException
java.io.IOExceptionprivate java.nio.ByteBuffer readLine(io.netty.buffer.ByteBuf buf,
int available)
throws java.io.IOException
java.io.IOExceptionCopyright © 2020 Spotify AB. All Rights Reserved.