org.jboss.cache.interceptors
Class EvictionInterceptor

java.lang.Object
  extended by org.jboss.cache.commands.AbstractVisitor
      extended by org.jboss.cache.interceptors.base.CommandInterceptor
          extended by org.jboss.cache.interceptors.EvictionInterceptor
All Implemented Interfaces:
Visitor
Direct Known Subclasses:
BuddyRegionAwareEvictionInterceptor

public class EvictionInterceptor
extends CommandInterceptor

Eviction Interceptor.

This interceptor is used to handle eviction events.

Version:
$Revision: 7654 $
Author:
Daniel Huang, Mircea.Markus@jboss.com

Field Summary
protected  RegionManager regionManager
           
 
Fields inherited from class org.jboss.cache.interceptors.base.CommandInterceptor
configuration, log, trace
 
Constructor Summary
EvictionInterceptor()
           
 
Method Summary
protected  Region getRegion(Fqn fqn)
           
 void initialize(DataContainer dataContainer)
           
 Object visitClearDataCommand(InvocationContext ctx, ClearDataCommand command)
          Visits a RemoveDataCommand.
 Object visitEvictFqnCommand(InvocationContext ctx, EvictCommand command)
          Visits a EvictCommand.
 Object visitGetDataMapCommand(InvocationContext ctx, GetDataMapCommand command)
          Visits a GetDataMapCommand.
 Object visitGetKeyValueCommand(InvocationContext ctx, GetKeyValueCommand command)
          Visits a GetKeyValueCommand.
 Object visitGetNodeCommand(InvocationContext ctx, GetNodeCommand command)
          Visits a GetNodeCommand.
 Object visitPutDataMapCommand(InvocationContext ctx, PutDataMapCommand command)
          Visits a PutDataMapCommand.
 Object visitPutForExternalReadCommand(InvocationContext ctx, PutForExternalReadCommand command)
          Visits a PutForExternalReadCommand.
 Object visitPutKeyValueCommand(InvocationContext ctx, PutKeyValueCommand command)
          Visits a PutKeyValueCommand.
 Object visitRemoveKeyCommand(InvocationContext ctx, RemoveKeyCommand command)
          Visits a RemoveKeyCommand.
 Object visitRemoveNodeCommand(InvocationContext ctx, RemoveNodeCommand command)
          Visits a RemoveNodeCommand.
 
Methods inherited from class org.jboss.cache.interceptors.base.CommandInterceptor
getNext, handleDefault, hasNext, invokeNextInterceptor, setNext
 
Methods inherited from class org.jboss.cache.commands.AbstractVisitor
visitCollection, visitCommitCommand, visitCreateNodeCommand, visitExistsNodeCommand, visitGetChildrenNamesCommand, visitGetKeysCommand, visitGravitateDataCommand, visitInvalidateCommand, visitMoveCommand, visitOptimisticPrepareCommand, visitPrepareCommand, visitRollbackCommand
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

regionManager

protected RegionManager regionManager
Constructor Detail

EvictionInterceptor

public EvictionInterceptor()
Method Detail

initialize

public void initialize(DataContainer dataContainer)

visitEvictFqnCommand

public Object visitEvictFqnCommand(InvocationContext ctx,
                                   EvictCommand command)
                            throws Throwable
Description copied from interface: Visitor
Visits a EvictCommand.

Specified by:
visitEvictFqnCommand in interface Visitor
Overrides:
visitEvictFqnCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitPutForExternalReadCommand

public Object visitPutForExternalReadCommand(InvocationContext ctx,
                                             PutForExternalReadCommand command)
                                      throws Throwable
Description copied from interface: Visitor
Visits a PutForExternalReadCommand.

Specified by:
visitPutForExternalReadCommand in interface Visitor
Overrides:
visitPutForExternalReadCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitPutKeyValueCommand

public Object visitPutKeyValueCommand(InvocationContext ctx,
                                      PutKeyValueCommand command)
                               throws Throwable
Description copied from interface: Visitor
Visits a PutKeyValueCommand.

Specified by:
visitPutKeyValueCommand in interface Visitor
Overrides:
visitPutKeyValueCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitPutDataMapCommand

public Object visitPutDataMapCommand(InvocationContext ctx,
                                     PutDataMapCommand command)
                              throws Throwable
Description copied from interface: Visitor
Visits a PutDataMapCommand.

Specified by:
visitPutDataMapCommand in interface Visitor
Overrides:
visitPutDataMapCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitRemoveKeyCommand

public Object visitRemoveKeyCommand(InvocationContext ctx,
                                    RemoveKeyCommand command)
                             throws Throwable
Description copied from interface: Visitor
Visits a RemoveKeyCommand.

Specified by:
visitRemoveKeyCommand in interface Visitor
Overrides:
visitRemoveKeyCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitGetNodeCommand

public Object visitGetNodeCommand(InvocationContext ctx,
                                  GetNodeCommand command)
                           throws Throwable
Description copied from interface: Visitor
Visits a GetNodeCommand.

Specified by:
visitGetNodeCommand in interface Visitor
Overrides:
visitGetNodeCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitGetDataMapCommand

public Object visitGetDataMapCommand(InvocationContext ctx,
                                     GetDataMapCommand command)
                              throws Throwable
Description copied from interface: Visitor
Visits a GetDataMapCommand.

Specified by:
visitGetDataMapCommand in interface Visitor
Overrides:
visitGetDataMapCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitGetKeyValueCommand

public Object visitGetKeyValueCommand(InvocationContext ctx,
                                      GetKeyValueCommand command)
                               throws Throwable
Description copied from interface: Visitor
Visits a GetKeyValueCommand.

Specified by:
visitGetKeyValueCommand in interface Visitor
Overrides:
visitGetKeyValueCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitRemoveNodeCommand

public Object visitRemoveNodeCommand(InvocationContext ctx,
                                     RemoveNodeCommand command)
                              throws Throwable
Description copied from interface: Visitor
Visits a RemoveNodeCommand.

Specified by:
visitRemoveNodeCommand in interface Visitor
Overrides:
visitRemoveNodeCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

visitClearDataCommand

public Object visitClearDataCommand(InvocationContext ctx,
                                    ClearDataCommand command)
                             throws Throwable
Description copied from interface: Visitor
Visits a RemoveDataCommand.

Specified by:
visitClearDataCommand in interface Visitor
Overrides:
visitClearDataCommand in class AbstractVisitor
Parameters:
ctx - invocation context
command - command to visit
Returns:
response from the visit
Throws:
Throwable - in the event of problems.

getRegion

protected Region getRegion(Fqn fqn)


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