bean

Get parent bean in prototype bean that gets injected

Hi, I would like to have a Bean and a SubBean like this: @Scope(BeanDefinition.SCOPE_PROTOTYPE) @Component public class SubBean implements ApplicationContextAware{ private Object parent; public void setApplicationContext(ApplicationContext ctx){ this.parent = doSomeMagicToGetMyParent(ctx); } public Object getParent(){ ...