How to override method with derived return type in C#?
I want to override a virtual method with a derived class type. What's the current best way to do this? So far I've found two approaches: Use an abstract base class for each derived type; bridge with protected methods. Use a protected implementation with a public accessor. Base case (no solution implemented, Clone always returns base type A1 ): public class A1 { public int X1 { get; set; } public A1(int x1) { this.X1 = x1; } public virtual A1 Clone() { return new A1(X1); } } public class A2 : A1 { public int X2 { get; set; } public A2(int x1, int x2) : base(x1) { this.X2 = x2; } public override