Parsing function args in Getopt::Long style

Is there a module to parse named function parameters in Getopt::Long style?

What I have in mind is something like:

# Call function
&foo('-p1' -> $v1, '-p2' => $v2);

#Define function
sub foo {
my $options = PARSER( [at] _);

my $v1 = $options->{'p1'};

# ....
}
Yuri Shtil [ Fr, 11 Januar 2008 22:11 ] [ ID #1905819 ]
Perl » comp.lang.perl.modules » Parsing function args in Getopt::Long style

Vorheriges Thema: For module X::Y, should Y be (isa) X?
Nächstes Thema: IPV6 socket connection, with a link-local address