Class: Bosh::Stemcell::Infrastructure::Base
- Inherits:
-
Object
- Object
- Bosh::Stemcell::Infrastructure::Base
- Defined in:
- lib/bosh/stemcell/infrastructure.rb
Direct Known Subclasses
Aws, Azure, NullInfrastructure, OpenStack, Softlayer, Vcloud, Vsphere, Warden
Instance Attribute Summary collapse
-
#default_disk_size ⇒ Object
readonly
Returns the value of attribute default_disk_size.
-
#disk_formats ⇒ Object
readonly
Returns the value of attribute disk_formats.
-
#hypervisor ⇒ Object
readonly
Returns the value of attribute hypervisor.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #additional_cloud_properties ⇒ Object
- #default_disk_format ⇒ Object
-
#initialize(options = {}) ⇒ Base
constructor
A new instance of Base.
Constructor Details
#initialize(options = {}) ⇒ Base
Returns a new instance of Base.
29 30 31 32 33 34 35 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 29 def initialize( = {}) @name = .fetch(:name) @supports_light_stemcell = .fetch(:supports_light_stemcell, false) @hypervisor = .fetch(:hypervisor) @default_disk_size = .fetch(:default_disk_size) @disk_formats = .fetch(:disk_formats) end |
Instance Attribute Details
#default_disk_size ⇒ Object (readonly)
Returns the value of attribute default_disk_size
27 28 29 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 27 def default_disk_size @default_disk_size end |
#disk_formats ⇒ Object (readonly)
Returns the value of attribute disk_formats
27 28 29 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 27 def disk_formats @disk_formats end |
#hypervisor ⇒ Object (readonly)
Returns the value of attribute hypervisor
27 28 29 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 27 def hypervisor @hypervisor end |
#name ⇒ Object (readonly)
Returns the value of attribute name
27 28 29 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 27 def name @name end |
Instance Method Details
#==(other) ⇒ Object
45 46 47 48 49 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 45 def ==(other) name == other.name && hypervisor == other.hypervisor && default_disk_size == other.default_disk_size end |
#additional_cloud_properties ⇒ Object
41 42 43 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 41 def additional_cloud_properties {} end |
#default_disk_format ⇒ Object
37 38 39 |
# File 'lib/bosh/stemcell/infrastructure.rb', line 37 def default_disk_format disk_formats.first end |