Class: Slidr::Commands::VoidExecutor
- Inherits:
-
BaseExecutor
- Object
- BaseExecutor
- Slidr::Commands::VoidExecutor
- Defined in:
- lib/slidr/commands/void_executor.rb
Instance Method Summary collapse
- #add(command) ⇒ Object
- #go ⇒ Object
-
#initialize ⇒ VoidExecutor
constructor
A new instance of VoidExecutor.
Constructor Details
#initialize ⇒ VoidExecutor
Returns a new instance of VoidExecutor.
5 6 7 |
# File 'lib/slidr/commands/void_executor.rb', line 5 def initialize @commands = [] end |
Instance Method Details
#add(command) ⇒ Object
9 10 11 12 |
# File 'lib/slidr/commands/void_executor.rb', line 9 def add(command) @commands << command self end |
#go ⇒ Object
14 15 16 17 18 |
# File 'lib/slidr/commands/void_executor.rb', line 14 def go @commands.each do |command| command.go end end |