Devel::Carnivore

Devel::Carnivore is a Perl module to spy on your hashes (and objects).
Download

Devel::Carnivore Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Malte Ubl
  • Publisher web site:
  • http://search.cpan.org/~malteu/Devel-Carnivore-0.09/Carnivore.pm

Devel::Carnivore Tags


Devel::Carnivore Description

Devel::Carnivore is a Perl module to spy on your hashes (and objects). Devel::Carnivore is a Perl module to spy on your hashes (and objects).SYNOPSIS use Devel::Carnivore; sub new_attribute { my %self : Watch("myName") = (); bless %self, shift; } sub new_functional { my $self = {}; watch $self, "myName"; bless $self } sub new_blessed { my $self = {}; bless $self; watch $self, "myName"; return $self; } sub new_scalar_attribute { my $self : Watch("myName") = {}; bless $self }This module allows you to debug your hashes and, in particular, your objects based on hashes without using the perl debugger. There are several good reasons to do this. Among them:1) You're too stupid to use the perl debugger (This is true for me)2) You're building web applications and the perl debugger doesn't work very well in that environmentObviously, this module does not provide you with a complete debugger. All it does is helping you keep track of the state changes which occur to your objects.OutputBy default all output is written to STDERR. You may change this behavior by assigning a valid output filehandle to $Devel::Carnivore::OUT.Everytime the hash which is being watched by this module is assigned to, a message like this is created: > ProgLang: "cool" changed from "Java" to "Perl" at devel.pl line 30So what does this tell you?You have a Perl file named devel.pl. On line 30 your code changed the value of the key "cool" from "Java" to "Perl". In order, to identify this hash you optionally named it "ProgLang". Requirements: · Perl


Devel::Carnivore Related Software