Class: Robot::Commands::Factory
- Inherits:
-
Object
- Object
- Robot::Commands::Factory
- Defined in:
- lib/robot/commands/factory.rb
Class Method Summary collapse
Class Method Details
.build(command) ⇒ Object
12 13 14 15 |
# File 'lib/robot/commands/factory.rb', line 12 def self.build(command) command_klass = COMMANDS.detect { |klass| klass.matches?(command) } command_klass end |