Skip to content
Implementation of setTimeout() function in JavaScript
Perl
Failed to load latest commit information.
lib/Fork ドキュメント内の単位まちがってた Jul 28, 2011
t テスト整理 Jul 28, 2011
xt
.gitignore implemented setTimeout by fork(2) Jul 25, 2011
.shipit implemented setTimeout by fork(2) Jul 25, 2011
Changes implemented setTimeout by fork(2) Jul 25, 2011
MANIFEST forkの後片付けをも少しちゃんと Jul 26, 2011
MANIFEST.SKIP implemented setTimeout by fork(2) Jul 25, 2011
Makefile.PL implemented setTimeout by fork(2) Jul 25, 2011
README.mkdn forkの後片付けをも少しちゃんと Jul 25, 2011

README.mkdn

NAME

Fork::setTimeout - Implementation of setTimeout() function in JavaScript

SYNOPSIS

use Fork::setTimeout;

my $timer = setTimeout(sub { ... }, 10); clearTimeout($timer);

DESCRIPTION

An emulation of setTimeout() funcion in JavaScript using fork(2).

METHODS

setTimeout( I<$code>, I<$msec> )

my $timer = setTimeout(sub { ... }, 10);

Dispatches $code after $msec micro seconds.

You should store the return value, $timer, in some lexical variable to wait for child process to finish dispatching $code.

clearTimeout( I<$timer> )

clearTimeout($timer);

Kills the child process and clear $timer out.

AUTHOR

Kentaro Kuribayashi kentarok@gmail.com

SEE ALSO

LICENSE

Copyright (C) Kentaro Kuribayashi

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

Something went wrong with that request. Please try again.