public class ReadOnlyManyCommand<K,V,R> extends AbstractTopologyAffectedCommand implements LocalCommand
VisitableCommand.LoadType
Modifier and Type | Field and Description |
---|---|
static int |
COMMAND_ID |
protected Function<EntryView.ReadEntryView<K,V>,R> |
f |
protected DataConversion |
keyDataConversion |
protected Collection<?> |
keys |
protected Params |
params |
protected DataConversion |
valueDataConversion |
Constructor and Description |
---|
ReadOnlyManyCommand() |
ReadOnlyManyCommand(Collection<?> keys,
Function<EntryView.ReadEntryView<K,V>,R> f,
Params params,
DataConversion keyDataConversion,
DataConversion valueDataConversion) |
ReadOnlyManyCommand(ReadOnlyManyCommand c) |
Modifier and Type | Method and Description |
---|---|
Object |
acceptVisitor(InvocationContext ctx,
Visitor visitor)
Accept a visitor, and return the result of accepting this visitor.
|
byte |
getCommandId()
Used by marshallers to convert this command into an id for streaming.
|
Function<EntryView.ReadEntryView<K,V>,R> |
getFunction() |
DataConversion |
getKeyDataConversion() |
Collection<?> |
getKeys() |
Params |
getParams() |
DataConversion |
getValueDataConversion() |
void |
init(ComponentRegistry componentRegistry) |
boolean |
isReturnValueExpected()
If true, a return value will be provided when performed remotely.
|
VisitableCommand.LoadType |
loadType() |
void |
readFrom(ObjectInput input)
Reads this instance from the stream written by
ReplicableCommand.writeTo(ObjectOutput) . |
void |
setKeys(Collection<?> keys) |
String |
toString() |
ReadOnlyManyCommand<K,V,R> |
withKeys(Collection<?> keys) |
void |
writeTo(ObjectOutput output)
Writes this instance to the
ObjectOutput . |
getTopologyId, setTopologyId
getFlagsBitSet, hasSameFlags, printFlags, setFlagsBitSet
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
canBlock, invoke, invokeAsync, isSuccessful, setOrigin
addFlag, addFlags, addFlags, getFlags, hasAllFlags, hasAnyFlag, hasFlag, setFlags
public static final int COMMAND_ID
protected Collection<?> keys
protected Function<EntryView.ReadEntryView<K,V>,R> f
protected Params params
protected DataConversion keyDataConversion
protected DataConversion valueDataConversion
public ReadOnlyManyCommand(Collection<?> keys, Function<EntryView.ReadEntryView<K,V>,R> f, Params params, DataConversion keyDataConversion, DataConversion valueDataConversion)
public ReadOnlyManyCommand()
public ReadOnlyManyCommand(ReadOnlyManyCommand c)
public void init(ComponentRegistry componentRegistry)
init
in interface VisitableCommand
public Collection<?> getKeys()
public void setKeys(Collection<?> keys)
public final ReadOnlyManyCommand<K,V,R> withKeys(Collection<?> keys)
public byte getCommandId()
ReplicableCommand
getCommandId
in interface ReplicableCommand
public boolean isReturnValueExpected()
ReplicableCommand
ResponseGenerator
may choose to simply return null to save on marshalling
costs.isReturnValueExpected
in interface ReplicableCommand
public void writeTo(ObjectOutput output) throws IOException
ReplicableCommand
ObjectOutput
.writeTo
in interface ReplicableCommand
output
- the stream.IOException
- if an error occurred during the I/O.public void readFrom(ObjectInput input) throws IOException, ClassNotFoundException
ReplicableCommand
ReplicableCommand.writeTo(ObjectOutput)
.readFrom
in interface ReplicableCommand
input
- the stream to read.IOException
- if an error occurred during the I/O.ClassNotFoundException
- if it tries to load an undefined class.public Object acceptVisitor(InvocationContext ctx, Visitor visitor) throws Throwable
VisitableCommand
acceptVisitor
in interface VisitableCommand
ctx
- invocation contextvisitor
- visitor to acceptThrowable
- in the event of problemspublic VisitableCommand.LoadType loadType()
loadType
in interface VisitableCommand
public DataConversion getKeyDataConversion()
public DataConversion getValueDataConversion()
public Params getParams()
public Function<EntryView.ReadEntryView<K,V>,R> getFunction()
Copyright © 2021 JBoss by Red Hat. All rights reserved.