Class: Cliqr::Executor::CommandRunnerFactory Private
- Inherits:
-
Object
- Object
- Cliqr::Executor::CommandRunnerFactory
- Defined in:
- lib/cliqr/executor/command_runner_factory.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Factory class to get instance of CommandRunner based on input options
Class Method Summary collapse
-
.get(**options) ⇒ Cliqr::Executor::StandardCommandRunner, Cliqr::Executor::BufferedCommandRunner
private
Get a instance of command runner based on options.
Class Method Details
.get(**options) ⇒ Cliqr::Executor::StandardCommandRunner, Cliqr::Executor::BufferedCommandRunner
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Get a instance of command runner based on options
17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/cliqr/executor/command_runner_factory.rb', line 17 def self.get(**) case [:output] when :default StandardCommandRunner.new when :buffer BufferedCommandRunner.new else fail Cliqr::Error::UnknownCommandRunnerException, 'cannot find a command runner for the given options' end end |