module F1Results

Constants

BASEURL
VERSION

Public Class Methods

fetch(year, country, type = :race) click to toggle source

Get results from formula1.com for a given year, country, and event type (race or qualifying)

F1Results.f1results(2010, 'australia', :qualifying)

Returns an `F1Results::Event` object which has a method `results`, which returns multiple objects of type `F1Results::Result`

# File lib/f1results.rb, line 18
def self.fetch(year, country, type = :race)
  event = Event.new(year: year, country: country, type: type)
  event.get_results
  return event
end
fetch_with_url(url) click to toggle source
# File lib/f1results.rb, line 24
def self.fetch_with_url(url)
  agent = Agent.new
  return agent.get_results_with_url(url)
end