Mike
On Monday, June 9, 2003, at 06:00 PM, Zulfi Umrani wrote:
Thanks for the info. I believe you have a HttpURLConnection class which is a wrapper on java.net.HttpURLConnection. Wouldn't that work to do POST+Authentication?
[EMAIL PROTECTED] 6/9/2003 8:51:06 PM >>>Hello again, HttpClient works differently to HttpURLConnection because despite initial impressions they do different things. If you want the ability
to change between Http libraries, you need to provide an abstraction layer in the form of a single class that handles all the HTTP stuff for
your app and then you only have to change that class when you change libraries (or implement subclasses for different libraries and use the
factory pattern).
So essentially the answer is no, unless you write a wrapper around HttpClient to map HttpURLConnection type calls to HttpClient calls. I'm not sure how much success you'll have with that. I would strongly
urge you to take some time and redesign your Http code so that it's more flexible and separate as your entire application will likely benefit as a result.
Regards,
Adrian Sutton.
On Tuesday, June 10, 2003, at 07:34 AM, Zulfi Umrani wrote:
I am trying to do POST using HttpURLConnection. Also I would like todotoBasic/Digest/NTLM Authentication at the same time. Since most of my earlier code is done using java.net.HttpURLConnection, I would like---------------------------------------------------------------------maintain the APIs such as getOutputStream(), getInputStream() and get/setHeader(). Does anyone know how can I do that using the 2.0 version?
Thanks, Zulfi
To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]