org.alfresco.repo.action
Class AbstractAsynchronousActionFilter

java.lang.Object
  extended by org.alfresco.repo.action.AbstractAsynchronousActionFilter
All Implemented Interfaces:
java.util.Comparator
Direct Known Subclasses:
ActionServiceImplTest.SleepActionFilter, CreateThumbnailActionFilter

public abstract class AbstractAsynchronousActionFilter
extends java.lang.Object
implements java.util.Comparator

This class is the base filter class for asynchronous actions. These filters are used in identifying 'equivalent' actions in the asynchronous action execution service. By registering a subclass of this type, all actions of a given action-definition-name that are still pending (i.e. currently executing or in the queue awaiting execution) will be compared to any new action and if they are equal (as determined by the compare implementation defined herein) the newly submitted action will not be added to the queue and will be dropped. Concrete subclasses can be implemented and then dependency-injected using the spring-bean baseActionFilter as their parent.


Constructor Summary
AbstractAsynchronousActionFilter()
           
 
Method Summary
 java.lang.String getActionDefinitionName()
          Gets the action definition name against which this comparator is registered.
 java.lang.String getName()
          Gets the name of this comparator.
 void init()
           
 void setActionDefinitionName(java.lang.String actionDefinitionName)
           
 void setAsynchronousActionExecutionQueue(AsynchronousActionExecutionQueueImpl asynchronousActionExecutionQueue)
           
 void setName(java.lang.String name)
          Sets the name of this comparator.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
compare, equals
 

Constructor Detail

AbstractAsynchronousActionFilter

public AbstractAsynchronousActionFilter()
Method Detail

getName

public java.lang.String getName()
Gets the name of this comparator.

Returns:

setName

public void setName(java.lang.String name)
Sets the name of this comparator.

Parameters:
name -

getActionDefinitionName

public java.lang.String getActionDefinitionName()
Gets the action definition name against which this comparator is registered.

Returns:

setActionDefinitionName

public void setActionDefinitionName(java.lang.String actionDefinitionName)

setAsynchronousActionExecutionQueue

public void setAsynchronousActionExecutionQueue(AsynchronousActionExecutionQueueImpl asynchronousActionExecutionQueue)

init

public void init()


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.