Getting method metadata from within the

  • Thread starter Thread starter Yuvraj Sujan
  • Start date Start date
Y

Yuvraj Sujan

Is there a generic way of getting the method metadata from within the
method itself e.g. consider a method

void knowThyself(string someParam_in )
{
//want to know the information about knowThyself here in a generic
way e.g.
allknowing.printCurrentMethodInfo(); // this would print out the
//method metadata like parameters, attributes, name etc.
}

Thanks in advance,
Peace,
Yuvraj.
 
Yuvraj,

Is there a generic way of getting the method metadata from within the
method itself

System.Reflection.MethodBase.GetCurrentMethod()



Mattias
 
Back
Top