Hi ,
You can find some programmatical ways to add the interceptors here [1]
[1] http://cwiki.apache.org/CXF20DOC/interceptors.html
Willem
John-M Baker wrote:
Hello,
While I'm a fan of Spring, I need to write an example that does not use
Spring. So I've got this far:
protected WSS4JOutInterceptor createWss4jInConfiguration(String user,
String password)
{
Map<String,Object> props = new HashMap<String,Object>();
props.put("action", "UsernameToken Timestamp");
props.put("passwordType", "PasswordDigest");
props.put("user", user);
props.put("passwordCallback", new MyPasswordCallbackHandler(password));
return new WSS4JOutInterceptor(props);
}
List interceptors = new ArrayList();
interceptors.add(new SAAJOutInterceptor());
interceptors.add(createWss4jInConfiguration("jbaker", "moo"));
How do I add the interceptors to the stub generated by CXF? ..e. I have:
Query q = new Query(url);
qPort = q.getQueryHttpport();
And I guess the interceptors need to be attached, somehow.
Thanks,
John Baker