Class: JanioAPI::Order::Collection
- Inherits:
-
ActiveResource::Collection
- Object
- ActiveResource::Collection
- JanioAPI::Order::Collection
- Defined in:
- lib/janio_api/resources/order.rb
Instance Attribute Summary collapse
-
#count ⇒ Object
Returns the value of attribute count.
-
#next ⇒ Object
Returns the value of attribute next.
-
#previous ⇒ Object
Returns the value of attribute previous.
Instance Method Summary collapse
-
#initialize(parsed = {}) ⇒ Collection
constructor
A new instance of Collection.
Constructor Details
#initialize(parsed = {}) ⇒ Collection
Returns a new instance of Collection.
8 9 10 11 12 13 |
# File 'lib/janio_api/resources/order.rb', line 8 def initialize(parsed = {}) @count = parsed["count"] @next = parsed["next"] @previous = parsed["previous"] @elements = parsed["results"] end |
Instance Attribute Details
#count ⇒ Object
Returns the value of attribute count.
6 7 8 |
# File 'lib/janio_api/resources/order.rb', line 6 def count @count end |
#next ⇒ Object
Returns the value of attribute next.
6 7 8 |
# File 'lib/janio_api/resources/order.rb', line 6 def next @next end |
#previous ⇒ Object
Returns the value of attribute previous.
6 7 8 |
# File 'lib/janio_api/resources/order.rb', line 6 def previous @previous end |