Hi,
My problem is as following:
Class TA
{
public:
double value;
}
Class TA a;
Is there any method like a.GetMethod(“value”), in which way we can get the member value using a string.
Thank you very much
Hi,
In which context/for what purpose do you need this?
If is sufficient to get the result as a long you can uselong res = gROOT->ProcessLineFast("a.value");
. If you need a double you could try:double result;
gROOT->ProcessLine(TString::Format("*(double*)0x%x = a.%s;",&result,"value"));
Cheers,
Philippe.