Class: Misty::Openstack::Nova::V2_1
- Inherits:
-
HTTP::Client
- Object
- HTTP::Client
- Misty::Openstack::Nova::V2_1
- Extended by:
- Misty::Openstack::NovaV2_1
- Includes:
- Microversion
- Defined in:
- lib/misty/openstack/nova/v2_1.rb
Constant Summary
Constants included from Microversion
Constants inherited from HTTP::Client
Instance Attribute Summary
Attributes inherited from HTTP::Client
Class Method Summary collapse
- .api ⇒ Object
-
.list_all_major_versions ⇒ Object
Overrides API because the definitions don’t specify prefix.
- .service_names ⇒ Object
- .show_details_of_specific_api_version(version) ⇒ Object
Instance Method Summary collapse
Methods included from Misty::Openstack::NovaV2_1
Methods included from Microversion
#initialize, #version_get, #versions
Methods inherited from HTTP::Client
#headers, #initialize, prefix_path_to_ignore, #requests
Methods included from HTTP::Direct
#base_set, #delete, #get, #post, #put
Methods included from HTTP::Request
#decode?, #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
Methods included from HTTP::NetHTTP
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Misty::HTTP::MethodBuilder
Class Method Details
.api ⇒ Object
12 13 14 |
# File 'lib/misty/openstack/nova/v2_1.rb', line 12 def self.api v2_1 end |
.list_all_major_versions ⇒ Object
Overrides API because the definitions don’t specify prefix
17 18 19 |
# File 'lib/misty/openstack/nova/v2_1.rb', line 17 def self.list_all_major_versions http_get('/', headers) end |
.service_names ⇒ Object
25 26 27 |
# File 'lib/misty/openstack/nova/v2_1.rb', line 25 def self.service_names %w{compute} end |
.show_details_of_specific_api_version(version) ⇒ Object
21 22 23 |
# File 'lib/misty/openstack/nova/v2_1.rb', line 21 def self.show_details_of_specific_api_version(version) http_get("/#{version}", headers) end |
Instance Method Details
#microversion_header ⇒ Object
29 30 31 32 33 34 35 |
# File 'lib/misty/openstack/nova/v2_1.rb', line 29 def microversion_header # Versions 2.27+ use default OpenStack-API-Version header = super # For prior vesions then remove once depcrecated header.merge!('X-Openstack-Nova-API-Version' => "#{@version}",) header end |