hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Kalnichevski <ol...@apache.org>
Subject Re: How to get cookies that are about to be sent?
Date Tue, 17 Apr 2012 09:54:26 GMT
On Tue, Apr 17, 2012 at 11:35:21AM +0200, tommmmmm wrote:
> One more thing,
> http://hc.apache.org/httpcomponents-client-ga/tutorial/html/index.html
> says and I quote: 4.1.3
> 
> http://hc.apache.org/httpcomponents-client-ga/tutorial/html/statemgmt.html#d5e816
> says
> and I quote:
> 
> 
> httpclient.setCookieStore(cookieStore);
> 
> And that method doesn't exit in HttpClient at all. So the official tutorial
> itself is wrong. And yes I triple checked it I am using 4.1.3 not 4.1.2 or
> anything like that.
> 
> 


Ahhh. Not again.

http://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/org/apache/http/impl/client/AbstractHttpClient.html#setCookieStore%28org.apache.http.client.CookieStore%29

Oleg


> On 17 April 2012 11:30, tommmmmm <tommmmmm@gmail.com> wrote:
> 
> >
> >
> > On 17 April 2012 11:28, tommmmmm <tommmmmm@gmail.com> wrote:
> >
> >> How to get cookies that are about to be sent?
> >>
> >> I read
> >> http://hc.apache.org/httpcomponents-client-ga/tutorial/html/statemgmt.html
> >> Nothing there. Only how to get cookies from the execution. And I am not
> >> interested in that. I want to get cookies before execution.
> >>
> >> I found some topics on stack overflow but getCookieStore
> >>  method simply doesn't exist.
> >>
> >> Any ideas?
> >>
> >> --
> >> Tomasz P.
> >>
> >>
> > I also found a solution with client.getState().getCookies();
> >
> > http://www.java2s.com/Code/Java/Apache-Common/GetCookievalueandsetcookievalue.htm
> >
> > However the method getState doesn't exist at all....
> >
> > All the good methods are gone in 4.x ?
> >
> 
> 
> 
> -- 
> Tomasz P.

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org


Mime
View raw message