I want to be able to add the soap header before making the call. I
don't want to add the header in a interceptor.
For example,
JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean();
factory.getInInterceptors().add(new LoggingInInterceptor());
factory.getOutInterceptors().add(new LoggingOutInterceptor());
factory.setServiceClass(HelloWorld.class);
factory.setAddress(address);
HelloWorld hello = (HelloWOrld)factory.create();
//I want to be able to add the soap header before I make the
hello.sayhi() call
hello.sayhi();
Thanks
Sonam
-----Original Message-----
From: Daniel Kulp [mailto:[email protected]]
Sent: Thursday, January 29, 2009 2:53 PM
To: [email protected]
Cc: Nepali, Sonam (GE Healthcare, consultant)
Subject: Re: How to add soap headers?
See:
http://cxf.apache.org/faq.html#FAQ-HowcanIaddsoapheaderstotherequest%252
Fresponse%253F
Dan
On Thursday 29 January 2009 4:48:09 pm Nepali, Sonam (GE Healthcare,
consultant) wrote:
> Is there a way to programmatically add custom soap headers given the
> following code:
>
> JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean();
>
> factory.getInInterceptors().add(new LoggingInInterceptor());
>
> factory.getOutInterceptors().add(new LoggingOutInterceptor());
>
> factory.setServiceClass(ExceptionWebService.class);
>
> factory.setAddress(address);
>
> HelloWorld hello = (HelloWOrld)factory.create();
>
> hello.sayhi();
>
>
>
> thanks
>
>
>
> Sonam
--
Daniel Kulp
[email protected]
http://dankulp.com/blog