Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Net::HTTP::get statis of a chunked response
Aníbal Rojas
12/27/2006 2:15:00 PM
Hello,
I am using a code like:
# using block
File.open('result.txt', 'w') {|f|
resp, data = http.get('/~foo/') do |str|
f.write str
end
}
To read a chunked response from a server (a large file) Docs say:
"In version 1.2, this method never raises exception."
How can I know if the transfer was Ok? Just checking the size
reported by the content-length header against the size of the file
written to disk? Or is there any other recommended way?
Thanks in advance,
--
Anibal Rojas
http://www.ruby...
http://www.hasmanydeve...
1 Answer
Ara.T.Howard
12/27/2006 2:49:00 PM
0
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Net::HTTP::get statis of a chunked response
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password