i am learning using Spring 4 by Java annotations, and i could not find how to set default init-method to all beans that belongs to specific configuration, without adding the @PostContruct annotation to initialize method at all clases and neither making them implement the InitializeBean interface... I just want to do something like this:
<beans default-init-method="init">
<bean id="blogService" class="com.foo.DefaultBlogService">
</bean>
<bean id="anotherBean" class="com.foo.AnotherBean">
</bean>
</beans>
So, i want to do exactly this by Java annotations, i want to set default beans configurations on bean's configuration container. Is that possible? Regards
Aucun commentaire:
Enregistrer un commentaire