Changeset 3 in mp3-find for trunk/lib/MP3/Find.pm


Ignore:
Timestamp:
01/30/06 02:05:25 (18 years ago)
Author:
peter
Message:
  • updated MANIFEST to include all lib/* and Makefile.PL to include bin/mp3find
  • doc updates to *.pm and mp3find
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/MP3/Find.pm

    r1 r3  
    3737=head1 SYNOPSIS 
    3838 
    39     use MP3Find; 
     39    # select with backend you want 
     40    use MP3::Find qw(Filesystem); 
    4041     
    4142    print "$_\n" foreach find_mp3s( 
     
    5960or the actual Perl data structure representing the results. 
    6061 
     62There are currently two backends to this module: L<MP3::Find::Filesystem> 
     63and L<MP3::Find::DB>. You choose which one you want by passing its 
     64name as the argument to you C<use> statement; B<MP3::Find> will look for 
     65a B<MP3::Find::$BACKEND> module. If no backend name is given, it will 
     66default to using L<MP3::Find::Filesystem>. 
     67 
     68B<Note:> I'm still working out some kinks in the DB backend, so it 
     69is currently not as stable as the Filesystem backend. 
     70 
    6171=head1 REQUIRES 
    6272 
    63 L<File::Find>, L<MP3::Info>, L<Scalar::Util> 
     73L<File::Find>, L<MP3::Info>, and L<Scalar::Util> are needed for 
     74the filesystem backend (L<MP3::Find::Filesystem>). 
    6475 
    65 L<DBI> and L<DBD::SQLite> are needed if you want to have a 
    66 database backend. 
     76L<DBI>, L<DBD::SQLite>, and L<SQL::Abstract> are needed for the 
     77database backend (L<MP3::Find::DB>). 
    6778 
    6879=head1 EXPORTS 
     
    95106=item C<exact_match> 
    96107 
    97 Adds an implicit C<^> and C<$> around each query string. 
     108Adds an implicit C<^> and C<$> around each query string. Does nothing 
     109if the query is already a regular expression. 
    98110 
    99111=item C<sort> 
     
    101113What field or fields to sort the results by. Can either be a single 
    102114scalar field name to sort by, or an arrayref of field names. Again, 
    103 acceptable field names are anything that L<MP3::Info> knows about. 
     115acceptable field names are anything that L<MP3::Info> knows about; 
     116field names will be converted to upper case as with the C<query> 
     117option. 
    104118 
    105119=item C<printf> 
     
    144158=back 
    145159 
     160=head1 BUGS 
     161 
     162There are probably some in there; let me know if you find any (patches 
     163welcome). 
     164 
    146165=head1 TODO 
    147166 
    148 More of a structured query would be nice; currently everything 
    149 is and-ed together, and it would be nice to be able to put query 
    150 keys together with a mixture of and and or. 
     167Better tests, using some actual sample mp3 files. 
    151168 
    152 Searching a big directory is slo-o-ow! Investigate some sort of  
    153 caching of results? 
    154  
    155 The current sorting function is also probably quite inefficient. 
     169Other backends (a caching filesystem backend, perhaps?) 
    156170 
    157171=head1 SEE ALSO 
     172 
     173L<MP3::Find::Filesystem>, L<MP3::Find::DB> 
     174 
     175L<mp3find> is the command line frontend to this module (it 
     176currently only uses the filesystem backend). 
    158177 
    159178See L<MP3::Info> for more information about the fields you can 
Note: See TracChangeset for help on using the changeset viewer.