Module: EventMachine

Defined in:
lib/ripl/readline/eminput.rb

Class Method Summary collapse

Class Method Details

.watch_stdin(handler, *args) ⇒ Object

Convenience method to add a watch on ‘STDIN` and set notify_readable to `true`.

See EventMachine.watch



6
7
8
9
10
# File 'lib/ripl/readline/eminput.rb', line 6

def self.watch_stdin(handler, *args)
  conn = EventMachine.watch $stdin, handler, *args
  conn.notify_readable = true
  conn
end