Class: HammerCLIForeman::BuildParams::ExpansionParams
- Inherits:
-
Object
- Object
- HammerCLIForeman::BuildParams::ExpansionParams
- Defined in:
- lib/hammer_cli_foreman/option_builders.rb
Instance Method Summary collapse
- #except(*resource_names) ⇒ Object
- #including(*resource_names) ⇒ Object
-
#initialize(params = {}) ⇒ ExpansionParams
constructor
A new instance of ExpansionParams.
- #only(*resource_names) ⇒ Object
- #primary(resource_name) ⇒ Object
- #to_hash ⇒ Object
Constructor Details
#initialize(params = {}) ⇒ ExpansionParams
Returns a new instance of ExpansionParams.
7 8 9 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 7 def initialize(params={}) @params = params || {} end |
Instance Method Details
#except(*resource_names) ⇒ Object
11 12 13 14 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 11 def except(*resource_names) @params[:except] = resource_names self end |
#including(*resource_names) ⇒ Object
16 17 18 19 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 16 def including(*resource_names) @params[:including] = resource_names self end |
#only(*resource_names) ⇒ Object
21 22 23 24 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 21 def only(*resource_names) @params[:only] = resource_names self end |
#primary(resource_name) ⇒ Object
26 27 28 29 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 26 def primary(resource_name) @params[:primary] = resource_name self end |
#to_hash ⇒ Object
31 32 33 |
# File 'lib/hammer_cli_foreman/option_builders.rb', line 31 def to_hash @params end |