The Artima Developer Community
Sponsored Link

Java Buzz Forum
Explaining why Dependency Injection is good

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
dion

Posts: 5028
Nickname: dion
Registered: Feb, 2003

Dion Almaer is the Editor-in-Chief for TheServerSide.com, and is an enterprise Java evangelist
Explaining why Dependency Injection is good Posted: Aug 16, 2004 12:42 PM
Reply to this message Reply

This post originated from an RSS feed registered with Java Buzz by dion.
Original Post: Explaining why Dependency Injection is good
Feed Title: techno.blog(Dion)
Feed URL: http://feeds.feedburner.com/dion
Feed Description: blogging about life the universe and everything tech
Latest Java Buzz Posts
Latest Java Buzz Posts by dion
Latest Posts From techno.blog(Dion)

Advertisement
Rickard has done a really good job and explaining why DI is good. In a very simple, scientific way, he details the simpliest of examples (Foo depending on Bar), and shows how the properties of different designs affect your agility. I really like how he explains these properties: This code has the following properties: Bar can be a class, an abstract class, or an interface Foo does not need to know how Bar is instantiated The Bar instance can be used by other components Bar can have any configuration needs The user of Foo needs to know how to provide a Bar Many people know that they enjoy moving to this model when designing their code, but don't know how to explain why they like it so much. On one hand people say "it is just a constructor / setter / ...".

Read: Explaining why Dependency Injection is good

Topic: [Aug 6, 2004 03:40 PDT] 2 Links Previous Topic   Next Topic Topic: October 19th, 2004

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use