public abstract class AbstractWriteManyCommand<K,V> extends Object implements WriteCommand, ParamsCommand
| Constructor and Description |
|---|
AbstractWriteManyCommand() |
| Modifier and Type | Method and Description |
|---|---|
Set<Flag> |
getFlags() |
Metadata |
getMetadata()
Get metadata of this command.
|
Params |
getParams() |
int |
getTopologyId() |
ValueMatcher |
getValueMatcher() |
boolean |
hasFlag(Flag flag)
Check whether a particular flag is present in the command
|
boolean |
isConditional()
Certain commands only work based on a certain condition or state of the cache.
|
boolean |
isForwarded() |
boolean |
isSuccessful()
Some commands may want to provide information on whether the command was successful or not.
|
void |
setFlags(Flag... flags)
Add some flags to the command.
|
void |
setFlags(Set<Flag> flags)
Set the flags, replacing any existing flags.
|
void |
setForwarded(boolean forwarded) |
void |
setMetadata(Metadata metadata)
Sets metadata for this command.
|
void |
setParams(Params params) |
void |
setTopologyId(int topologyId) |
void |
setValueMatcher(ValueMatcher valueMatcher) |
boolean |
shouldInvoke(InvocationContext ctx)
Used by the InboundInvocationHandler to determine whether the command should be invoked or not.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAffectedKeys, isWriteOnly, updateStatusFromRemoteResponseacceptVisitor, alwaysReadsExistingValues, ignoreCommandOnStatus, readsExistingValuescanBlock, getCommandId, getParameters, isReturnValueExpected, perform, readFrom, setParameters, writeToaddFlag, addFlagspublic int getTopologyId()
getTopologyId in interface TopologyAffectedCommandpublic void setTopologyId(int topologyId)
setTopologyId in interface TopologyAffectedCommandpublic boolean isForwarded()
public void setForwarded(boolean forwarded)
public ValueMatcher getValueMatcher()
getValueMatcher in interface WriteCommandpublic void setValueMatcher(ValueMatcher valueMatcher)
setValueMatcher in interface WriteCommandvalueMatcher - The new value matching policy.public boolean isSuccessful()
WriteCommandisSuccessful in interface WriteCommandpublic boolean isConditional()
WriteCommandConcurrentMap.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.isConditional in interface WriteCommandpublic boolean shouldInvoke(InvocationContext ctx)
VisitableCommandshouldInvoke in interface VisitableCommandpublic Set<Flag> getFlags()
getFlags in interface LocalFlagAffectedCommandLocalFlagAffectedCommand.setFlags(java.util.Set). The set should
not be modified directly, only via the LocalFlagAffectedCommand.setFlags(Set), LocalFlagAffectedCommand.addFlag(Flag) and LocalFlagAffectedCommand.addFlags(Set) methods.public Metadata getMetadata()
MetadataAwareCommandgetMetadata in interface MetadataAwareCommandpublic void setMetadata(Metadata metadata)
MetadataAwareCommandsetMetadata in interface MetadataAwareCommandpublic void setFlags(Set<Flag> flags)
LocalFlagAffectedCommandsetFlags in interface LocalFlagAffectedCommandflags - The new flags.public void setFlags(Flag... flags)
LocalFlagAffectedCommandsetFlags in interface LocalFlagAffectedCommandflags - The flags to add.public boolean hasFlag(Flag flag)
LocalFlagAffectedCommandhasFlag in interface LocalFlagAffectedCommandflag - to lookup in the commandpublic Params getParams()
getParams in interface ParamsCommandpublic void setParams(Params params)
Copyright © 2025 JBoss, a division of Red Hat. All rights reserved.