in reply to Getting methods existing in a Perl Object!

Class::Can?
use Class::Can; use Data::Dumper; my %methods = Class::Can->interrogate( ref $bah ); print Dumper(\%methods);
$VAR1 = {
          'printBah' => 'Bah',
          'new' => 'Bah',
          'toString' => 'Object'
        };

updated with example