org.axonframework.contextsupport.spring
Class AbstractSagaManagerBeanDefinitionParser

java.lang.Object
  extended by org.axonframework.contextsupport.spring.AbstractSagaManagerBeanDefinitionParser
Direct Known Subclasses:
AsyncSagaManagerBeanDefinitionParser, SyncSagaManagerBeanDefinitionParser

public abstract class AbstractSagaManagerBeanDefinitionParser
extends Object

Abstract SagaManager parser that parses common properties for all SagaManager implementations.

Since:
2.0
Author:
Allard Buijze

Constructor Summary
AbstractSagaManagerBeanDefinitionParser()
           
 
Method Summary
protected abstract  Class<? extends SagaManager> getBeanClass()
          Returns the type of bean to be created by this BeanDefinitionParser.
protected  org.springframework.beans.factory.support.AbstractBeanDefinition parseInternal(Element element, org.springframework.beans.factory.xml.ParserContext parserContext)
          Parses elements for shared SagaManager logic.
protected  void parseReplayableAttribute(Element element, org.springframework.beans.MutablePropertyValues propertyValues)
          Process the "replayable" setting on the given element.
protected abstract  void parseSuppressExceptionsAttribute(Element element, org.springframework.beans.MutablePropertyValues beanDefinition)
          Process the "suppress-exceptions" setting on the given element.
protected abstract  void registerSagaFactory(Object sagaFactoryDefinition, org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
          Registers the given sagaFactoryDefinition in the given sagaManagerDefinition.
protected abstract  void registerSagaRepository(Object sagaRepositoryDefinition, org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
          Registers the given sagaRepositoryDefinition in the given sagaManagerDefinition.
protected abstract  void registerSpecificProperties(Element element, org.springframework.beans.factory.xml.ParserContext parserContext, org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
          Registers any implementation specific properties found in the given element in the given sagaManagerDefinition.
protected abstract  void registerTypes(String[] types, org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition, org.springframework.beans.factory.config.RuntimeBeanReference parameterResolverFactoryReference)
          Registers the given Saga types in the given sagaManagerDefinition.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractSagaManagerBeanDefinitionParser

public AbstractSagaManagerBeanDefinitionParser()
Method Detail

parseInternal

protected final org.springframework.beans.factory.support.AbstractBeanDefinition parseInternal(Element element,
                                                                                               org.springframework.beans.factory.xml.ParserContext parserContext)
Parses elements for shared SagaManager logic.

Parameters:
element - The xml element containing the Bean Definition
parserContext - The context for the parser
Returns:
a BeanDefinition for the bean defined in the element

getBeanClass

protected abstract Class<? extends SagaManager> getBeanClass()
Returns the type of bean to be created by this BeanDefinitionParser.

Returns:
the type of bean to be created by this BeanDefinitionParser.

registerSagaRepository

protected abstract void registerSagaRepository(Object sagaRepositoryDefinition,
                                               org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
Registers the given sagaRepositoryDefinition in the given sagaManagerDefinition.

Parameters:
sagaRepositoryDefinition - The bean definition of the repository to register
sagaManagerDefinition - The definition of the saga manager to register the repository in.

registerSagaFactory

protected abstract void registerSagaFactory(Object sagaFactoryDefinition,
                                            org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
Registers the given sagaFactoryDefinition in the given sagaManagerDefinition.

Parameters:
sagaFactoryDefinition - The bean definition of the factory to register
sagaManagerDefinition - The definition of the saga manager to register the factory in.

registerTypes

protected abstract void registerTypes(String[] types,
                                      org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition,
                                      org.springframework.beans.factory.config.RuntimeBeanReference parameterResolverFactoryReference)
Registers the given Saga types in the given sagaManagerDefinition.

Parameters:
types - The types of sagas found in the bean definition
sagaManagerDefinition - The definition of the saga manager to register the types in.
parameterResolverFactoryReference - the reference to the ParameterResolverFactory bean

registerSpecificProperties

protected abstract void registerSpecificProperties(Element element,
                                                   org.springframework.beans.factory.xml.ParserContext parserContext,
                                                   org.springframework.beans.factory.support.GenericBeanDefinition sagaManagerDefinition)
Registers any implementation specific properties found in the given element in the given sagaManagerDefinition. The purpose of this method is to allow different elements to contain properties specific to that type of implementation.

Parameters:
element - The custom namespace element to parse
parserContext - The object encapsulating the current state of the parsing process; provides access to a BeanDefinitionRegistry
sagaManagerDefinition - The definition of the saga manager to register the custom properties in.

parseSuppressExceptionsAttribute

protected abstract void parseSuppressExceptionsAttribute(Element element,
                                                         org.springframework.beans.MutablePropertyValues beanDefinition)
Process the "suppress-exceptions" setting on the given element.

Parameters:
element - The element representing the saga manager's bean definition
beanDefinition - The bean definition of the Saga Manager

parseReplayableAttribute

protected void parseReplayableAttribute(Element element,
                                        org.springframework.beans.MutablePropertyValues propertyValues)
Process the "replayable" setting on the given element.

Parameters:
element - The element representing the saga manager's bean definition
propertyValues - The bean definition of the Saga Manager


Copyright © 2010-2016. All Rights Reserved.