BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Spring.NET QnA with Aleks Seovic and Mark Pollack

Spring.NET QnA with Aleks Seovic and Mark Pollack

Bookmarks

InfoQ had a chance to sit down with Aleksandar Seovic and Mark Pollack the co-creaters of Spring.NET.  Spring.NET is an application framework that brings AOP, a Dependency Injection container and data access framework to .NET.  It is not a complete port of Spring to .NET, yet it preserves the main tenets of Spring.

Aleks shares this thought on the need for Dependency Injection in .NET:

"Dependency Injection implies that an object's dependencies will be "injected" by external means. There is no need for an object to look up anything - it simply declares private fields for its dependencies and allows for them to be provided externally, either via a constructor argument or via a property setter. This makes objects very clean and reusable, and if dependencies are declared in terms of interfaces instead of specific classes, it also makes them very easy to unit test."

 Mark talks about where a developer might choose Spring.NET's data access framework on top of  ADO.NET:

"Spring.NET's Data Access Framework (Spring.Data) provides lots of added value above ‘plain' ADO.NET. One of the key components is a transaction management abstraction that allows you to easily switch between different transaction strategies, i.e plain old local ADO.NET, EnterpriseServices distributed transactions and the new System.Transaction namespace. All the strategies can be used to perform declarative transaction demarcation either via embedded attributes or non-invasive XML configuration. Our extensions to the ADO.NET framework make most ADO.NET operations a one-liner and take care of the connection/transaction resource handling - which would otherwise still require some extra work on the part of the developer in common scenarios, even with the new System.Transactions namespace."

The bottom line is Spring.NET allows developers familiar with Spring or Dependency Injection to become very productive in .NET quickly by capitalizing on a framework they are familiar with. 

Rate this Article

Adoption
Style

BT