Class: Misty::Openstack::API::Nova::V2_1

Inherits:
Object
  • Object
show all
Includes:
Microversion, Misty::Openstack::API::NovaV2_1, ServicePack
Defined in:
lib/misty/openstack/api/nova/v2_1.rb

Constant Summary

Constants included from HTTP::Request

HTTP::Request::DECODE_TO_JSON

Instance Attribute Summary

Attributes included from Service

#headers, #microversion

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Microversion

#set_version

Methods included from HTTP::Direct

#base_set, #delete, #get, #post, #put

Methods included from HTTP::Request

#decode?, #decode_to_json?, #http, #http_copy, #http_delete, #http_get, #http_head, #http_options, #http_patch, #http_post, #http_put, #http_to_s

Methods included from HTTP::MethodBuilder

#method_missing

Methods included from HTTP::NetHTTP

http_request

Methods included from Service

#initialize, #prefix_path_to_ignore, #request_config, #requests

Methods included from Misty::Openstack::API::NovaV2_1

#api, #tag

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Misty::HTTP::MethodBuilder

Class Method Details

.show_details_of_specific_api_version(version) ⇒ Object



14
15
16
# File 'lib/misty/openstack/api/nova/v2_1.rb', line 14

def self.show_details_of_specific_api_version(version)
  http_get("/#{version}", headers)
end

Instance Method Details

#microversion_header(version) ⇒ Object



18
19
20
21
22
23
24
# File 'lib/misty/openstack/api/nova/v2_1.rb', line 18

def microversion_header(version)
  if @version >= '2.27'
    super
  else
    {'X-Openstack-Nova-API-Version' => "#{version}"}
  end
end

#service_typesObject



26
27
28
# File 'lib/misty/openstack/api/nova/v2_1.rb', line 26

def service_types
  %w(compute)
end