Re: Event and IO::Socket

[email protected] (Jeff Boes) 06 Aug 2002 09:12:52 -0400
Newsgroups perl.loop
Message-ID <[email protected]>
On Tue, 2002-08-06 at 00:55, Joshua N Pritikin wrote:

> OK, i was confused.  The best way to settle this is to point you to
> the man page:
> 
> =item io
> 
> Extra attributes: fd => $fd, poll => 'rwe'
> [timeout => $seconds, hard => $bool, timeout_cb => \&code]

Ah, I see where my confusion came from.  'min' is mentioned in the
"Watcher Attributes" section:

min => $seconds
  Enforce a minimum number of seconds between triggering events.

.... which is pretty clearly what I wanted to do, but it's an
*attribute*, not a *constructor attribute*.  What should the behavior of
the constructor be if you supply an unused (but recognized) constructor
attribute?  That is,

  Event->io(  fd => $fd, poll => 'r', cb => \&cb, min => 20 );

doesn't complain, but it doesn't do what I expected, either.

-- 
Jeff Boes                                      vox 269.226.9550 ext 24
Database Engineer                                     fax 269.349.9076
Nexcerpt, Inc.                                 http://www.nexcerpt.com
           ...Nexcerpt... Extend your Expertise