You need to sign in to do that
Don't have an account?
Darshit Pathak 10
Why multiple classes cannot be inherited apex?
As java provides multiple inheritance, so that class can inherit properties and methods of 2 different parent classes. But apex doesn't support that. Can anyone tell the conecpt/reason behind this?
Apex syntax is mostly based on Java and it does not allow multiple inheritance. Salesforce allows multiple interface implementation and to inherit any class it must be defined with keyword Virtual.
Something like below:
Hope above information was helpful.
Please mark as Best Answer so that it can help others in the future.
Thanks,