NetClients and HTTP GET/HEAD/POST

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

NetClients and HTTP GET/HEAD/POST

Holger Freyther
Hi Paolo,

I am trying to use NetClients for the SoapOpera port. I think I will want to
add custom headers and such and right now I look into unifying the
GET/HEAD/POST code in URIResolver.st. One thing I noticed is that:

HEAD/POST use  #guessMimeTypeFromResponse:
GET       uses #guessMimeType

is there a good reason that this should be different? Should I go with the
default of the GET code?

_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk
Reply | Threaded
Open this post in threaded view
|

Re: NetClients and HTTP GET/HEAD/POST

Holger Freyther
On 03/06/2011 05:57 PM, Holger Hans Peter Freyther wrote:
> Hi Paolo,

>
> is there a good reason that this should be different? Should I go with the
> default of the GET code?

Hi again,

#guessMimeType will/might inspect the file and give an accurate answer. So
this will be useful for the result of a POST and the result of a GET. The HEAD
will never have a response that could be content-sniffed.

Still this hasFile criteria could be factored somehow.


cheers
        holger

_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk