public virtual class parent {
public static void doStuff(){system.debug('stuff');}
}
public class child extends parent{}
When I call
child.doStuff();
I get this error: Method does not exist or incorrect signature: child.doStuff()
Are static methods not inherited in salesforce or am I doing something wrong?
Apex is consistent with Java on this. Statics are not inherited.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With