I read Eric Evans' amazing work on Domain Management. However, I cannot help but feel that the model of “layers” is contrived. To expand on this statement, it seems that he is trying to teach different concepts in a concrete, neat model, about layers that speak to each other. It seems to me that the layer model is too simplified to actually capture the way the (good) software works.
For further expansion: Evans says:
"Divide the complex program into layers. Design a design in each layer that is cohesive, and it depends only on the layers below. Follow standard architectural templates to ensure free communication with the overlying layers."
Perhaps I don’t understand what “depends” means, but as far as I can see, it can mean: a) Class X (for example, in the user interface) has a link to a specific class Y (in the main application) or b) Class X has a reference to an object of class Y-ish that provides services of class Y-ish (i.e., a link contained as an interface).
If this means (a), then this is certainly bad, since it defeats the reuse of the user interface as an interface before any other application that provides Y-ish functionality. But if that means (b), then how does the user interface depend more on the application than the application depends on the user interface? Both of them are separated from each other as much as they can be, while still talking to each other.
Evans, , .
-, , , , , , /? (.. " " ). , - ( DAO ..) , . , .
-, ( ) - , , , .., ?
- , .
Edit: , , () : " , . , ... , , ,
. , . , , , ! , , , - , -, , , . " ", ? , OBSERVER APP, .
, , SEEM , - , . , .