public class OptimisticPrepareCommand extends PrepareCommand
PrepareCommand.| Modifier and Type | Field and Description |
|---|---|
static int |
METHOD_ID |
localAddress, modifications, onePhaseCommitglobalTransaction| Constructor and Description |
|---|
OptimisticPrepareCommand() |
OptimisticPrepareCommand(GlobalTransaction gtx,
List<WriteCommand> modifications,
org.jgroups.Address address,
boolean onePhaseCommit) |
| Modifier and Type | Method and Description |
|---|---|
Object |
acceptVisitor(InvocationContext ctx,
Visitor visitor)
Accept a visitor, and return the result of accepting this visitor.
|
OptimisticPrepareCommand |
copy()
A shallow copy of all fields except collections.
|
int |
getCommandId()
Used by marshallers to convert this command into an id for streaming.
|
Object[] |
getParameters()
Used by marshallers to stream this command across a network
|
void |
setParameters(int commandId,
Object[] args)
Used by the
CommandsFactory to create a command from raw data read off a stream. |
String |
toString() |
containsModificationType, equals, existModifications, getLocalAddress, getModifications, getModificationsCount, hashCode, isOnePhaseCommit, removeModificationsgetGlobalTransaction, perform, setGlobalTransactionpublic static final int METHOD_ID
public OptimisticPrepareCommand(GlobalTransaction gtx, List<WriteCommand> modifications, org.jgroups.Address address, boolean onePhaseCommit)
public OptimisticPrepareCommand()
public Object acceptVisitor(InvocationContext ctx, Visitor visitor) throws Throwable
VisitableCommandacceptVisitor in interface VisitableCommandacceptVisitor in class PrepareCommandctx - invocation contextvisitor - visitor to acceptThrowable - in the event of problemspublic int getCommandId()
ReplicableCommandgetCommandId in interface ReplicableCommandgetCommandId in class PrepareCommandpublic Object[] getParameters()
ReplicableCommandgetParameters in interface ReplicableCommandgetParameters in class PrepareCommandpublic OptimisticPrepareCommand copy()
copy in class PrepareCommandpublic void setParameters(int commandId,
Object[] args)
ReplicableCommandCommandsFactory to create a command from raw data read off a stream.setParameters in interface ReplicableCommandsetParameters in class PrepareCommandcommandId - command id to set. This is usually unused but *could* be used in the event of a command having multiple IDs, such as PutKeyValueCommand.args - object array of argspublic String toString()
toString in class PrepareCommandCopyright © 2012 JBoss, a division of Red Hat. All Rights Reserved.