develooper Front page | perl.perl5.porters | Postings from July 2001

Re: Asynchronous callbacks from C

Thread Previous
From:
Paul Johnson
Date:
July 7, 2001 02:42
Subject:
Re: Asynchronous callbacks from C
Message ID:
20010707124349.H6367@pjcj.net
On Sat, Jul 07, 2001 at 01:28:26AM -0500, David M. Lloyd wrote:

> My vague theory was that when a callback is triggered, it is then
> disabled.  I suppose it makes more sense to have an 'on' function (that
> would be called by an asynchronous event maybe) and an 'off' function
> (maybe triggered in the callback itself, or maybe not at all).

I think that's a better idea.  You may also need to consider providing
an easy way to access the callback's handle from within the callback to
either re-enable to disable the callback.  Or think of some other
method.

I would go for leaving the callback on by default for efficiency where
the callback is required continually.

But I think I should probably leave you to work on the implementation
and the issues should become apparent.

-- 
Paul Johnson - paul@pjcj.net
http://www.pjcj.net

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About