Class: Fog::Compute::Proxmox::Disk

Inherits:
Proxmox::Model show all
Defined in:
lib/fog/compute/proxmox/models/disk.rb

Overview

class Disk model

Instance Method Summary collapse

Methods inherited from Proxmox::Model

#create, #destroy, #initialize, #inspect, #to_s, #update

Constructor Details

This class inherits a constructor from Fog::Proxmox::Model

Instance Method Details

#cdrom?Boolean


60
61
62
# File 'lib/fog/compute/proxmox/models/disk.rb', line 60

def cdrom?
  id == 'ide2' && media == 'cdrom'
end

#controllerObject


52
53
54
# File 'lib/fog/compute/proxmox/models/disk.rb', line 52

def controller
  Fog::Proxmox::DiskHelper.extract_controller(id)
end

#deviceObject


56
57
58
# File 'lib/fog/compute/proxmox/models/disk.rb', line 56

def device
  Fog::Proxmox::DiskHelper.extract_device(id)
end

#rootfs?Boolean


64
65
66
# File 'lib/fog/compute/proxmox/models/disk.rb', line 64

def rootfs?
  id == 'rootfs'
end