I think we can acheive this by creating private method.
and not call like $self->_method()
Inside module if we call the private method like this:
_method($self,arguments.)
and if we try to call this subroutine outside then this will thorw an error.