coupling too high - settlement category better?
running fxcop code, i warning:
microsoft.maintainability :
'foobar.ctor assimilated 99
opposite forms 9 different
namespaces. rewrite refactor the
slight diminution the category coupling,
cruise relocating slight one
forms tightly
assimilated with. category coupling above
40 indicates bad maintainability, a
category coupling between 40 30
indicates lessen maintainability,
category coupling next 30
indicates good maintainability.
my category ingress section messages server. server send us messages opposite eventargs types:
public foobar()
{
var messagehandlers = new dictionary<type, action<eventargs>>();
messagehandlers.add(typeof(youhavebeenloggedouteventargs), handlesignout);
messagehandlers.add(typeof(testconnectioneventargs), handleconnectiontest);
// ... etc 90 types
}
the "handlesignout" "handleconnectiontest" methods have small formula them; wholly pass work off duty another class.
how i category improved devaluate coupling?
Comments
Post a Comment