vendredi 25 août 2023

Get implementer class type

I have the below code

public abstract class abstract1
{
    public void Test1()
    {
        // Do something
    }
}

public class class1 : abstract1
{
}

public class Class1Test
{
    public void InvokeTest1()
    {
        Class1 c1 = new Class1();
        c1.Test1();
    }
}

How can I get that Test1 method invoked from Class1 then abstract1 for logging purposes?

Thanks,





Aucun commentaire:

Enregistrer un commentaire