The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Data::HTML::TreeDumper - dumps perl data as HTML5 open/close tree

SYNOPSIS

    use Data::HTML::TreeDumper;
    my $td = Data::HTML::TreeDumper->new(
        ClassKey    => 'trdKey',
        ClassValue  => 'trdValue',
        MaxDepth    => 8,
    );
    my $obj = someFunction();
    print $td->dump($obj);

There are some samples.

DESCRIPTION

Data::HTML::TreeDumper dumps perl data as HTML5 open/close tree.

CLASS METHODS

new([option => value, ...])

Creates a new Data::HTML::TreeDumper instance. This method can take a list of options. You can set each options later as the properties of the instance.

ClassKey, ClassValue, ClassOrderedList, ClassUnorderedList

CSS class names for each items. OrderedList is for arrays. UnorderedList is for hashes.

StartOrderedList

An integer to start counting from for arrays. Default is 0.

MaxDepth

Stops following object tree at this level, and show "..." instead. Default is 8. Over 32 is not acceptable to prevent memory leak.

INSTANCE METHODS

dump($object)

Dumps perl data as a HTML5 open/close tree.

SOURCE

Source repository is at p-Data-HTML-TreeDumper .

SEE ALSO

Similar CPAN modules:

Data::HTMLDumper, Data::Dumper::HTML, Data::Format::Pretty::HTML

LICENSE

Copyright (C) TakeAsh.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

AUTHOR

TakeAsh