react-php/react — pull request #17 by nrk (2012-05-13 05:57:06+00:00)
Title: [EventLoop] Implement timers for the libevent based loop.

Timers can be one-shot or periodic and both are cancellable by using the signature returned when adding them to the event loop. Periodic timers can be cancelled also by returing `FALSE` from the provided callback.

The event loop will continue to run even without any registered stream until there is at least one timer scheduled for execution or the loop is explicitly stopped.

This is basically the same that has been implemented for `React\EventLoop\StreamSelectLoop` but on top of the timer event exposed by libevent. Overhead seems slightly lower.