H
Hans Ruck
I'm trying to detect the interfaces directly inherited by a class. I've
tried to use the Type.GetInterfaces method but in a situation like
this:
public interface I
{
void f();
}
public interface I2 : I
{
void f2();
new void f();
}
public interface Ii : I, I2
{
new void f();
new void f2();
void f1();
}
public class CC : Ii
{
public void f(){}
public void f1(){}
public void f2(){}
}
the entire interface types' hierarchy would be returned as a list ( Ii
and I instead of Ii ).
Is there any way to detect the relationship between two parent-child
interfaces? Or: is it possible to obtain only the interfaces directly
inherited by a class?
tried to use the Type.GetInterfaces method but in a situation like
this:
public interface I
{
void f();
}
public interface I2 : I
{
void f2();
new void f();
}
public interface Ii : I, I2
{
new void f();
new void f2();
void f1();
}
public class CC : Ii
{
public void f(){}
public void f1(){}
public void f2(){}
}
the entire interface types' hierarchy would be returned as a list ( Ii
and I instead of Ii ).
Is there any way to detect the relationship between two parent-child
interfaces? Or: is it possible to obtain only the interfaces directly
inherited by a class?