public class SetRequest extends AsciiRequest<MemcacheStatus> implements SetRequest
| Modifier and Type | Class and Description |
|---|---|
static class |
SetRequest.Operation |
| Modifier and Type | Field and Description |
|---|---|
private long |
cas |
private static java.util.EnumMap<SetRequest.Operation,byte[]> |
CMD |
private static byte[] |
FLAGS |
private SetRequest.Operation |
operation |
private int |
ttl |
private byte[] |
value |
NEWLINE_BYTES, SPACE_BYTESkey| Modifier | Constructor and Description |
|---|---|
private |
SetRequest(SetRequest.Operation operation,
byte[] key,
byte[] value,
int ttl,
long cas) |
| Modifier and Type | Method and Description |
|---|---|
static SetRequest |
casSet(byte[] key,
byte[] value,
int ttl,
long cas) |
static SetRequest |
create(SetRequest.Operation operation,
byte[] key,
byte[] value,
int ttl) |
byte[] |
getValue() |
void |
handle(AsciiResponse response,
HostAndPort server) |
private static io.netty.buffer.ByteBuf |
toBufferWithValueAndNewLine(io.netty.buffer.ByteBufAllocator alloc,
java.nio.ByteBuffer dst,
byte[] value) |
io.netty.buffer.ByteBuf |
writeRequest(io.netty.buffer.ByteBufAllocator alloc,
java.nio.ByteBuffer dst) |
handleasFuture, encodeKey, encodeKeys, fail, getKey, succeed, toBuffer, toBufferacceptEither, acceptEitherAsync, acceptEitherAsync, allOf, anyOf, applyToEither, applyToEitherAsync, applyToEitherAsync, cancel, complete, completedFuture, completeExceptionally, exceptionally, get, get, getNow, getNumberOfDependents, handle, handleAsync, handleAsync, isCancelled, isCompletedExceptionally, isDone, join, obtrudeException, obtrudeValue, runAfterBoth, runAfterBothAsync, runAfterBothAsync, runAfterEither, runAfterEitherAsync, runAfterEitherAsync, runAsync, runAsync, supplyAsync, supplyAsync, thenAccept, thenAcceptAsync, thenAcceptAsync, thenAcceptBoth, thenAcceptBothAsync, thenAcceptBothAsync, thenApply, thenApplyAsync, thenApplyAsync, thenCombine, thenCombineAsync, thenCombineAsync, thenCompose, thenComposeAsync, thenComposeAsync, thenRun, thenRunAsync, thenRunAsync, toCompletableFuture, toString, whenComplete, whenCompleteAsync, whenCompleteAsyncprivate static final java.util.EnumMap<SetRequest.Operation,byte[]> CMD
private static final byte[] FLAGS
private final SetRequest.Operation operation
private final byte[] value
private final int ttl
private final long cas
private SetRequest(SetRequest.Operation operation, byte[] key, byte[] value, int ttl, long cas)
public static SetRequest casSet(byte[] key, byte[] value, int ttl, long cas)
public static SetRequest create(SetRequest.Operation operation, byte[] key, byte[] value, int ttl)
public io.netty.buffer.ByteBuf writeRequest(io.netty.buffer.ByteBufAllocator alloc,
java.nio.ByteBuffer dst)
writeRequest in interface Request<MemcacheStatus>private static io.netty.buffer.ByteBuf toBufferWithValueAndNewLine(io.netty.buffer.ByteBufAllocator alloc,
java.nio.ByteBuffer dst,
byte[] value)
public void handle(AsciiResponse response, HostAndPort server) throws java.io.IOException
handle in class AsciiRequest<MemcacheStatus>java.io.IOExceptionpublic byte[] getValue()
getValue in interface SetRequestCopyright © 2020 Spotify AB. All Rights Reserved.