Sha256: 84fcb3108bf37ac1f3cbf07d11d3662135f06c34d94b63ecd466714fca60a444
Contents?: true
Size: 650 Bytes
Versions: 6
Compression:
Stored size: 650 Bytes
Contents
module Osm class Event attr_reader :id, :section_id, :name, :start, :end, :cost, :location, :notes # Initialize a new Event using the hash returned by the API call # @param data the hash of data for the object returned by the API def initialize(data) @id = Osm::to_i_or_nil(data['eventid']) @section_id = Osm::to_i_or_nil(data['sectionid']) @name = data['name'] @start = Osm::make_datetime(data['startdate'], data['starttime']) @end = Osm::make_datetime(data['enddate'], data['endtime']) @cost = data['cost'] @location = data['location'] @notes = data['notes'] end end end
Version data entries
6 entries across 6 versions & 1 rubygems
Version | Path |
---|---|
osm-0.0.5 | lib/osm/event.rb |
osm-0.0.4 | lib/osm/event.rb |
osm-0.0.3 | lib/osm/event.rb |
osm-0.0.2 | lib/osm/event.rb |
osm-0.0.1 | lib/osm/event.rb |
osm-0.0.1.alpha | lib/osm/event.rb |