public abstract class BaseProcessor<U,T> extends Object implements org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.BeanFactoryAware, Processor<U,T>, org.springframework.context.ApplicationListener<org.springframework.context.event.ContextRefreshedEvent>
ActivitiesActivity| Modifier and Type | Field and Description |
|---|---|
protected List<Activity<ProcessContext<U>>> |
activities |
protected boolean |
allowEmptyActivities
If set to true, this will allow an empty set of activities, thus creating a 'do-nothing' workflow
|
protected org.springframework.beans.factory.BeanFactory |
beanFactory |
protected String |
beanName |
protected ErrorHandler |
defaultErrorHandler |
protected List<ModuleActivity> |
moduleActivities |
protected SupportLogger |
supportLogger |
| Constructor and Description |
|---|
BaseProcessor() |
| Modifier and Type | Method and Description |
|---|---|
List<Activity<ProcessContext<U>>> |
getActivities() |
boolean |
getAutoRollbackOnError()
Whether or not the ActivityStateManager should automatically attempt to rollback any RollbackHandlers registered.
|
protected String |
getBeanDesc()
Returns the bean description if the current bean factory allows it.
|
org.springframework.beans.factory.BeanFactory |
getBeanFactory() |
String |
getBeanName() |
ErrorHandler |
getDefaultErrorHandler() |
List<ModuleActivity> |
getModuleActivities()
Returns a filtered set of
getActivities() that have implemented the ModuleActivity interface. |
boolean |
isAllowEmptyActivities()
Defaults to 'false'.
|
void |
onApplicationEvent(org.springframework.context.event.ContextRefreshedEvent event)
Ensures the the list of activities is properly merged and sorted after all activities have been initialized
|
void |
setActivities(List<Activity<ProcessContext<U>>> activities)
Sets the collection of Activities to be executed by the Workflow Process
|
void |
setAllowEmptyActivities(boolean allowEmptyActivities) |
void |
setAutoRollbackOnError(boolean autoRollbackOnError)
Set whether or not the ActivityStateManager should automatically attempt to rollback any RollbackHandlers registered.
|
void |
setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
Sets the spring bean factroy bean that is responsible for this processor.
|
void |
setBeanName(String beanName)
Sets name of the spring bean in the application context that this
processor is configured under
|
void |
setDefaultErrorHandler(ErrorHandler defaultErrorHandler) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdoActivities, doActivities, setProcessContextFactory, supportsprotected org.springframework.beans.factory.BeanFactory beanFactory
protected String beanName
protected List<Activity<ProcessContext<U>>> activities
protected List<ModuleActivity> moduleActivities
protected ErrorHandler defaultErrorHandler
protected boolean allowEmptyActivities
protected SupportLogger supportLogger
public void setBeanName(String beanName)
setBeanName in interface org.springframework.beans.factory.BeanNameAwareBeanNameAware.setBeanName(java.lang.String)public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory)
throws org.springframework.beans.BeansException
setBeanFactory in interface org.springframework.beans.factory.BeanFactoryAwareorg.springframework.beans.BeansExceptionBeanFactoryAware.setBeanFactory(org.springframework.beans.factory.BeanFactory)public boolean getAutoRollbackOnError()
public void setAutoRollbackOnError(boolean autoRollbackOnError)
autoRollbackOnError - Whether or not the ActivityStateManager should automatically attempt to rollbackpublic boolean isAllowEmptyActivities()
public void setAllowEmptyActivities(boolean allowEmptyActivities)
allowEmptyActivities - the allowEmptyActivities to setpublic void onApplicationEvent(org.springframework.context.event.ContextRefreshedEvent event)
onApplicationEvent in interface org.springframework.context.ApplicationListener<org.springframework.context.event.ContextRefreshedEvent>protected String getBeanDesc()
public void setActivities(List<Activity<ProcessContext<U>>> activities)
setActivities in interface Processor<U,T>activities - ordered collection (List) of activities to be executed by the processorpublic void setDefaultErrorHandler(ErrorHandler defaultErrorHandler)
setDefaultErrorHandler in interface Processor<U,T>public List<Activity<ProcessContext<U>>> getActivities()
public List<ModuleActivity> getModuleActivities()
getActivities() that have implemented the ModuleActivity interface. This
set of module activities is only set once during #afterPropertiesSet(), so if you invoke
setActivities(List) after the bean has been initialized you will need to manually reset the list of module
activities as well (which could be achieved by manually invoking #afterPropertiesSet()).public String getBeanName()
public ErrorHandler getDefaultErrorHandler()
public org.springframework.beans.factory.BeanFactory getBeanFactory()
Copyright © 2025. All rights reserved.