Saturday, February 23, 2008

More IoC - A Castle Windsor and Unity Application Block Comparison

Matthew Podwysocki's Blog - IoC and the Unity Application Block - Going Deeper

"I thought after my recent F# post, I'd get back to the Unity post that was halfway done before the firestorm began...

In a previous post, I showed how easy it was to create a basic application using the Unity Application Block. I'm always finding new ways to solve my problems and new tools to do it.  Since Inversion of Control (IoC) containers are near and dear to my heart, I thought I'd investigate to see whether it meets my needs or not.  It's something you need to determine on your own, whether it works for you.  Some like Spring.NET, others StructureMap, Castle Windsor and so on.

...

Compare/Contrast with Windsor

Anyhow, today I will focus on a little compare/contrast with Castle Windsor just to show the different styles used.  I'm not going to say one is better than the other, because quite frankly, that's up to you to decide...  I want to thank Dustin Campbell for his help in getting a better code formatter via this post here.

..."

More IoC (Inversion of Control) reading material.

Also I believe this is my first reference to the very recently released Unity Application Block (a "lightweight extensible dependency injection container with support for constructor, property, and method call injection").

 

Related Past Post XRef:
Getting to know IoC (Inversion of Control) Container
Take a Lunch Break with Windsor IoC Container (part of the Castle Project)

1 comment:

Anonymous said...

I use my config with Windsor to set default values, etc...

I haven't been able to see how to do this with Unity.

I also don't really like to see attributes used - I don't want this in my domain objects