Hello,
I have a class TableData with two magic methods. One is the constructor and the other is the __call method.
I have realized the invoke with following code:
$class = new ReflectionClass('TableData');
$class->newInstanceArgs($parArray);
It work great. But now I want to use my magic method. So I call $class->getData()
, but it doesn't work. I get the error, that I called an undefined method.
I tried to use ReflectionMethod and invoke, but it doesn't work again.
Is there no way to cast the ReflectionClass Object to my TableData class?
Thanks for advice!