[squeak-dev] Re: [Pharo-project] A point a.k.a excuse to you

Keith Hodges keith_hodges at yahoo.co.uk
Tue Mar 3 02:16:43 UTC 2009


> build server to innovate Rio for everyone rather than just for the image
> I am using (trouble was I was using 3 different images), all I needed
> was an inclusive attitude rather than an exclusive attitude.
>   
Dear All,

I was trying to implement FileHttpExecutive in Rio today, I wanted to
perform a GET, and have Rio informed of the File size as soon as the
headers have been downloaded. As an alternative it would also be nice to
be able to send a HEAD request prior to getting the whole file. I also
want to read the stream as it is coming in, since Rio already can buffer
ftp reads direct to a file, or other destination.

About 5 minutes looking at the code showed me that this was pretty
impossible. There was no clean way to subclass HTTPSocket and have it
hold a handle on my file instance and report that information to me,
since most of the business is performed on the class side (why do people
do that?) My only option is probably to subclass HTTPSocket, inserting
some Notifications in there, and use exception handlers to collect the data.

So... would anyone out there be willing to rewrite HTTPSocket/Client
from scratch so that it is well designed and so on from the ground up?
Assuming that Socket will remain common between Squeak/Pharo etc, it
could also provide an abstraction onto the Curl plugin as well. This new
module would of course be for the benefit of all.

Has anyone done/is anyone doing this already?

thanks in advance

Keith




More information about the Squeak-dev mailing list