Class: JobInvocationComposer::ParamsForFeature
- Inherits:
-
Object
- Object
- JobInvocationComposer::ParamsForFeature
- Defined in:
- app/models/job_invocation_composer.rb
Instance Attribute Summary collapse
-
#feature ⇒ Object
readonly
Returns the value of attribute feature.
-
#feature_label ⇒ Object
readonly
Returns the value of attribute feature_label.
-
#provided_inputs ⇒ Object
readonly
Returns the value of attribute provided_inputs.
Instance Method Summary collapse
-
#initialize(feature_label, hosts, provided_inputs = {}) ⇒ ParamsForFeature
constructor
A new instance of ParamsForFeature.
- #params ⇒ Object
Constructor Details
#initialize(feature_label, hosts, provided_inputs = {}) ⇒ ParamsForFeature
Returns a new instance of ParamsForFeature.
211 212 213 214 215 216 217 218 219 220 221 222 223 |
# File 'app/models/job_invocation_composer.rb', line 211 def initialize(feature_label, hosts, provided_inputs = {}) @feature = RemoteExecutionFeature.feature(feature_label) @provided_inputs = provided_inputs if hosts.is_a? Bookmark @host_bookmark = hosts elsif hosts.is_a? Host::Base @host_objects = [hosts] elsif hosts.is_a? String @host_scoped_search = hosts else @host_objects = hosts end end |
Instance Attribute Details
#feature ⇒ Object (readonly)
Returns the value of attribute feature.
209 210 211 |
# File 'app/models/job_invocation_composer.rb', line 209 def feature @feature end |
#feature_label ⇒ Object (readonly)
Returns the value of attribute feature_label.
209 210 211 |
# File 'app/models/job_invocation_composer.rb', line 209 def feature_label @feature_label end |
#provided_inputs ⇒ Object (readonly)
Returns the value of attribute provided_inputs.
209 210 211 |
# File 'app/models/job_invocation_composer.rb', line 209 def provided_inputs @provided_inputs end |
Instance Method Details
#params ⇒ Object
225 226 227 228 229 230 231 |
# File 'app/models/job_invocation_composer.rb', line 225 def params { :job_category => job_template.job_category, :targeting => targeting_params, :triggering => {}, :concurrency_control => {}, :template_invocations => template_invocations_params }.with_indifferent_access end |