7 # CC This lib path is unnecessary - commented out as supercedes the 'lib' use in jpred itself.
8 #use lib qw(/homes/jon/cvs/jon/jpred/src /homes/jon/usr/lib/perl5);
12 Root - Base module for new classes to inherit from
16 This modules provides a new method for other classes to use if they so wish.
20 =head2 new(foo => "bar")
22 This constructs an object of the right class and returns it. Any arugments passed to the constructer will be parsed as a hash with the first argument from the pair acting as the method that should be called and the second being the argument for that method.
27 my ($class, %args) = @_;
28 my $self = bless {}, ref($class) || $class;
31 croak "No such method '$_'" unless $self->can($_);
43 while (my @caller = caller $i) {
44 #print join("#", map { defined $_ ? $_ : ""} @caller), "\n";
45 print $caller[0], ":", $caller[2], " ", $caller[3], "\n";
51 my ($self, @message) = @_;
52 print STDERR join("\n", @message), "\n";