Main > Programming > Libraries >

Acme::Hyperindex 0.12

Acme::Hyperindex 0.12

Sponsored Links

Acme::Hyperindex 0.12 Ranking & Summary

RankingClick at the star to rank
Ranking Level
User Review: 0 (0 times)
File size: 0.004 MB
Platform: Any Platform
License: Perl Artistic License
Price:
Downloads: 814
Date added: 2007-08-02
Publisher: Berik Visschers

Acme::Hyperindex 0.12 description

Acme::Hyperindex is a Perl module to look deep into structures using a list of indexes.

SYNOPSIS

use strict;
use Acme::Hyperindex;

my @struct = (
{ j_psi => [qw( eta_prime phi kaon )] },
{ j_psi => [qw( selectron down tau_sneutrino )] },
{ j_psi => [qw( upsilon gluino photino )] }
);

print @struct[[ 2, j_psi, 1 ]], "n"; ### Prints gluino
my $row = @struct[[ 1, j_psi ]]; ### Row contains [qw( selectron down tau_sneutrino )]

When you use dynamic datastructures, the perl index syntax may not be felxible enough. A little examle:

my @struct = (
{
pion => [
[qw(strange j_psi positron)],
[qw(down_squark electron gluino)],
],
w_plus_wino => [
[qw(neutralino tau kaon)],
[qw(charm_squark photino strange_squark)]
],
},
);

Now to get to the kaon particle, normally we use:

my $particle = $struct[0]->{w_plus_wino}->[2];
-- or better --
my $particle = $struct[0]{w_plus_wino}[2];

But what if you dont know how deep your datastructure is at compile time? Course this is doable:

my $particle = @struct;
$particle = $particle->[$_] for qw(0 pion 2);

Two problems here: Perl will tell you Not an ARRAY reference once we try to index in the hash on pion with this array indexing syntax. Its damn ugly and looks complicated.

So Acme::Hyperindex lets you index arbitrary deep into data structures:

my $particle = @struct[[ 0, pion, 2 ]];
-- or even --
my $particle = @struct[[ @indexes ]];
-- or --
my $particle = @struct[[ get_index() ]];
-- or --
my $particle = @struct[[ $particleindexes[[ 3, 42 ]] ]];

Acme::Hyperindex now also lets you index on scalars, arrays and hashes:

$struct[[ ... ]];
@struct[[ ... ]];
%struct[[ ... ]];

And lists ary auto-derefed in list context:

my $struct = [ [qw(a b c)], [qw(d e f)] ];

my $foo = $struct[[ 0 ]]; # $foo contains a ref to qw(a b c)
my @foo = $struct[[ 0 ]]; # @foo contains qw(a b c)

Acme::Hyperindex 0.12 Screenshot

Advertisements

Acme::Hyperindex 0.12 Keywords

Bookmark Acme::Hyperindex 0.12

Hyperlink code:
Link for forum:

Acme::Hyperindex 0.12 Copyright

WareSeeker periodically updates pricing and software information of Acme::Hyperindex 0.12 full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Acme::Hyperindex 0.12 Edition. Download links are directly from our publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed

Allok Video Splitter 2.2.0 Review:

Name (Required)
Email(Required)
Captcha
Featured Software

Want to place your software product here?
Please contact us for consideration.

Contact WareSeeker.com
Related Software
Acme::RTB is a Perl extension for building realtimebattle bots. Free Download
PerlIO is a Perl module created to load on demand PerlIO layers and root of PerlIO::* name space. Free Download
Acme::Scripticide is a Perl extension to allow your script to kill itself. Free Download
Acme::Test::Weather is a Perl module to test the weather conditions for a user. Free Download
Hash::Merge Perl module merges arbitrarily deep hashes into a single hash. Free Download
MP3::ID3Lib is a Perl module for ID3v1/ID3v2 Tagging of MP3 files. Free Download
Acme::Laugh is a Perl module that can add joy to your scripts. Free Download
The metric implemented in the Image::Density Perl Module estimates the density of data where there is data. Free Download