arunhorne has asked for the wisdom of the Perl Monks concerning the following question:

Monks

I am writing a program that has a number of complex data structures and want the be able to view them easily in a generic fashion without having to write custom code that relies upon inside knowledge of their organisation. I'm sure that I came across a module to facilitate this a while ago but have been searching CPAN for a while now in vain... its hard to know exactly what to call such a thing. Does anyone know the name of the module that can do this?

Thnaks,

____________
Arun

Replies are listed 'Best First'.
Re: Viewing Data Structures
by DamnDirtyApe (Curate) on Jul 20, 2002 at 16:52 UTC
Re: Viewing Data Structures
by Courage (Parson) on Jul 20, 2002 at 17:16 UTC
    In addition to mentioned Data::Dumper I would recommend looking at Tk::ObjScanner, which will show your structures in a very friendly GUI.

    Courage, the Cowardly Dog

Re: Viewing Data Structures
by screamingeagle (Curate) on Jul 21, 2002 at 03:29 UTC
    check out Data::Denter ... It's a nice alternative to Data::Dumper
Re: Viewing Data Structures
by bronto (Priest) on Jul 22, 2002 at 09:33 UTC

    If you want to check them on-the-run, and you have Tk, you can also use ptkdb. It's a full perl/tk visual debugger; you can go step by step and see your data structures on the sidebar; also, you can point a variable with a mouse and see its current value in a pop-up. At the moment, I haven't seen any better free software for the task.

    Instead, when all I need is to get a dump of a data structure in a certain point and then stop, I tend to use Data::Dumper, too.

    Ciao!
    --bronto

    # Another Perl edition of a song:
    # The End, by The Beatles
    END {
      $you->take($love) eq $you->made($love) ;
    }