Class: SirvRestApi::BillingPlan

Inherits:
Object
  • Object
show all
Defined in:
lib/sirv_rest_api/models.rb

Overview

Billing plan

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data = {}) ⇒ BillingPlan

Returns a new instance of BillingPlan.



94
95
96
97
98
99
100
101
102
103
# File 'lib/sirv_rest_api/models.rb', line 94

def initialize(data = {})
  @id = data["id"]
  @name = data["name"]
  @description = data["description"]
  @period = data["period"]
  @storage = data["storage"]
  @data_transfer_limit = data["dataTransferLimit"]
  @price = data["price"] ? PlanPrice.new(data["price"]) : nil
  @date_active = data["dateActive"]
end

Instance Attribute Details

#data_transfer_limitObject

Returns the value of attribute data_transfer_limit.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def data_transfer_limit
  @data_transfer_limit
end

#date_activeObject

Returns the value of attribute date_active.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def date_active
  @date_active
end

#descriptionObject

Returns the value of attribute description.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def description
  @description
end

#idObject

Returns the value of attribute id.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def id
  @id
end

#nameObject

Returns the value of attribute name.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def name
  @name
end

#periodObject

Returns the value of attribute period.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def period
  @period
end

#priceObject

Returns the value of attribute price.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def price
  @price
end

#storageObject

Returns the value of attribute storage.



92
93
94
# File 'lib/sirv_rest_api/models.rb', line 92

def storage
  @storage
end