Win a copy of Classic Computer Science Problems in Swift this week in the iOS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Q for Dhanji for SealerAdapter DI concept  RSS feed

 
Ranch Hand
Posts: 78
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Mr Dhanji Prasanna,

We are extensively using Spring in our projects and use a lot of Dependency Injections and AOP cross-cutting concern modularization. I would really like to know something about the SealedAdaper class that uses the Inject annotation to inject the dependency, how is it different from the usual DI we perform by reading beans from a xml configuration.

Regards,
DS [SCJP 1.5, SCWCD, SCDJWS]
 
author
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

The SealedAdapter is an alternative to XML configuration. It allows you to do all your configuration in Java code and test and manage your Adapter class directly inside your injector. The idea is to avoid XML configuration at all (by preferring the @Inject from Guice or @Autowired from Spring).

Dhanji.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!