org.infinispan.commands.read
Class AbstractDataCommand

java.lang.Object
  extended by org.infinispan.commands.read.AbstractDataCommand
All Implemented Interfaces:
DataCommand, ReplicableCommand, VisitableCommand
Direct Known Subclasses:
AbstractDataWriteCommand, GetKeyValueCommand

public abstract class AbstractDataCommand
extends Object
implements DataCommand

Since:
4.0
Author:
Mircea.Markus@jboss.com

Field Summary
protected  Object key
           
 
Constructor Summary
protected AbstractDataCommand()
           
protected AbstractDataCommand(Object key)
           
 
Method Summary
 boolean equals(Object o)
           
 Object getKey()
           
 Object[] getParameters()
          Used by marshallers to stream this command across a network
 int hashCode()
           
 void setKey(Object key)
           
 void setParameters(int commandId, Object[] parameters)
          Used by the CommandsFactory to create a command from raw data read off a stream.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.infinispan.commands.VisitableCommand
acceptVisitor
 
Methods inherited from interface org.infinispan.commands.ReplicableCommand
getCommandId, perform
 

Field Detail

key

protected Object key
Constructor Detail

AbstractDataCommand

protected AbstractDataCommand(Object key)

AbstractDataCommand

protected AbstractDataCommand()
Method Detail

getKey

public Object getKey()
Specified by:
getKey in interface DataCommand

setKey

public void setKey(Object key)

setParameters

public void setParameters(int commandId,
                          Object[] parameters)
Description copied from interface: ReplicableCommand
Used by the CommandsFactory to create a command from raw data read off a stream.

Specified by:
setParameters in interface ReplicableCommand
Parameters:
commandId - command id to set. This is usually unused but *could* be used in the event of a command having multiple IDs, such as PutKeyValueCommand.
parameters - object array of args

getParameters

public Object[] getParameters()
Description copied from interface: ReplicableCommand
Used by marshallers to stream this command across a network

Specified by:
getParameters in interface ReplicableCommand
Returns:
an object array of arguments, compatible with pre-2.2.0 MethodCall args.

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object

Google Analytics

Copyright © 2010 JBoss, a division of Red Hat. All Rights Reserved.