Name : perl-Tie-Autotie
| |
Version : 0.03
| Vendor : obs://build_opensuse_org/devel:languages:perl
|
Release : lp154.6.1
| Date : 2023-01-27 18:22:08
|
Group : Development/Libraries/Perl
| Source RPM : perl-Tie-Autotie-0.03-lp154.6.1.src.rpm
|
Size : 0.01 MB
| |
Packager : https://www_suse_com/
| |
Summary : Automatically ties underlying references
|
Description :
This module allows you to automatically tie data structures contained in a tied data structure. As an example:
use Tie::Autotie \'Tie::IxHash\';
tie my(%hash), \'Tie::IxHash\';
$hash{jeff}{age} = 22; $hash{jeff}{lang} = \'Perl\'; $hash{jeff}{brothers} = 3; $hash{jeff}{sisters} = 4;
$hash{kristin}{age} = 22; $hash{kristin}{lang} = \'Latin\'; $hash{kristin}{brothers} = 1; $hash{kristin}{sisters} = 0;
for my $who (keys %hash) { print \"$who:\ \"; for my $what (keys %) { print \" $what = $hash{$who}{$what}\ \"; } }
This program outputs:
jeff: age = 22 lang = Perl brothers = 3 sisters = 4 kristin: age = 22 lang = Latin brothers = 1 sisters = 0
You can see that the keys of %hash are returned in the order in which they were created, _as well_ as the keys of the sub-hashes.
|
RPM found in directory: /packages/linux-pbone/ftp5.gwdg.de/pub/opensuse/repositories/devel:/languages:/perl:/CPAN-T/15.4/noarch |