Class: GovKit::VoteSmart::BillCategory

Inherits:
GovKit::VoteSmartResource show all
Defined in:
lib/gov_kit/vote_smart.rb

Instance Attribute Summary

Attributes inherited from Resource

#attributes, #raw_response

Class Method Summary collapse

Methods inherited from Resource

#initialize, instantiate, instantiate_collection, parse, #to_md5, #unload

Constructor Details

This class inherits a constructor from GovKit::Resource

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class GovKit::Resource

Class Method Details

.find(year, state_abbrev) ⇒ Object



103
104
105
106
# File 'lib/gov_kit/vote_smart.rb', line 103

def self.find(year, state_abbrev)
  response = get("/Votes.getCategories", :query => {'year' => year, 'stateId' => state_abbrev})
  parse(response['categories']['category'])
end