Created
September 17, 2009 03:24
-
-
Save queso/188329 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def self.friend_ids(id, &blk) | |
http = EventMachine::HttpRequest.new("http://twitter.com/friends/ids/#{id}.json").get | |
http.callback { yield } | |
http.errback { raise StandardError, http.inspect } | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#<EventMachine::HttpClient:0x10100e478 @parser=#<EventMachine::HttpClientParser:0x10100e388>, @errors="", @state=:response_header, @errbacks=[], @options={}, @deferred_args=[#<EventMachine::HttpClient:0x10100e478 ...>], @inflate=[], @method="GET", @chunk_header={}, @stream=nil, @response="", @uri=#<URI::HTTP:0x10100e798 URL:http://twitter.com/friends/ids/kevinrose.json>, @response_header={}, @data=#<EventMachine::Buffer:0x10100e360>, @callbacks=[#<Proc:0x000000010118d628@./twitter-em.rb:25>], @content_decoder=nil, @deferred_status=:failed, @parser_nbytes=0, @signature="90e9a62e086207975e805c2e829bb2f82"> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment