The OS-specific syscalls will live in Poller, but the actual dispatch will happen in another structure that owns Poller. Allows for better testing. For example:
func (r *Reactor) Run(timeout int) {
events := r.poller.Poll(timeout)
for _, e := range events { r.dispatch(event) }
}
The OS-specific syscalls will live in Poller, but the actual dispatch will happen in another structure that owns Poller. Allows for better testing. For example: