Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Analysing FxCop / Code Analysis warning CA1506: AvoidExcessiveClassCoupling

I'm getting Visual Studio Code Analysis warning CA1506 for a C# class. It says, "'FormMain' is coupled with 93 different (non-IComponent) types from 25 different namespaces. Rewrite or refactor this class's methods to decrease its class coupling, or consider moving some of the class's methods to some of the other types it is tightly coupled with. A class coupling above 95 indicates poor maintainability, a class coupling between 95 and 80 indicates moderate maintainability, and a class coupling below 80 indicates good maintainability."

My question is simply, where can I see a list of all of the types that FormMain is coupled to, so I can understand the situation better?

Thanks.

like image 971
RenniePet Avatar asked Jan 17 '11 15:01

RenniePet


1 Answers

You can use Reflector to analyze everything a class uses (right-click on the class, click 'Analyze', expand 'Depends On')

like image 175
thecoop Avatar answered Oct 24 '22 04:10

thecoop