class Spielbash::CommandAction
Attributes
command[RW]
Public Class Methods
new(command, action_context)
click to toggle source
Calls superclass method
Spielbash::BaseAction::new
# File lib/spielbash/model/action/command_action.rb, line 5 def initialize(command, action_context) super(action_context) @command = command end
Public Instance Methods
execute(session)
click to toggle source
# File lib/spielbash/model/action/command_action.rb, line 10 def execute(session) command.each_char do |c| session.send_key(c) sleep(action_context.typing_delay_s) end session.send_key('C-m') session.wait if action_context.wait sleep(action_context.reading_delay_s) end