Class: Ec2spec::HostResult
- Inherits:
-
Object
- Object
- Ec2spec::HostResult
- Defined in:
- lib/ec2spec/host_result.rb
Constant Summary collapse
- MONTH_OF_DAYS =
31- NA_VALUE =
'N/A'
Instance Attribute Summary collapse
-
#backend ⇒ Object
Returns the value of attribute backend.
-
#cpu ⇒ Object
Returns the value of attribute cpu.
-
#host ⇒ Object
Returns the value of attribute host.
-
#instance_id ⇒ Object
Returns the value of attribute instance_id.
-
#instance_type ⇒ Object
Returns the value of attribute instance_type.
-
#memory ⇒ Object
Returns the value of attribute memory.
- #price_per_unit ⇒ Object
Instance Method Summary collapse
-
#initialize(host, days = nil) ⇒ HostResult
constructor
A new instance of HostResult.
- #na_values ⇒ Object
- #price_per_month ⇒ Object
Constructor Details
#initialize(host, days = nil) ⇒ HostResult
10 11 12 13 14 |
# File 'lib/ec2spec/host_result.rb', line 10 def initialize(host, days = nil) @host = host @backend = nil @days = days || MONTH_OF_DAYS end |
Instance Attribute Details
#backend ⇒ Object
Returns the value of attribute backend.
6 7 8 |
# File 'lib/ec2spec/host_result.rb', line 6 def backend @backend end |
#cpu ⇒ Object
Returns the value of attribute cpu.
6 7 8 |
# File 'lib/ec2spec/host_result.rb', line 6 def cpu @cpu end |
#host ⇒ Object
Returns the value of attribute host.
6 7 8 |
# File 'lib/ec2spec/host_result.rb', line 6 def host @host end |
#instance_id ⇒ Object
Returns the value of attribute instance_id.
6 7 8 |
# File 'lib/ec2spec/host_result.rb', line 6 def instance_id @instance_id end |
#instance_type ⇒ Object
Returns the value of attribute instance_type.
7 8 9 |
# File 'lib/ec2spec/host_result.rb', line 7 def instance_type @instance_type end |
#memory ⇒ Object
Returns the value of attribute memory.
6 7 8 |
# File 'lib/ec2spec/host_result.rb', line 6 def memory @memory end |
#price_per_unit ⇒ Object
32 33 34 |
# File 'lib/ec2spec/host_result.rb', line 32 def price_per_unit @price_per_unit ||= @offer_file.price_per_unit end |