Class: App42::AppTab::Time
- Inherits:
-
Object
- Object
- App42::AppTab::Time
- 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.
-
#state ⇒ Object
Returns the value of attribute state.
-
#time ⇒ Object
Returns the value of attribute time.
-
#unit ⇒ Object
Returns the value of attribute unit.
-
#user ⇒ Object
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(usage) ⇒ Time
constructor
This is a constructor that takes no parameter.
-
#to_s ⇒ Object
Returns the Usage Response in JSON format.
Constructor Details
#initialize(usage) ⇒ Time
This is a constructor that takes no parameter
174 175 176 |
# File 'lib/appTab/Usage.rb', line 174 def initialize(usage) usage.timeList.push(self) end |
Instance Attribute Details
#currency ⇒ Object
Returns the value of attribute currency.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def currency @currency end |
#description ⇒ Object
Returns the value of attribute description.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def description @description end |
#name ⇒ Object
Returns the value of attribute name.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def name @name end |
#price ⇒ Object
Returns the value of attribute price.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def price @price end |
#state ⇒ Object
Returns the value of attribute state.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def state @state end |
#time ⇒ Object
Returns the value of attribute time.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def time @time end |
#unit ⇒ Object
Returns the value of attribute unit.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def unit @unit end |
#user ⇒ Object
Returns the value of attribute user.
162 163 164 |
# File 'lib/appTab/Usage.rb', line 162 def user @user end |
Instance Method Details
#to_s ⇒ Object
Returns the Usage Response in JSON format.
184 185 186 |
# File 'lib/appTab/Usage.rb', line 184 def to_s return "Name : #{@name}" + "Price : #{@price}" + "Currency : #{@currency}" + "State : #{@state}" + "Description : #{@description}"; end |