The Artima Developer Community
Sponsored Link

.NET Buzz Forum
Decoupling layers - upside down

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
Udi Dahan

Posts: 882
Nickname: udidahan
Registered: Nov, 2003

Udi Dahan is The Software Simplist
Decoupling layers - upside down Posted: Jun 10, 2005 3:51 PM
Reply to this message Reply

This post originated from an RSS feed registered with .NET Buzz by Udi Dahan.
Original Post: Decoupling layers - upside down
Feed Title: Udi Dahan - The Software Simplist
Feed URL: http://feeds.feedburner.com/UdiDahan-TheSoftwareSimplist
Feed Description: I am a software simplist. I make this beast of architecting, analysing, designing, developing, testing, managing, deploying software systems simple. This blog is about how I do it.
Latest .NET Buzz Posts
Latest .NET Buzz Posts by Udi Dahan
Latest Posts From Udi Dahan - The Software Simplist

Advertisement
Every once in a while I run into a question about how code from a "lower layer" can call code in an "upper layer". This comes up a lot around the DDD groups where you see people trying to work around the idea that repositories are above entities when they want/need an entity to call into a repository. Same thing in data access.
Why is it not yet obvious that events (in .net) are the solution?
Just have your "lower layer" objects expose events for what they need from "upper layers" and have objects there register for those events. In the event-handling methods the calls can be made between objects on the upper layer finally returning the result back to the lower layer. As an aside, a lot of people aren't used to the fact that raising an event can return something - it really is quite useful.

Read: Decoupling layers - upside down

Topic: Understanding Microsoft's Integration Technologies (whitepaper) Previous Topic   Next Topic Topic: TechEd 2005: Visual Studio Team Edition for Architects

Sponsored Links



Google
  Web Artima.com   

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