Event::File 0.1.1

[email protected] (Raul Dias)
Newsgroups perl.loop
Message-ID <[email protected]>
Hi,

I just got to know about Event a few weeks ago.  So I am still 
getting familiar with it.

Reading the archieves I noted that there was the issue about
reading a file as io (specially as a 'tail -f' format).

I separated as a module, the part of my project that deals with 
it.
I do not know too much XS and Event internals to write my own
event handler, (I stoped at the pe_event_allocate() part).

So I wrote Event::File as a fake event handler parent for
Event::File::tail (Event::File->tail()).  I tryied to mimic the behaviour
of real watcher with a few methods (stop, start, cancel).

Event::File::tail can tail a file, detect unlinks, 
file rotations/truncations and does not eat all the CPU when the
file gets to the end.   8)

It is available at => http://www.swi.com.br/~chaos/files/Event-File-0.1.1.tar.gz


Comments,  suggestions,  critics and patches are welcome.



Raul Dias
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.