public abstract class BinaryRequest<V> extends Request<V>
| Modifier and Type | Field and Description |
|---|---|
protected static int |
HEADER_SIZE |
protected static byte |
MAGIC_NUMBER |
protected int |
opaque |
protected boolean |
opaqueSet |
| Modifier | Constructor and Description |
|---|---|
protected |
BinaryRequest(byte[] key) |
protected |
BinaryRequest(String key,
Charset charset) |
| Modifier and Type | Method and Description |
|---|---|
protected int |
getOpaque() |
protected abstract void |
handle(BinaryResponse response) |
void |
handle(Object response) |
protected ResponsePacket |
handleSingleReply(BinaryResponse replies) |
void |
setOpaque(int opaque) |
void |
writeHeader(ByteBuffer dst,
byte opCode,
int extraLength,
int valueLength,
long cas) |
encodeKey, encodeKeys, fail, getKey, succeed, toBuffer, toBuffer, writeRequestprotected static final int HEADER_SIZE
protected static final byte MAGIC_NUMBER
protected int opaque
protected boolean opaqueSet
protected int getOpaque()
public void writeHeader(ByteBuffer dst, byte opCode, int extraLength, int valueLength, long cas)
protected ResponsePacket handleSingleReply(BinaryResponse replies) throws IOException
IOExceptionpublic void handle(Object response) throws IOException
handle in class Request<V>IOExceptionprotected abstract void handle(BinaryResponse response) throws IOException
IOExceptionpublic void setOpaque(int opaque)
Copyright © 2017 Spotify AB. All Rights Reserved.