Click here to Skip to main content

Design and Architecture

 
GeneralRe: Website design help Pinmemberdschumann13-Sep-11 16:20 
QuestionNeed help understanding how to initiate a Power OFF seq from BIos PinmemberMember 390671822-Aug-11 16:10 
AnswerRe: Need help understanding how to initiate a Power OFF seq from BIos PinmemberEddy Vluggen25-Aug-11 14:10 
QuestionGood programming practice Pinmembertamasu19-Aug-11 8:57 
AnswerRe: Good programming practice Pinmemberjschell21-Aug-11 12:03 
QuestionDesign and Architecture is it a secret ?? why people keep hiding ?? Pinmembercapsulez17-Aug-11 14:08 
AnswerRe: Design and Architecture is it a secret ?? why people keep hiding ?? Pinmemberjschell18-Aug-11 13:54 
QuestionIt's mediators all the way down. PinmemberLeslie Sanford10-Aug-11 5:48 
I've been re-reading Arthur J. Riel's classic "Object-Oriented Design Heuristics."
 
One thing that I've found striking on this re-reading is how much Riel emphasizes the use of the mediator design pattern (though he doesn't refer to it as such). Specifically, it's heuristic 4.14:
 
"Objects which share lexical scope, should not have uses relationships between them."
 
What this means, basically, is that objects that exist at the same level of abstraction shouldn't be communicating with each other. Rather, they should be communicating with an object at a higher level of abstract which in turn takes the appropriate action and communicates any necessary info to the other objects at the lower level of abstraction, in other words, the mediator pattern.
 
(as an aside this heuristic conflicts somewhat with heuristic 4.13. Riel addresses this by suggesting the use of abstract classes, i.e. interfaces, as a means through which children communicate with their parents)
 
There are at least a couple of reasons for this heuristic. One, it promotes decoupling and reuse. If the objects at the same level of abstraction don't know about each other, they're more likely to be reuseable. Two, it lowers complexity. Instead of a many-to-many relationship between objects, you have a one-to-many, i.e. the mediator has a one-to-many relationship with its child objects. One-to-many relationships are easier to reason about and understand.
 
Following this heuristic, you can wind up with a layered approach in which each layer is made up of mediators. The child objects are in turn mediators to their child objects, and so on.
 
I like this idea in that it seems to strike a balance between a hyper object oriented approach in which objects are tangled together in a complex many-to-many web of connections and a strictly procedural approach in which nothing is connected. I'd never thought of mediator in this light before.
AnswerRe: It's mediators all the way down. PinprotectorPete O'Hanlon10-Aug-11 5:53 
AnswerRe: It's mediators all the way down. Pinmemberjschell10-Aug-11 10:59 
QuestionGeneral Architecture query - SSIS / XML / BizTalk [modified] Pinmemberbgallagher_lib2-Aug-11 23:18 
AnswerRe: General Architecture query - SSIS / XML / BizTalk Pinmemberjschell3-Aug-11 11:16 
GeneralRe: General Architecture query - SSIS / XML / BizTalk Pinmemberbgallagher_lib4-Aug-11 2:22 
GeneralRe: General Architecture query - SSIS / XML / BizTalk Pinmemberjschell4-Aug-11 9:16 
AnswerRe: General Architecture query - SSIS / XML / BizTalk PinmemberMycroft Holmes4-Aug-11 4:05 
GeneralRe: General Architecture query - SSIS / XML / BizTalk Pinmemberbgallagher_lib4-Aug-11 4:37 
GeneralRe: General Architecture query - SSIS / XML / BizTalk PinmemberS Douglas25-Aug-11 16:28 
QuestionMaster / Detail Datasource design quesiton PinmemberDavid Mujica12-Jul-11 11:47 
AnswerRe: Master / Detail Datasource design quesiton Pinmemberjschell12-Jul-11 11:56 
GeneralRe: Master / Detail Datasource design quesiton PinmemberDavid Mujica13-Jul-11 4:29 
GeneralRe: Master / Detail Datasource design quesiton Pinmemberjschell13-Jul-11 10:00 
GeneralRe: Master / Detail Datasource design quesiton PinmemberMycroft Holmes4-Aug-11 4:13 
GeneralRe: Master / Detail Datasource design quesiton Pinmembermay esguerra22-Aug-11 6:34 
AnswerRe: Master / Detail Datasource design quesiton PinmemberNagy Vilmos2-Aug-11 23:41 
GeneralThank you PinmemberDavid Mujica3-Aug-11 6:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web02 | 2.8.150327.1 | Last Updated 27 Mar 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid