|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.spy.memcached.compat.SpyObject net.spy.memcached.protocol.BaseOperationImpl net.spy.memcached.protocol.ascii.ConcatenationOperationImpl
public class ConcatenationOperationImpl
Operation for ascii concatenations.
Field Summary | |
---|---|
protected static byte[] |
CRLF
|
protected byte[] |
data
|
protected int |
exp
|
protected int |
flags
|
protected String |
key
|
protected String |
type
|
Fields inherited from class net.spy.memcached.protocol.BaseOperationImpl |
---|
callback, CANCELLED |
Constructor Summary | |
---|---|
ConcatenationOperationImpl(ConcatenationType t,
String k,
byte[] d,
OperationCallback cb)
|
Method Summary | |
---|---|
long |
getCasValue()
Get the CAS value sent with this operation. |
byte[] |
getData()
|
int |
getExpiration()
|
int |
getFlags()
|
Collection<String> |
getKeys()
|
protected net.spy.memcached.protocol.ascii.OperationReadType |
getReadType()
|
ConcatenationType |
getStoreType()
Get the concatenation type for this operation. |
void |
handleLine(String line)
|
void |
initialize()
Initialize this operation. |
protected OperationStatus |
matchStatus(String line,
OperationStatus... statii)
Match the status line provided against one of the given OperationStatus objects. |
void |
readFromBuffer(ByteBuffer data)
Read data from the given byte buffer and dispatch to the appropriate read mechanism. |
protected void |
setArguments(ByteBuffer bb,
Object... args)
Set some arguments for an operation into the given byte buffer. |
protected void |
setReadType(net.spy.memcached.protocol.ascii.OperationReadType to)
Set the read type of this operation. |
protected void |
wasCancelled()
This is called on each subclass whenever an operation was cancelled. |
Methods inherited from class net.spy.memcached.protocol.BaseOperationImpl |
---|
cancel, getBuffer, getCallback, getException, getHandlingNode, getState, handleError, handleRead, hasErrored, isCancelled, setBuffer, setCallback, setHandlingNode, transitionState, writeComplete |
Methods inherited from class net.spy.memcached.compat.SpyObject |
---|
getLogger |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface net.spy.memcached.ops.ConcatenationOperation |
---|
getData |
Methods inherited from interface net.spy.memcached.ops.KeyedOperation |
---|
getKeys |
Methods inherited from interface net.spy.memcached.ops.Operation |
---|
cancel, getBuffer, getCallback, getException, getHandlingNode, getState, handleRead, hasErrored, initialize, isCancelled, readFromBuffer, setHandlingNode, writeComplete |
Field Detail |
---|
protected final String type
protected final String key
protected final int flags
protected final int exp
protected final byte[] data
protected static final byte[] CRLF
Constructor Detail |
---|
public ConcatenationOperationImpl(ConcatenationType t, String k, byte[] d, OperationCallback cb)
Method Detail |
---|
public long getCasValue()
ConcatenationOperation
getCasValue
in interface ConcatenationOperation
public ConcatenationType getStoreType()
ConcatenationOperation
getStoreType
in interface ConcatenationOperation
public void handleLine(String line)
public void initialize()
Operation
initialize
in interface Operation
initialize
in class BaseOperationImpl
protected void wasCancelled()
BaseOperationImpl
wasCancelled
in class BaseOperationImpl
public Collection<String> getKeys()
public int getFlags()
public int getExpiration()
public byte[] getData()
protected final OperationStatus matchStatus(String line, OperationStatus... statii)
line
- the current linestatii
- several status objects
protected final net.spy.memcached.protocol.ascii.OperationReadType getReadType()
protected final void setReadType(net.spy.memcached.protocol.ascii.OperationReadType to)
protected final void setArguments(ByteBuffer bb, Object... args)
public void readFromBuffer(ByteBuffer data) throws IOException
Operation
readFromBuffer
in interface Operation
readFromBuffer
in class BaseOperationImpl
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |