Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 976 Categories, Downloaded 29.858.072 Times

Acme::Hyperindex 0.12

  Date Added: September 18, 2010  |  Visits: 751

Acme::Hyperindex

Report Broken Link
Printer Friendly Version


Product Homepage
Download (72 downloads)



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).

Requirements: No special requirements
Platforms: Linux
Keyword: Acmehyperindex Libraries List Of Particle Perl Perl Module Programming Psi Qw Struct Using A
Users rating: 0/10

License: Freeware Size: 4.1 KB
USER REVIEWS
More Reviews or Write Review


ACME::HYPERINDEX RELATED
Network & Internet  -  SRESI 0.19.10
SRESI is a smart bookmarks manager: from a list of tagged bookmarks, it can generate an exhaustive tree or a portal, where each bookmark is at every place in the hierarchy you can expect to find it, and with absurd branches absorbed back in their...
225.28 KB  
Libraries  -  Dir::Which 0.3
Dir::Which is a Perl module to search for directory entries in a list of directories. SYNOPSIS use Dir::Which qw/ which /; @entries = which( -entry => "myprog.conf", -env => "myprog_path", -defaultpath =>...
5.12 KB  
Libraries  -  Parallel::Queue 1.00
Parallel::Queue is a Perl module to fork or thread a list of closures N-way parallel. SYNOPSIS # example queue: # only squish files larger than 8KB in size. figure # that the system can handle four copies of squish # running at the same...
8.19 KB  
Development Tools  -  Converting a list of equal length lists into XML 1.0
This module takes a list of equal length lists and converts it into XML. If the first sublist is a list of headings, these are used to form the element names of the rest of the data, or these can be defined in the function call. Root and "row"...
 
Miscellaneous  -  A List of Dictionaries 1.0
This  class emulates a list of dictionary objects without the memory and pickle storage overhead which occurs when storing every item in the list as a dictionary.
 
Miscellaneous  -  Transposing a List of Lists 1.0
This script allows you to transpose a list of lists of different lengths.
 
Modules  -  SMS List (Scri[ts) 6.x-1.0
The SMS List Module will help Maintain a List of Users with active subscription and send them SMS using the smsframework Module.Proposed Features* Provides a Block to Subscribe/Unsubscribe* Checks for The Validity of Number* Send an SMS Challenge...
10 KB  
Networking  -  List of Posts from each Category plugin for WordPress 2.0
List of Posts from each Category plugin for WordPressThis plugin displays a list of the posts from each category of your WordPress installation. It can be added to a post or page, or used directly in a template file. In the plugind¬DSdus...
10 KB  
Games  -  Christmas Gift Mania - A list of Gifts to Discover and Match them Free Game 1.1
Christmas Gift Mania - A list of Gifts to Discover and Match them Free Game It's a perfect game for the whole family!!! Seasons come and go. Christmas is the best time to spend with you family. We Wish You A Very Happy...
15.7 MB  
Video Editors  -  OGMRip 0.10.3
OGMRip is an application and a set of libraries for ripping and encoding DVD into AVI or OGM files using a wide variety of codecs. OGMRip relies on mplayer, mencoder, oggenc, ogmtools and lame to perform its tasks. The GUI features a clean...
634.88 KB  
NEW DOWNLOADS IN PROGRAMMING, LIBRARIES
Programming  -  FLEX-db Digital Asset Manager 3.0.9
FLEX-db - an enterprise Digital Asset Manager (DAM). It ingests and links metadata with files, creates thumbnails, and processes files using business rules. FLEX-db has a JSP client, Java app server for file input and output and an EJB metadata...
21.57 MB  
Programming  -  Libicom 0.9.0
The libicom library is a character based dynamicly linked library for Linux. It is used to remotely control the Icom IC-R8500 wide band receiver via an RS232 link. All call and return parameters to the control functions are character string based....
20.48 KB  
Programming  -  dotdesktop 0.3
Dotdesktop library provides ability to parse desktop entry file and access the information in a convenient way. Desktop entry file format is defined by freedesktop.org, it is used to describe information about an application such as the name and...
327.68 KB  
Programming  -  Cedalion for Linux 0.2.6
Cedalion is a programming language that allows its users to add new abstractions and define (and use) internal DSLs. Its innovation is in the fact that it uses projectional editing to allow the new abstractions to have no syntactic limitations.
471.04 KB  
Programming  -  libyasl 0.2
Libyasl is a C++ class library to easily realize TCP/UDP/Multicast clientsand servers in IPv4 and IPv6 environments under GNU/Linux systems.
143.36 KB  
Libraries  -  wolfSSL 3.11.0
The wolfSSL embedded SSL/TLS library is a lightweight SSL library written in ANSI standard C and targeted for embedded and RTOS environments - primarily because of its small size, speed, and feature set. It is commonly used in standard operating...
2.73 MB  
Libraries  -  EuGTK 4.8.9
Makes it easy to develop good- looking, fast, cross-platform programs that run on Linux, OS X, and Windows. Euphoria is a very fast interpreted/compiled language with straight-forward syntax. EuGTK allows programming in a clean, object-oriented...
10.68 MB  
Libraries  -  Linux User Group Library Manager 1.0
The LUG Library Manager is a project to help Linux User Groups start their own library. A LUG library is helpful to the community at large because it increases access to information, and gives everyone the opportunity to become more knowledgeable.
5.35 KB  
Libraries  -  Module::MakefilePL::Parse 0.12
Module::MakefilePL::Parse is a Perl module to parse required modules from Makefile.PL. SYNOPSIS use Module::MakefilePL::Parse; open $fh, Makefile.PL; $parser = Module::MakefilePL::Parse->new( join("", ) ); $info = $parser->required;...
8.19 KB  
Libraries  -  sqlpp 0.06
sqlpp Perl package is a SQL preprocessor. sqlpp is a conventional cpp-alike preprocessor taught to understand SQL ( PgSQL, in particular) syntax specificities. In addition to the standard #define/#ifdef/#else/#endif cohort, provides also...
10.24 KB