简体   繁体   中英

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.

您可以使用Reflector分析类使用的所有内容(右键单击类,单击“分析”,展开“取决于”)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM