Class: Osm::Evening::EveningActivity

Inherits:
Object
  • Object
show all
Defined in:
lib/osm/evening.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ EveningActivity

Initialize a new EveningActivity using the hash returned by the API call

Parameters:

  • data

    the hash of data for the object returned by the API



116
117
118
119
120
# File 'lib/osm/evening.rb', line 116

def initialize(data)
  @activity_id = Osm::to_i_or_nil(data['activityid'])
  @title = data['title']
  @notes = data['notes']
end

Instance Attribute Details

#activity_idFixnum (readonly)

Returns the activity being done.

Returns:

  • (Fixnum)

    the activity being done



107
108
109
# File 'lib/osm/evening.rb', line 107

def activity_id
  @activity_id
end

#notesString (readonly)

Returns notes relevant to doing this activity on this evening.

Returns:

  • (String)

    notes relevant to doing this activity on this evening



107
108
109
# File 'lib/osm/evening.rb', line 107

def notes
  @notes
end

#titleString (readonly)

Returns the activity’s title.

Returns:

  • (String)

    the activity’s title



107
108
109
# File 'lib/osm/evening.rb', line 107

def title
  @title
end