Class: NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd
- Inherits:
-
InplaceCommand
- Object
- FileCommand
- InplaceCommand
- NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd
- Includes:
- NCO_warning_filter
- Defined in:
- lib/file_command.rb
Instance Method Summary collapse
- #cmd_txt_inplace(file) ⇒ Object
-
#initialize(var_name, attribute_names) ⇒ NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd
constructor
A new instance of NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd.
Methods included from NCO_warning_filter
Methods inherited from InplaceCommand
Methods inherited from FileCommand
Constructor Details
#initialize(var_name, attribute_names) ⇒ NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd
Returns a new instance of NCATTED_DELETE_VARIABLE_ATTRIBUTES_cmd.
235 236 237 238 |
# File 'lib/file_command.rb', line 235 def initialize(var_name, attribute_names) @var_name = var_name @attribute_names = attribute_names end |
Instance Method Details
#cmd_txt_inplace(file) ⇒ Object
240 241 242 243 244 |
# File 'lib/file_command.rb', line 240 def cmd_txt_inplace(file) att_args = "" @attribute_names.each {|n| att_args += %Q( -a #{n},#{@var_name},d,,)} %Q(#{SYSTEM_COMMANDS::NCATTED} --create_ram -h#{att_args} #{file}) end |