Sha256: 2dbafd3871fe34925adf7b80c4d43d9c04861e19b6ccee0ec324b7f819230426

Contents?: true

Size: 557 Bytes

Versions: 16

Compression:

Stored size: 557 Bytes

Contents

module SportsDataApi
  module Nhl
    class Venue
      attr_reader :id, :name, :address, :city, :state, :zip, :country, :capacity
      def initialize(xml)
        xml = xml.first if xml.is_a? Nokogiri::XML::NodeSet
        if xml.is_a? Nokogiri::XML::Element
          @id = xml['id']
          @name = xml['name']
          @address = xml['address']
          @city = xml['city']
          @state = xml['state']
          @zip = xml['zip']
          @country = xml['country']
          @capacity = xml['capacity']
        end
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
sports_data_api-0.12.1 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.12.0 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.6 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.5 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.3 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.2 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.1 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.11.0 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.10.1 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.10.0 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.9.2 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.2.4 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.2.3 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.2.2 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.2.1 lib/sports_data_api/nhl/venue.rb
sports_data_api-0.2.0 lib/sports_data_api/nhl/venue.rb