Law of Demeter is easy to spot when you need extra mocks(richarddingwall.name)
submitted by
rdingwall(323) 2 years, 8 months ago
In this example, DoSomething() knows intimate details about what an IFoo’s insides look like. This is bad because it’s additional coupling that will bog us down later — if we ever want to change the internal composition of IFoo, we will have to also update all pervert methods like DoSomething() that depend on it.
|category: Architecture
|Views: 10
tags:
Architecture another
Everyones tags:
Your Tags: