injectFields(bean, beanName);
injectMethods(bean, beanName);
if (bean instanceof CamelContextAware && canSetCamelContext(bean, beanName)) {
CamelContextAware contextAware = (CamelContextAware)bean;
CamelContext context = getOrLookupCamelContext();
if (context == null) {
LOG.warn("No CamelContext defined yet so cannot inject into bean: " + beanName);
} else {
contextAware.setCamelContext(context);
}
}
return bean;
}