Dumpvalue(3) Perl Programmers Reference Guide Dumpvalue(3) NNNNAAAAMMMMEEEE Dumpvalue - provides screen dump of Perl data. SSSSYYYYNNNNOOOOPPPPSSSSYYYYSSSS use Dumpvalue; my $dumper = new Dumpvalue; $dumper->set(globPrint => 1); $dumper->dumpValue(\*::); $dumper->dumpvars('main'); DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN CCCCrrrreeeeaaaattttiiiioooonnnn A new dumper is created by a call $d = new Dumpvalue(option1 => value1, option2 => value2) Recognized options: arrayDepth, hashDepth Print only first N elements of arrays and hashes. If false, prints all the elements. compactDump, veryCompact Change style of array and hash dump. If true, short array may be printed on one line. globPrint Whether to print contents of globs. DumpDBFiles Dump arrays holding contents of debugged files. DumpPackages Dump symbol tables of packages. DumpReused Dump contents of "reused" addresses. tick, HighBit, printUndef Change style of string dump. Default value of tick is auto, one can enable either double-quotish dump, or single-quotish by setting it to " or '. By default, characters with high bit set are printed _a_s _i_s. UsageOnly _v_e_r_y rudimentally per-package memory usage dump. If set, dumpvars calculates total size of strings in variables in the package. unctrl Changes the style of printout of strings. Possible 12/Jul/1999 perl 5.005, patch 03 1 Dumpvalue(3) Perl Programmers Reference Guide Dumpvalue(3) values are unctrl and quote. subdump Whether to try to find the subroutine name given the reference. bareStringify Whether to write the non-overloaded form of the stringify-overloaded objects. quoteHighBit Whether to print chars with high bit set in binary or "as is". stopDbSignal Whether to abort printing if debugger signal flag is raised. Later in the life of the object the methods may be queries with _g_e_t_(_) method and _s_e_t_(_) method (which accept multiple arguments). MMMMeeeetttthhhhooooddddssss dumpValue $dumper->dumpValue($value); $dumper->dumpValue([$value1, $value2]); dumpValues $dumper->dumpValues($value1, $value2); dumpvars $dumper->dumpvars('my_package'); $dumper->dumpvars('my_package', 'foo', '~bar$', '!......'); The optional arguments are considered as literal strings unless they start with ~ or !, in which case they are interpreted as regular expressions (possibly negated). The second example prints entries with names foo, and also entries with names which ends on bar, or are shorter than 5 chars. set_quote $d->set_quote('"'); 12/Jul/1999 perl 5.005, patch 03 2 Dumpvalue(3) Perl Programmers Reference Guide Dumpvalue(3) Sets tick and unctrl options to suitable values for printout with the given quote char. Possible values are auto, ' and ". set_unctrl $d->set_unctrl('"'); Sets unctrl option with checking for an invalid argument. Possible values are unctrl and quote. compactDump $d->compactDump(1); Sets compactDump option. If the value is 1, sets to a reasonable big number. veryCompact $d->veryCompact(1); Sets compactDump and veryCompact options simultaneously. set $d->set(option1 => value1, option2 => value2); get @values = $d->get('option1', 'option2'); 12/Jul/1999 perl 5.005, patch 03 3 Dumpvalue(3) Perl Programmers Reference Guide Dumpvalue(3) 12/Jul/1999 perl 5.005, patch 03 4