Repeat for each method you don't want to inherit.package ChildClass; use ParentClass; our @ISA = qw[ChildClass]; sub risky_method1 {die "You're not allowed to call this"} sub risky_method2 {die "You're not allowed to call this either"}
In reply to Re: Inherit only few methods from a parent class
by JavaFan
in thread Inherit only few methods from a parent class
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |