generic and inheritance - C#