¡@

Home 

c# Programming Glossary: caseinfo

Is there a better alternative than this to 'switch on type'?

http://stackoverflow.com/questions/298976/is-there-a-better-alternative-than-this-to-switch-on-type

into your project. static class TypeSwitch public class CaseInfo public bool IsDefault get set public Type Target get set public.. Action get set public static void Do object source params CaseInfo cases var type source.GetType foreach var entry in cases if.. type entry.Action source break public static CaseInfo Case T Action action return new CaseInfo Action x action Target..