|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.camel.impl.CamelPostProcessorHelper
public class CamelPostProcessorHelper
A helper class for Camel based injector or post processing hooks which can be reused by both the Spring, Guice and Blueprint support.
Constructor Summary | |
---|---|
CamelPostProcessorHelper()
|
|
CamelPostProcessorHelper(CamelContext camelContext)
|
Method Summary | |
---|---|
void |
consumerInjection(Method method,
Object bean,
String beanName)
|
protected Processor |
createConsumerProcessor(Object pojo,
Method method,
Endpoint endpoint)
Create a processor which invokes the given method when an incoming message exchange is received |
protected ConsumerTemplate |
createInjectionConsumerTemplate(String endpointUri,
String endpointRef,
String endpointProperty,
String injectionPointName)
Factory method to create a ConsumerTemplate to be injected into a POJO |
protected PollingConsumer |
createInjectionPollingConsumer(Endpoint endpoint,
Object bean,
String beanName)
Factory method to create a started PollingConsumer to be injected into a POJO |
protected Producer |
createInjectionProducer(Endpoint endpoint,
Object bean,
String beanName)
A Factory method to create a started Producer to be injected into a POJO |
protected ProducerTemplate |
createInjectionProducerTemplate(String endpointUri,
String endpointRef,
String endpointProperty,
String injectionPointName,
Object bean)
Factory method to create a ProducerTemplate to be injected into a POJO |
protected RuntimeException |
createProxyInstantiationRuntimeException(Class<?> type,
Endpoint endpoint,
Exception e)
|
CamelContext |
getCamelContext()
Get the CamelContext |
Endpoint |
getEndpointInjection(Object bean,
String uri,
String name,
String propertyName,
String injectionPointName,
boolean mandatory)
|
Object |
getInjectionPropertyValue(Class<?> type,
String propertyName,
String propertyDefaultValue,
String injectionPointName,
Object bean,
String beanName)
|
Object |
getInjectionValue(Class<?> type,
String endpointUri,
String endpointRef,
String endpointProperty,
String injectionPointName,
Object bean,
String beanName)
Creates the object to be injected for an EndpointInject or Produce injection point |
protected boolean |
isSingleton(Object bean,
String beanName)
Implementations can override this method to determine if the bean is singleton. |
boolean |
matchContext(String context)
Does the given context match this camel context |
void |
setCamelContext(CamelContext camelContext)
Injects the CamelContext |
protected void |
startService(Service service,
Object bean,
String beanName)
Stats the given service |
void |
subscribeMethod(Method method,
Object bean,
String beanName,
String endpointUri,
String endpointName,
String endpointProperty)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CamelPostProcessorHelper()
public CamelPostProcessorHelper(CamelContext camelContext)
Method Detail |
---|
public CamelContext getCamelContext()
CamelContextAware
CamelContext
getCamelContext
in interface CamelContextAware
public void setCamelContext(CamelContext camelContext)
CamelContextAware
CamelContext
setCamelContext
in interface CamelContextAware
camelContext
- the Camel contextpublic boolean matchContext(String context)
public void consumerInjection(Method method, Object bean, String beanName)
public void subscribeMethod(Method method, Object bean, String beanName, String endpointUri, String endpointName, String endpointProperty)
protected void startService(Service service, Object bean, String beanName) throws Exception
Exception
protected Processor createConsumerProcessor(Object pojo, Method method, Endpoint endpoint)
public Endpoint getEndpointInjection(Object bean, String uri, String name, String propertyName, String injectionPointName, boolean mandatory)
public Object getInjectionValue(Class<?> type, String endpointUri, String endpointRef, String endpointProperty, String injectionPointName, Object bean, String beanName)
EndpointInject
or Produce
injection point
public Object getInjectionPropertyValue(Class<?> type, String propertyName, String propertyDefaultValue, String injectionPointName, Object bean, String beanName)
protected ProducerTemplate createInjectionProducerTemplate(String endpointUri, String endpointRef, String endpointProperty, String injectionPointName, Object bean)
ProducerTemplate
to be injected into a POJO
protected ConsumerTemplate createInjectionConsumerTemplate(String endpointUri, String endpointRef, String endpointProperty, String injectionPointName)
ConsumerTemplate
to be injected into a POJO
protected PollingConsumer createInjectionPollingConsumer(Endpoint endpoint, Object bean, String beanName)
PollingConsumer
to be injected into a POJO
protected Producer createInjectionProducer(Endpoint endpoint, Object bean, String beanName)
Producer
to be injected into a POJO
protected RuntimeException createProxyInstantiationRuntimeException(Class<?> type, Endpoint endpoint, Exception e)
protected boolean isSingleton(Object bean, String beanName)
bean
- the bean
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |