Added TimeoutEmitter class (with tests!).

It can easily be replaced with a promise interface...