Class: Exec::NodeInstall::CustomCommandOption
- Inherits:
-
CommandOption
- Object
- CommandOption
- Exec::NodeInstall::CustomCommandOption
- Defined in:
- lib/exec/node_install.rb
Overview
Inherited CommandOption used only by ServiceLs.
Instance Attribute Summary
Attributes inherited from CommandOption
Instance Method Summary collapse
-
#check_mandatory ⇒ Object
protected
This method overrides the default behaviour.
-
#get_banner ⇒ Object
This method overrides the default bannger generating.
Methods inherited from CommandOption
#add_option, #get_help, #get_sorted_options, #has_argument, #initialize, #initialize_option_values, #verify
Constructor Details
This class inherits a constructor from Exec::CommandOption
Instance Method Details
#check_mandatory ⇒ Object (protected)
This method overrides the default behaviour.
227 228 229 230 231 |
# File 'lib/exec/node_install.rb', line 227 def check_mandatory raise Common::MissingParameter.new("-n or -a", get_help()) if !@values["help"] && !@values["all"] && @values["node"].nil? raise Common::InconsistentParameter.new("can not be used together.", get_help(), "-a", "-n") if !@values["help"] && @values["all"] && !@values["node"].nil? raise Common::InconsistentParameter.new("can not be used together.", get_help(), "-a", "-f") if !@values["help"] && @values["all"] && @values["force"] end |
#get_banner ⇒ Object
This method overrides the default bannger generating
220 221 222 |
# File 'lib/exec/node_install.rb', line 220 def return "Usage: -a|-n NODE_NAME [-b BIOS_NAME] [-r RAID_NAME] [-f] [-h]" end |