CSharp examples for Custom Type:is
The is operator tests whether an object derives from a specified class or implements an interface.
It is often used to test before downcasting:
if (a is Stock) Console.WriteLine (((Stock)a).SharesOwned);