I was looking for a good way to fill up my business objects.
I came up with the following architecture..
First I create a stored procedure in SQL Server Management Studio.

After that I drag and drop the stored procedure from the Visual Studio server explorer to my Linq datamodel.

Then I create my business object.. A class with the name Catalogus.

Then I create a static method in my class Catalog
i. This piece of code shows you how I did the filling.

I think this architecture is pretty clean and has a lot of advantages:
- Use of stored procedures: Database abstraction and query directly against the database with a great IDE (SQL Server Management Studio).
- Multiple layers: This helps you to gain a better level of abstraction. You can decouple the layers for other purposes.
- Debugging: Being able to step through each layer will make life easier.
- Mapping: You can implement the result of the stored procedures with your own custom mapping. Another developer could easily reuse the datamodel and map it to it's own business objects (which wouldn't be good though).
What is
your opinion on this architecture?