I created and generic interface and a class implements this interface twice.
public class MyClass: IMyInterface<Class1>, IMyInterface <Class2> { List<Class1> IMyInterface<Class1>.MyMethod() { throw new NotImplementedException(); } List<Class2> IMyInterface<Class2>.MyMethod() { throw new NotImplementedException(); } }
This works fine so far.
Now I am getting stuck when try to call one of the Methods. I tried:
MyClass myobject = new MyClass(); myobject.MyInterace<Class2>.MyMethod()
But this give a compiler error. Any idea?