On Tue, 2009-02-10 at 04:25 -0800, caffeine zombie wrote:
> If I use the same HttpClient and c executrMethod with a
> getMethod and then a postMethod, the getMethod just gets executed twice. 

your code only shows the PostMethod, there's no definition of a
getMethod. If "method" is a PostMethod, then there's no definition of a
GetMethod.
The proper way to do this is to define a GetMethod named getMethod and a
PostMethod named postMethod, then execute these.

Christine


> Here is my code, is there a way to override the getMethod so the postMethod
> gets done correctly
> 
> many thanks
> 
> 
> HttpClient client = new HttpClient();
>           client.getParams().setParameter("http.useragent", "Test Client");
>           client.getParams().setParameter("http.connection.timeout",new
> Integer(5000));
> 
> String authToken = null;
>           try {
> 
>             method.setURI(new
> URI("http://dev-integration-test.dsi.thus.net:3001/orders/new";, true));
>             int returnCode = client.executeMethod(method);
> 

-- 
dagdag is just a two-character rotation of byebye...


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to