This package contains perl module for traversing RePEc / ReDIF
archives collections: RePEc/Iterator.pm.

It uses (depends on) Events.pm perl module, which is distributed
together with this module, but not included into this.

To install run from the command prompt:

   perl Makefile.PL  [ PREFIX = "..." ... ]
   make 
   make install

Typical step 'make test' is skipped here because we have not yet
prepared any tests to the module, which could be redistributed with it
in a standard fashion.  Instead there is a file test.pl which is a
very simple, but complete example of usage of the RePEc::Iterator.  To
get any useful results from it, you must have a RePEc mirror or
imitate it by the standard directory structure and some filenames.  Do
not forget to change the $redif_dir in test.pl value to the yours
local ReDIF directory, before running.



BRIEF DESCRIPTION

The Iterator is activated by the main ( REDIF_DIR, AUTHORITY )
function where REDIF_DIR is a scalar, pointing to a local ReDIF
directory.   This directory is assumed to contain subdir remo/.

The AUTHORITY parameter will be used to supply it to the client
processing code.  For instance, it can be correctly set to 'RePEc'.

Then the Iterator looks for remo/all archive and processes archive by
archive sequentially.  Processing an archive means also finding its
series file and the mirroring file and the basic level ReDIF metadata.

The iterator reports to the client every found data file and supplies
some handy information about it.  To report anything to the client we
use Events-technique, see the Events module for more information.

If you get an idea of the Events module and run the test.pl script you
might get able to use the module.  At least this what I hope for. 

Nevertheless, a few more notes.  For each ReDIF file found, the
Iterator gives its full (physical) pathname and a logical (short)
pathname, which is either local to the REDIFDIR/remo/ or to REDIFDIR/
directory itself.  

When the REDIF::ARCHIVE::FINISHED event comes with no data, that means
that the archive hasn't been successfully processed.

Errors, warning and some other processing information is not displayed
unless you do that by handling REPEC::ITERATOR::ERROR,
REPEC::ITERATOR::WARNING and REPEC::ITERATOR::MESSAGE events.


SYMBOLIC LINKS

This module uses standard Perl library module File::Find, which cannot
search into deep by the symbolic links.  But the Iterator design can
actually overcome some of the limitations.


WHERE TO FIND

http://openlib.org/acmes/root/soft/RePEc/RePEc-Iterator/



That's all.  Sorry for the lack of good documentation.
   
Ivan Kurmanov, <ivan@tm.minsk.by>, <iku@fnmail.com>

