Coding
cast operator and how to use them efficently
So, previously I did that if (instance is typeA) return (instance as typeA).CustomProperty; if (instance is TypeB) return (instance as TypeB).CustomProperty; if (instance is TypeC) return (instance as TypeC).CustomProperty; But with newer c#, we can Read more…