Sha256: a19b1bd67d8d446524d46ba0750a5b8647c0ed80da1af04f1eb2788c757016d0

Contents?: true

Size: 595 Bytes

Versions: 2

Compression:

Stored size: 595 Bytes

Contents

module Rockstar
  class Geo < Base
    # Get events in a specific location. Opts can be
    #
    # * :location => 'madrid'  # A city name from geo.metros
    # * :lat => 50.0, :long => 14.0 # A geo point
    #
    # Additionally you can set the distance from that point with
    #   :distance => 50 # 50 km from the given location
    #
    def events(opts = {}, force = false)
      get_instance("geo.getEvents", :events, :event, opts, force)
    end

    def metros(country, force = false)
      get_instance("geo.getMetros", :metros, :metro, {:country => country}, force)
    end

  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rockstar-0.7.0 lib/rockstar/geo.rb
rockstar-0.6.4 lib/rockstar/geo.rb