Class: Fog::Storage::AzureRM::DataDisk

Inherits:
Model
  • Object
show all
Defined in:
lib/fog/azurerm/models/storage/data_disk.rb

Overview

DataDisk Model for Storage Service

Class Method Summary collapse

Class Method Details

.parse(disk) ⇒ Object



13
14
15
16
17
18
19
20
21
22
# File 'lib/fog/azurerm/models/storage/data_disk.rb', line 13

def self.parse(disk)
  hash = {}
  hash['name'] = disk['name']
  hash['disk_size_gb'] = disk['diskSizeGB']
  hash['lun'] = disk['lun']
  hash['vhd_uri'] = disk['vhd']['uri']
  hash['caching'] = disk['caching'] unless disk['caching'].nil?
  hash['create_option'] = disk['createOption']
  hash
end