Class: RemoteExecutionProvider
- Inherits:
-
Object
- Object
- RemoteExecutionProvider
- Defined in:
- app/models/remote_execution_provider.rb
Direct Known Subclasses
Class Method Summary collapse
- .provider_for(type) ⇒ Object
- .provider_names ⇒ Object
- .providers ⇒ Object
- .register(key, klass) ⇒ Object
Class Method Details
.provider_for(type) ⇒ Object
2 3 4 |
# File 'app/models/remote_execution_provider.rb', line 2 def self.provider_for(type) providers[type.to_s] || providers[:Ssh] end |
.provider_names ⇒ Object
14 15 16 |
# File 'app/models/remote_execution_provider.rb', line 14 def self.provider_names providers.keys.map(&:to_s) end |
.providers ⇒ Object
6 7 8 |
# File 'app/models/remote_execution_provider.rb', line 6 def self.providers @providers ||= { :Ssh => N_(SSHExecutionProvider) }.with_indifferent_access end |
.register(key, klass) ⇒ Object
10 11 12 |
# File 'app/models/remote_execution_provider.rb', line 10 def self.register(key, klass) providers[key.to_sym] = klass end |