via RT wrote:
Show quoted text>This message about Data-Dumper-EasyOO was sent to you by MARKSTOS <MARKSTOS@cpan.org> via rt.cpan.org
>
>
>
> Here's further documentatiomn suggestion.
>
>If you module is 'Easy', it doesn't look "simple" from the documentation.
>
>To use Data::Dumper, I can do this:
>
> use Data::Dumper;
> warn Dumper($foo);
>
>
>
the nearest (current) equivalent would be
use Data::Dumper::EasyOO(init => \our $ez);
$ez->($foo); # output like DD's Dumper($foo)
$ez->(foo=>$foo); # labelled like output from
DD::Dumper->Dump([$foo],['foo'])
Show quoted text>Any replacement needs to be nearly as easy to use, or it won't get used.
>
>>From the current Synopsis, it looks like I might need to do 20 lines of
>setup just to dump some data.
>
>If your module has way to use it 'quickly', I would put that as a first
>stand-alone example in the Synopsis.
>
>I'm hoping something like this might be be possible:
>
> use Data::Dumper::EasyOO ( alias => EzDD );
> EzDD->Dumper($foo);
>
>
>
Hmm. the object is a blessed codref, and needs a variable to hold the
reference.
But wrt your specific example, I *could* do it.
I could export ezdump ( this is less polluting than dump, or pp )
this would be most DD like; with a default export, no use-time stuff is
needed.
use Data::Dumper::EasyOO;
ezdump($foo);
or I could pollute &{$callrpkg}::EzDD (reasonable when alias is used)
then &EzDD could return a ref to a (newly constructed) default object,
thus supporting EzDD->(@args)
and while im in a polluting mood, $EzDD might as well hold that default
object,
so $EzDD->(foo=>$bar) also works.
Show quoted text>Perhaps the user needs to initialize it with more options to be valuable.
>
>
this is the crux of it. EzDD is for adjusting DD the way I like it,
the rest is just feeping creaturism.
Show quoted text>Whatever it is, I would begin the Synopsis with the simplest possible
>common example usage.
>
>
>
it would certainly be easy to move the big synopsis down into desc,
and write a 2 liner, as you suggest.
Show quoted text>Save some of the features that are less important for the detailed
>documentation.
>
> Mark
>
>
>
>
Hmm, I started this response thinking I was going to solicit further input,
but Im pretty much sold already. though Im still listening.
Now to find out if I can cram all that in w/o breaking something else.
thanks again
jimc