Linux SoftwareProgrammingLibrariesData::Stag::HashDB 0.10

Data::Stag::HashDB 0.10



Developer:   Chris Mungall
      more software by author →
Price:  0.00
License:   GPL (GNU General Public License)
File size:   433K
Language:   
OS:   
Rating:   0 /5 (0 votes)
Your vote:  
enlarge screenshot


Data::Stag::HashDB is a perl used for building indexes over Stag files or objects.

SYNOPSIS

# parsing a file into a hash
my $hdb = Data::Stag::HashDB->new;
$hdb->unique_key("ss_details/social_security_no");
$hdb->record_type("person");
my $obj = {};
$hdb->index_hash($obj);
Data::Stag->parse(-file=>$fn, -handler=>$hdb);
my $person = $obj->{'999-9999-9999'};
print $person->xml;

# indexing an existing stag tree into a hash
my $personset = Data::Stag->parse($fn);
my $hdb = Data::Stag::HashDB->new;
$hdb->unique_key("ss_details/social_security_no");
$hdb->record_type("person");
my $obj = {};
$hdb->index_hash($obj);
$personset->sax($hdb);
my $person = $obj->{'999-9999-9999'};
print $person->xml;

You need to provide a record_type - this is the type of element that will be indexed

You need to provide a unique_key - this is a single value used to index the record_types

For example, if we have data in the stag structure below, and if ss_no is unique (we assume it is) then we can index all the people in the database using the code above

publicinfo:
persondata:
person:
ss_details:
social_security_no:
name:
address:

There is a subclass of this method callsed Data::Stag::StagDB, which makes the hash persistent

Requirements:
  • Perl
    tags data stag  details social  social security  unique key  record type  stag hashdb  999 9999  stag parse  person obj  9999 9999  you need  person xml  print person  

    Download Data::Stag::HashDB 0.10


     http://ftp.hostingromania.ro/Linux/mirrors/ftp.cpan.org/authors/id/C/CM/CMUNGALL/Data-Stag-0.10.tar.gz


    Authors software

    DBIx::DBStag::Cookbook 0.08 (by Chris Mungall)

    Data::Stag::HashDB 0.10 (by Chris Mungall)

    Data::Stag 0.10 (by Chris Mungall)

    DBIx::DBStag 0.08 (by Chris Mungall)


    Similar software

    Data::Stag::HashDB 0.10 (by Chris Mungall)

    Data::Stag 0.10 (by Chris Mungall)

    DBIx::DBStag::Cookbook 0.08 (by Chris Mungall)

    Template::Tutorial 2.15 (by Andy Wardley)
    Template::Tutorial are template toolkit tutorials.

    This section includes tutorials on using the Template Toolkit

    XML::Mini::Document 1.2.8 (by Patrick Deegan, Psychogenic Inc.)
    XML::Mini::Document is a Perl implementation of the XML::Mini Document API.

    SYNOPSIS

    use XML::Mini::Document;

    Rose::HTML::Form 0.53 (by John C. Siracusa)
    Rose::HTML::Form is a HTML form base class.

    SYNOPSIS

    package PersonForm;

    use Rose::HTML::Form;
    our @ISA = qw(Rose::HT

    Who Is This Person? 0.9.3 (by Ted Rheingold)

    tellico-search-amarok 0.1 (by Robby Stephenson)

    DBIx::DBStag 0.08 (by Chris Mungall)

    FLV::VideoTag 0.11 (by Clotho Advanced Media, Inc.)
    FLV::VideoTag is a flash video file data structure Perl module.

    METHODS

    This is a subclass of FLV::Base.

    $self->parse($filei


    Other software in this category

    zlib 1.2.3 (by Jean-loup Gailly)
    zlib is designed to be a free, general-purpose, legally unencumbered, lossless data-compression library for use on virtually any comp

    libjpeg v6b (by Independent JPEG Group)
    libjpeg is a library for handling the JPEG (JFIF) image format

    OpenSSL 0.9.7c (by The OpenSSL Project Team)
    The OpenSSL Project is a collaborative effort to develop a robust, commercial-grade, full-featured, and Open Source toolkit implement

    libxml2 2.6.27 (by DV)
    Libxml2 is the XML C parser and toolkit developed for the Gnome project (but usable outside of the Gnome platform), libxml2 library i

    GNU C library 2.4 (by Andreas Jaeger)
    GNU C library (glibc) is one of the most important components of GNU Hurd and most modern Linux distributions.

    GNU C library is us

  •     search


    Featured Software

    jEdit 4.3 pre8
    jEdit is an Open Source text editor written in Java

    Opera 9.02
    Surf the Internet in a safer, faster, and easier way with Opera browser

    GNU Aspell 0.60.4
    GNU Aspell is a Free and Open Source spell checker designed to eventually replace Ispell


    Subscribe in Rojo
    Google Reader
    Add to My Yahoo!

    Add to My AOL
    Subscribe with Bloglines
    Subscribe in NewsGator Online
    Add 'nixbit linux software' to Newsburst from CNET News.com
    del.icio.us nixbit linux software


    Top tags