cp = componentProcessorMap.get(c);
if (cp != null) {
return (cp == NULL_COMPONENT_PROCESSOR) ? null : cp;
}
final ResourceComponentInjector rci = Errors.processWithErrors(new Errors.Closure<ResourceComponentInjector>() {
@Override
public ResourceComponentInjector f() {
return new ResourceComponentInjector(
injectableFactory, scope, getAbstractResource(c));
}
});
if (rci.hasInjectableArtifacts()) {
cp = new ComponentProcessorImpl(rci);
componentProcessorMap.put(c, cp);
} else {
cp = null;
componentProcessorMap.put(c, NULL_COMPONENT_PROCESSOR);