Class: Yarel::Connection
- Inherits:
-
Object
- Object
- Yarel::Connection
- Defined in:
- lib/yarel/connection.rb
Constant Summary collapse
- END_POINT_URL =
'http://query.yahooapis.com/v1/public/yql'
Class Method Summary collapse
Class Method Details
.get(yql) ⇒ Object
5 6 7 8 |
# File 'lib/yarel/connection.rb', line 5 def self.get(yql) response = Net::HTTP.post_form(URI.parse(END_POINT_URL), { :q => yql, :format => :json }) ActiveSupport::JSON.decode response.body end |