org.apache.camel.bam.processor
Class BamProcessorSupport<T>
java.lang.Object
org.apache.camel.bam.processor.BamProcessorSupport<T>
- All Implemented Interfaces:
- Processor
- Direct Known Subclasses:
- JpaBamProcessorSupport
public abstract class BamProcessorSupport<T>
- extends Object
- implements Processor
A base Processor for working on BAM which a derived
class would do the actual persistence such as the JpaBamProcessor
- Version:
|
Constructor Summary |
protected |
BamProcessorSupport(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
Expression correlationKeyExpression)
|
protected |
BamProcessorSupport(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
Expression correlationKeyExpression,
Class<T> entitytype)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BamProcessorSupport
protected BamProcessorSupport(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
Expression correlationKeyExpression)
BamProcessorSupport
protected BamProcessorSupport(org.springframework.transaction.support.TransactionTemplate transactionTemplate,
Expression correlationKeyExpression,
Class<T> entitytype)
process
public void process(Exchange exchange)
- Description copied from interface:
Processor
- Processes the message exchange
- Specified by:
process in interface Processor
- Parameters:
exchange - the message exchange
getCorrelationKeyExpression
public Expression getCorrelationKeyExpression()
getEntityType
public Class<T> getEntityType()
processEntity
protected abstract void processEntity(Exchange exchange,
T entity)
throws Exception
- Throws:
Exception
loadEntity
protected abstract T loadEntity(Exchange exchange,
Object key)
throws Exception
- Throws:
Exception
getKeyType
protected abstract Class<?> getKeyType()
getCorrelationKey
protected Object getCorrelationKey(Exchange exchange)
throws NoCorrelationKeyException
- Throws:
NoCorrelationKeyException
onError
protected Object onError(org.springframework.transaction.TransactionStatus status,
Exception e)
Apache CAMEL