org.infinispan.commands
Interface VisitableCommand

All Superinterfaces:
ReplicableCommand
All Known Subinterfaces:
DataCommand, DataWriteCommand, TransactionBoundaryCommand, WriteCommand
All Known Implementing Classes:
AbstractDataCommand, AbstractDataWriteCommand, AbstractTransactionBoundaryCommand, ClearCommand, CommitCommand, EntrySetCommand, EvictCommand, GetKeyValueCommand, InvalidateCommand, InvalidateL1Command, KeySetCommand, LockControlCommand, PrepareCommand, PutKeyValueCommand, PutMapCommand, RemoveCommand, ReplaceCommand, RollbackCommand, SizeCommand, ValuesCommand

public interface VisitableCommand
extends ReplicableCommand

A type of command that can accept Visitors, such as CommandInterceptors.

Since:
4.0
Author:
Manik Surtani (manik@jboss.org)

Method Summary
 Object acceptVisitor(InvocationContext ctx, Visitor visitor)
          Accept a visitor, and return the result of accepting this visitor.
 boolean shouldInvoke(InvocationContext ctx)
          Used by the InboundInvocationHandler to determine whether the command should be invoked or not.
 
Methods inherited from interface org.infinispan.commands.ReplicableCommand
getCommandId, getParameters, perform, setParameters
 

Method Detail

acceptVisitor

Object acceptVisitor(InvocationContext ctx,
                     Visitor visitor)
                     throws Throwable
Accept a visitor, and return the result of accepting this visitor.

Parameters:
ctx - invocation context
visitor - visitor to accept
Returns:
arbitrary return value
Throws:
Throwable - in the event of problems

shouldInvoke

boolean shouldInvoke(InvocationContext ctx)
Used by the InboundInvocationHandler to determine whether the command should be invoked or not.

Returns:
true if the command should be invoked, false otherwise.

Google Analytics

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