Class: Gowalla::Stamp
Instance Attribute Summary collapse
-
#checkins_count ⇒ Object
Returns the value of attribute checkins_count.
-
#first_checkin_at ⇒ Object
Returns the value of attribute first_checkin_at.
-
#last_checkin_at ⇒ Object
Returns the value of attribute last_checkin_at.
-
#spot ⇒ Object
Returns the value of attribute spot.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ Stamp
constructor
A new instance of Stamp.
Constructor Details
#initialize(data = {}) ⇒ Stamp
Returns a new instance of Stamp.
5 6 7 8 9 10 |
# File 'lib/gowalla/stamp.rb', line 5 def initialize(data={}) @spot = Spot.new(data['spot']) @checkins_count = data['checkins_count'] @first_checkin_at = DateTime.parse(data['first_checkin_at']) @last_checkin_at = DateTime.parse(data['last_checkin_at']) end |
Instance Attribute Details
#checkins_count ⇒ Object
Returns the value of attribute checkins_count.
3 4 5 |
# File 'lib/gowalla/stamp.rb', line 3 def checkins_count @checkins_count end |
#first_checkin_at ⇒ Object
Returns the value of attribute first_checkin_at.
3 4 5 |
# File 'lib/gowalla/stamp.rb', line 3 def first_checkin_at @first_checkin_at end |
#last_checkin_at ⇒ Object
Returns the value of attribute last_checkin_at.
3 4 5 |
# File 'lib/gowalla/stamp.rb', line 3 def last_checkin_at @last_checkin_at end |
#spot ⇒ Object
Returns the value of attribute spot.
3 4 5 |
# File 'lib/gowalla/stamp.rb', line 3 def spot @spot end |