Class: EventMachine::EvmaKeyboard

Inherits:
StreamObject show all
Defined in:
lib/em/pure_ruby.rb

Instance Attribute Summary

Attributes inherited from Selectable

#io, #is_server, #uuid

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from StreamObject

#eventable_read, #eventable_write, #get_outbound_data_size, #get_peername, #get_sockname, #heartbeat, #send_data

Methods inherited from Selectable

#close_scheduled?, #get_peername, #get_sockname, #heartbeat, #schedule_close, #set_inactivity_timeout

Constructor Details

#initialize(io) ⇒ EvmaKeyboard

Returns a new instance of EvmaKeyboard



967
968
969
# File 'lib/em/pure_ruby.rb', line 967

def initialize io
  super
end

Class Method Details

.openObject



962
963
964
# File 'lib/em/pure_ruby.rb', line 962

def self.open
  EvmaKeyboard.new STDIN
end

Instance Method Details

#select_for_reading?Boolean

Returns:

  • (Boolean)


976
977
978
# File 'lib/em/pure_ruby.rb', line 976

def select_for_reading?
  true
end

#select_for_writing?Boolean

Returns:

  • (Boolean)


972
973
974
# File 'lib/em/pure_ruby.rb', line 972

def select_for_writing?
  false
end