BSD Ports

devel/p5-Data-OptList 0.114 DragonFly

Parse and validate simple name/value option pairs

System
DragonFly
Repository
DPorts
Maintainer
[email protected] (as in FreeBSD)
License
ART10, GPLv1+
Categories
devel, perl5
Package size
13.6 KiB, 51.7 KiB installed

Description

Hashes are great for storing named data, but if you want more than one entry for a name, you have to use a list of pairs. Even then, this is really boring to write:

@values = ( foo => undef, bar => undef, baz => undef, xyz => { ... }, );

With Data::OptList, you can do this instead:

Data::OptList::mkopt([ qw(foo bar baz), xyz => { ... }, ]);

This works by assuming that any defined scalar is a name and any reference following a name is its value.

In the other systems

SystemPortVersion
DragonFlydevel/p5-Data-OptList0.114
FreeBSDdevel/p5-Data-OptList0.114
OpenBSDdevel/p5-Data-OptList0.115
NetBSDdevel/p5-Data-OptList0.115
MidnightBSDdevel/p5-Data-OptList0.114
HardenedBSDdevel/p5-Data-OptList0.114
GhostBSDdevel/p5-Data-OptList0.114
OPNsensedevel/p5-Data-OptList0.114

Install

Binary package:

pkg install p5-Data-OptList

From DPorts:

cd /usr/dports/devel/p5-Data-OptList && make install clean

Dependencies

Run dependencies 3