Class: OneviewSDK::ImageStreamer::API600::OSVolume

Inherits:
OneviewSDK::ImageStreamer::API500::OSVolume show all
Defined in:
lib/oneview-sdk/image-streamer/resource/api600/os_volume.rb

Overview

OS Volume resource implementation for Image Streamer

Constant Summary

Constants inherited from OneviewSDK::ImageStreamer::API300::OSVolume

OneviewSDK::ImageStreamer::API300::OSVolume::BASE_URI

Constants inherited from Resource

Resource::BASE_URI, Resource::DEFAULT_REQUEST_HEADER, Resource::UNIQUE_IDENTIFIERS

Instance Attribute Summary

Attributes inherited from Resource

#api_version, #client, #data, #logger

Instance Method Summary collapse

Methods inherited from OneviewSDK::ImageStreamer::API300::OSVolume

#create, #delete, #update

Methods inherited from Resource

#==, #[], #[]=, build_query, #create, #create!, #deep_merge!, #delete, #each, #eql?, #exists?, find_by, find_with_pagination, from_file, get_all, get_all_with_query, #initialize, #like?, #refresh, #retrieve!, schema, #schema, #set, #set_all, #to_file, #update

Constructor Details

This class inherits a constructor from OneviewSDK::Resource

Instance Method Details

#get_details_archiveHash

Get the details of the archived OS volume with the specified attribute.

Returns:

  • (Hash)

    The details of the archived OS volume with the specified attribute



21
22
23
24
25
# File 'lib/oneview-sdk/image-streamer/resource/api600/os_volume.rb', line 21

def get_details_archive
  ensure_client && ensure_uri
  response = @client.rest_get("#{BASE_URI}/archive/#{data['name']}")
  @client.response_handler(response)
end

#get_os_volumes_storageHash

Retrieves the os volumes storage of the selected os volumes as per the selected attributes.

Returns:

  • (Hash)

    The readonly artifacts of the selected OS Volumes.



29
30
31
32
33
34
# File 'lib/oneview-sdk/image-streamer/resource/api600/os_volume.rb', line 29

def get_os_volumes_storage
  ensure_client && ensure_uri
  path = "#{BASE_URI}/#{@data['uri'].split('/').last}/storage"
  response = @client.rest_get(path, { 'Content-Type' => 'none' }, @api_version)
  @client.response_handler(response)
end