protected Statement generateFactoryHandleStatement(final Injectable injectable) {
final Statement newObject;
if (injectable.getInjectedType().isAnnotationPresent(ActivatedBy.class)) {
final Class<? extends BeanActivator> activatorType = injectable.getInjectedType().getAnnotation(ActivatedBy.class).value();
newObject = newObject(FactoryHandleImpl.class, loadLiteral(injectable.getInjectedType()),
injectable.getFactoryName(), injectable.getScope(), isEager(injectable.getInjectedType()),
injectable.getBeanName(), !injectable.isContextual(), loadLiteral(activatorType));
} else {
newObject = newObject(FactoryHandleImpl.class, loadLiteral(injectable.getInjectedType()),
injectable.getFactoryName(), injectable.getScope(), isEager(injectable.getInjectedType()),
injectable.getBeanName(), !injectable.isContextual());
}
return newObject;
}