Law of Demeter in MVC regarding Controller-View communication
- by Antonio MG
The scenario: Having a Controller that controls a view composed of complex subviews.
Each one of those subviews is a separated class in a separate file. For example, one of those subviews is called ButtonsView, and has a bunch of buttons.
The Controller has to access those buttons.
Would accessing those buttons like this:
…