public interface WriteCommand extends VisitableCommand, FlagAffectedCommand
| Modifier and Type | Method and Description |
|---|---|
Set<Object> |
getAffectedKeys() |
boolean |
isConditional()
Certain commands only work based on a certain condition or state of the cache.
|
boolean |
isIgnorePreviousValue()
Only relevant for conditional commands.
|
boolean |
isSuccessful()
Some commands may want to provide information on whether the command was successful or not.
|
void |
setIgnorePreviousValue(boolean ignorePreviousValue)
Only relevant for conditional commands.
|
acceptVisitor, ignoreCommandOnStatus, shouldInvokegetTopologyId, setTopologyIdcanBlock, getCommandId, getParameters, isReturnValueExpected, perform, setParametersgetMetadata, setMetadatagetFlags, hasFlag, setFlags, setFlagsboolean isSuccessful()
boolean isConditional()
ConcurrentMap.putIfAbsent(Object, Object) only does anything if a condition is met, i.e., the entry in
question is not already present. This method tests whether the command in question is conditional or not.boolean isIgnorePreviousValue()
true if the command isn't really conditional, because the previous value was already checked
- either on the originator (tx) or on the primary owner (non-tx).void setIgnorePreviousValue(boolean ignorePreviousValue)
ignorePreviousValue - true if the command isn't really conditional, because the previous value
was already checked - either on the originator (tx) or on the primary owner (non-tx).Copyright © 2013 JBoss, a division of Red Hat. All rights reserved.