When there is inheritance we can do this:
class Demo
{
public function doStuff(Form $form, Request $request)
{
parent::doStuff($form, $request);
}
}
Is there a way to inject these same parameter in a funciton that is not a parent, ie:
//...
MyRandomClass::doStuff($form, $request);
//...
If yes, what is the synthax?
Cheers
will just work (assuming MyRandomClass has been included/required in the context of this line) if the function doStuff() is defined as “public static”.