home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


Book Home Programming PerlSearch this book

32.12. Dumpvalue

use Dumpvalue;

Dumpvalue->new->dumpValue($store);
When used on the example from Class::Struct, this prints:
'Shoppe::addrs' => ARRAY(0x9c1d4)
   0  'Miskatonic University'
   1  'Innsmouth, Mass.'
'Shoppe::boss' => Manager=HASH(0xa5754)
   'Manager::name' => 'Prof L. P. Haitch'
   'Manager::salary' => 'madness'
   'Manager::started' => 'Sat Apr  1 16:18:13 2000'
'Shoppe::owner' => 'Abdul Alhazred'
'Shoppe::stock' => HASH(0xfdbb4)
   'books' => 208
   'charms' => 3
   'potions' => 'none'
This is another module to help display complex data. It's not so much meant for marshalling as it is for pretty printing. It's used by the Perl debugger's x command. As such, it offers a dizzying wealth of options to control the output format. It also provides convenient access to Perl's package symbol tables to dump out the contents of an entire package.



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.