Class: App42::AppTab::Storage
- Inherits:
-
Object
- Object
- App42::AppTab::Storage
- Defined in:
- lib/appTab/Usage.rb
Instance Attribute Summary collapse
-
#currency ⇒ Object
Returns the value of attribute currency.
-
#description ⇒ Object
Returns the value of attribute description.
-
#name ⇒ Object
Returns the value of attribute name.
-
#price ⇒ Object
Returns the value of attribute price.
-
#space ⇒ Object
Returns the value of attribute space.
-
#state ⇒ Object
Returns the value of attribute state.
-
#unit ⇒ Object
Returns the value of attribute unit.
-
#user ⇒ Object
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(usage) ⇒ Storage
constructor
This is a constructor that takes no parameter.
-
#to_s ⇒ Object
Returns the Usage Response in JSON format.
Constructor Details
#initialize(usage) ⇒ Storage
This is a constructor that takes no parameter
145 146 147 |
# File 'lib/appTab/Usage.rb', line 145 def initialize(usage) usage.storageList.push(self) end |
Instance Attribute Details
#currency ⇒ Object
Returns the value of attribute currency.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def currency @currency end |
#description ⇒ Object
Returns the value of attribute description.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def description @description end |
#name ⇒ Object
Returns the value of attribute name.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def name @name end |
#price ⇒ Object
Returns the value of attribute price.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def price @price end |
#space ⇒ Object
Returns the value of attribute space.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def space @space end |
#state ⇒ Object
Returns the value of attribute state.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def state @state end |
#unit ⇒ Object
Returns the value of attribute unit.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def unit @unit end |
#user ⇒ Object
Returns the value of attribute user.
133 134 135 |
# File 'lib/appTab/Usage.rb', line 133 def user @user end |
Instance Method Details
#to_s ⇒ Object
Returns the Usage Response in JSON format.
155 156 157 |
# File 'lib/appTab/Usage.rb', line 155 def to_s return "Name : #{@name}" + "Price : #{@price}" + "Currency : #{@currency}" + "State : #{@state}" + "Description : #{@description}"; end |