Class: Skytap::Commands::Update

Inherits:
HttpBase show all
Defined in:
lib/skytap/commands/http.rb

Instance Attribute Summary

Attributes inherited from Base

#args, #command_options, #error, #global_options, #invoker, #logger

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from HttpBase

#delete, #encode_body, #get, #join_paths, make_for, #options_for_request, #parent_path, #path, #post, #put, #request, #requester, #resource, #resource_path, #root_path

Methods inherited from Base

#api_token, #ask, #ask_param, #command_line_params, command_name, #composed_params, #expected_options, #file_params, #find_id, #initialize, #interactive_params, #invoke, make_from, #noninteractive_params, #programmatic?, #solicit_user_input?, #username

Methods included from Help

#description, #help!, #help?, included, #parameters, #synopsis, #version?

Constructor Details

This class inherits a constructor from Skytap::Commands::Base

Class Method Details

.default_descriptionObject



187
188
189
# File 'lib/skytap/commands/http.rb', line 187

def self.default_description
  "Update attributes of specified #{parent.command_name.gsub('_', ' ')}"
end

Instance Method Details

#expected_argsObject



182
183
184
# File 'lib/skytap/commands/http.rb', line 182

def expected_args
  super.merge('id' => "ID or URL of #{resource} to update")
end

#run!Object



191
192
193
# File 'lib/skytap/commands/http.rb', line 191

def run!
  put(path)
end