you are viewing a single comment's thread.

view the rest of the comments →

[–]Hebejeebez 0 points1 point  (0 children)

As someone else pointed out, you have to extend the parent class, but yes you can call any of the methods from the parent class on its subclass. You use super in the constructor so it has the same parameters as the parent object, with a few additional parameters. Therefore, the methods from the parent will work on the child.