Reputation: 183
Suppose I have a parent class A
and a daughter class B
. Now A
has 10 methods in it and B requires only three of those methods. How can this be done?
Upvotes: 0
Views: 51
Reputation: 423
There is nothing special to do.
Just inherit class A
:
class B(A):
super(B, self).__init__():
Use/override the methods you need and ignore the rest.
Upvotes: 1